Skip to main content

nominal_api_proto/proto/
nominal.datasets.v1.rs

1// This file is @generated by prost-build.
2#[derive(Clone, PartialEq, ::prost::Message)]
3pub struct DatasetFile {
4    #[prost(string, tag = "1")]
5    pub id: ::prost::alloc::string::String,
6    #[prost(string, tag = "2")]
7    pub dataset_rid: ::prost::alloc::string::String,
8    #[prost(string, tag = "3")]
9    pub name: ::prost::alloc::string::String,
10    #[prost(message, optional, tag = "4")]
11    pub handle: ::core::option::Option<super::super::types::object_storage::Handle>,
12    #[prost(int64, optional, tag = "5")]
13    pub size_bytes: ::core::option::Option<i64>,
14    #[prost(message, optional, tag = "6")]
15    pub bounds: ::core::option::Option<DataBounds>,
16    #[prost(message, optional, tag = "7")]
17    pub uploaded_at: ::core::option::Option<
18        super::super::super::google::protobuf::Timestamp,
19    >,
20    #[prost(message, optional, tag = "8")]
21    pub ingested_at: ::core::option::Option<
22        super::super::super::google::protobuf::Timestamp,
23    >,
24    #[prost(message, optional, tag = "9")]
25    pub ingest_status: ::core::option::Option<IngestStatus>,
26    #[prost(message, optional, tag = "10")]
27    pub timestamp_metadata: ::core::option::Option<
28        super::super::ingest::v2::TimestampMetadata,
29    >,
30    #[prost(message, optional, tag = "11")]
31    pub ingest_tag_metadata: ::core::option::Option<IngestTagMetadata>,
32    #[prost(string, repeated, tag = "12")]
33    pub origin_file_paths: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
34    #[prost(string, optional, tag = "13")]
35    pub ingest_job_rid: ::core::option::Option<::prost::alloc::string::String>,
36    #[prost(string, optional, tag = "14")]
37    pub ingest_transform_rid: ::core::option::Option<::prost::alloc::string::String>,
38    #[prost(message, optional, tag = "15")]
39    pub deleted_at: ::core::option::Option<
40        super::super::super::google::protobuf::Timestamp,
41    >,
42    #[prost(message, optional, tag = "16")]
43    pub metadata: ::core::option::Option<DatasetFileMetadata>,
44}
45#[derive(Clone, Copy, PartialEq, ::prost::Message)]
46pub struct DataBounds {
47    #[prost(message, optional, tag = "1")]
48    pub start: ::core::option::Option<super::super::super::google::protobuf::Timestamp>,
49    #[prost(message, optional, tag = "2")]
50    pub end: ::core::option::Option<super::super::super::google::protobuf::Timestamp>,
51    #[prost(enumeration = "TimeBase", tag = "3")]
52    pub time_base: i32,
53}
54#[derive(Clone, PartialEq, ::prost::Message)]
55pub struct IngestStatus {
56    #[prost(oneof = "ingest_status::Status", tags = "1, 2, 3, 4, 5")]
57    pub status: ::core::option::Option<ingest_status::Status>,
58}
59/// Nested message and enum types in `IngestStatus`.
60pub mod ingest_status {
61    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
62    pub struct Succeeded {}
63    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
64    pub struct DeletionInProgress {}
65    #[derive(Clone, Copy, PartialEq, ::prost::Message)]
66    pub struct Deleted {}
67    #[derive(Clone, PartialEq, ::prost::Oneof)]
68    pub enum Status {
69        #[prost(message, tag = "1")]
70        Succeeded(Succeeded),
71        #[prost(message, tag = "2")]
72        Failed(super::IngestFailed),
73        #[prost(message, tag = "3")]
74        InProgress(super::IngestInProgress),
75        #[prost(message, tag = "4")]
76        DeletionInProgress(DeletionInProgress),
77        #[prost(message, tag = "5")]
78        Deleted(Deleted),
79    }
80}
81#[derive(Clone, PartialEq, ::prost::Message)]
82pub struct IngestFailed {
83    #[prost(string, tag = "1")]
84    pub error_type: ::prost::alloc::string::String,
85    #[prost(string, tag = "2")]
86    pub message: ::prost::alloc::string::String,
87    #[prost(string, optional, tag = "3")]
88    pub error_instance_id: ::core::option::Option<::prost::alloc::string::String>,
89}
90#[derive(Clone, Copy, PartialEq, ::prost::Message)]
91pub struct IngestInProgress {
92    #[prost(enumeration = "IngestPhase", tag = "1")]
93    pub phase: i32,
94    #[prost(double, optional, tag = "2")]
95    pub progress: ::core::option::Option<f64>,
96}
97#[derive(Clone, PartialEq, ::prost::Message)]
98pub struct IngestTagMetadata {
99    #[prost(map = "string, string", tag = "1")]
100    pub tag_columns: ::std::collections::HashMap<
101        ::prost::alloc::string::String,
102        ::prost::alloc::string::String,
103    >,
104    #[prost(map = "string, string", tag = "2")]
105    pub additional_file_tags: ::std::collections::HashMap<
106        ::prost::alloc::string::String,
107        ::prost::alloc::string::String,
108    >,
109}
110#[derive(Clone, PartialEq, ::prost::Message)]
111pub struct DatasetFileMetadata {
112    #[prost(oneof = "dataset_file_metadata::Metadata", tags = "1")]
113    pub metadata: ::core::option::Option<dataset_file_metadata::Metadata>,
114}
115/// Nested message and enum types in `DatasetFileMetadata`.
116pub mod dataset_file_metadata {
117    #[derive(Clone, PartialEq, ::prost::Oneof)]
118    pub enum Metadata {
119        #[prost(message, tag = "1")]
120        Video(super::VideoFileMetadata),
121    }
122}
123#[derive(Clone, PartialEq, ::prost::Message)]
124pub struct VideoFileMetadata {
125    #[prost(message, optional, tag = "1")]
126    pub timestamp_manifest: ::core::option::Option<
127        super::super::ingest::v2::VideoTimestampManifest,
128    >,
129    #[prost(message, optional, tag = "2")]
130    pub segments_summary: ::core::option::Option<VideoSegmentsSummary>,
131}
132#[derive(Clone, Copy, PartialEq, ::prost::Message)]
133pub struct VideoSegmentsSummary {
134    #[prost(int32, tag = "1")]
135    pub frame_count: i32,
136    #[prost(int32, tag = "2")]
137    pub segment_count: i32,
138    #[prost(double, tag = "3")]
139    pub scale_factor: f64,
140    #[prost(double, tag = "4")]
141    pub media_duration_seconds: f64,
142    #[prost(double, tag = "5")]
143    pub media_frame_rate: f64,
144}
145#[derive(Clone, PartialEq, ::prost::Message)]
146pub struct GetDatasetFileRequest {
147    #[prost(string, tag = "1")]
148    pub dataset_rid: ::prost::alloc::string::String,
149    #[prost(string, tag = "2")]
150    pub file_id: ::prost::alloc::string::String,
151}
152#[derive(Clone, PartialEq, ::prost::Message)]
153pub struct GetDatasetFileResponse {
154    #[prost(message, optional, tag = "1")]
155    pub dataset_file: ::core::option::Option<DatasetFile>,
156}
157#[derive(Clone, PartialEq, ::prost::Message)]
158pub struct BatchGetDatasetFilesRequest {
159    #[prost(string, tag = "1")]
160    pub dataset_rid: ::prost::alloc::string::String,
161    #[prost(string, repeated, tag = "2")]
162    pub file_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
163}
164#[derive(Clone, PartialEq, ::prost::Message)]
165pub struct BatchGetDatasetFilesResponse {
166    #[prost(message, repeated, tag = "1")]
167    pub dataset_files: ::prost::alloc::vec::Vec<DatasetFile>,
168}
169#[derive(Clone, PartialEq, ::prost::Message)]
170pub struct ListDatasetFilesRequest {
171    #[prost(string, tag = "1")]
172    pub dataset_rid: ::prost::alloc::string::String,
173    #[prost(int32, optional, tag = "2")]
174    pub page_size: ::core::option::Option<i32>,
175    #[prost(string, tag = "3")]
176    pub page_token: ::prost::alloc::string::String,
177}
178#[derive(Clone, PartialEq, ::prost::Message)]
179pub struct ListDatasetFilesResponse {
180    #[prost(message, repeated, tag = "1")]
181    pub dataset_files: ::prost::alloc::vec::Vec<DatasetFile>,
182    #[prost(string, tag = "2")]
183    pub next_page_token: ::prost::alloc::string::String,
184}
185#[derive(Clone, PartialEq, ::prost::Message)]
186pub struct SearchDatasetFilesRequest {
187    #[prost(string, tag = "1")]
188    pub dataset_rid: ::prost::alloc::string::String,
189    #[prost(message, optional, tag = "2")]
190    pub query: ::core::option::Option<DatasetFileQuery>,
191    #[prost(int32, optional, tag = "3")]
192    pub page_size: ::core::option::Option<i32>,
193    #[prost(string, tag = "4")]
194    pub page_token: ::prost::alloc::string::String,
195    #[prost(message, optional, tag = "5")]
196    pub sort: ::core::option::Option<DatasetFileSort>,
197}
198#[derive(Clone, PartialEq, ::prost::Message)]
199pub struct SearchDatasetFilesResponse {
200    #[prost(message, repeated, tag = "1")]
201    pub dataset_files: ::prost::alloc::vec::Vec<DatasetFile>,
202    #[prost(string, tag = "2")]
203    pub next_page_token: ::prost::alloc::string::String,
204}
205#[derive(Clone, PartialEq, ::prost::Message)]
206pub struct DatasetFileQuery {
207    #[prost(oneof = "dataset_file_query::Query", tags = "1, 2, 3, 4, 5")]
208    pub query: ::core::option::Option<dataset_file_query::Query>,
209}
210/// Nested message and enum types in `DatasetFileQuery`.
211pub mod dataset_file_query {
212    #[derive(Clone, PartialEq, ::prost::Oneof)]
213    pub enum Query {
214        #[prost(message, tag = "1")]
215        DataTimeRange(super::TimeRangeFilter),
216        #[prost(message, tag = "2")]
217        UploadedAtRange(super::TimeRangeFilter),
218        #[prost(message, tag = "3")]
219        AdditionalFileTags(super::FileTagFilter),
220        #[prost(message, tag = "4")]
221        And(super::DatasetFileQueryList),
222        #[prost(message, tag = "5")]
223        Or(super::DatasetFileQueryList),
224    }
225}
226#[derive(Clone, Copy, PartialEq, ::prost::Message)]
227pub struct TimeRangeFilter {
228    #[prost(message, optional, tag = "1")]
229    pub start: ::core::option::Option<super::super::super::google::protobuf::Timestamp>,
230    #[prost(message, optional, tag = "2")]
231    pub end: ::core::option::Option<super::super::super::google::protobuf::Timestamp>,
232}
233#[derive(Clone, PartialEq, ::prost::Message)]
234pub struct FileTagFilter {
235    #[prost(map = "string, string", tag = "1")]
236    pub tags: ::std::collections::HashMap<
237        ::prost::alloc::string::String,
238        ::prost::alloc::string::String,
239    >,
240}
241#[derive(Clone, PartialEq, ::prost::Message)]
242pub struct DatasetFileQueryList {
243    #[prost(message, repeated, tag = "1")]
244    pub queries: ::prost::alloc::vec::Vec<DatasetFileQuery>,
245}
246#[derive(Clone, Copy, PartialEq, ::prost::Message)]
247pub struct DatasetFileSort {
248    #[prost(enumeration = "DatasetFileSortField", tag = "1")]
249    pub field: i32,
250    #[prost(bool, tag = "2")]
251    pub descending: bool,
252}
253#[derive(Clone, PartialEq, ::prost::Message)]
254pub struct ListIngestJobDatasetFilesRequest {
255    #[prost(string, tag = "1")]
256    pub ingest_job_rid: ::prost::alloc::string::String,
257    #[prost(int32, optional, tag = "2")]
258    pub page_size: ::core::option::Option<i32>,
259    #[prost(string, tag = "3")]
260    pub page_token: ::prost::alloc::string::String,
261}
262#[derive(Clone, PartialEq, ::prost::Message)]
263pub struct ListIngestJobDatasetFilesResponse {
264    #[prost(message, repeated, tag = "1")]
265    pub dataset_files: ::prost::alloc::vec::Vec<DatasetFile>,
266    #[prost(string, tag = "2")]
267    pub next_page_token: ::prost::alloc::string::String,
268}
269#[derive(Clone, PartialEq, ::prost::Message)]
270pub struct GetDatasetFileDownloadUriRequest {
271    #[prost(string, tag = "1")]
272    pub dataset_rid: ::prost::alloc::string::String,
273    #[prost(string, tag = "2")]
274    pub file_id: ::prost::alloc::string::String,
275}
276#[derive(Clone, PartialEq, ::prost::Message)]
277pub struct GetDatasetFileDownloadUriResponse {
278    #[prost(string, tag = "1")]
279    pub uri: ::prost::alloc::string::String,
280}
281#[derive(Clone, PartialEq, ::prost::Message)]
282pub struct ListDatasetFileOriginUrisRequest {
283    #[prost(string, tag = "1")]
284    pub dataset_rid: ::prost::alloc::string::String,
285    #[prost(string, tag = "2")]
286    pub file_id: ::prost::alloc::string::String,
287    #[prost(int32, optional, tag = "3")]
288    pub page_size: ::core::option::Option<i32>,
289    #[prost(string, tag = "4")]
290    pub page_token: ::prost::alloc::string::String,
291}
292#[derive(Clone, PartialEq, ::prost::Message)]
293pub struct ListDatasetFileOriginUrisResponse {
294    #[prost(message, repeated, tag = "1")]
295    pub origin_file_uris: ::prost::alloc::vec::Vec<OriginFileUri>,
296    #[prost(string, tag = "2")]
297    pub next_page_token: ::prost::alloc::string::String,
298}
299#[derive(Clone, PartialEq, ::prost::Message)]
300pub struct OriginFileUri {
301    #[prost(string, tag = "1")]
302    pub path: ::prost::alloc::string::String,
303    #[prost(string, tag = "2")]
304    pub uri: ::prost::alloc::string::String,
305}
306#[derive(Clone, PartialEq, ::prost::Message)]
307pub struct CreateDatasetFileRequest {
308    #[prost(string, tag = "1")]
309    pub dataset_rid: ::prost::alloc::string::String,
310    #[prost(message, optional, tag = "2")]
311    pub handle: ::core::option::Option<super::super::types::object_storage::Handle>,
312    #[prost(int64, tag = "3")]
313    pub size_bytes: i64,
314    #[prost(message, optional, tag = "4")]
315    pub timestamp_metadata: ::core::option::Option<
316        super::super::ingest::v2::TimestampMetadata,
317    >,
318    #[prost(message, optional, tag = "5")]
319    pub ingest_tag_metadata: ::core::option::Option<IngestTagMetadata>,
320    #[prost(message, repeated, tag = "6")]
321    pub origin_files: ::prost::alloc::vec::Vec<
322        super::super::types::object_storage::Handle,
323    >,
324    #[prost(string, optional, tag = "7")]
325    pub ingest_job_rid: ::core::option::Option<::prost::alloc::string::String>,
326    #[prost(message, optional, tag = "8")]
327    pub metadata: ::core::option::Option<DatasetFileMetadata>,
328}
329#[derive(Clone, PartialEq, ::prost::Message)]
330pub struct CreateDatasetFileResponse {
331    #[prost(message, optional, tag = "1")]
332    pub dataset_file: ::core::option::Option<DatasetFile>,
333}
334#[derive(Clone, PartialEq, ::prost::Message)]
335pub struct CompleteDatasetFileIngestRequest {
336    #[prost(string, tag = "1")]
337    pub dataset_rid: ::prost::alloc::string::String,
338    #[prost(string, tag = "2")]
339    pub file_id: ::prost::alloc::string::String,
340    #[prost(message, optional, tag = "3")]
341    pub bounds: ::core::option::Option<DataBounds>,
342    #[prost(message, optional, tag = "4")]
343    pub ingested_at: ::core::option::Option<
344        super::super::super::google::protobuf::Timestamp,
345    >,
346}
347#[derive(Clone, PartialEq, ::prost::Message)]
348pub struct CompleteDatasetFileIngestResponse {
349    #[prost(message, optional, tag = "1")]
350    pub dataset_file: ::core::option::Option<DatasetFile>,
351}
352#[derive(Clone, PartialEq, ::prost::Message)]
353pub struct UpdateDatasetFileIngestStatusRequest {
354    #[prost(string, tag = "1")]
355    pub dataset_rid: ::prost::alloc::string::String,
356    #[prost(string, tag = "2")]
357    pub file_id: ::prost::alloc::string::String,
358    #[prost(message, optional, tag = "3")]
359    pub ingest_status: ::core::option::Option<IngestStatus>,
360}
361#[derive(Clone, PartialEq, ::prost::Message)]
362pub struct UpdateDatasetFileIngestStatusResponse {
363    #[prost(message, optional, tag = "1")]
364    pub dataset_file: ::core::option::Option<DatasetFile>,
365}
366#[derive(Clone, PartialEq, ::prost::Message)]
367pub struct UpdateDatasetFileMetadataRequest {
368    #[prost(string, tag = "1")]
369    pub dataset_rid: ::prost::alloc::string::String,
370    #[prost(string, tag = "2")]
371    pub file_id: ::prost::alloc::string::String,
372    #[prost(message, optional, tag = "3")]
373    pub metadata: ::core::option::Option<DatasetFileMetadata>,
374}
375#[derive(Clone, PartialEq, ::prost::Message)]
376pub struct UpdateDatasetFileMetadataResponse {
377    #[prost(message, optional, tag = "1")]
378    pub dataset_file: ::core::option::Option<DatasetFile>,
379}
380#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
381#[repr(i32)]
382pub enum DatasetFileError {
383    InvalidRequest = 0,
384}
385impl DatasetFileError {
386    /// String value of the enum field names used in the ProtoBuf definition.
387    ///
388    /// The values are not transformed in any way and thus are considered stable
389    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
390    pub fn as_str_name(&self) -> &'static str {
391        match self {
392            Self::InvalidRequest => "DATASET_FILE_ERROR_INVALID_REQUEST",
393        }
394    }
395    /// Creates an enum from field names used in the ProtoBuf definition.
396    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
397        match value {
398            "DATASET_FILE_ERROR_INVALID_REQUEST" => Some(Self::InvalidRequest),
399            _ => None,
400        }
401    }
402}
403#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
404#[repr(i32)]
405pub enum TimeBase {
406    Unspecified = 0,
407    Absolute = 1,
408    Relative = 2,
409}
410impl TimeBase {
411    /// String value of the enum field names used in the ProtoBuf definition.
412    ///
413    /// The values are not transformed in any way and thus are considered stable
414    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
415    pub fn as_str_name(&self) -> &'static str {
416        match self {
417            Self::Unspecified => "TIME_BASE_UNSPECIFIED",
418            Self::Absolute => "TIME_BASE_ABSOLUTE",
419            Self::Relative => "TIME_BASE_RELATIVE",
420        }
421    }
422    /// Creates an enum from field names used in the ProtoBuf definition.
423    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
424        match value {
425            "TIME_BASE_UNSPECIFIED" => Some(Self::Unspecified),
426            "TIME_BASE_ABSOLUTE" => Some(Self::Absolute),
427            "TIME_BASE_RELATIVE" => Some(Self::Relative),
428            _ => None,
429        }
430    }
431}
432#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
433#[repr(i32)]
434pub enum IngestPhase {
435    Unspecified = 0,
436    Queued = 1,
437    Parsing = 2,
438    Ingesting = 3,
439}
440impl IngestPhase {
441    /// String value of the enum field names used in the ProtoBuf definition.
442    ///
443    /// The values are not transformed in any way and thus are considered stable
444    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
445    pub fn as_str_name(&self) -> &'static str {
446        match self {
447            Self::Unspecified => "INGEST_PHASE_UNSPECIFIED",
448            Self::Queued => "INGEST_PHASE_QUEUED",
449            Self::Parsing => "INGEST_PHASE_PARSING",
450            Self::Ingesting => "INGEST_PHASE_INGESTING",
451        }
452    }
453    /// Creates an enum from field names used in the ProtoBuf definition.
454    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
455        match value {
456            "INGEST_PHASE_UNSPECIFIED" => Some(Self::Unspecified),
457            "INGEST_PHASE_QUEUED" => Some(Self::Queued),
458            "INGEST_PHASE_PARSING" => Some(Self::Parsing),
459            "INGEST_PHASE_INGESTING" => Some(Self::Ingesting),
460            _ => None,
461        }
462    }
463}
464#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
465#[repr(i32)]
466pub enum DatasetFileSortField {
467    Unspecified = 0,
468    UploadedAt = 1,
469}
470impl DatasetFileSortField {
471    /// String value of the enum field names used in the ProtoBuf definition.
472    ///
473    /// The values are not transformed in any way and thus are considered stable
474    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
475    pub fn as_str_name(&self) -> &'static str {
476        match self {
477            Self::Unspecified => "DATASET_FILE_SORT_FIELD_UNSPECIFIED",
478            Self::UploadedAt => "DATASET_FILE_SORT_FIELD_UPLOADED_AT",
479        }
480    }
481    /// Creates an enum from field names used in the ProtoBuf definition.
482    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
483        match value {
484            "DATASET_FILE_SORT_FIELD_UNSPECIFIED" => Some(Self::Unspecified),
485            "DATASET_FILE_SORT_FIELD_UPLOADED_AT" => Some(Self::UploadedAt),
486            _ => None,
487        }
488    }
489}
490/// Generated client implementations.
491pub mod dataset_file_service_client {
492    #![allow(
493        unused_variables,
494        dead_code,
495        missing_docs,
496        clippy::wildcard_imports,
497        clippy::let_unit_value,
498    )]
499    use tonic::codegen::*;
500    use tonic::codegen::http::Uri;
501    #[derive(Debug, Clone)]
502    pub struct DatasetFileServiceClient<T> {
503        inner: tonic::client::Grpc<T>,
504    }
505    impl DatasetFileServiceClient<tonic::transport::Channel> {
506        /// Attempt to create a new client by connecting to a given endpoint.
507        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
508        where
509            D: TryInto<tonic::transport::Endpoint>,
510            D::Error: Into<StdError>,
511        {
512            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
513            Ok(Self::new(conn))
514        }
515    }
516    impl<T> DatasetFileServiceClient<T>
517    where
518        T: tonic::client::GrpcService<tonic::body::Body>,
519        T::Error: Into<StdError>,
520        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
521        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
522    {
523        pub fn new(inner: T) -> Self {
524            let inner = tonic::client::Grpc::new(inner);
525            Self { inner }
526        }
527        pub fn with_origin(inner: T, origin: Uri) -> Self {
528            let inner = tonic::client::Grpc::with_origin(inner, origin);
529            Self { inner }
530        }
531        pub fn with_interceptor<F>(
532            inner: T,
533            interceptor: F,
534        ) -> DatasetFileServiceClient<InterceptedService<T, F>>
535        where
536            F: tonic::service::Interceptor,
537            T::ResponseBody: Default,
538            T: tonic::codegen::Service<
539                http::Request<tonic::body::Body>,
540                Response = http::Response<
541                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
542                >,
543            >,
544            <T as tonic::codegen::Service<
545                http::Request<tonic::body::Body>,
546            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
547        {
548            DatasetFileServiceClient::new(InterceptedService::new(inner, interceptor))
549        }
550        /// Compress requests with the given encoding.
551        ///
552        /// This requires the server to support it otherwise it might respond with an
553        /// error.
554        #[must_use]
555        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
556            self.inner = self.inner.send_compressed(encoding);
557            self
558        }
559        /// Enable decompressing responses.
560        #[must_use]
561        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
562            self.inner = self.inner.accept_compressed(encoding);
563            self
564        }
565        /// Limits the maximum size of a decoded message.
566        ///
567        /// Default: `4MB`
568        #[must_use]
569        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
570            self.inner = self.inner.max_decoding_message_size(limit);
571            self
572        }
573        /// Limits the maximum size of an encoded message.
574        ///
575        /// Default: `usize::MAX`
576        #[must_use]
577        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
578            self.inner = self.inner.max_encoding_message_size(limit);
579            self
580        }
581        pub async fn get_dataset_file(
582            &mut self,
583            request: impl tonic::IntoRequest<super::GetDatasetFileRequest>,
584        ) -> std::result::Result<
585            tonic::Response<super::GetDatasetFileResponse>,
586            tonic::Status,
587        > {
588            self.inner
589                .ready()
590                .await
591                .map_err(|e| {
592                    tonic::Status::unknown(
593                        format!("Service was not ready: {}", e.into()),
594                    )
595                })?;
596            let codec = tonic::codec::ProstCodec::default();
597            let path = http::uri::PathAndQuery::from_static(
598                "/nominal.datasets.v1.DatasetFileService/GetDatasetFile",
599            );
600            let mut req = request.into_request();
601            req.extensions_mut()
602                .insert(
603                    GrpcMethod::new(
604                        "nominal.datasets.v1.DatasetFileService",
605                        "GetDatasetFile",
606                    ),
607                );
608            self.inner.unary(req, path, codec).await
609        }
610        pub async fn batch_get_dataset_files(
611            &mut self,
612            request: impl tonic::IntoRequest<super::BatchGetDatasetFilesRequest>,
613        ) -> std::result::Result<
614            tonic::Response<super::BatchGetDatasetFilesResponse>,
615            tonic::Status,
616        > {
617            self.inner
618                .ready()
619                .await
620                .map_err(|e| {
621                    tonic::Status::unknown(
622                        format!("Service was not ready: {}", e.into()),
623                    )
624                })?;
625            let codec = tonic::codec::ProstCodec::default();
626            let path = http::uri::PathAndQuery::from_static(
627                "/nominal.datasets.v1.DatasetFileService/BatchGetDatasetFiles",
628            );
629            let mut req = request.into_request();
630            req.extensions_mut()
631                .insert(
632                    GrpcMethod::new(
633                        "nominal.datasets.v1.DatasetFileService",
634                        "BatchGetDatasetFiles",
635                    ),
636                );
637            self.inner.unary(req, path, codec).await
638        }
639        pub async fn list_dataset_files(
640            &mut self,
641            request: impl tonic::IntoRequest<super::ListDatasetFilesRequest>,
642        ) -> std::result::Result<
643            tonic::Response<super::ListDatasetFilesResponse>,
644            tonic::Status,
645        > {
646            self.inner
647                .ready()
648                .await
649                .map_err(|e| {
650                    tonic::Status::unknown(
651                        format!("Service was not ready: {}", e.into()),
652                    )
653                })?;
654            let codec = tonic::codec::ProstCodec::default();
655            let path = http::uri::PathAndQuery::from_static(
656                "/nominal.datasets.v1.DatasetFileService/ListDatasetFiles",
657            );
658            let mut req = request.into_request();
659            req.extensions_mut()
660                .insert(
661                    GrpcMethod::new(
662                        "nominal.datasets.v1.DatasetFileService",
663                        "ListDatasetFiles",
664                    ),
665                );
666            self.inner.unary(req, path, codec).await
667        }
668        pub async fn search_dataset_files(
669            &mut self,
670            request: impl tonic::IntoRequest<super::SearchDatasetFilesRequest>,
671        ) -> std::result::Result<
672            tonic::Response<super::SearchDatasetFilesResponse>,
673            tonic::Status,
674        > {
675            self.inner
676                .ready()
677                .await
678                .map_err(|e| {
679                    tonic::Status::unknown(
680                        format!("Service was not ready: {}", e.into()),
681                    )
682                })?;
683            let codec = tonic::codec::ProstCodec::default();
684            let path = http::uri::PathAndQuery::from_static(
685                "/nominal.datasets.v1.DatasetFileService/SearchDatasetFiles",
686            );
687            let mut req = request.into_request();
688            req.extensions_mut()
689                .insert(
690                    GrpcMethod::new(
691                        "nominal.datasets.v1.DatasetFileService",
692                        "SearchDatasetFiles",
693                    ),
694                );
695            self.inner.unary(req, path, codec).await
696        }
697        pub async fn list_ingest_job_dataset_files(
698            &mut self,
699            request: impl tonic::IntoRequest<super::ListIngestJobDatasetFilesRequest>,
700        ) -> std::result::Result<
701            tonic::Response<super::ListIngestJobDatasetFilesResponse>,
702            tonic::Status,
703        > {
704            self.inner
705                .ready()
706                .await
707                .map_err(|e| {
708                    tonic::Status::unknown(
709                        format!("Service was not ready: {}", e.into()),
710                    )
711                })?;
712            let codec = tonic::codec::ProstCodec::default();
713            let path = http::uri::PathAndQuery::from_static(
714                "/nominal.datasets.v1.DatasetFileService/ListIngestJobDatasetFiles",
715            );
716            let mut req = request.into_request();
717            req.extensions_mut()
718                .insert(
719                    GrpcMethod::new(
720                        "nominal.datasets.v1.DatasetFileService",
721                        "ListIngestJobDatasetFiles",
722                    ),
723                );
724            self.inner.unary(req, path, codec).await
725        }
726        pub async fn get_dataset_file_download_uri(
727            &mut self,
728            request: impl tonic::IntoRequest<super::GetDatasetFileDownloadUriRequest>,
729        ) -> std::result::Result<
730            tonic::Response<super::GetDatasetFileDownloadUriResponse>,
731            tonic::Status,
732        > {
733            self.inner
734                .ready()
735                .await
736                .map_err(|e| {
737                    tonic::Status::unknown(
738                        format!("Service was not ready: {}", e.into()),
739                    )
740                })?;
741            let codec = tonic::codec::ProstCodec::default();
742            let path = http::uri::PathAndQuery::from_static(
743                "/nominal.datasets.v1.DatasetFileService/GetDatasetFileDownloadUri",
744            );
745            let mut req = request.into_request();
746            req.extensions_mut()
747                .insert(
748                    GrpcMethod::new(
749                        "nominal.datasets.v1.DatasetFileService",
750                        "GetDatasetFileDownloadUri",
751                    ),
752                );
753            self.inner.unary(req, path, codec).await
754        }
755        pub async fn list_dataset_file_origin_uris(
756            &mut self,
757            request: impl tonic::IntoRequest<super::ListDatasetFileOriginUrisRequest>,
758        ) -> std::result::Result<
759            tonic::Response<super::ListDatasetFileOriginUrisResponse>,
760            tonic::Status,
761        > {
762            self.inner
763                .ready()
764                .await
765                .map_err(|e| {
766                    tonic::Status::unknown(
767                        format!("Service was not ready: {}", e.into()),
768                    )
769                })?;
770            let codec = tonic::codec::ProstCodec::default();
771            let path = http::uri::PathAndQuery::from_static(
772                "/nominal.datasets.v1.DatasetFileService/ListDatasetFileOriginUris",
773            );
774            let mut req = request.into_request();
775            req.extensions_mut()
776                .insert(
777                    GrpcMethod::new(
778                        "nominal.datasets.v1.DatasetFileService",
779                        "ListDatasetFileOriginUris",
780                    ),
781                );
782            self.inner.unary(req, path, codec).await
783        }
784        pub async fn create_dataset_file(
785            &mut self,
786            request: impl tonic::IntoRequest<super::CreateDatasetFileRequest>,
787        ) -> std::result::Result<
788            tonic::Response<super::CreateDatasetFileResponse>,
789            tonic::Status,
790        > {
791            self.inner
792                .ready()
793                .await
794                .map_err(|e| {
795                    tonic::Status::unknown(
796                        format!("Service was not ready: {}", e.into()),
797                    )
798                })?;
799            let codec = tonic::codec::ProstCodec::default();
800            let path = http::uri::PathAndQuery::from_static(
801                "/nominal.datasets.v1.DatasetFileService/CreateDatasetFile",
802            );
803            let mut req = request.into_request();
804            req.extensions_mut()
805                .insert(
806                    GrpcMethod::new(
807                        "nominal.datasets.v1.DatasetFileService",
808                        "CreateDatasetFile",
809                    ),
810                );
811            self.inner.unary(req, path, codec).await
812        }
813        pub async fn complete_dataset_file_ingest(
814            &mut self,
815            request: impl tonic::IntoRequest<super::CompleteDatasetFileIngestRequest>,
816        ) -> std::result::Result<
817            tonic::Response<super::CompleteDatasetFileIngestResponse>,
818            tonic::Status,
819        > {
820            self.inner
821                .ready()
822                .await
823                .map_err(|e| {
824                    tonic::Status::unknown(
825                        format!("Service was not ready: {}", e.into()),
826                    )
827                })?;
828            let codec = tonic::codec::ProstCodec::default();
829            let path = http::uri::PathAndQuery::from_static(
830                "/nominal.datasets.v1.DatasetFileService/CompleteDatasetFileIngest",
831            );
832            let mut req = request.into_request();
833            req.extensions_mut()
834                .insert(
835                    GrpcMethod::new(
836                        "nominal.datasets.v1.DatasetFileService",
837                        "CompleteDatasetFileIngest",
838                    ),
839                );
840            self.inner.unary(req, path, codec).await
841        }
842        pub async fn update_dataset_file_ingest_status(
843            &mut self,
844            request: impl tonic::IntoRequest<super::UpdateDatasetFileIngestStatusRequest>,
845        ) -> std::result::Result<
846            tonic::Response<super::UpdateDatasetFileIngestStatusResponse>,
847            tonic::Status,
848        > {
849            self.inner
850                .ready()
851                .await
852                .map_err(|e| {
853                    tonic::Status::unknown(
854                        format!("Service was not ready: {}", e.into()),
855                    )
856                })?;
857            let codec = tonic::codec::ProstCodec::default();
858            let path = http::uri::PathAndQuery::from_static(
859                "/nominal.datasets.v1.DatasetFileService/UpdateDatasetFileIngestStatus",
860            );
861            let mut req = request.into_request();
862            req.extensions_mut()
863                .insert(
864                    GrpcMethod::new(
865                        "nominal.datasets.v1.DatasetFileService",
866                        "UpdateDatasetFileIngestStatus",
867                    ),
868                );
869            self.inner.unary(req, path, codec).await
870        }
871        pub async fn update_dataset_file_metadata(
872            &mut self,
873            request: impl tonic::IntoRequest<super::UpdateDatasetFileMetadataRequest>,
874        ) -> std::result::Result<
875            tonic::Response<super::UpdateDatasetFileMetadataResponse>,
876            tonic::Status,
877        > {
878            self.inner
879                .ready()
880                .await
881                .map_err(|e| {
882                    tonic::Status::unknown(
883                        format!("Service was not ready: {}", e.into()),
884                    )
885                })?;
886            let codec = tonic::codec::ProstCodec::default();
887            let path = http::uri::PathAndQuery::from_static(
888                "/nominal.datasets.v1.DatasetFileService/UpdateDatasetFileMetadata",
889            );
890            let mut req = request.into_request();
891            req.extensions_mut()
892                .insert(
893                    GrpcMethod::new(
894                        "nominal.datasets.v1.DatasetFileService",
895                        "UpdateDatasetFileMetadata",
896                    ),
897                );
898            self.inner.unary(req, path, codec).await
899        }
900    }
901}
902#[derive(Clone, PartialEq, ::prost::Message)]
903pub struct Dataset {
904    #[prost(string, tag = "1")]
905    pub rid: ::prost::alloc::string::String,
906    #[prost(string, tag = "2")]
907    pub name: ::prost::alloc::string::String,
908    #[prost(string, optional, tag = "3")]
909    pub description: ::core::option::Option<::prost::alloc::string::String>,
910    #[prost(message, optional, tag = "4")]
911    pub created_at: ::core::option::Option<
912        super::super::super::google::protobuf::Timestamp,
913    >,
914    #[prost(message, optional, tag = "5")]
915    pub last_ingested_at: ::core::option::Option<
916        super::super::super::google::protobuf::Timestamp,
917    >,
918    #[prost(message, optional, tag = "6")]
919    pub last_ingest_status: ::core::option::Option<IngestStatus>,
920    #[prost(message, optional, tag = "7")]
921    pub bounds: ::core::option::Option<DataBounds>,
922    #[prost(string, repeated, tag = "8")]
923    pub labels: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
924    #[prost(map = "string, message", tag = "9")]
925    pub properties: ::std::collections::HashMap<
926        ::prost::alloc::string::String,
927        super::super::types::TypedPropertyValue,
928    >,
929    #[prost(enumeration = "super::super::types::Granularity", tag = "10")]
930    pub granularity: i32,
931    #[prost(bool, tag = "11")]
932    pub is_archived: bool,
933    #[prost(enumeration = "DatasetBackingType", tag = "12")]
934    pub backing_type: i32,
935    #[prost(message, optional, tag = "13")]
936    pub retention_policy: ::core::option::Option<
937        super::super::storage::v1::RetentionPolicy,
938    >,
939    #[prost(string, optional, tag = "14")]
940    pub migrated_from_connection_rid: ::core::option::Option<
941        ::prost::alloc::string::String,
942    >,
943    #[prost(string, repeated, tag = "15")]
944    pub channel_search_split_tag_keys: ::prost::alloc::vec::Vec<
945        ::prost::alloc::string::String,
946    >,
947    #[prost(string, optional, tag = "16")]
948    pub channel_prefix_tree_delimiter: ::core::option::Option<
949        ::prost::alloc::string::String,
950    >,
951    #[prost(bool, tag = "17")]
952    pub is_derived: bool,
953}
954#[derive(Clone, PartialEq, ::prost::Message)]
955pub struct GetDatasetRequest {
956    #[prost(string, tag = "1")]
957    pub dataset_rid: ::prost::alloc::string::String,
958}
959#[derive(Clone, PartialEq, ::prost::Message)]
960pub struct GetDatasetResponse {
961    #[prost(message, optional, tag = "1")]
962    pub dataset: ::core::option::Option<Dataset>,
963}
964#[derive(Clone, PartialEq, ::prost::Message)]
965pub struct BatchGetDatasetsRequest {
966    #[prost(string, repeated, tag = "1")]
967    pub dataset_rids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
968}
969#[derive(Clone, PartialEq, ::prost::Message)]
970pub struct BatchGetDatasetsResponse {
971    #[prost(message, repeated, tag = "1")]
972    pub datasets: ::prost::alloc::vec::Vec<Dataset>,
973}
974#[derive(Clone, PartialEq, ::prost::Message)]
975pub struct SearchDatasetsRequest {
976    #[prost(message, optional, tag = "1")]
977    pub query: ::core::option::Option<DatasetQuery>,
978    #[prost(int32, optional, tag = "2")]
979    pub page_size: ::core::option::Option<i32>,
980    #[prost(string, tag = "3")]
981    pub page_token: ::prost::alloc::string::String,
982    #[prost(message, optional, tag = "4")]
983    pub sort: ::core::option::Option<DatasetSort>,
984}
985#[derive(Clone, PartialEq, ::prost::Message)]
986pub struct SearchDatasetsResponse {
987    #[prost(message, repeated, tag = "1")]
988    pub datasets: ::prost::alloc::vec::Vec<Dataset>,
989    #[prost(string, tag = "2")]
990    pub next_page_token: ::prost::alloc::string::String,
991}
992#[derive(Clone, PartialEq, ::prost::Message)]
993pub struct DatasetQuery {
994    #[prost(
995        oneof = "dataset_query::Query",
996        tags = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14"
997    )]
998    pub query: ::core::option::Option<dataset_query::Query>,
999}
1000/// Nested message and enum types in `DatasetQuery`.
1001pub mod dataset_query {
1002    #[derive(Clone, PartialEq, ::prost::Oneof)]
1003    pub enum Query {
1004        #[prost(string, tag = "1")]
1005        SearchText(::prost::alloc::string::String),
1006        #[prost(string, tag = "2")]
1007        ExactName(::prost::alloc::string::String),
1008        #[prost(string, tag = "3")]
1009        Label(::prost::alloc::string::String),
1010        #[prost(message, tag = "4")]
1011        Property(super::super::super::types::Property),
1012        #[prost(message, tag = "5")]
1013        NumericProperty(super::super::super::types::NumericPropertyPredicate),
1014        #[prost(message, tag = "6")]
1015        NumericPropertyRange(super::super::super::types::NumericPropertyRangePredicate),
1016        #[prost(enumeration = "super::super::super::types::IngestStatus", tag = "7")]
1017        LastIngestStatus(i32),
1018        #[prost(message, tag = "8")]
1019        CreatedAtOrBefore(super::super::super::super::google::protobuf::Timestamp),
1020        #[prost(message, tag = "9")]
1021        CreatedAtOrAfter(super::super::super::super::google::protobuf::Timestamp),
1022        #[prost(bool, tag = "10")]
1023        IsArchived(bool),
1024        #[prost(bool, tag = "11")]
1025        IsDerived(bool),
1026        #[prost(message, tag = "12")]
1027        And(super::DatasetQueryList),
1028        #[prost(message, tag = "13")]
1029        Or(super::DatasetQueryList),
1030        #[prost(string, tag = "14")]
1031        WorkspaceRid(::prost::alloc::string::String),
1032    }
1033}
1034#[derive(Clone, PartialEq, ::prost::Message)]
1035pub struct DatasetQueryList {
1036    #[prost(message, repeated, tag = "1")]
1037    pub queries: ::prost::alloc::vec::Vec<DatasetQuery>,
1038}
1039#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1040pub struct DatasetSort {
1041    #[prost(enumeration = "DatasetSortField", tag = "1")]
1042    pub field: i32,
1043    #[prost(bool, tag = "2")]
1044    pub descending: bool,
1045}
1046#[derive(Clone, PartialEq, ::prost::Message)]
1047pub struct CreateDatasetRequest {
1048    #[prost(message, optional, tag = "1")]
1049    pub dataset: ::core::option::Option<Dataset>,
1050    #[prost(string, optional, tag = "2")]
1051    pub dataset_uuid: ::core::option::Option<::prost::alloc::string::String>,
1052    #[prost(string, optional, tag = "3")]
1053    pub workspace_rid: ::core::option::Option<::prost::alloc::string::String>,
1054    #[prost(string, repeated, tag = "4")]
1055    pub marking_rids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1056}
1057#[derive(Clone, PartialEq, ::prost::Message)]
1058pub struct CreateDatasetResponse {
1059    #[prost(message, optional, tag = "1")]
1060    pub dataset: ::core::option::Option<Dataset>,
1061}
1062#[derive(Clone, PartialEq, ::prost::Message)]
1063pub struct UpdateDatasetRequest {
1064    #[prost(message, optional, tag = "1")]
1065    pub dataset: ::core::option::Option<Dataset>,
1066    #[prost(message, optional, tag = "2")]
1067    pub update_mask: ::core::option::Option<
1068        super::super::super::google::protobuf::FieldMask,
1069    >,
1070}
1071#[derive(Clone, PartialEq, ::prost::Message)]
1072pub struct UpdateDatasetResponse {
1073    #[prost(message, optional, tag = "1")]
1074    pub dataset: ::core::option::Option<Dataset>,
1075}
1076#[derive(Clone, PartialEq, ::prost::Message)]
1077pub struct UpdateDatasetBoundsRequest {
1078    #[prost(string, tag = "1")]
1079    pub dataset_rid: ::prost::alloc::string::String,
1080    #[prost(message, optional, tag = "2")]
1081    pub bounds: ::core::option::Option<DataBounds>,
1082}
1083#[derive(Clone, PartialEq, ::prost::Message)]
1084pub struct UpdateDatasetBoundsResponse {
1085    #[prost(message, optional, tag = "1")]
1086    pub dataset: ::core::option::Option<Dataset>,
1087}
1088#[derive(Clone, PartialEq, ::prost::Message)]
1089pub struct ArchiveDatasetRequest {
1090    #[prost(string, tag = "1")]
1091    pub dataset_rid: ::prost::alloc::string::String,
1092}
1093#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1094pub struct ArchiveDatasetResponse {}
1095#[derive(Clone, PartialEq, ::prost::Message)]
1096pub struct UnarchiveDatasetRequest {
1097    #[prost(string, tag = "1")]
1098    pub dataset_rid: ::prost::alloc::string::String,
1099}
1100#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1101pub struct UnarchiveDatasetResponse {}
1102#[derive(Clone, PartialEq, ::prost::Message)]
1103pub struct DatasetExternalConnection {
1104    #[prost(string, tag = "1")]
1105    pub dataset_rid: ::prost::alloc::string::String,
1106}
1107#[derive(Clone, PartialEq, ::prost::Message)]
1108pub struct BatchGetDatasetExternalConnectionsRequest {
1109    #[prost(string, repeated, tag = "1")]
1110    pub dataset_rids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1111}
1112#[derive(Clone, PartialEq, ::prost::Message)]
1113pub struct BatchGetDatasetExternalConnectionsResponse {
1114    #[prost(message, repeated, tag = "1")]
1115    pub dataset_external_connections: ::prost::alloc::vec::Vec<
1116        DatasetExternalConnection,
1117    >,
1118}
1119#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1120#[repr(i32)]
1121pub enum DatasetError {
1122    InvalidRequest = 0,
1123}
1124impl DatasetError {
1125    /// String value of the enum field names used in the ProtoBuf definition.
1126    ///
1127    /// The values are not transformed in any way and thus are considered stable
1128    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1129    pub fn as_str_name(&self) -> &'static str {
1130        match self {
1131            Self::InvalidRequest => "DATASET_ERROR_INVALID_REQUEST",
1132        }
1133    }
1134    /// Creates an enum from field names used in the ProtoBuf definition.
1135    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1136        match value {
1137            "DATASET_ERROR_INVALID_REQUEST" => Some(Self::InvalidRequest),
1138            _ => None,
1139        }
1140    }
1141}
1142#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1143#[repr(i32)]
1144pub enum DatasetBackingType {
1145    Unspecified = 0,
1146    Legacy = 1,
1147    Iceberg = 2,
1148    Dual = 3,
1149}
1150impl DatasetBackingType {
1151    /// String value of the enum field names used in the ProtoBuf definition.
1152    ///
1153    /// The values are not transformed in any way and thus are considered stable
1154    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1155    pub fn as_str_name(&self) -> &'static str {
1156        match self {
1157            Self::Unspecified => "DATASET_BACKING_TYPE_UNSPECIFIED",
1158            Self::Legacy => "DATASET_BACKING_TYPE_LEGACY",
1159            Self::Iceberg => "DATASET_BACKING_TYPE_ICEBERG",
1160            Self::Dual => "DATASET_BACKING_TYPE_DUAL",
1161        }
1162    }
1163    /// Creates an enum from field names used in the ProtoBuf definition.
1164    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1165        match value {
1166            "DATASET_BACKING_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
1167            "DATASET_BACKING_TYPE_LEGACY" => Some(Self::Legacy),
1168            "DATASET_BACKING_TYPE_ICEBERG" => Some(Self::Iceberg),
1169            "DATASET_BACKING_TYPE_DUAL" => Some(Self::Dual),
1170            _ => None,
1171        }
1172    }
1173}
1174#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1175#[repr(i32)]
1176pub enum DatasetSortField {
1177    Unspecified = 0,
1178    CreatedAt = 1,
1179    DataStart = 2,
1180    DataEnd = 3,
1181    LastIngestedAt = 4,
1182}
1183impl DatasetSortField {
1184    /// String value of the enum field names used in the ProtoBuf definition.
1185    ///
1186    /// The values are not transformed in any way and thus are considered stable
1187    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1188    pub fn as_str_name(&self) -> &'static str {
1189        match self {
1190            Self::Unspecified => "DATASET_SORT_FIELD_UNSPECIFIED",
1191            Self::CreatedAt => "DATASET_SORT_FIELD_CREATED_AT",
1192            Self::DataStart => "DATASET_SORT_FIELD_DATA_START",
1193            Self::DataEnd => "DATASET_SORT_FIELD_DATA_END",
1194            Self::LastIngestedAt => "DATASET_SORT_FIELD_LAST_INGESTED_AT",
1195        }
1196    }
1197    /// Creates an enum from field names used in the ProtoBuf definition.
1198    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1199        match value {
1200            "DATASET_SORT_FIELD_UNSPECIFIED" => Some(Self::Unspecified),
1201            "DATASET_SORT_FIELD_CREATED_AT" => Some(Self::CreatedAt),
1202            "DATASET_SORT_FIELD_DATA_START" => Some(Self::DataStart),
1203            "DATASET_SORT_FIELD_DATA_END" => Some(Self::DataEnd),
1204            "DATASET_SORT_FIELD_LAST_INGESTED_AT" => Some(Self::LastIngestedAt),
1205            _ => None,
1206        }
1207    }
1208}
1209/// Generated client implementations.
1210pub mod dataset_service_client {
1211    #![allow(
1212        unused_variables,
1213        dead_code,
1214        missing_docs,
1215        clippy::wildcard_imports,
1216        clippy::let_unit_value,
1217    )]
1218    use tonic::codegen::*;
1219    use tonic::codegen::http::Uri;
1220    #[derive(Debug, Clone)]
1221    pub struct DatasetServiceClient<T> {
1222        inner: tonic::client::Grpc<T>,
1223    }
1224    impl DatasetServiceClient<tonic::transport::Channel> {
1225        /// Attempt to create a new client by connecting to a given endpoint.
1226        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1227        where
1228            D: TryInto<tonic::transport::Endpoint>,
1229            D::Error: Into<StdError>,
1230        {
1231            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1232            Ok(Self::new(conn))
1233        }
1234    }
1235    impl<T> DatasetServiceClient<T>
1236    where
1237        T: tonic::client::GrpcService<tonic::body::Body>,
1238        T::Error: Into<StdError>,
1239        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1240        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1241    {
1242        pub fn new(inner: T) -> Self {
1243            let inner = tonic::client::Grpc::new(inner);
1244            Self { inner }
1245        }
1246        pub fn with_origin(inner: T, origin: Uri) -> Self {
1247            let inner = tonic::client::Grpc::with_origin(inner, origin);
1248            Self { inner }
1249        }
1250        pub fn with_interceptor<F>(
1251            inner: T,
1252            interceptor: F,
1253        ) -> DatasetServiceClient<InterceptedService<T, F>>
1254        where
1255            F: tonic::service::Interceptor,
1256            T::ResponseBody: Default,
1257            T: tonic::codegen::Service<
1258                http::Request<tonic::body::Body>,
1259                Response = http::Response<
1260                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
1261                >,
1262            >,
1263            <T as tonic::codegen::Service<
1264                http::Request<tonic::body::Body>,
1265            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1266        {
1267            DatasetServiceClient::new(InterceptedService::new(inner, interceptor))
1268        }
1269        /// Compress requests with the given encoding.
1270        ///
1271        /// This requires the server to support it otherwise it might respond with an
1272        /// error.
1273        #[must_use]
1274        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1275            self.inner = self.inner.send_compressed(encoding);
1276            self
1277        }
1278        /// Enable decompressing responses.
1279        #[must_use]
1280        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1281            self.inner = self.inner.accept_compressed(encoding);
1282            self
1283        }
1284        /// Limits the maximum size of a decoded message.
1285        ///
1286        /// Default: `4MB`
1287        #[must_use]
1288        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1289            self.inner = self.inner.max_decoding_message_size(limit);
1290            self
1291        }
1292        /// Limits the maximum size of an encoded message.
1293        ///
1294        /// Default: `usize::MAX`
1295        #[must_use]
1296        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1297            self.inner = self.inner.max_encoding_message_size(limit);
1298            self
1299        }
1300        pub async fn get_dataset(
1301            &mut self,
1302            request: impl tonic::IntoRequest<super::GetDatasetRequest>,
1303        ) -> std::result::Result<
1304            tonic::Response<super::GetDatasetResponse>,
1305            tonic::Status,
1306        > {
1307            self.inner
1308                .ready()
1309                .await
1310                .map_err(|e| {
1311                    tonic::Status::unknown(
1312                        format!("Service was not ready: {}", e.into()),
1313                    )
1314                })?;
1315            let codec = tonic::codec::ProstCodec::default();
1316            let path = http::uri::PathAndQuery::from_static(
1317                "/nominal.datasets.v1.DatasetService/GetDataset",
1318            );
1319            let mut req = request.into_request();
1320            req.extensions_mut()
1321                .insert(
1322                    GrpcMethod::new("nominal.datasets.v1.DatasetService", "GetDataset"),
1323                );
1324            self.inner.unary(req, path, codec).await
1325        }
1326        pub async fn batch_get_datasets(
1327            &mut self,
1328            request: impl tonic::IntoRequest<super::BatchGetDatasetsRequest>,
1329        ) -> std::result::Result<
1330            tonic::Response<super::BatchGetDatasetsResponse>,
1331            tonic::Status,
1332        > {
1333            self.inner
1334                .ready()
1335                .await
1336                .map_err(|e| {
1337                    tonic::Status::unknown(
1338                        format!("Service was not ready: {}", e.into()),
1339                    )
1340                })?;
1341            let codec = tonic::codec::ProstCodec::default();
1342            let path = http::uri::PathAndQuery::from_static(
1343                "/nominal.datasets.v1.DatasetService/BatchGetDatasets",
1344            );
1345            let mut req = request.into_request();
1346            req.extensions_mut()
1347                .insert(
1348                    GrpcMethod::new(
1349                        "nominal.datasets.v1.DatasetService",
1350                        "BatchGetDatasets",
1351                    ),
1352                );
1353            self.inner.unary(req, path, codec).await
1354        }
1355        pub async fn search_datasets(
1356            &mut self,
1357            request: impl tonic::IntoRequest<super::SearchDatasetsRequest>,
1358        ) -> std::result::Result<
1359            tonic::Response<super::SearchDatasetsResponse>,
1360            tonic::Status,
1361        > {
1362            self.inner
1363                .ready()
1364                .await
1365                .map_err(|e| {
1366                    tonic::Status::unknown(
1367                        format!("Service was not ready: {}", e.into()),
1368                    )
1369                })?;
1370            let codec = tonic::codec::ProstCodec::default();
1371            let path = http::uri::PathAndQuery::from_static(
1372                "/nominal.datasets.v1.DatasetService/SearchDatasets",
1373            );
1374            let mut req = request.into_request();
1375            req.extensions_mut()
1376                .insert(
1377                    GrpcMethod::new(
1378                        "nominal.datasets.v1.DatasetService",
1379                        "SearchDatasets",
1380                    ),
1381                );
1382            self.inner.unary(req, path, codec).await
1383        }
1384        pub async fn create_dataset(
1385            &mut self,
1386            request: impl tonic::IntoRequest<super::CreateDatasetRequest>,
1387        ) -> std::result::Result<
1388            tonic::Response<super::CreateDatasetResponse>,
1389            tonic::Status,
1390        > {
1391            self.inner
1392                .ready()
1393                .await
1394                .map_err(|e| {
1395                    tonic::Status::unknown(
1396                        format!("Service was not ready: {}", e.into()),
1397                    )
1398                })?;
1399            let codec = tonic::codec::ProstCodec::default();
1400            let path = http::uri::PathAndQuery::from_static(
1401                "/nominal.datasets.v1.DatasetService/CreateDataset",
1402            );
1403            let mut req = request.into_request();
1404            req.extensions_mut()
1405                .insert(
1406                    GrpcMethod::new(
1407                        "nominal.datasets.v1.DatasetService",
1408                        "CreateDataset",
1409                    ),
1410                );
1411            self.inner.unary(req, path, codec).await
1412        }
1413        pub async fn update_dataset(
1414            &mut self,
1415            request: impl tonic::IntoRequest<super::UpdateDatasetRequest>,
1416        ) -> std::result::Result<
1417            tonic::Response<super::UpdateDatasetResponse>,
1418            tonic::Status,
1419        > {
1420            self.inner
1421                .ready()
1422                .await
1423                .map_err(|e| {
1424                    tonic::Status::unknown(
1425                        format!("Service was not ready: {}", e.into()),
1426                    )
1427                })?;
1428            let codec = tonic::codec::ProstCodec::default();
1429            let path = http::uri::PathAndQuery::from_static(
1430                "/nominal.datasets.v1.DatasetService/UpdateDataset",
1431            );
1432            let mut req = request.into_request();
1433            req.extensions_mut()
1434                .insert(
1435                    GrpcMethod::new(
1436                        "nominal.datasets.v1.DatasetService",
1437                        "UpdateDataset",
1438                    ),
1439                );
1440            self.inner.unary(req, path, codec).await
1441        }
1442        pub async fn update_dataset_bounds(
1443            &mut self,
1444            request: impl tonic::IntoRequest<super::UpdateDatasetBoundsRequest>,
1445        ) -> std::result::Result<
1446            tonic::Response<super::UpdateDatasetBoundsResponse>,
1447            tonic::Status,
1448        > {
1449            self.inner
1450                .ready()
1451                .await
1452                .map_err(|e| {
1453                    tonic::Status::unknown(
1454                        format!("Service was not ready: {}", e.into()),
1455                    )
1456                })?;
1457            let codec = tonic::codec::ProstCodec::default();
1458            let path = http::uri::PathAndQuery::from_static(
1459                "/nominal.datasets.v1.DatasetService/UpdateDatasetBounds",
1460            );
1461            let mut req = request.into_request();
1462            req.extensions_mut()
1463                .insert(
1464                    GrpcMethod::new(
1465                        "nominal.datasets.v1.DatasetService",
1466                        "UpdateDatasetBounds",
1467                    ),
1468                );
1469            self.inner.unary(req, path, codec).await
1470        }
1471        pub async fn archive_dataset(
1472            &mut self,
1473            request: impl tonic::IntoRequest<super::ArchiveDatasetRequest>,
1474        ) -> std::result::Result<
1475            tonic::Response<super::ArchiveDatasetResponse>,
1476            tonic::Status,
1477        > {
1478            self.inner
1479                .ready()
1480                .await
1481                .map_err(|e| {
1482                    tonic::Status::unknown(
1483                        format!("Service was not ready: {}", e.into()),
1484                    )
1485                })?;
1486            let codec = tonic::codec::ProstCodec::default();
1487            let path = http::uri::PathAndQuery::from_static(
1488                "/nominal.datasets.v1.DatasetService/ArchiveDataset",
1489            );
1490            let mut req = request.into_request();
1491            req.extensions_mut()
1492                .insert(
1493                    GrpcMethod::new(
1494                        "nominal.datasets.v1.DatasetService",
1495                        "ArchiveDataset",
1496                    ),
1497                );
1498            self.inner.unary(req, path, codec).await
1499        }
1500        pub async fn unarchive_dataset(
1501            &mut self,
1502            request: impl tonic::IntoRequest<super::UnarchiveDatasetRequest>,
1503        ) -> std::result::Result<
1504            tonic::Response<super::UnarchiveDatasetResponse>,
1505            tonic::Status,
1506        > {
1507            self.inner
1508                .ready()
1509                .await
1510                .map_err(|e| {
1511                    tonic::Status::unknown(
1512                        format!("Service was not ready: {}", e.into()),
1513                    )
1514                })?;
1515            let codec = tonic::codec::ProstCodec::default();
1516            let path = http::uri::PathAndQuery::from_static(
1517                "/nominal.datasets.v1.DatasetService/UnarchiveDataset",
1518            );
1519            let mut req = request.into_request();
1520            req.extensions_mut()
1521                .insert(
1522                    GrpcMethod::new(
1523                        "nominal.datasets.v1.DatasetService",
1524                        "UnarchiveDataset",
1525                    ),
1526                );
1527            self.inner.unary(req, path, codec).await
1528        }
1529        pub async fn batch_get_dataset_external_connections(
1530            &mut self,
1531            request: impl tonic::IntoRequest<
1532                super::BatchGetDatasetExternalConnectionsRequest,
1533            >,
1534        ) -> std::result::Result<
1535            tonic::Response<super::BatchGetDatasetExternalConnectionsResponse>,
1536            tonic::Status,
1537        > {
1538            self.inner
1539                .ready()
1540                .await
1541                .map_err(|e| {
1542                    tonic::Status::unknown(
1543                        format!("Service was not ready: {}", e.into()),
1544                    )
1545                })?;
1546            let codec = tonic::codec::ProstCodec::default();
1547            let path = http::uri::PathAndQuery::from_static(
1548                "/nominal.datasets.v1.DatasetService/BatchGetDatasetExternalConnections",
1549            );
1550            let mut req = request.into_request();
1551            req.extensions_mut()
1552                .insert(
1553                    GrpcMethod::new(
1554                        "nominal.datasets.v1.DatasetService",
1555                        "BatchGetDatasetExternalConnections",
1556                    ),
1557                );
1558            self.inner.unary(req, path, codec).await
1559        }
1560    }
1561}