Skip to main content

perspective_client/
proto.rs

1// This file is @generated by prost-build.
2/// Recoverable, user-readable error reporting from the engine.
3#[derive(serde::Serialize)]
4#[allow(clippy::derive_partial_eq_without_eq)]
5#[derive(Clone, PartialEq, ::prost::Message)]
6pub struct ServerError {
7    #[prost(string, tag = "1")]
8    pub message: ::prost::alloc::string::String,
9    #[prost(enumeration = "StatusCode", tag = "2")]
10    pub status_code: i32,
11}
12#[derive(serde::Serialize)]
13#[allow(clippy::derive_partial_eq_without_eq)]
14#[derive(Clone, PartialEq, ::prost::Message)]
15pub struct Schema {
16    #[prost(message, repeated, tag = "1")]
17    pub schema: ::prost::alloc::vec::Vec<schema::KeyTypePair>,
18}
19/// Nested message and enum types in `Schema`.
20pub mod schema {
21    #[derive(serde::Serialize)]
22    #[allow(clippy::derive_partial_eq_without_eq)]
23    #[derive(Clone, PartialEq, ::prost::Message)]
24    pub struct KeyTypePair {
25        #[prost(string, tag = "1")]
26        pub name: ::prost::alloc::string::String,
27        #[prost(enumeration = "super::ColumnType", tag = "2")]
28        pub r#type: i32,
29    }
30}
31/// The data type constructors Perspective supports.
32#[derive(serde::Serialize)]
33#[allow(clippy::derive_partial_eq_without_eq)]
34#[derive(Clone, PartialEq, ::prost::Message)]
35pub struct MakeTableData {
36    #[prost(oneof = "make_table_data::Data", tags = "1, 2, 3, 4, 5, 6, 7")]
37    pub data: ::core::option::Option<make_table_data::Data>,
38}
39/// Nested message and enum types in `MakeTableData`.
40pub mod make_table_data {
41    #[derive(serde::Serialize)]
42    #[allow(clippy::derive_partial_eq_without_eq)]
43    #[derive(Clone, PartialEq, ::prost::Oneof)]
44    pub enum Data {
45        #[prost(message, tag = "1")]
46        FromSchema(super::Schema),
47        #[prost(string, tag = "2")]
48        FromCsv(::prost::alloc::string::String),
49        #[prost(bytes, tag = "3")]
50        #[serde(skip)]
51        FromArrow(::prost::alloc::vec::Vec<u8>),
52        #[prost(string, tag = "4")]
53        FromRows(::prost::alloc::string::String),
54        #[prost(string, tag = "5")]
55        FromCols(::prost::alloc::string::String),
56        #[prost(string, tag = "6")]
57        FromView(::prost::alloc::string::String),
58        #[prost(string, tag = "7")]
59        FromNdjson(::prost::alloc::string::String),
60    }
61}
62/// Filter type scalars - this is _not_ the same as a Columns scalar, as this
63/// value is used in the view config and must be JSON safe!
64#[derive(serde::Serialize)]
65#[allow(clippy::derive_partial_eq_without_eq)]
66#[derive(Clone, PartialEq, ::prost::Message)]
67pub struct Scalar {
68    #[prost(oneof = "scalar::Scalar", tags = "1, 4, 6, 7")]
69    pub scalar: ::core::option::Option<scalar::Scalar>,
70}
71/// Nested message and enum types in `Scalar`.
72pub mod scalar {
73    #[derive(serde::Serialize)]
74    #[allow(clippy::derive_partial_eq_without_eq)]
75    #[derive(Clone, PartialEq, ::prost::Oneof)]
76    pub enum Scalar {
77        #[prost(bool, tag = "1")]
78        Bool(bool),
79        /// int64 date = 2; // TODO these are the wrong type
80        /// int64 datetime = 3;
81        #[prost(double, tag = "4")]
82        Float(f64),
83        /// int32 int = 5;
84        #[prost(string, tag = "6")]
85        String(::prost::alloc::string::String),
86        #[prost(enumeration = "::prost_types::NullValue", tag = "7")]
87        Null(i32),
88    }
89}
90/// Options for requresting a slice of data, starting with the rectangular
91/// viewport.
92#[derive(serde::Serialize)]
93#[derive(serde::Deserialize)]
94#[allow(clippy::derive_partial_eq_without_eq)]
95#[derive(Clone, PartialEq, ::prost::Message)]
96pub struct ViewPort {
97    #[prost(uint32, optional, tag = "1")]
98    pub start_row: ::core::option::Option<u32>,
99    #[prost(uint32, optional, tag = "2")]
100    pub start_col: ::core::option::Option<u32>,
101    #[prost(uint32, optional, tag = "3")]
102    pub end_row: ::core::option::Option<u32>,
103    #[prost(uint32, optional, tag = "4")]
104    pub end_col: ::core::option::Option<u32>,
105    ///    optional bool id = 5;
106    ///    optional bool index = 3;
107    ///    optional bool formatted = 6;
108    ///    optional bool leaves_only = 7;
109    ///    optional bool compression = 3;
110    #[prost(bool, optional, tag = "5")]
111    pub emit_legacy_row_path_names: ::core::option::Option<bool>,
112}
113#[derive(serde::Serialize)]
114#[allow(clippy::derive_partial_eq_without_eq)]
115#[derive(Clone, PartialEq, ::prost::Message)]
116pub struct Request {
117    #[prost(uint32, tag = "1")]
118    pub msg_id: u32,
119    #[prost(string, tag = "2")]
120    pub entity_id: ::prost::alloc::string::String,
121    #[prost(
122        oneof = "request::ClientReq",
123        tags = "3, 4, 37, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 36, 27, 28, 29, 30, 31, 32, 33, 34, 35, 38"
124    )]
125    pub client_req: ::core::option::Option<request::ClientReq>,
126}
127/// Nested message and enum types in `Request`.
128pub mod request {
129    #[derive(serde::Serialize)]
130    #[allow(clippy::derive_partial_eq_without_eq)]
131    #[derive(Clone, PartialEq, ::prost::Oneof)]
132    pub enum ClientReq {
133        /// Minimum Virtual API (theoretical).
134        #[prost(message, tag = "3")]
135        GetFeaturesReq(super::GetFeaturesReq),
136        #[prost(message, tag = "4")]
137        GetHostedTablesReq(super::GetHostedTablesReq),
138        #[prost(message, tag = "37")]
139        RemoveHostedTablesUpdateReq(super::RemoveHostedTablesUpdateReq),
140        #[prost(message, tag = "5")]
141        TableMakePortReq(super::TableMakePortReq),
142        #[prost(message, tag = "6")]
143        TableMakeViewReq(super::TableMakeViewReq),
144        #[prost(message, tag = "7")]
145        TableSchemaReq(super::TableSchemaReq),
146        #[prost(message, tag = "8")]
147        TableSizeReq(super::TableSizeReq),
148        #[prost(message, tag = "9")]
149        TableValidateExprReq(super::TableValidateExprReq),
150        #[prost(message, tag = "10")]
151        ViewColumnPathsReq(super::ViewColumnPathsReq),
152        #[prost(message, tag = "11")]
153        ViewDeleteReq(super::ViewDeleteReq),
154        #[prost(message, tag = "12")]
155        ViewDimensionsReq(super::ViewDimensionsReq),
156        #[prost(message, tag = "13")]
157        ViewExpressionSchemaReq(super::ViewExpressionSchemaReq),
158        #[prost(message, tag = "14")]
159        ViewGetConfigReq(super::ViewGetConfigReq),
160        #[prost(message, tag = "15")]
161        ViewSchemaReq(super::ViewSchemaReq),
162        #[prost(message, tag = "16")]
163        ViewToArrowReq(super::ViewToArrowReq),
164        /// Optional (we can enable real-time/autocomplete/etc with these, but
165        /// not required).
166        #[prost(message, tag = "17")]
167        ServerSystemInfoReq(super::ServerSystemInfoReq),
168        #[prost(message, tag = "18")]
169        ViewCollapseReq(super::ViewCollapseReq),
170        #[prost(message, tag = "19")]
171        ViewExpandReq(super::ViewExpandReq),
172        #[prost(message, tag = "20")]
173        ViewGetMinMaxReq(super::ViewGetMinMaxReq),
174        #[prost(message, tag = "21")]
175        ViewOnUpdateReq(super::ViewOnUpdateReq),
176        #[prost(message, tag = "22")]
177        ViewRemoveOnUpdateReq(super::ViewRemoveOnUpdateReq),
178        #[prost(message, tag = "23")]
179        ViewSetDepthReq(super::ViewSetDepthReq),
180        #[prost(message, tag = "24")]
181        ViewToColumnsStringReq(super::ViewToColumnsStringReq),
182        #[prost(message, tag = "25")]
183        ViewToCsvReq(super::ViewToCsvReq),
184        #[prost(message, tag = "26")]
185        ViewToRowsStringReq(super::ViewToRowsStringReq),
186        #[prost(message, tag = "36")]
187        ViewToNdjsonStringReq(super::ViewToNdjsonStringReq),
188        /// External (we don't need these for viewer, but the developer may).
189        #[prost(message, tag = "27")]
190        MakeTableReq(super::MakeTableReq),
191        #[prost(message, tag = "28")]
192        TableDeleteReq(super::TableDeleteReq),
193        #[prost(message, tag = "29")]
194        TableOnDeleteReq(super::TableOnDeleteReq),
195        #[prost(message, tag = "30")]
196        TableRemoveDeleteReq(super::TableRemoveDeleteReq),
197        #[prost(message, tag = "31")]
198        TableRemoveReq(super::TableRemoveReq),
199        #[prost(message, tag = "32")]
200        TableReplaceReq(super::TableReplaceReq),
201        #[prost(message, tag = "33")]
202        TableUpdateReq(super::TableUpdateReq),
203        #[prost(message, tag = "34")]
204        ViewOnDeleteReq(super::ViewOnDeleteReq),
205        #[prost(message, tag = "35")]
206        ViewRemoveDeleteReq(super::ViewRemoveDeleteReq),
207        #[prost(message, tag = "38")]
208        MakeJoinTableReq(super::MakeJoinTableReq),
209    }
210}
211#[derive(serde::Serialize)]
212#[allow(clippy::derive_partial_eq_without_eq)]
213#[derive(Clone, PartialEq, ::prost::Message)]
214pub struct Response {
215    #[prost(uint32, tag = "1")]
216    pub msg_id: u32,
217    #[prost(string, tag = "2")]
218    pub entity_id: ::prost::alloc::string::String,
219    #[prost(
220        oneof = "response::ClientResp",
221        tags = "3, 4, 37, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 36, 27, 28, 29, 30, 31, 32, 33, 34, 35, 38, 50"
222    )]
223    pub client_resp: ::core::option::Option<response::ClientResp>,
224}
225/// Nested message and enum types in `Response`.
226pub mod response {
227    #[derive(serde::Serialize)]
228    #[allow(clippy::derive_partial_eq_without_eq)]
229    #[derive(Clone, PartialEq, ::prost::Oneof)]
230    pub enum ClientResp {
231        #[prost(message, tag = "3")]
232        GetFeaturesResp(super::GetFeaturesResp),
233        #[prost(message, tag = "4")]
234        GetHostedTablesResp(super::GetHostedTablesResp),
235        #[prost(message, tag = "37")]
236        RemoveHostedTablesUpdateResp(super::RemoveHostedTablesUpdateResp),
237        #[prost(message, tag = "5")]
238        TableMakePortResp(super::TableMakePortResp),
239        #[prost(message, tag = "6")]
240        TableMakeViewResp(super::TableMakeViewResp),
241        #[prost(message, tag = "7")]
242        TableSchemaResp(super::TableSchemaResp),
243        #[prost(message, tag = "8")]
244        TableSizeResp(super::TableSizeResp),
245        #[prost(message, tag = "9")]
246        TableValidateExprResp(super::TableValidateExprResp),
247        #[prost(message, tag = "10")]
248        ViewColumnPathsResp(super::ViewColumnPathsResp),
249        #[prost(message, tag = "11")]
250        ViewDeleteResp(super::ViewDeleteResp),
251        #[prost(message, tag = "12")]
252        ViewDimensionsResp(super::ViewDimensionsResp),
253        #[prost(message, tag = "13")]
254        ViewExpressionSchemaResp(super::ViewExpressionSchemaResp),
255        #[prost(message, tag = "14")]
256        ViewGetConfigResp(super::ViewGetConfigResp),
257        #[prost(message, tag = "15")]
258        ViewSchemaResp(super::ViewSchemaResp),
259        #[prost(message, tag = "16")]
260        ViewToArrowResp(super::ViewToArrowResp),
261        #[prost(message, tag = "17")]
262        ServerSystemInfoResp(super::ServerSystemInfoResp),
263        #[prost(message, tag = "18")]
264        ViewCollapseResp(super::ViewCollapseResp),
265        #[prost(message, tag = "19")]
266        ViewExpandResp(super::ViewExpandResp),
267        #[prost(message, tag = "20")]
268        ViewGetMinMaxResp(super::ViewGetMinMaxResp),
269        #[prost(message, tag = "21")]
270        ViewOnUpdateResp(super::ViewOnUpdateResp),
271        #[prost(message, tag = "22")]
272        ViewRemoveOnUpdateResp(super::ViewRemoveOnUpdateResp),
273        #[prost(message, tag = "23")]
274        ViewSetDepthResp(super::ViewSetDepthResp),
275        #[prost(message, tag = "24")]
276        ViewToColumnsStringResp(super::ViewToColumnsStringResp),
277        #[prost(message, tag = "25")]
278        ViewToCsvResp(super::ViewToCsvResp),
279        #[prost(message, tag = "26")]
280        ViewToRowsStringResp(super::ViewToRowsStringResp),
281        #[prost(message, tag = "36")]
282        ViewToNdjsonStringResp(super::ViewToNdjsonStringResp),
283        #[prost(message, tag = "27")]
284        MakeTableResp(super::MakeTableResp),
285        #[prost(message, tag = "28")]
286        TableDeleteResp(super::TableDeleteResp),
287        #[prost(message, tag = "29")]
288        TableOnDeleteResp(super::TableOnDeleteResp),
289        #[prost(message, tag = "30")]
290        TableRemoveDeleteResp(super::TableRemoveDeleteResp),
291        #[prost(message, tag = "31")]
292        TableRemoveResp(super::TableRemoveResp),
293        #[prost(message, tag = "32")]
294        TableReplaceResp(super::TableReplaceResp),
295        #[prost(message, tag = "33")]
296        TableUpdateResp(super::TableUpdateResp),
297        #[prost(message, tag = "34")]
298        ViewOnDeleteResp(super::ViewOnDeleteResp),
299        #[prost(message, tag = "35")]
300        ViewRemoveDeleteResp(super::ViewRemoveDeleteResp),
301        #[prost(message, tag = "38")]
302        MakeJoinTableResp(super::MakeJoinTableResp),
303        #[prost(message, tag = "50")]
304        ServerError(super::ServerError),
305    }
306}
307/// Informs the client of the feature set, e.g. what to expect in the
308/// `ViewConfig` message.
309#[derive(serde::Serialize)]
310#[allow(clippy::derive_partial_eq_without_eq)]
311#[derive(Clone, PartialEq, ::prost::Message)]
312pub struct GetFeaturesReq {}
313#[derive(serde::Serialize)]
314#[allow(clippy::derive_partial_eq_without_eq)]
315#[derive(Clone, PartialEq, ::prost::Message)]
316pub struct GetFeaturesResp {
317    #[prost(bool, tag = "1")]
318    pub group_by: bool,
319    #[prost(bool, tag = "2")]
320    pub split_by: bool,
321    #[prost(bool, tag = "3")]
322    pub expressions: bool,
323    #[prost(bool, tag = "4")]
324    pub on_update: bool,
325    #[prost(bool, tag = "5")]
326    pub sort: bool,
327    #[prost(map = "uint32, message", tag = "6")]
328    pub filter_ops: ::std::collections::HashMap<
329        u32,
330        get_features_resp::ColumnTypeOptions,
331    >,
332    #[prost(map = "uint32, message", tag = "7")]
333    pub aggregates: ::std::collections::HashMap<
334        u32,
335        get_features_resp::AggregateOptions,
336    >,
337    #[prost(enumeration = "GroupRollupMode", repeated, tag = "8")]
338    pub group_rollup_mode: ::prost::alloc::vec::Vec<i32>,
339}
340/// Nested message and enum types in `GetFeaturesResp`.
341pub mod get_features_resp {
342    #[derive(serde::Serialize)]
343    #[allow(clippy::derive_partial_eq_without_eq)]
344    #[derive(Clone, PartialEq, ::prost::Message)]
345    pub struct ColumnTypeOptions {
346        #[prost(string, repeated, tag = "1")]
347        pub options: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
348    }
349    #[derive(serde::Serialize)]
350    #[allow(clippy::derive_partial_eq_without_eq)]
351    #[derive(Clone, PartialEq, ::prost::Message)]
352    pub struct AggregateOptions {
353        #[prost(message, repeated, tag = "1")]
354        pub aggregates: ::prost::alloc::vec::Vec<AggregateArgs>,
355    }
356    #[derive(serde::Serialize)]
357    #[allow(clippy::derive_partial_eq_without_eq)]
358    #[derive(Clone, PartialEq, ::prost::Message)]
359    pub struct AggregateArgs {
360        #[prost(string, tag = "1")]
361        pub name: ::prost::alloc::string::String,
362        #[prost(enumeration = "super::ColumnType", repeated, tag = "2")]
363        pub args: ::prost::alloc::vec::Vec<i32>,
364    }
365}
366/// `Client::get_hosted_tables`
367#[derive(serde::Serialize)]
368#[allow(clippy::derive_partial_eq_without_eq)]
369#[derive(Clone, PartialEq, ::prost::Message)]
370pub struct GetHostedTablesReq {
371    #[prost(bool, tag = "1")]
372    pub subscribe: bool,
373}
374#[derive(serde::Serialize)]
375#[allow(clippy::derive_partial_eq_without_eq)]
376#[derive(Clone, PartialEq, ::prost::Message)]
377pub struct GetHostedTablesResp {
378    #[prost(message, repeated, tag = "1")]
379    pub table_infos: ::prost::alloc::vec::Vec<HostedTable>,
380}
381#[derive(serde::Serialize)]
382#[allow(clippy::derive_partial_eq_without_eq)]
383#[derive(Clone, PartialEq, ::prost::Message)]
384pub struct HostedTable {
385    #[prost(string, tag = "1")]
386    pub entity_id: ::prost::alloc::string::String,
387    #[prost(string, optional, tag = "2")]
388    pub index: ::core::option::Option<::prost::alloc::string::String>,
389    #[prost(uint32, optional, tag = "3")]
390    pub limit: ::core::option::Option<u32>,
391}
392#[derive(serde::Serialize)]
393#[allow(clippy::derive_partial_eq_without_eq)]
394#[derive(Clone, PartialEq, ::prost::Message)]
395pub struct RemoveHostedTablesUpdateReq {
396    #[prost(uint32, tag = "1")]
397    pub id: u32,
398}
399#[derive(serde::Serialize)]
400#[allow(clippy::derive_partial_eq_without_eq)]
401#[derive(Clone, PartialEq, ::prost::Message)]
402pub struct RemoveHostedTablesUpdateResp {}
403/// `Table::size`
404#[derive(serde::Serialize)]
405#[allow(clippy::derive_partial_eq_without_eq)]
406#[derive(Clone, PartialEq, ::prost::Message)]
407pub struct TableSizeReq {}
408#[derive(serde::Serialize)]
409#[allow(clippy::derive_partial_eq_without_eq)]
410#[derive(Clone, PartialEq, ::prost::Message)]
411pub struct TableSizeResp {
412    #[prost(uint32, tag = "2")]
413    pub size: u32,
414}
415/// `Table::schema`
416#[derive(serde::Serialize)]
417#[allow(clippy::derive_partial_eq_without_eq)]
418#[derive(Clone, PartialEq, ::prost::Message)]
419pub struct TableSchemaReq {}
420#[derive(serde::Serialize)]
421#[allow(clippy::derive_partial_eq_without_eq)]
422#[derive(Clone, PartialEq, ::prost::Message)]
423pub struct TableSchemaResp {
424    #[prost(message, optional, tag = "1")]
425    pub schema: ::core::option::Option<Schema>,
426}
427/// `Table::validate_expressions`
428/// TODO: This should be just `validate()`
429#[derive(serde::Serialize)]
430#[allow(clippy::derive_partial_eq_without_eq)]
431#[derive(Clone, PartialEq, ::prost::Message)]
432pub struct TableValidateExprReq {
433    #[prost(map = "string, string", tag = "1")]
434    pub column_to_expr: ::std::collections::HashMap<
435        ::prost::alloc::string::String,
436        ::prost::alloc::string::String,
437    >,
438}
439#[derive(serde::Serialize)]
440#[derive(serde::Deserialize)]
441#[allow(clippy::derive_partial_eq_without_eq)]
442#[derive(Clone, PartialEq, ::prost::Message)]
443pub struct TableValidateExprResp {
444    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
445    pub expression_schema: ::std::collections::HashMap<
446        ::prost::alloc::string::String,
447        i32,
448    >,
449    #[prost(map = "string, message", tag = "2")]
450    pub errors: ::std::collections::HashMap<
451        ::prost::alloc::string::String,
452        table_validate_expr_resp::ExprValidationError,
453    >,
454    #[prost(map = "string, string", tag = "3")]
455    pub expression_alias: ::std::collections::HashMap<
456        ::prost::alloc::string::String,
457        ::prost::alloc::string::String,
458    >,
459}
460/// Nested message and enum types in `TableValidateExprResp`.
461pub mod table_validate_expr_resp {
462    #[derive(serde::Serialize)]
463    #[derive(serde::Deserialize)]
464    #[allow(clippy::derive_partial_eq_without_eq)]
465    #[derive(Clone, PartialEq, ::prost::Message)]
466    pub struct ExprValidationError {
467        #[prost(string, tag = "1")]
468        pub error_message: ::prost::alloc::string::String,
469        #[prost(uint32, tag = "2")]
470        pub line: u32,
471        #[prost(uint32, tag = "3")]
472        pub column: u32,
473    }
474}
475/// `Table::view`
476#[derive(serde::Serialize)]
477#[allow(clippy::derive_partial_eq_without_eq)]
478#[derive(Clone, PartialEq, ::prost::Message)]
479pub struct TableMakeViewReq {
480    #[prost(string, tag = "1")]
481    pub view_id: ::prost::alloc::string::String,
482    #[prost(message, optional, tag = "2")]
483    pub config: ::core::option::Option<ViewConfig>,
484}
485#[derive(serde::Serialize)]
486#[allow(clippy::derive_partial_eq_without_eq)]
487#[derive(Clone, PartialEq, ::prost::Message)]
488pub struct TableMakeViewResp {
489    #[prost(string, tag = "1")]
490    pub view_id: ::prost::alloc::string::String,
491}
492/// `View::schema`
493#[derive(serde::Serialize)]
494#[allow(clippy::derive_partial_eq_without_eq)]
495#[derive(Clone, PartialEq, ::prost::Message)]
496pub struct ViewSchemaReq {}
497#[derive(serde::Serialize)]
498#[allow(clippy::derive_partial_eq_without_eq)]
499#[derive(Clone, PartialEq, ::prost::Message)]
500pub struct ViewSchemaResp {
501    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
502    pub schema: ::std::collections::HashMap<::prost::alloc::string::String, i32>,
503}
504/// `View::dimensions`
505#[derive(serde::Serialize)]
506#[allow(clippy::derive_partial_eq_without_eq)]
507#[derive(Clone, PartialEq, ::prost::Message)]
508pub struct ViewDimensionsReq {}
509#[derive(serde::Serialize)]
510#[derive(serde::Deserialize)]
511#[allow(clippy::derive_partial_eq_without_eq)]
512#[derive(Clone, PartialEq, ::prost::Message)]
513pub struct ViewDimensionsResp {
514    #[prost(uint32, tag = "1")]
515    pub num_table_rows: u32,
516    #[prost(uint32, tag = "2")]
517    pub num_table_columns: u32,
518    #[prost(uint32, tag = "3")]
519    pub num_view_rows: u32,
520    #[prost(uint32, tag = "4")]
521    pub num_view_columns: u32,
522}
523/// `View::get_config`
524#[derive(serde::Serialize)]
525#[allow(clippy::derive_partial_eq_without_eq)]
526#[derive(Clone, PartialEq, ::prost::Message)]
527pub struct ViewGetConfigReq {}
528#[derive(serde::Serialize)]
529#[allow(clippy::derive_partial_eq_without_eq)]
530#[derive(Clone, PartialEq, ::prost::Message)]
531pub struct ViewGetConfigResp {
532    #[prost(message, optional, tag = "1")]
533    pub config: ::core::option::Option<ViewConfig>,
534}
535/// `Client::table`.
536#[derive(serde::Serialize)]
537#[allow(clippy::derive_partial_eq_without_eq)]
538#[derive(Clone, PartialEq, ::prost::Message)]
539pub struct MakeTableReq {
540    #[prost(message, optional, tag = "1")]
541    pub data: ::core::option::Option<MakeTableData>,
542    #[prost(message, optional, tag = "2")]
543    pub options: ::core::option::Option<make_table_req::MakeTableOptions>,
544}
545/// Nested message and enum types in `MakeTableReq`.
546pub mod make_table_req {
547    #[derive(serde::Serialize)]
548    #[allow(clippy::derive_partial_eq_without_eq)]
549    #[derive(Clone, PartialEq, ::prost::Message)]
550    pub struct MakeTableOptions {
551        /// Back this Table's canonical data with the on-disk storage backend
552        /// (memory-mapped file on native; OPFS on WASM) instead of memory.
553        /// Orthogonal to `make_table_type`, so it is a standalone field.
554        #[prost(bool, optional, tag = "3")]
555        pub page_to_disk: ::core::option::Option<bool>,
556        #[prost(oneof = "make_table_options::MakeTableType", tags = "1, 2")]
557        pub make_table_type: ::core::option::Option<make_table_options::MakeTableType>,
558    }
559    /// Nested message and enum types in `MakeTableOptions`.
560    pub mod make_table_options {
561        #[derive(serde::Serialize)]
562        #[allow(clippy::derive_partial_eq_without_eq)]
563        #[derive(Clone, PartialEq, ::prost::Oneof)]
564        pub enum MakeTableType {
565            #[prost(string, tag = "1")]
566            MakeIndexTable(::prost::alloc::string::String),
567            #[prost(uint32, tag = "2")]
568            MakeLimitTable(u32),
569        }
570    }
571}
572#[derive(serde::Serialize)]
573#[allow(clippy::derive_partial_eq_without_eq)]
574#[derive(Clone, PartialEq, ::prost::Message)]
575pub struct MakeTableResp {}
576/// `Client::join` — create a read-only table from a JOIN of two tables.
577#[derive(serde::Serialize)]
578#[allow(clippy::derive_partial_eq_without_eq)]
579#[derive(Clone, PartialEq, ::prost::Message)]
580pub struct MakeJoinTableReq {
581    #[prost(string, tag = "1")]
582    pub left_table_id: ::prost::alloc::string::String,
583    #[prost(string, tag = "2")]
584    pub right_table_id: ::prost::alloc::string::String,
585    #[prost(string, tag = "3")]
586    pub on_column: ::prost::alloc::string::String,
587    #[prost(enumeration = "JoinType", tag = "4")]
588    pub join_type: i32,
589    #[prost(string, tag = "5")]
590    pub right_on_column: ::prost::alloc::string::String,
591}
592#[derive(serde::Serialize)]
593#[allow(clippy::derive_partial_eq_without_eq)]
594#[derive(Clone, PartialEq, ::prost::Message)]
595pub struct MakeJoinTableResp {}
596/// `Table::delete`
597#[derive(serde::Serialize)]
598#[allow(clippy::derive_partial_eq_without_eq)]
599#[derive(Clone, PartialEq, ::prost::Message)]
600pub struct TableDeleteReq {
601    #[prost(bool, tag = "1")]
602    pub is_immediate: bool,
603}
604#[derive(serde::Serialize)]
605#[allow(clippy::derive_partial_eq_without_eq)]
606#[derive(Clone, PartialEq, ::prost::Message)]
607pub struct TableDeleteResp {}
608/// `Table::on_delete`
609#[derive(serde::Serialize)]
610#[allow(clippy::derive_partial_eq_without_eq)]
611#[derive(Clone, PartialEq, ::prost::Message)]
612pub struct TableOnDeleteReq {}
613#[derive(serde::Serialize)]
614#[allow(clippy::derive_partial_eq_without_eq)]
615#[derive(Clone, PartialEq, ::prost::Message)]
616pub struct TableOnDeleteResp {}
617/// `Table::make_port`
618#[derive(serde::Serialize)]
619#[allow(clippy::derive_partial_eq_without_eq)]
620#[derive(Clone, PartialEq, ::prost::Message)]
621pub struct TableMakePortReq {}
622#[derive(serde::Serialize)]
623#[allow(clippy::derive_partial_eq_without_eq)]
624#[derive(Clone, PartialEq, ::prost::Message)]
625pub struct TableMakePortResp {
626    #[prost(uint32, tag = "1")]
627    pub port_id: u32,
628}
629/// `Table::remove_delete`
630#[derive(serde::Serialize)]
631#[allow(clippy::derive_partial_eq_without_eq)]
632#[derive(Clone, PartialEq, ::prost::Message)]
633pub struct TableRemoveDeleteReq {
634    #[prost(uint32, tag = "1")]
635    pub id: u32,
636}
637#[derive(serde::Serialize)]
638#[allow(clippy::derive_partial_eq_without_eq)]
639#[derive(Clone, PartialEq, ::prost::Message)]
640pub struct TableRemoveDeleteResp {}
641/// `Table::update`
642#[derive(serde::Serialize)]
643#[allow(clippy::derive_partial_eq_without_eq)]
644#[derive(Clone, PartialEq, ::prost::Message)]
645pub struct TableUpdateReq {
646    #[prost(message, optional, tag = "1")]
647    pub data: ::core::option::Option<MakeTableData>,
648    #[prost(uint32, tag = "2")]
649    pub port_id: u32,
650}
651#[derive(serde::Serialize)]
652#[allow(clippy::derive_partial_eq_without_eq)]
653#[derive(Clone, PartialEq, ::prost::Message)]
654pub struct TableUpdateResp {}
655/// `Table::replace`
656#[derive(serde::Serialize)]
657#[allow(clippy::derive_partial_eq_without_eq)]
658#[derive(Clone, PartialEq, ::prost::Message)]
659pub struct TableReplaceReq {
660    #[prost(message, optional, tag = "1")]
661    pub data: ::core::option::Option<MakeTableData>,
662}
663#[derive(serde::Serialize)]
664#[allow(clippy::derive_partial_eq_without_eq)]
665#[derive(Clone, PartialEq, ::prost::Message)]
666pub struct TableReplaceResp {}
667/// `Table::remove`
668#[derive(serde::Serialize)]
669#[allow(clippy::derive_partial_eq_without_eq)]
670#[derive(Clone, PartialEq, ::prost::Message)]
671pub struct TableRemoveReq {
672    #[prost(message, optional, tag = "1")]
673    pub data: ::core::option::Option<MakeTableData>,
674}
675#[derive(serde::Serialize)]
676#[allow(clippy::derive_partial_eq_without_eq)]
677#[derive(Clone, PartialEq, ::prost::Message)]
678pub struct TableRemoveResp {}
679#[derive(serde::Serialize)]
680#[allow(clippy::derive_partial_eq_without_eq)]
681#[derive(Clone, PartialEq, ::prost::Message)]
682pub struct ViewOnUpdateReq {
683    #[prost(enumeration = "view_on_update_req::Mode", optional, tag = "1")]
684    pub mode: ::core::option::Option<i32>,
685}
686/// Nested message and enum types in `ViewOnUpdateReq`.
687pub mod view_on_update_req {
688    #[derive(serde::Serialize)]
689    #[derive(
690        Clone,
691        Copy,
692        Debug,
693        PartialEq,
694        Eq,
695        Hash,
696        PartialOrd,
697        Ord,
698        ::prost::Enumeration
699    )]
700    #[repr(i32)]
701    pub enum Mode {
702        Row = 0,
703    }
704    impl Mode {
705        /// String value of the enum field names used in the ProtoBuf definition.
706        ///
707        /// The values are not transformed in any way and thus are considered stable
708        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
709        pub fn as_str_name(&self) -> &'static str {
710            match self {
711                Mode::Row => "ROW",
712            }
713        }
714        /// Creates an enum from field names used in the ProtoBuf definition.
715        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
716            match value {
717                "ROW" => Some(Self::Row),
718                _ => None,
719            }
720        }
721    }
722}
723#[derive(ts_rs::TS)]
724#[derive(serde::Serialize)]
725#[allow(clippy::derive_partial_eq_without_eq)]
726#[derive(Clone, PartialEq, ::prost::Message)]
727pub struct ViewOnUpdateResp {
728    #[prost(bytes = "vec", optional, tag = "1")]
729    #[ts(as = "Vec::<u8>")]
730    #[serde(with = "serde_bytes")]
731    pub delta: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
732    #[prost(uint32, tag = "2")]
733    pub port_id: u32,
734}
735#[derive(serde::Serialize)]
736#[allow(clippy::derive_partial_eq_without_eq)]
737#[derive(Clone, PartialEq, ::prost::Message)]
738pub struct ViewOnDeleteReq {}
739#[derive(serde::Serialize)]
740#[allow(clippy::derive_partial_eq_without_eq)]
741#[derive(Clone, PartialEq, ::prost::Message)]
742pub struct ViewOnDeleteResp {}
743#[derive(serde::Serialize)]
744#[allow(clippy::derive_partial_eq_without_eq)]
745#[derive(Clone, PartialEq, ::prost::Message)]
746pub struct ViewRemoveDeleteReq {
747    #[prost(uint32, tag = "1")]
748    pub id: u32,
749}
750#[derive(serde::Serialize)]
751#[allow(clippy::derive_partial_eq_without_eq)]
752#[derive(Clone, PartialEq, ::prost::Message)]
753pub struct ViewRemoveDeleteResp {}
754#[derive(serde::Serialize)]
755#[allow(clippy::derive_partial_eq_without_eq)]
756#[derive(Clone, PartialEq, ::prost::Message)]
757pub struct ViewToColumnsStringReq {
758    #[prost(message, optional, tag = "1")]
759    pub viewport: ::core::option::Option<ViewPort>,
760    #[prost(bool, optional, tag = "2")]
761    pub id: ::core::option::Option<bool>,
762    #[prost(bool, optional, tag = "3")]
763    pub index: ::core::option::Option<bool>,
764    #[prost(bool, optional, tag = "4")]
765    pub formatted: ::core::option::Option<bool>,
766}
767#[derive(serde::Serialize)]
768#[allow(clippy::derive_partial_eq_without_eq)]
769#[derive(Clone, PartialEq, ::prost::Message)]
770pub struct ViewToColumnsStringResp {
771    #[prost(string, tag = "1")]
772    pub json_string: ::prost::alloc::string::String,
773}
774#[derive(serde::Serialize)]
775#[allow(clippy::derive_partial_eq_without_eq)]
776#[derive(Clone, PartialEq, ::prost::Message)]
777pub struct ViewToRowsStringReq {
778    #[prost(message, optional, tag = "1")]
779    pub viewport: ::core::option::Option<ViewPort>,
780    #[prost(bool, optional, tag = "2")]
781    pub id: ::core::option::Option<bool>,
782    #[prost(bool, optional, tag = "3")]
783    pub index: ::core::option::Option<bool>,
784    #[prost(bool, optional, tag = "4")]
785    pub formatted: ::core::option::Option<bool>,
786}
787#[derive(serde::Serialize)]
788#[allow(clippy::derive_partial_eq_without_eq)]
789#[derive(Clone, PartialEq, ::prost::Message)]
790pub struct ViewToRowsStringResp {
791    #[prost(string, tag = "1")]
792    pub json_string: ::prost::alloc::string::String,
793}
794#[derive(serde::Serialize)]
795#[allow(clippy::derive_partial_eq_without_eq)]
796#[derive(Clone, PartialEq, ::prost::Message)]
797pub struct ViewToNdjsonStringReq {
798    #[prost(message, optional, tag = "1")]
799    pub viewport: ::core::option::Option<ViewPort>,
800    #[prost(bool, optional, tag = "2")]
801    pub id: ::core::option::Option<bool>,
802    #[prost(bool, optional, tag = "3")]
803    pub index: ::core::option::Option<bool>,
804    #[prost(bool, optional, tag = "4")]
805    pub formatted: ::core::option::Option<bool>,
806}
807#[derive(serde::Serialize)]
808#[allow(clippy::derive_partial_eq_without_eq)]
809#[derive(Clone, PartialEq, ::prost::Message)]
810pub struct ViewToNdjsonStringResp {
811    #[prost(string, tag = "1")]
812    pub ndjson_string: ::prost::alloc::string::String,
813}
814#[derive(serde::Serialize)]
815#[allow(clippy::derive_partial_eq_without_eq)]
816#[derive(Clone, PartialEq, ::prost::Message)]
817pub struct ViewToArrowReq {
818    #[prost(message, optional, tag = "1")]
819    pub viewport: ::core::option::Option<ViewPort>,
820    #[prost(string, optional, tag = "2")]
821    pub compression: ::core::option::Option<::prost::alloc::string::String>,
822}
823#[derive(serde::Serialize)]
824#[allow(clippy::derive_partial_eq_without_eq)]
825#[derive(Clone, PartialEq, ::prost::Message)]
826pub struct ViewToArrowResp {
827    #[prost(bytes = "vec", tag = "1")]
828    #[serde(skip)]
829    pub arrow: ::prost::alloc::vec::Vec<u8>,
830}
831#[derive(serde::Serialize)]
832#[allow(clippy::derive_partial_eq_without_eq)]
833#[derive(Clone, PartialEq, ::prost::Message)]
834pub struct ViewColumnPathsReq {
835    #[prost(uint32, optional, tag = "1")]
836    pub start_col: ::core::option::Option<u32>,
837    #[prost(uint32, optional, tag = "2")]
838    pub end_col: ::core::option::Option<u32>,
839}
840#[derive(serde::Serialize)]
841#[allow(clippy::derive_partial_eq_without_eq)]
842#[derive(Clone, PartialEq, ::prost::Message)]
843pub struct ViewColumnPathsResp {
844    /// repeated ColumnPath paths = 1;
845    #[prost(string, repeated, tag = "1")]
846    pub paths: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
847}
848#[derive(serde::Serialize)]
849#[allow(clippy::derive_partial_eq_without_eq)]
850#[derive(Clone, PartialEq, ::prost::Message)]
851pub struct ViewDeleteReq {}
852#[derive(serde::Serialize)]
853#[allow(clippy::derive_partial_eq_without_eq)]
854#[derive(Clone, PartialEq, ::prost::Message)]
855pub struct ViewDeleteResp {}
856#[derive(serde::Serialize)]
857#[allow(clippy::derive_partial_eq_without_eq)]
858#[derive(Clone, PartialEq, ::prost::Message)]
859pub struct ViewGetMinMaxReq {
860    #[prost(string, tag = "1")]
861    pub column_name: ::prost::alloc::string::String,
862}
863#[derive(serde::Serialize)]
864#[allow(clippy::derive_partial_eq_without_eq)]
865#[derive(Clone, PartialEq, ::prost::Message)]
866pub struct ViewGetMinMaxResp {
867    #[prost(message, optional, tag = "1")]
868    pub min: ::core::option::Option<Scalar>,
869    #[prost(message, optional, tag = "2")]
870    pub max: ::core::option::Option<Scalar>,
871}
872#[derive(serde::Serialize)]
873#[allow(clippy::derive_partial_eq_without_eq)]
874#[derive(Clone, PartialEq, ::prost::Message)]
875pub struct ViewExpressionSchemaReq {}
876#[derive(serde::Serialize)]
877#[allow(clippy::derive_partial_eq_without_eq)]
878#[derive(Clone, PartialEq, ::prost::Message)]
879pub struct ViewExpressionSchemaResp {
880    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
881    pub schema: ::std::collections::HashMap<::prost::alloc::string::String, i32>,
882}
883#[derive(serde::Serialize)]
884#[allow(clippy::derive_partial_eq_without_eq)]
885#[derive(Clone, PartialEq, ::prost::Message)]
886pub struct ViewToCsvReq {
887    #[prost(message, optional, tag = "1")]
888    pub viewport: ::core::option::Option<ViewPort>,
889}
890#[derive(serde::Serialize)]
891#[allow(clippy::derive_partial_eq_without_eq)]
892#[derive(Clone, PartialEq, ::prost::Message)]
893pub struct ViewToCsvResp {
894    #[prost(string, tag = "1")]
895    pub csv: ::prost::alloc::string::String,
896}
897#[derive(serde::Serialize)]
898#[allow(clippy::derive_partial_eq_without_eq)]
899#[derive(Clone, PartialEq, ::prost::Message)]
900pub struct ViewRemoveOnUpdateReq {
901    #[prost(uint32, tag = "1")]
902    pub id: u32,
903}
904#[derive(serde::Serialize)]
905#[allow(clippy::derive_partial_eq_without_eq)]
906#[derive(Clone, PartialEq, ::prost::Message)]
907pub struct ViewRemoveOnUpdateResp {}
908#[derive(serde::Serialize)]
909#[allow(clippy::derive_partial_eq_without_eq)]
910#[derive(Clone, PartialEq, ::prost::Message)]
911pub struct ViewCollapseReq {
912    #[prost(uint32, tag = "1")]
913    pub row_index: u32,
914}
915#[derive(serde::Serialize)]
916#[allow(clippy::derive_partial_eq_without_eq)]
917#[derive(Clone, PartialEq, ::prost::Message)]
918pub struct ViewCollapseResp {
919    #[prost(uint32, tag = "1")]
920    pub num_changed: u32,
921}
922#[derive(serde::Serialize)]
923#[allow(clippy::derive_partial_eq_without_eq)]
924#[derive(Clone, PartialEq, ::prost::Message)]
925pub struct ViewExpandReq {
926    #[prost(uint32, tag = "1")]
927    pub row_index: u32,
928}
929#[derive(serde::Serialize)]
930#[allow(clippy::derive_partial_eq_without_eq)]
931#[derive(Clone, PartialEq, ::prost::Message)]
932pub struct ViewExpandResp {
933    #[prost(uint32, tag = "1")]
934    pub num_changed: u32,
935}
936/// `View::set_depth`
937#[derive(serde::Serialize)]
938#[allow(clippy::derive_partial_eq_without_eq)]
939#[derive(Clone, PartialEq, ::prost::Message)]
940pub struct ViewSetDepthReq {
941    #[prost(uint32, tag = "1")]
942    pub depth: u32,
943}
944#[derive(serde::Serialize)]
945#[allow(clippy::derive_partial_eq_without_eq)]
946#[derive(Clone, PartialEq, ::prost::Message)]
947pub struct ViewSetDepthResp {}
948#[derive(serde::Serialize)]
949#[allow(clippy::derive_partial_eq_without_eq)]
950#[derive(Clone, PartialEq, ::prost::Message)]
951pub struct ServerSystemInfoReq {}
952#[derive(serde::Serialize)]
953#[allow(clippy::derive_partial_eq_without_eq)]
954#[derive(Clone, PartialEq, ::prost::Message)]
955pub struct ServerSystemInfoResp {
956    #[prost(uint64, tag = "1")]
957    pub heap_size: u64,
958    #[prost(uint64, tag = "2")]
959    pub used_size: u64,
960    #[prost(uint32, tag = "3")]
961    pub cpu_time: u32,
962    #[prost(uint32, tag = "4")]
963    pub cpu_time_epoch: u32,
964}
965#[derive(serde::Serialize)]
966#[allow(clippy::derive_partial_eq_without_eq)]
967#[derive(Clone, PartialEq, ::prost::Message)]
968pub struct ViewConfig {
969    #[prost(string, repeated, tag = "1")]
970    pub group_by: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
971    #[prost(string, repeated, tag = "2")]
972    pub split_by: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
973    #[prost(message, optional, tag = "3")]
974    pub columns: ::core::option::Option<ColumnsUpdate>,
975    #[prost(message, repeated, tag = "4")]
976    pub filter: ::prost::alloc::vec::Vec<view_config::Filter>,
977    #[prost(message, repeated, tag = "5")]
978    pub sort: ::prost::alloc::vec::Vec<view_config::Sort>,
979    #[prost(map = "string, string", tag = "6")]
980    pub expressions: ::std::collections::HashMap<
981        ::prost::alloc::string::String,
982        ::prost::alloc::string::String,
983    >,
984    #[prost(map = "string, message", tag = "7")]
985    pub aggregates: ::std::collections::HashMap<
986        ::prost::alloc::string::String,
987        view_config::AggList,
988    >,
989    #[prost(enumeration = "view_config::FilterReducer", tag = "8")]
990    pub filter_op: i32,
991    #[prost(uint32, optional, tag = "9")]
992    pub group_by_depth: ::core::option::Option<u32>,
993    #[prost(enumeration = "GroupRollupMode", optional, tag = "10")]
994    pub group_rollup_mode: ::core::option::Option<i32>,
995}
996/// Nested message and enum types in `ViewConfig`.
997pub mod view_config {
998    #[derive(serde::Serialize)]
999    #[allow(clippy::derive_partial_eq_without_eq)]
1000    #[derive(Clone, PartialEq, ::prost::Message)]
1001    pub struct AggList {
1002        #[prost(string, repeated, tag = "1")]
1003        pub aggregations: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1004    }
1005    #[derive(serde::Serialize)]
1006    #[allow(clippy::derive_partial_eq_without_eq)]
1007    #[derive(Clone, PartialEq, ::prost::Message)]
1008    pub struct Sort {
1009        #[prost(string, tag = "1")]
1010        pub column: ::prost::alloc::string::String,
1011        #[prost(enumeration = "super::SortOp", tag = "2")]
1012        pub op: i32,
1013    }
1014    #[derive(serde::Serialize)]
1015    #[allow(clippy::derive_partial_eq_without_eq)]
1016    #[derive(Clone, PartialEq, ::prost::Message)]
1017    pub struct Filter {
1018        #[prost(string, tag = "1")]
1019        pub column: ::prost::alloc::string::String,
1020        #[prost(string, tag = "2")]
1021        pub op: ::prost::alloc::string::String,
1022        #[prost(message, repeated, tag = "3")]
1023        pub value: ::prost::alloc::vec::Vec<super::Scalar>,
1024    }
1025    #[derive(serde::Serialize)]
1026    #[derive(
1027        Clone,
1028        Copy,
1029        Debug,
1030        PartialEq,
1031        Eq,
1032        Hash,
1033        PartialOrd,
1034        Ord,
1035        ::prost::Enumeration
1036    )]
1037    #[repr(i32)]
1038    pub enum FilterReducer {
1039        And = 0,
1040        Or = 1,
1041    }
1042    impl FilterReducer {
1043        /// String value of the enum field names used in the ProtoBuf definition.
1044        ///
1045        /// The values are not transformed in any way and thus are considered stable
1046        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1047        pub fn as_str_name(&self) -> &'static str {
1048            match self {
1049                FilterReducer::And => "AND",
1050                FilterReducer::Or => "OR",
1051            }
1052        }
1053        /// Creates an enum from field names used in the ProtoBuf definition.
1054        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1055            match value {
1056                "AND" => Some(Self::And),
1057                "OR" => Some(Self::Or),
1058                _ => None,
1059            }
1060        }
1061    }
1062}
1063#[derive(serde::Serialize)]
1064#[allow(clippy::derive_partial_eq_without_eq)]
1065#[derive(Clone, PartialEq, ::prost::Message)]
1066pub struct ColumnsUpdate {
1067    #[prost(oneof = "columns_update::OptColumns", tags = "1, 2")]
1068    pub opt_columns: ::core::option::Option<columns_update::OptColumns>,
1069}
1070/// Nested message and enum types in `ColumnsUpdate`.
1071pub mod columns_update {
1072    #[derive(serde::Serialize)]
1073    #[allow(clippy::derive_partial_eq_without_eq)]
1074    #[derive(Clone, PartialEq, ::prost::Message)]
1075    pub struct Columns {
1076        #[prost(string, repeated, tag = "1")]
1077        pub columns: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1078    }
1079    #[derive(serde::Serialize)]
1080    #[allow(clippy::derive_partial_eq_without_eq)]
1081    #[derive(Clone, PartialEq, ::prost::Oneof)]
1082    pub enum OptColumns {
1083        #[prost(enumeration = "::prost_types::NullValue", tag = "1")]
1084        DefaultColumns(i32),
1085        #[prost(message, tag = "2")]
1086        Columns(Columns),
1087    }
1088}
1089#[derive(serde::Serialize)]
1090#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1091#[repr(i32)]
1092pub enum StatusCode {
1093    ServerError = 0,
1094    ViewNotFound = 1,
1095    TransportError = 2,
1096}
1097impl StatusCode {
1098    /// String value of the enum field names used in the ProtoBuf definition.
1099    ///
1100    /// The values are not transformed in any way and thus are considered stable
1101    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1102    pub fn as_str_name(&self) -> &'static str {
1103        match self {
1104            StatusCode::ServerError => "SERVER_ERROR",
1105            StatusCode::ViewNotFound => "VIEW_NOT_FOUND",
1106            StatusCode::TransportError => "TRANSPORT_ERROR",
1107        }
1108    }
1109    /// Creates an enum from field names used in the ProtoBuf definition.
1110    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1111        match value {
1112            "SERVER_ERROR" => Some(Self::ServerError),
1113            "VIEW_NOT_FOUND" => Some(Self::ViewNotFound),
1114            "TRANSPORT_ERROR" => Some(Self::TransportError),
1115            _ => None,
1116        }
1117    }
1118}
1119/// View types
1120#[derive(ts_rs::TS)]
1121#[derive(serde::Serialize)]
1122#[derive(serde::Deserialize)]
1123#[serde(rename_all = "snake_case")]
1124#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1125#[repr(i32)]
1126pub enum ColumnType {
1127    String = 0,
1128    Date = 1,
1129    Datetime = 2,
1130    Integer = 3,
1131    Float = 4,
1132    Boolean = 5,
1133}
1134impl ColumnType {
1135    /// String value of the enum field names used in the ProtoBuf definition.
1136    ///
1137    /// The values are not transformed in any way and thus are considered stable
1138    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1139    pub fn as_str_name(&self) -> &'static str {
1140        match self {
1141            ColumnType::String => "STRING",
1142            ColumnType::Date => "DATE",
1143            ColumnType::Datetime => "DATETIME",
1144            ColumnType::Integer => "INTEGER",
1145            ColumnType::Float => "FLOAT",
1146            ColumnType::Boolean => "BOOLEAN",
1147        }
1148    }
1149    /// Creates an enum from field names used in the ProtoBuf definition.
1150    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1151        match value {
1152            "STRING" => Some(Self::String),
1153            "DATE" => Some(Self::Date),
1154            "DATETIME" => Some(Self::Datetime),
1155            "INTEGER" => Some(Self::Integer),
1156            "FLOAT" => Some(Self::Float),
1157            "BOOLEAN" => Some(Self::Boolean),
1158            _ => None,
1159        }
1160    }
1161}
1162/// TODO This belongs in features
1163#[derive(serde::Serialize)]
1164#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1165#[repr(i32)]
1166pub enum SortOp {
1167    SortNone = 0,
1168    SortAsc = 1,
1169    SortDesc = 2,
1170    SortColAsc = 3,
1171    SortColDesc = 4,
1172    SortAscAbs = 5,
1173    SortDescAbs = 6,
1174    SortColAscAbs = 7,
1175    SortColDescAbs = 8,
1176}
1177impl SortOp {
1178    /// String value of the enum field names used in the ProtoBuf definition.
1179    ///
1180    /// The values are not transformed in any way and thus are considered stable
1181    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1182    pub fn as_str_name(&self) -> &'static str {
1183        match self {
1184            SortOp::SortNone => "SORT_NONE",
1185            SortOp::SortAsc => "SORT_ASC",
1186            SortOp::SortDesc => "SORT_DESC",
1187            SortOp::SortColAsc => "SORT_COL_ASC",
1188            SortOp::SortColDesc => "SORT_COL_DESC",
1189            SortOp::SortAscAbs => "SORT_ASC_ABS",
1190            SortOp::SortDescAbs => "SORT_DESC_ABS",
1191            SortOp::SortColAscAbs => "SORT_COL_ASC_ABS",
1192            SortOp::SortColDescAbs => "SORT_COL_DESC_ABS",
1193        }
1194    }
1195    /// Creates an enum from field names used in the ProtoBuf definition.
1196    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1197        match value {
1198            "SORT_NONE" => Some(Self::SortNone),
1199            "SORT_ASC" => Some(Self::SortAsc),
1200            "SORT_DESC" => Some(Self::SortDesc),
1201            "SORT_COL_ASC" => Some(Self::SortColAsc),
1202            "SORT_COL_DESC" => Some(Self::SortColDesc),
1203            "SORT_ASC_ABS" => Some(Self::SortAscAbs),
1204            "SORT_DESC_ABS" => Some(Self::SortDescAbs),
1205            "SORT_COL_ASC_ABS" => Some(Self::SortColAscAbs),
1206            "SORT_COL_DESC_ABS" => Some(Self::SortColDescAbs),
1207            _ => None,
1208        }
1209    }
1210}
1211#[derive(serde::Serialize)]
1212#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1213#[repr(i32)]
1214pub enum GroupRollupMode {
1215    Rollup = 0,
1216    Flat = 1,
1217    Total = 2,
1218}
1219impl GroupRollupMode {
1220    /// String value of the enum field names used in the ProtoBuf definition.
1221    ///
1222    /// The values are not transformed in any way and thus are considered stable
1223    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1224    pub fn as_str_name(&self) -> &'static str {
1225        match self {
1226            GroupRollupMode::Rollup => "ROLLUP",
1227            GroupRollupMode::Flat => "FLAT",
1228            GroupRollupMode::Total => "TOTAL",
1229        }
1230    }
1231    /// Creates an enum from field names used in the ProtoBuf definition.
1232    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1233        match value {
1234            "ROLLUP" => Some(Self::Rollup),
1235            "FLAT" => Some(Self::Flat),
1236            "TOTAL" => Some(Self::Total),
1237            _ => None,
1238        }
1239    }
1240}
1241#[derive(serde::Deserialize, ts_rs::TS)]
1242#[serde(rename_all = "snake_case")]
1243#[derive(serde::Serialize)]
1244#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1245#[repr(i32)]
1246pub enum JoinType {
1247    Inner = 0,
1248    Left = 1,
1249    Outer = 2,
1250}
1251impl JoinType {
1252    /// String value of the enum field names used in the ProtoBuf definition.
1253    ///
1254    /// The values are not transformed in any way and thus are considered stable
1255    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1256    pub fn as_str_name(&self) -> &'static str {
1257        match self {
1258            JoinType::Inner => "INNER",
1259            JoinType::Left => "LEFT",
1260            JoinType::Outer => "OUTER",
1261        }
1262    }
1263    /// Creates an enum from field names used in the ProtoBuf definition.
1264    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1265        match value {
1266            "INNER" => Some(Self::Inner),
1267            "LEFT" => Some(Self::Left),
1268            "OUTER" => Some(Self::Outer),
1269            _ => None,
1270        }
1271    }
1272}