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 machine_column_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, 41, 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, 39, 40"
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 = "41")]
149        TableDescribeReq(super::TableDescribeReq),
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        #[prost(message, tag = "39")]
210        ViewOnRemoveReq(super::ViewOnRemoveReq),
211        #[prost(message, tag = "40")]
212        ViewRemoveOnRemoveReq(super::ViewRemoveOnRemoveReq),
213    }
214}
215#[derive(serde::Serialize)]
216#[allow(clippy::derive_partial_eq_without_eq)]
217#[derive(Clone, PartialEq, ::prost::Message)]
218pub struct Response {
219    #[prost(uint32, tag = "1")]
220    pub msg_id: u32,
221    #[prost(string, tag = "2")]
222    pub entity_id: ::prost::alloc::string::String,
223    #[prost(
224        oneof = "response::ClientResp",
225        tags = "3, 4, 37, 5, 6, 7, 8, 41, 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, 39, 40, 50"
226    )]
227    pub client_resp: ::core::option::Option<response::ClientResp>,
228}
229/// Nested message and enum types in `Response`.
230pub mod response {
231    #[derive(serde::Serialize)]
232    #[allow(clippy::derive_partial_eq_without_eq)]
233    #[derive(Clone, PartialEq, ::prost::Oneof)]
234    pub enum ClientResp {
235        #[prost(message, tag = "3")]
236        GetFeaturesResp(super::GetFeaturesResp),
237        #[prost(message, tag = "4")]
238        GetHostedTablesResp(super::GetHostedTablesResp),
239        #[prost(message, tag = "37")]
240        RemoveHostedTablesUpdateResp(super::RemoveHostedTablesUpdateResp),
241        #[prost(message, tag = "5")]
242        TableMakePortResp(super::TableMakePortResp),
243        #[prost(message, tag = "6")]
244        TableMakeViewResp(super::TableMakeViewResp),
245        #[prost(message, tag = "7")]
246        TableSchemaResp(super::TableSchemaResp),
247        #[prost(message, tag = "8")]
248        TableSizeResp(super::TableSizeResp),
249        #[prost(message, tag = "41")]
250        TableDescribeResp(super::TableDescribeResp),
251        #[prost(message, tag = "10")]
252        ViewColumnPathsResp(super::ViewColumnPathsResp),
253        #[prost(message, tag = "11")]
254        ViewDeleteResp(super::ViewDeleteResp),
255        #[prost(message, tag = "12")]
256        ViewDimensionsResp(super::ViewDimensionsResp),
257        #[prost(message, tag = "13")]
258        ViewExpressionSchemaResp(super::ViewExpressionSchemaResp),
259        #[prost(message, tag = "14")]
260        ViewGetConfigResp(super::ViewGetConfigResp),
261        #[prost(message, tag = "15")]
262        ViewSchemaResp(super::ViewSchemaResp),
263        #[prost(message, tag = "16")]
264        ViewToArrowResp(super::ViewToArrowResp),
265        #[prost(message, tag = "17")]
266        ServerSystemInfoResp(super::ServerSystemInfoResp),
267        #[prost(message, tag = "18")]
268        ViewCollapseResp(super::ViewCollapseResp),
269        #[prost(message, tag = "19")]
270        ViewExpandResp(super::ViewExpandResp),
271        #[prost(message, tag = "20")]
272        ViewGetMinMaxResp(super::ViewGetMinMaxResp),
273        #[prost(message, tag = "21")]
274        ViewOnUpdateResp(super::ViewOnUpdateResp),
275        #[prost(message, tag = "22")]
276        ViewRemoveOnUpdateResp(super::ViewRemoveOnUpdateResp),
277        #[prost(message, tag = "23")]
278        ViewSetDepthResp(super::ViewSetDepthResp),
279        #[prost(message, tag = "24")]
280        ViewToColumnsStringResp(super::ViewToColumnsStringResp),
281        #[prost(message, tag = "25")]
282        ViewToCsvResp(super::ViewToCsvResp),
283        #[prost(message, tag = "26")]
284        ViewToRowsStringResp(super::ViewToRowsStringResp),
285        #[prost(message, tag = "36")]
286        ViewToNdjsonStringResp(super::ViewToNdjsonStringResp),
287        #[prost(message, tag = "27")]
288        MakeTableResp(super::MakeTableResp),
289        #[prost(message, tag = "28")]
290        TableDeleteResp(super::TableDeleteResp),
291        #[prost(message, tag = "29")]
292        TableOnDeleteResp(super::TableOnDeleteResp),
293        #[prost(message, tag = "30")]
294        TableRemoveDeleteResp(super::TableRemoveDeleteResp),
295        #[prost(message, tag = "31")]
296        TableRemoveResp(super::TableRemoveResp),
297        #[prost(message, tag = "32")]
298        TableReplaceResp(super::TableReplaceResp),
299        #[prost(message, tag = "33")]
300        TableUpdateResp(super::TableUpdateResp),
301        #[prost(message, tag = "34")]
302        ViewOnDeleteResp(super::ViewOnDeleteResp),
303        #[prost(message, tag = "35")]
304        ViewRemoveDeleteResp(super::ViewRemoveDeleteResp),
305        #[prost(message, tag = "38")]
306        MakeJoinTableResp(super::MakeJoinTableResp),
307        #[prost(message, tag = "39")]
308        ViewOnRemoveResp(super::ViewOnRemoveResp),
309        #[prost(message, tag = "40")]
310        ViewRemoveOnRemoveResp(super::ViewRemoveOnRemoveResp),
311        #[prost(message, tag = "50")]
312        ServerError(super::ServerError),
313    }
314}
315/// Informs the client of the feature set, e.g. what to expect in the
316/// `ViewConfig` message.
317#[derive(serde::Serialize)]
318#[allow(clippy::derive_partial_eq_without_eq)]
319#[derive(Clone, PartialEq, ::prost::Message)]
320pub struct GetFeaturesReq {}
321#[derive(serde::Serialize)]
322#[allow(clippy::derive_partial_eq_without_eq)]
323#[derive(Clone, PartialEq, ::prost::Message)]
324pub struct GetFeaturesResp {
325    #[prost(bool, tag = "1")]
326    pub group_by: bool,
327    #[prost(bool, tag = "2")]
328    pub split_by: bool,
329    #[prost(bool, tag = "3")]
330    pub expressions: bool,
331    #[prost(bool, tag = "4")]
332    pub on_update: bool,
333    #[prost(bool, tag = "5")]
334    pub sort: bool,
335    #[prost(map = "uint32, message", tag = "6")]
336    pub filter_ops: ::std::collections::HashMap<
337        u32,
338        get_features_resp::ColumnTypeOptions,
339    >,
340    #[prost(map = "uint32, message", tag = "7")]
341    pub aggregates: ::std::collections::HashMap<
342        u32,
343        get_features_resp::AggregateOptions,
344    >,
345    #[prost(enumeration = "GroupRollupMode", repeated, tag = "8")]
346    pub group_rollup_mode: ::prost::alloc::vec::Vec<i32>,
347    #[prost(map = "uint32, message", tag = "9")]
348    pub window_aggregates: ::std::collections::HashMap<
349        u32,
350        get_features_resp::WindowAggregateOptions,
351    >,
352    #[prost(bool, tag = "10")]
353    pub unordered: bool,
354    #[prost(enumeration = "SplitRollupMode", repeated, tag = "11")]
355    pub split_rollup_mode: ::prost::alloc::vec::Vec<i32>,
356    /// Whether a `Table` can be derived from a `View` of this server.
357    #[prost(bool, tag = "12")]
358    pub view_derivations: bool,
359}
360/// Nested message and enum types in `GetFeaturesResp`.
361pub mod get_features_resp {
362    #[derive(serde::Serialize)]
363    #[allow(clippy::derive_partial_eq_without_eq)]
364    #[derive(Clone, PartialEq, ::prost::Message)]
365    pub struct WindowAggregateOptions {
366        #[prost(message, repeated, tag = "1")]
367        pub options: ::prost::alloc::vec::Vec<super::WindowAggregateArgs>,
368    }
369    #[derive(serde::Serialize)]
370    #[allow(clippy::derive_partial_eq_without_eq)]
371    #[derive(Clone, PartialEq, ::prost::Message)]
372    pub struct ColumnTypeOptions {
373        #[prost(string, repeated, tag = "1")]
374        pub options: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
375    }
376    #[derive(serde::Serialize)]
377    #[allow(clippy::derive_partial_eq_without_eq)]
378    #[derive(Clone, PartialEq, ::prost::Message)]
379    pub struct AggregateOptions {
380        #[prost(message, repeated, tag = "1")]
381        pub aggregates: ::prost::alloc::vec::Vec<AggregateArgs>,
382    }
383    #[derive(serde::Serialize)]
384    #[allow(clippy::derive_partial_eq_without_eq)]
385    #[derive(Clone, PartialEq, ::prost::Message)]
386    pub struct AggregateArgs {
387        #[prost(string, tag = "1")]
388        pub name: ::prost::alloc::string::String,
389        #[prost(enumeration = "super::ColumnType", repeated, tag = "2")]
390        pub args: ::prost::alloc::vec::Vec<i32>,
391    }
392}
393#[derive(serde::Serialize)]
394#[allow(clippy::derive_partial_eq_without_eq)]
395#[derive(Clone, PartialEq, ::prost::Message)]
396pub struct WindowAggregateArgs {
397    #[prost(string, tag = "1")]
398    pub name: ::prost::alloc::string::String,
399    #[prost(string, repeated, tag = "2")]
400    pub frames: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
401    #[prost(bool, tag = "3")]
402    pub offset: bool,
403    #[prost(bool, tag = "4")]
404    pub alpha: bool,
405    #[prost(enumeration = "ColumnType", optional, tag = "5")]
406    pub result_type: ::core::option::Option<i32>,
407}
408/// `Client::get_hosted_tables`
409#[derive(serde::Serialize)]
410#[allow(clippy::derive_partial_eq_without_eq)]
411#[derive(Clone, PartialEq, ::prost::Message)]
412pub struct GetHostedTablesReq {
413    #[prost(bool, tag = "1")]
414    pub subscribe: bool,
415}
416#[derive(serde::Serialize)]
417#[allow(clippy::derive_partial_eq_without_eq)]
418#[derive(Clone, PartialEq, ::prost::Message)]
419pub struct GetHostedTablesResp {
420    #[prost(message, repeated, tag = "1")]
421    pub table_infos: ::prost::alloc::vec::Vec<HostedTable>,
422}
423#[derive(serde::Serialize)]
424#[allow(clippy::derive_partial_eq_without_eq)]
425#[derive(Clone, PartialEq, ::prost::Message)]
426pub struct HostedTable {
427    #[prost(string, tag = "1")]
428    pub entity_id: ::prost::alloc::string::String,
429    #[prost(string, optional, tag = "2")]
430    pub index: ::core::option::Option<::prost::alloc::string::String>,
431    #[prost(uint32, optional, tag = "3")]
432    pub limit: ::core::option::Option<u32>,
433}
434#[derive(serde::Serialize)]
435#[allow(clippy::derive_partial_eq_without_eq)]
436#[derive(Clone, PartialEq, ::prost::Message)]
437pub struct RemoveHostedTablesUpdateReq {
438    #[prost(uint32, tag = "1")]
439    pub id: u32,
440}
441#[derive(serde::Serialize)]
442#[allow(clippy::derive_partial_eq_without_eq)]
443#[derive(Clone, PartialEq, ::prost::Message)]
444pub struct RemoveHostedTablesUpdateResp {}
445/// `Table::size`
446#[derive(serde::Serialize)]
447#[allow(clippy::derive_partial_eq_without_eq)]
448#[derive(Clone, PartialEq, ::prost::Message)]
449pub struct TableSizeReq {}
450#[derive(serde::Serialize)]
451#[allow(clippy::derive_partial_eq_without_eq)]
452#[derive(Clone, PartialEq, ::prost::Message)]
453pub struct TableSizeResp {
454    #[prost(uint32, tag = "2")]
455    pub size: u32,
456}
457/// `Table::schema`
458#[derive(serde::Serialize)]
459#[allow(clippy::derive_partial_eq_without_eq)]
460#[derive(Clone, PartialEq, ::prost::Message)]
461pub struct TableSchemaReq {}
462#[derive(serde::Serialize)]
463#[allow(clippy::derive_partial_eq_without_eq)]
464#[derive(Clone, PartialEq, ::prost::Message)]
465pub struct TableSchemaResp {
466    #[prost(message, optional, tag = "1")]
467    pub schema: ::core::option::Option<Schema>,
468}
469/// `Table::describe` - validate a complete `ViewConfig` against this table and
470/// report its result schema, without creating a `View`.
471#[derive(serde::Serialize)]
472#[allow(clippy::derive_partial_eq_without_eq)]
473#[derive(Clone, PartialEq, ::prost::Message)]
474pub struct TableDescribeReq {
475    #[prost(message, optional, tag = "1")]
476    pub config: ::core::option::Option<ViewConfig>,
477}
478#[derive(serde::Serialize)]
479#[derive(serde::Deserialize)]
480#[allow(clippy::derive_partial_eq_without_eq)]
481#[derive(Clone, PartialEq, ::prost::Message)]
482pub struct TableDescribeResp {
483    /// Every VALID expression's type, whether or not the config as a whole is
484    /// valid.
485    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
486    pub expression_schema: ::std::collections::HashMap<
487        ::prost::alloc::string::String,
488        i32,
489    >,
490    #[prost(map = "string, message", tag = "2")]
491    pub expression_errors: ::std::collections::HashMap<
492        ::prost::alloc::string::String,
493        ExpressionError,
494    >,
495    #[prost(oneof = "table_describe_resp::Result", tags = "3, 4")]
496    pub result: ::core::option::Option<table_describe_resp::Result>,
497}
498/// Nested message and enum types in `TableDescribeResp`.
499pub mod table_describe_resp {
500    #[derive(serde::Serialize)]
501    #[derive(serde::Deserialize)]
502    #[allow(clippy::derive_partial_eq_without_eq)]
503    #[derive(Clone, PartialEq, ::prost::Oneof)]
504    pub enum Result {
505        /// Present IFF `expression_errors` is empty and the whole config is
506        /// valid.
507        #[prost(message, tag = "3")]
508        View(super::ViewDescription),
509        /// The first non-expression config error, when the expressions are all
510        /// valid but the config is not.
511        #[prost(string, tag = "4")]
512        ConfigError(::prost::alloc::string::String),
513    }
514}
515#[derive(serde::Serialize)]
516#[derive(serde::Deserialize)]
517#[allow(clippy::derive_partial_eq_without_eq)]
518#[derive(Clone, PartialEq, ::prost::Message)]
519pub struct ViewDescription {
520    /// Equal to `View::schema()` of a `View` built from the same config.
521    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
522    pub schema: ::std::collections::HashMap<::prost::alloc::string::String, i32>,
523}
524#[derive(serde::Serialize)]
525#[derive(serde::Deserialize)]
526#[allow(clippy::derive_partial_eq_without_eq)]
527#[derive(Clone, PartialEq, ::prost::Message)]
528pub struct ExpressionError {
529    #[prost(string, tag = "1")]
530    pub error_message: ::prost::alloc::string::String,
531    #[prost(uint32, tag = "2")]
532    pub line: u32,
533    #[prost(uint32, tag = "3")]
534    pub column: u32,
535}
536/// `Table::view`
537#[derive(serde::Serialize)]
538#[allow(clippy::derive_partial_eq_without_eq)]
539#[derive(Clone, PartialEq, ::prost::Message)]
540pub struct TableMakeViewReq {
541    #[prost(string, tag = "1")]
542    pub view_id: ::prost::alloc::string::String,
543    #[prost(message, optional, tag = "2")]
544    pub config: ::core::option::Option<ViewConfig>,
545}
546#[derive(serde::Serialize)]
547#[allow(clippy::derive_partial_eq_without_eq)]
548#[derive(Clone, PartialEq, ::prost::Message)]
549pub struct TableMakeViewResp {
550    #[prost(string, tag = "1")]
551    pub view_id: ::prost::alloc::string::String,
552}
553/// `View::schema`
554#[derive(serde::Serialize)]
555#[allow(clippy::derive_partial_eq_without_eq)]
556#[derive(Clone, PartialEq, ::prost::Message)]
557pub struct ViewSchemaReq {}
558#[derive(serde::Serialize)]
559#[allow(clippy::derive_partial_eq_without_eq)]
560#[derive(Clone, PartialEq, ::prost::Message)]
561pub struct ViewSchemaResp {
562    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
563    pub schema: ::std::collections::HashMap<::prost::alloc::string::String, i32>,
564}
565/// `View::dimensions`
566#[derive(serde::Serialize)]
567#[allow(clippy::derive_partial_eq_without_eq)]
568#[derive(Clone, PartialEq, ::prost::Message)]
569pub struct ViewDimensionsReq {}
570#[derive(serde::Serialize)]
571#[derive(serde::Deserialize)]
572#[allow(clippy::derive_partial_eq_without_eq)]
573#[derive(Clone, PartialEq, ::prost::Message)]
574pub struct ViewDimensionsResp {
575    #[prost(uint32, tag = "1")]
576    pub num_table_rows: u32,
577    #[prost(uint32, tag = "2")]
578    pub num_table_columns: u32,
579    #[prost(uint32, tag = "3")]
580    pub num_view_rows: u32,
581    #[prost(uint32, tag = "4")]
582    pub num_view_columns: u32,
583}
584/// `View::get_config`
585#[derive(serde::Serialize)]
586#[allow(clippy::derive_partial_eq_without_eq)]
587#[derive(Clone, PartialEq, ::prost::Message)]
588pub struct ViewGetConfigReq {}
589#[derive(serde::Serialize)]
590#[allow(clippy::derive_partial_eq_without_eq)]
591#[derive(Clone, PartialEq, ::prost::Message)]
592pub struct ViewGetConfigResp {
593    #[prost(message, optional, tag = "1")]
594    pub config: ::core::option::Option<ViewConfig>,
595}
596/// `Client::table`.
597#[derive(serde::Serialize)]
598#[allow(clippy::derive_partial_eq_without_eq)]
599#[derive(Clone, PartialEq, ::prost::Message)]
600pub struct MakeTableReq {
601    #[prost(message, optional, tag = "1")]
602    pub data: ::core::option::Option<MakeTableData>,
603    #[prost(message, optional, tag = "2")]
604    pub options: ::core::option::Option<make_table_req::MakeTableOptions>,
605}
606/// Nested message and enum types in `MakeTableReq`.
607pub mod make_table_req {
608    #[derive(serde::Serialize)]
609    #[allow(clippy::derive_partial_eq_without_eq)]
610    #[derive(Clone, PartialEq, ::prost::Message)]
611    pub struct MakeTableOptions {
612        /// Back this Table's canonical data with the on-disk storage backend
613        /// (memory-mapped file on native; OPFS on WASM) instead of memory.
614        /// Orthogonal to `make_table_type`, so it is a standalone field.
615        #[prost(bool, optional, tag = "3")]
616        pub page_to_disk: ::core::option::Option<bool>,
617        #[prost(enumeration = "super::ListFlatten", optional, tag = "4")]
618        pub list_flatten: ::core::option::Option<i32>,
619        /// The columns of a `Table` made from a `View`, in place of the ones
620        /// inferred from it. Only valid with `MakeTableData.from_view`.
621        #[prost(message, optional, tag = "5")]
622        pub view_schema: ::core::option::Option<super::Schema>,
623        #[prost(oneof = "make_table_options::MakeTableType", tags = "1, 2")]
624        pub make_table_type: ::core::option::Option<make_table_options::MakeTableType>,
625    }
626    /// Nested message and enum types in `MakeTableOptions`.
627    pub mod make_table_options {
628        #[derive(serde::Serialize)]
629        #[allow(clippy::derive_partial_eq_without_eq)]
630        #[derive(Clone, PartialEq, ::prost::Oneof)]
631        pub enum MakeTableType {
632            #[prost(string, tag = "1")]
633            MakeIndexTable(::prost::alloc::string::String),
634            #[prost(uint32, tag = "2")]
635            MakeLimitTable(u32),
636        }
637    }
638}
639#[derive(serde::Serialize)]
640#[allow(clippy::derive_partial_eq_without_eq)]
641#[derive(Clone, PartialEq, ::prost::Message)]
642pub struct MakeTableResp {}
643/// `Client::join` — create a read-only table from a JOIN of two tables.
644#[derive(serde::Serialize)]
645#[allow(clippy::derive_partial_eq_without_eq)]
646#[derive(Clone, PartialEq, ::prost::Message)]
647pub struct MakeJoinTableReq {
648    #[prost(string, tag = "1")]
649    pub left_table_id: ::prost::alloc::string::String,
650    #[prost(string, tag = "2")]
651    pub right_table_id: ::prost::alloc::string::String,
652    #[prost(string, tag = "3")]
653    pub on_column: ::prost::alloc::string::String,
654    #[prost(enumeration = "JoinType", tag = "4")]
655    pub join_type: i32,
656    #[prost(string, tag = "5")]
657    pub right_on_column: ::prost::alloc::string::String,
658}
659#[derive(serde::Serialize)]
660#[allow(clippy::derive_partial_eq_without_eq)]
661#[derive(Clone, PartialEq, ::prost::Message)]
662pub struct MakeJoinTableResp {}
663/// `Table::delete`
664#[derive(serde::Serialize)]
665#[allow(clippy::derive_partial_eq_without_eq)]
666#[derive(Clone, PartialEq, ::prost::Message)]
667pub struct TableDeleteReq {
668    #[prost(bool, tag = "1")]
669    pub is_immediate: bool,
670}
671#[derive(serde::Serialize)]
672#[allow(clippy::derive_partial_eq_without_eq)]
673#[derive(Clone, PartialEq, ::prost::Message)]
674pub struct TableDeleteResp {}
675/// `Table::on_delete`
676#[derive(serde::Serialize)]
677#[allow(clippy::derive_partial_eq_without_eq)]
678#[derive(Clone, PartialEq, ::prost::Message)]
679pub struct TableOnDeleteReq {}
680#[derive(serde::Serialize)]
681#[allow(clippy::derive_partial_eq_without_eq)]
682#[derive(Clone, PartialEq, ::prost::Message)]
683pub struct TableOnDeleteResp {}
684/// `Table::make_port`
685#[derive(serde::Serialize)]
686#[allow(clippy::derive_partial_eq_without_eq)]
687#[derive(Clone, PartialEq, ::prost::Message)]
688pub struct TableMakePortReq {}
689#[derive(serde::Serialize)]
690#[allow(clippy::derive_partial_eq_without_eq)]
691#[derive(Clone, PartialEq, ::prost::Message)]
692pub struct TableMakePortResp {
693    #[prost(uint32, tag = "1")]
694    pub port_id: u32,
695}
696/// `Table::remove_delete`
697#[derive(serde::Serialize)]
698#[allow(clippy::derive_partial_eq_without_eq)]
699#[derive(Clone, PartialEq, ::prost::Message)]
700pub struct TableRemoveDeleteReq {
701    #[prost(uint32, tag = "1")]
702    pub id: u32,
703}
704#[derive(serde::Serialize)]
705#[allow(clippy::derive_partial_eq_without_eq)]
706#[derive(Clone, PartialEq, ::prost::Message)]
707pub struct TableRemoveDeleteResp {}
708/// `View::on_remove`
709#[derive(serde::Serialize)]
710#[allow(clippy::derive_partial_eq_without_eq)]
711#[derive(Clone, PartialEq, ::prost::Message)]
712pub struct ViewOnRemoveReq {}
713#[derive(ts_rs::TS)]
714#[derive(serde::Serialize)]
715#[allow(clippy::derive_partial_eq_without_eq)]
716#[derive(Clone, PartialEq, ::prost::Message)]
717pub struct ViewOnRemoveResp {
718    #[prost(bytes = "vec", optional, tag = "1")]
719    #[ts(type = "Uint8Array")]
720    #[serde(with = "serde_bytes")]
721    pub indices: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
722    #[prost(uint32, tag = "2")]
723    pub port_id: u32,
724}
725/// `View::remove_remove`
726#[derive(serde::Serialize)]
727#[allow(clippy::derive_partial_eq_without_eq)]
728#[derive(Clone, PartialEq, ::prost::Message)]
729pub struct ViewRemoveOnRemoveReq {
730    #[prost(uint32, tag = "1")]
731    pub id: u32,
732}
733#[derive(serde::Serialize)]
734#[allow(clippy::derive_partial_eq_without_eq)]
735#[derive(Clone, PartialEq, ::prost::Message)]
736pub struct ViewRemoveOnRemoveResp {}
737/// `Table::update`
738#[derive(serde::Serialize)]
739#[allow(clippy::derive_partial_eq_without_eq)]
740#[derive(Clone, PartialEq, ::prost::Message)]
741pub struct TableUpdateReq {
742    #[prost(message, optional, tag = "1")]
743    pub data: ::core::option::Option<MakeTableData>,
744    #[prost(uint32, tag = "2")]
745    pub port_id: u32,
746}
747#[derive(serde::Serialize)]
748#[allow(clippy::derive_partial_eq_without_eq)]
749#[derive(Clone, PartialEq, ::prost::Message)]
750pub struct TableUpdateResp {}
751/// `Table::replace`
752#[derive(serde::Serialize)]
753#[allow(clippy::derive_partial_eq_without_eq)]
754#[derive(Clone, PartialEq, ::prost::Message)]
755pub struct TableReplaceReq {
756    #[prost(message, optional, tag = "1")]
757    pub data: ::core::option::Option<MakeTableData>,
758}
759#[derive(serde::Serialize)]
760#[allow(clippy::derive_partial_eq_without_eq)]
761#[derive(Clone, PartialEq, ::prost::Message)]
762pub struct TableReplaceResp {}
763/// `Table::remove`
764#[derive(serde::Serialize)]
765#[allow(clippy::derive_partial_eq_without_eq)]
766#[derive(Clone, PartialEq, ::prost::Message)]
767pub struct TableRemoveReq {
768    #[prost(message, optional, tag = "1")]
769    pub data: ::core::option::Option<MakeTableData>,
770}
771#[derive(serde::Serialize)]
772#[allow(clippy::derive_partial_eq_without_eq)]
773#[derive(Clone, PartialEq, ::prost::Message)]
774pub struct TableRemoveResp {}
775#[derive(serde::Serialize)]
776#[allow(clippy::derive_partial_eq_without_eq)]
777#[derive(Clone, PartialEq, ::prost::Message)]
778pub struct ViewOnUpdateReq {
779    #[prost(enumeration = "view_on_update_req::Mode", optional, tag = "1")]
780    pub mode: ::core::option::Option<i32>,
781}
782/// Nested message and enum types in `ViewOnUpdateReq`.
783pub mod view_on_update_req {
784    #[derive(serde::Serialize)]
785    #[derive(
786        Clone,
787        Copy,
788        Debug,
789        PartialEq,
790        Eq,
791        Hash,
792        PartialOrd,
793        Ord,
794        ::prost::Enumeration
795    )]
796    #[repr(i32)]
797    pub enum Mode {
798        Row = 0,
799    }
800    impl Mode {
801        /// String value of the enum field names used in the ProtoBuf definition.
802        ///
803        /// The values are not transformed in any way and thus are considered stable
804        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
805        pub fn as_str_name(&self) -> &'static str {
806            match self {
807                Mode::Row => "ROW",
808            }
809        }
810        /// Creates an enum from field names used in the ProtoBuf definition.
811        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
812            match value {
813                "ROW" => Some(Self::Row),
814                _ => None,
815            }
816        }
817    }
818}
819#[derive(ts_rs::TS)]
820#[derive(serde::Serialize)]
821#[allow(clippy::derive_partial_eq_without_eq)]
822#[derive(Clone, PartialEq, ::prost::Message)]
823pub struct ViewOnUpdateResp {
824    #[prost(bytes = "vec", optional, tag = "1")]
825    #[ts(type = "Uint8Array | undefined")]
826    #[serde(with = "serde_bytes")]
827    pub delta: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
828    #[prost(uint32, tag = "2")]
829    pub port_id: u32,
830}
831#[derive(serde::Serialize)]
832#[allow(clippy::derive_partial_eq_without_eq)]
833#[derive(Clone, PartialEq, ::prost::Message)]
834pub struct ViewOnDeleteReq {}
835#[derive(serde::Serialize)]
836#[allow(clippy::derive_partial_eq_without_eq)]
837#[derive(Clone, PartialEq, ::prost::Message)]
838pub struct ViewOnDeleteResp {}
839#[derive(serde::Serialize)]
840#[allow(clippy::derive_partial_eq_without_eq)]
841#[derive(Clone, PartialEq, ::prost::Message)]
842pub struct ViewRemoveDeleteReq {
843    #[prost(uint32, tag = "1")]
844    pub id: u32,
845}
846#[derive(serde::Serialize)]
847#[allow(clippy::derive_partial_eq_without_eq)]
848#[derive(Clone, PartialEq, ::prost::Message)]
849pub struct ViewRemoveDeleteResp {}
850#[derive(serde::Serialize)]
851#[allow(clippy::derive_partial_eq_without_eq)]
852#[derive(Clone, PartialEq, ::prost::Message)]
853pub struct ViewToColumnsStringReq {
854    #[prost(message, optional, tag = "1")]
855    pub viewport: ::core::option::Option<ViewPort>,
856    #[prost(bool, optional, tag = "2")]
857    pub id: ::core::option::Option<bool>,
858    #[prost(bool, optional, tag = "3")]
859    pub index: ::core::option::Option<bool>,
860    #[prost(bool, optional, tag = "4")]
861    pub formatted: ::core::option::Option<bool>,
862}
863#[derive(serde::Serialize)]
864#[allow(clippy::derive_partial_eq_without_eq)]
865#[derive(Clone, PartialEq, ::prost::Message)]
866pub struct ViewToColumnsStringResp {
867    #[prost(string, tag = "1")]
868    pub json_string: ::prost::alloc::string::String,
869}
870#[derive(serde::Serialize)]
871#[allow(clippy::derive_partial_eq_without_eq)]
872#[derive(Clone, PartialEq, ::prost::Message)]
873pub struct ViewToRowsStringReq {
874    #[prost(message, optional, tag = "1")]
875    pub viewport: ::core::option::Option<ViewPort>,
876    #[prost(bool, optional, tag = "2")]
877    pub id: ::core::option::Option<bool>,
878    #[prost(bool, optional, tag = "3")]
879    pub index: ::core::option::Option<bool>,
880    #[prost(bool, optional, tag = "4")]
881    pub formatted: ::core::option::Option<bool>,
882}
883#[derive(serde::Serialize)]
884#[allow(clippy::derive_partial_eq_without_eq)]
885#[derive(Clone, PartialEq, ::prost::Message)]
886pub struct ViewToRowsStringResp {
887    #[prost(string, tag = "1")]
888    pub json_string: ::prost::alloc::string::String,
889}
890#[derive(serde::Serialize)]
891#[allow(clippy::derive_partial_eq_without_eq)]
892#[derive(Clone, PartialEq, ::prost::Message)]
893pub struct ViewToNdjsonStringReq {
894    #[prost(message, optional, tag = "1")]
895    pub viewport: ::core::option::Option<ViewPort>,
896    #[prost(bool, optional, tag = "2")]
897    pub id: ::core::option::Option<bool>,
898    #[prost(bool, optional, tag = "3")]
899    pub index: ::core::option::Option<bool>,
900    #[prost(bool, optional, tag = "4")]
901    pub formatted: ::core::option::Option<bool>,
902}
903#[derive(serde::Serialize)]
904#[allow(clippy::derive_partial_eq_without_eq)]
905#[derive(Clone, PartialEq, ::prost::Message)]
906pub struct ViewToNdjsonStringResp {
907    #[prost(string, tag = "1")]
908    pub ndjson_string: ::prost::alloc::string::String,
909}
910#[derive(serde::Serialize)]
911#[allow(clippy::derive_partial_eq_without_eq)]
912#[derive(Clone, PartialEq, ::prost::Message)]
913pub struct ViewToArrowReq {
914    #[prost(message, optional, tag = "1")]
915    pub viewport: ::core::option::Option<ViewPort>,
916    #[prost(string, optional, tag = "2")]
917    pub compression: ::core::option::Option<::prost::alloc::string::String>,
918}
919#[derive(serde::Serialize)]
920#[allow(clippy::derive_partial_eq_without_eq)]
921#[derive(Clone, PartialEq, ::prost::Message)]
922pub struct ViewToArrowResp {
923    #[prost(bytes = "vec", tag = "1")]
924    #[serde(skip)]
925    pub arrow: ::prost::alloc::vec::Vec<u8>,
926}
927#[derive(serde::Serialize)]
928#[allow(clippy::derive_partial_eq_without_eq)]
929#[derive(Clone, PartialEq, ::prost::Message)]
930pub struct ViewColumnPathsReq {
931    #[prost(uint32, optional, tag = "1")]
932    pub start_col: ::core::option::Option<u32>,
933    #[prost(uint32, optional, tag = "2")]
934    pub end_col: ::core::option::Option<u32>,
935}
936/// One row of a column path area, `width` values long.
937#[derive(serde::Serialize)]
938#[allow(clippy::derive_partial_eq_without_eq)]
939#[derive(Clone, PartialEq, ::prost::Message)]
940pub struct ColumnPathLevel {
941    #[prost(message, repeated, tag = "1")]
942    pub values: ::prost::alloc::vec::Vec<Scalar>,
943}
944#[derive(serde::Serialize)]
945#[allow(clippy::derive_partial_eq_without_eq)]
946#[derive(Clone, PartialEq, ::prost::Message)]
947pub struct ViewColumnPathsResp {
948    /// Transposed, `split_by.len() + 1` rows of `width` values each.
949    #[prost(message, repeated, tag = "2")]
950    pub area: ::prost::alloc::vec::Vec<ColumnPathLevel>,
951}
952#[derive(serde::Serialize)]
953#[allow(clippy::derive_partial_eq_without_eq)]
954#[derive(Clone, PartialEq, ::prost::Message)]
955pub struct ViewDeleteReq {}
956#[derive(serde::Serialize)]
957#[allow(clippy::derive_partial_eq_without_eq)]
958#[derive(Clone, PartialEq, ::prost::Message)]
959pub struct ViewDeleteResp {}
960#[derive(serde::Serialize)]
961#[allow(clippy::derive_partial_eq_without_eq)]
962#[derive(Clone, PartialEq, ::prost::Message)]
963pub struct ViewGetMinMaxReq {
964    #[prost(string, tag = "1")]
965    pub column_name: ::prost::alloc::string::String,
966}
967#[derive(serde::Serialize)]
968#[allow(clippy::derive_partial_eq_without_eq)]
969#[derive(Clone, PartialEq, ::prost::Message)]
970pub struct ViewGetMinMaxResp {
971    #[prost(message, optional, tag = "1")]
972    pub min: ::core::option::Option<Scalar>,
973    #[prost(message, optional, tag = "2")]
974    pub max: ::core::option::Option<Scalar>,
975}
976#[derive(serde::Serialize)]
977#[allow(clippy::derive_partial_eq_without_eq)]
978#[derive(Clone, PartialEq, ::prost::Message)]
979pub struct ViewExpressionSchemaReq {}
980#[derive(serde::Serialize)]
981#[allow(clippy::derive_partial_eq_without_eq)]
982#[derive(Clone, PartialEq, ::prost::Message)]
983pub struct ViewExpressionSchemaResp {
984    #[prost(map = "string, enumeration(ColumnType)", tag = "1")]
985    pub schema: ::std::collections::HashMap<::prost::alloc::string::String, i32>,
986}
987#[derive(serde::Serialize)]
988#[allow(clippy::derive_partial_eq_without_eq)]
989#[derive(Clone, PartialEq, ::prost::Message)]
990pub struct ViewToCsvReq {
991    #[prost(message, optional, tag = "1")]
992    pub viewport: ::core::option::Option<ViewPort>,
993}
994#[derive(serde::Serialize)]
995#[allow(clippy::derive_partial_eq_without_eq)]
996#[derive(Clone, PartialEq, ::prost::Message)]
997pub struct ViewToCsvResp {
998    #[prost(string, tag = "1")]
999    pub csv: ::prost::alloc::string::String,
1000}
1001#[derive(serde::Serialize)]
1002#[allow(clippy::derive_partial_eq_without_eq)]
1003#[derive(Clone, PartialEq, ::prost::Message)]
1004pub struct ViewRemoveOnUpdateReq {
1005    #[prost(uint32, tag = "1")]
1006    pub id: u32,
1007}
1008#[derive(serde::Serialize)]
1009#[allow(clippy::derive_partial_eq_without_eq)]
1010#[derive(Clone, PartialEq, ::prost::Message)]
1011pub struct ViewRemoveOnUpdateResp {}
1012#[derive(serde::Serialize)]
1013#[allow(clippy::derive_partial_eq_without_eq)]
1014#[derive(Clone, PartialEq, ::prost::Message)]
1015pub struct ViewCollapseReq {
1016    #[prost(uint32, tag = "1")]
1017    pub row_index: u32,
1018}
1019#[derive(serde::Serialize)]
1020#[allow(clippy::derive_partial_eq_without_eq)]
1021#[derive(Clone, PartialEq, ::prost::Message)]
1022pub struct ViewCollapseResp {
1023    #[prost(uint32, tag = "1")]
1024    pub num_changed: u32,
1025}
1026#[derive(serde::Serialize)]
1027#[allow(clippy::derive_partial_eq_without_eq)]
1028#[derive(Clone, PartialEq, ::prost::Message)]
1029pub struct ViewExpandReq {
1030    #[prost(uint32, tag = "1")]
1031    pub row_index: u32,
1032}
1033#[derive(serde::Serialize)]
1034#[allow(clippy::derive_partial_eq_without_eq)]
1035#[derive(Clone, PartialEq, ::prost::Message)]
1036pub struct ViewExpandResp {
1037    #[prost(uint32, tag = "1")]
1038    pub num_changed: u32,
1039}
1040/// `View::set_depth`
1041#[derive(serde::Serialize)]
1042#[allow(clippy::derive_partial_eq_without_eq)]
1043#[derive(Clone, PartialEq, ::prost::Message)]
1044pub struct ViewSetDepthReq {
1045    #[prost(uint32, tag = "1")]
1046    pub depth: u32,
1047}
1048#[derive(serde::Serialize)]
1049#[allow(clippy::derive_partial_eq_without_eq)]
1050#[derive(Clone, PartialEq, ::prost::Message)]
1051pub struct ViewSetDepthResp {}
1052#[derive(serde::Serialize)]
1053#[allow(clippy::derive_partial_eq_without_eq)]
1054#[derive(Clone, PartialEq, ::prost::Message)]
1055pub struct ServerSystemInfoReq {}
1056#[derive(serde::Serialize)]
1057#[allow(clippy::derive_partial_eq_without_eq)]
1058#[derive(Clone, PartialEq, ::prost::Message)]
1059pub struct ServerSystemInfoResp {
1060    #[prost(uint64, tag = "1")]
1061    pub heap_size: u64,
1062    #[prost(uint64, tag = "2")]
1063    pub used_size: u64,
1064    #[prost(uint32, tag = "3")]
1065    pub cpu_time: u32,
1066    #[prost(uint32, tag = "4")]
1067    pub cpu_time_epoch: u32,
1068}
1069#[derive(serde::Serialize)]
1070#[allow(clippy::derive_partial_eq_without_eq)]
1071#[derive(Clone, PartialEq, ::prost::Message)]
1072pub struct WindowSpec {
1073    #[prost(string, tag = "2")]
1074    pub source: ::prost::alloc::string::String,
1075    /// The aggregate, in the data model's own vocabulary - see
1076    /// `GetFeaturesResp.WindowAggregateArgs`. A string rather than an enum so
1077    /// that a `View` can carry an op the built-in engine has never heard of,
1078    /// e.g. kdb+'s `mdev`.
1079    #[prost(string, tag = "3")]
1080    pub op: ::prost::alloc::string::String,
1081    #[prost(string, repeated, tag = "4")]
1082    pub partition_by: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1083    #[prost(message, optional, tag = "5")]
1084    pub order_by: ::core::option::Option<window_spec::Order>,
1085    #[prost(uint32, optional, tag = "9")]
1086    pub offset: ::core::option::Option<u32>,
1087    #[prost(double, optional, tag = "10")]
1088    pub alpha: ::core::option::Option<f64>,
1089    #[prost(oneof = "window_spec::Frame", tags = "6, 7, 8")]
1090    pub frame: ::core::option::Option<window_spec::Frame>,
1091}
1092/// Nested message and enum types in `WindowSpec`.
1093pub mod window_spec {
1094    #[derive(serde::Serialize)]
1095    #[allow(clippy::derive_partial_eq_without_eq)]
1096    #[derive(Clone, PartialEq, ::prost::Message)]
1097    pub struct Order {
1098        #[prost(string, tag = "1")]
1099        pub column: ::prost::alloc::string::String,
1100        #[prost(bool, tag = "2")]
1101        pub desc: bool,
1102    }
1103    #[derive(serde::Serialize)]
1104    #[allow(clippy::derive_partial_eq_without_eq)]
1105    #[derive(Clone, PartialEq, ::prost::Oneof)]
1106    pub enum Frame {
1107        #[prost(uint32, tag = "6")]
1108        Rows(u32),
1109        #[prost(double, tag = "7")]
1110        Range(f64),
1111        #[prost(enumeration = "::prost_types::NullValue", tag = "8")]
1112        Cumulative(i32),
1113    }
1114}
1115#[derive(serde::Serialize)]
1116#[allow(clippy::derive_partial_eq_without_eq)]
1117#[derive(Clone, PartialEq, ::prost::Message)]
1118pub struct ViewConfig {
1119    #[prost(string, repeated, tag = "1")]
1120    pub group_by: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1121    #[prost(string, repeated, tag = "2")]
1122    pub split_by: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1123    #[prost(message, optional, tag = "3")]
1124    pub columns: ::core::option::Option<ColumnsUpdate>,
1125    #[prost(message, repeated, tag = "4")]
1126    pub filter: ::prost::alloc::vec::Vec<view_config::Filter>,
1127    #[prost(message, repeated, tag = "5")]
1128    pub sort: ::prost::alloc::vec::Vec<view_config::Sort>,
1129    #[prost(map = "string, string", tag = "6")]
1130    pub expressions: ::std::collections::HashMap<
1131        ::prost::alloc::string::String,
1132        ::prost::alloc::string::String,
1133    >,
1134    #[prost(map = "string, message", tag = "7")]
1135    pub aggregates: ::std::collections::HashMap<
1136        ::prost::alloc::string::String,
1137        view_config::AggList,
1138    >,
1139    #[prost(enumeration = "view_config::FilterReducer", tag = "8")]
1140    pub filter_op: i32,
1141    #[prost(uint32, optional, tag = "9")]
1142    pub group_by_depth: ::core::option::Option<u32>,
1143    #[prost(enumeration = "GroupRollupMode", optional, tag = "10")]
1144    pub group_rollup_mode: ::core::option::Option<i32>,
1145    #[prost(map = "string, message", tag = "11")]
1146    pub windows: ::std::collections::HashMap<::prost::alloc::string::String, WindowSpec>,
1147    #[prost(enumeration = "SplitRollupMode", optional, tag = "12")]
1148    pub split_rollup_mode: ::core::option::Option<i32>,
1149}
1150/// Nested message and enum types in `ViewConfig`.
1151pub mod view_config {
1152    #[derive(serde::Serialize)]
1153    #[allow(clippy::derive_partial_eq_without_eq)]
1154    #[derive(Clone, PartialEq, ::prost::Message)]
1155    pub struct AggList {
1156        #[prost(string, repeated, tag = "1")]
1157        pub aggregations: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1158    }
1159    #[derive(serde::Serialize)]
1160    #[allow(clippy::derive_partial_eq_without_eq)]
1161    #[derive(Clone, PartialEq, ::prost::Message)]
1162    pub struct Sort {
1163        #[prost(string, tag = "1")]
1164        pub column: ::prost::alloc::string::String,
1165        #[prost(enumeration = "super::SortOp", tag = "2")]
1166        pub op: i32,
1167    }
1168    #[derive(serde::Serialize)]
1169    #[allow(clippy::derive_partial_eq_without_eq)]
1170    #[derive(Clone, PartialEq, ::prost::Message)]
1171    pub struct Filter {
1172        #[prost(string, tag = "1")]
1173        pub column: ::prost::alloc::string::String,
1174        #[prost(string, tag = "2")]
1175        pub op: ::prost::alloc::string::String,
1176        #[prost(message, repeated, tag = "3")]
1177        pub value: ::prost::alloc::vec::Vec<super::Scalar>,
1178    }
1179    #[derive(serde::Serialize)]
1180    #[derive(
1181        Clone,
1182        Copy,
1183        Debug,
1184        PartialEq,
1185        Eq,
1186        Hash,
1187        PartialOrd,
1188        Ord,
1189        ::prost::Enumeration
1190    )]
1191    #[repr(i32)]
1192    pub enum FilterReducer {
1193        And = 0,
1194        Or = 1,
1195    }
1196    impl FilterReducer {
1197        /// String value of the enum field names used in the ProtoBuf definition.
1198        ///
1199        /// The values are not transformed in any way and thus are considered stable
1200        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1201        pub fn as_str_name(&self) -> &'static str {
1202            match self {
1203                FilterReducer::And => "AND",
1204                FilterReducer::Or => "OR",
1205            }
1206        }
1207        /// Creates an enum from field names used in the ProtoBuf definition.
1208        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1209            match value {
1210                "AND" => Some(Self::And),
1211                "OR" => Some(Self::Or),
1212                _ => None,
1213            }
1214        }
1215    }
1216}
1217#[derive(serde::Serialize)]
1218#[allow(clippy::derive_partial_eq_without_eq)]
1219#[derive(Clone, PartialEq, ::prost::Message)]
1220pub struct ColumnsUpdate {
1221    #[prost(oneof = "columns_update::OptColumns", tags = "1, 2")]
1222    pub opt_columns: ::core::option::Option<columns_update::OptColumns>,
1223}
1224/// Nested message and enum types in `ColumnsUpdate`.
1225pub mod columns_update {
1226    #[derive(serde::Serialize)]
1227    #[allow(clippy::derive_partial_eq_without_eq)]
1228    #[derive(Clone, PartialEq, ::prost::Message)]
1229    pub struct Columns {
1230        #[prost(string, repeated, tag = "1")]
1231        pub columns: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1232    }
1233    #[derive(serde::Serialize)]
1234    #[allow(clippy::derive_partial_eq_without_eq)]
1235    #[derive(Clone, PartialEq, ::prost::Oneof)]
1236    pub enum OptColumns {
1237        #[prost(enumeration = "::prost_types::NullValue", tag = "1")]
1238        DefaultColumns(i32),
1239        #[prost(message, tag = "2")]
1240        Columns(Columns),
1241    }
1242}
1243#[derive(serde::Serialize)]
1244#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1245#[repr(i32)]
1246pub enum StatusCode {
1247    ServerError = 0,
1248    ViewNotFound = 1,
1249    TransportError = 2,
1250}
1251impl StatusCode {
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            StatusCode::ServerError => "SERVER_ERROR",
1259            StatusCode::ViewNotFound => "VIEW_NOT_FOUND",
1260            StatusCode::TransportError => "TRANSPORT_ERROR",
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            "SERVER_ERROR" => Some(Self::ServerError),
1267            "VIEW_NOT_FOUND" => Some(Self::ViewNotFound),
1268            "TRANSPORT_ERROR" => Some(Self::TransportError),
1269            _ => None,
1270        }
1271    }
1272}
1273/// View types
1274#[derive(ts_rs::TS)]
1275#[derive(serde::Serialize)]
1276#[derive(serde::Deserialize)]
1277#[serde(rename_all = "snake_case")]
1278#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1279#[repr(i32)]
1280pub enum ColumnType {
1281    String = 0,
1282    Date = 1,
1283    Datetime = 2,
1284    Integer = 3,
1285    Float = 4,
1286    Boolean = 5,
1287}
1288impl ColumnType {
1289    /// String value of the enum field names used in the ProtoBuf definition.
1290    ///
1291    /// The values are not transformed in any way and thus are considered stable
1292    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1293    pub fn as_str_name(&self) -> &'static str {
1294        match self {
1295            ColumnType::String => "STRING",
1296            ColumnType::Date => "DATE",
1297            ColumnType::Datetime => "DATETIME",
1298            ColumnType::Integer => "INTEGER",
1299            ColumnType::Float => "FLOAT",
1300            ColumnType::Boolean => "BOOLEAN",
1301        }
1302    }
1303    /// Creates an enum from field names used in the ProtoBuf definition.
1304    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1305        match value {
1306            "STRING" => Some(Self::String),
1307            "DATE" => Some(Self::Date),
1308            "DATETIME" => Some(Self::Datetime),
1309            "INTEGER" => Some(Self::Integer),
1310            "FLOAT" => Some(Self::Float),
1311            "BOOLEAN" => Some(Self::Boolean),
1312            _ => None,
1313        }
1314    }
1315}
1316/// TODO This belongs in features
1317#[derive(serde::Serialize)]
1318#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1319#[repr(i32)]
1320pub enum SortOp {
1321    SortNone = 0,
1322    SortAsc = 1,
1323    SortDesc = 2,
1324    SortColAsc = 3,
1325    SortColDesc = 4,
1326    SortAscAbs = 5,
1327    SortDescAbs = 6,
1328    SortColAscAbs = 7,
1329    SortColDescAbs = 8,
1330}
1331impl SortOp {
1332    /// String value of the enum field names used in the ProtoBuf definition.
1333    ///
1334    /// The values are not transformed in any way and thus are considered stable
1335    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1336    pub fn as_str_name(&self) -> &'static str {
1337        match self {
1338            SortOp::SortNone => "SORT_NONE",
1339            SortOp::SortAsc => "SORT_ASC",
1340            SortOp::SortDesc => "SORT_DESC",
1341            SortOp::SortColAsc => "SORT_COL_ASC",
1342            SortOp::SortColDesc => "SORT_COL_DESC",
1343            SortOp::SortAscAbs => "SORT_ASC_ABS",
1344            SortOp::SortDescAbs => "SORT_DESC_ABS",
1345            SortOp::SortColAscAbs => "SORT_COL_ASC_ABS",
1346            SortOp::SortColDescAbs => "SORT_COL_DESC_ABS",
1347        }
1348    }
1349    /// Creates an enum from field names used in the ProtoBuf definition.
1350    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1351        match value {
1352            "SORT_NONE" => Some(Self::SortNone),
1353            "SORT_ASC" => Some(Self::SortAsc),
1354            "SORT_DESC" => Some(Self::SortDesc),
1355            "SORT_COL_ASC" => Some(Self::SortColAsc),
1356            "SORT_COL_DESC" => Some(Self::SortColDesc),
1357            "SORT_ASC_ABS" => Some(Self::SortAscAbs),
1358            "SORT_DESC_ABS" => Some(Self::SortDescAbs),
1359            "SORT_COL_ASC_ABS" => Some(Self::SortColAscAbs),
1360            "SORT_COL_DESC_ABS" => Some(Self::SortColDescAbs),
1361            _ => None,
1362        }
1363    }
1364}
1365#[derive(serde::Serialize)]
1366#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1367#[repr(i32)]
1368pub enum GroupRollupMode {
1369    Rollup = 0,
1370    Flat = 1,
1371    Total = 2,
1372}
1373impl GroupRollupMode {
1374    /// String value of the enum field names used in the ProtoBuf definition.
1375    ///
1376    /// The values are not transformed in any way and thus are considered stable
1377    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1378    pub fn as_str_name(&self) -> &'static str {
1379        match self {
1380            GroupRollupMode::Rollup => "ROLLUP",
1381            GroupRollupMode::Flat => "FLAT",
1382            GroupRollupMode::Total => "TOTAL",
1383        }
1384    }
1385    /// Creates an enum from field names used in the ProtoBuf definition.
1386    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1387        match value {
1388            "ROLLUP" => Some(Self::Rollup),
1389            "FLAT" => Some(Self::Flat),
1390            "TOTAL" => Some(Self::Total),
1391            _ => None,
1392        }
1393    }
1394}
1395/// The `split_by` corollary to `GroupRollupMode`. `FLAT` (the wire default)
1396/// is the historical behavior - only full-depth split combinations are
1397/// emitted as columns. `ROLLUP` additionally emits grand-total and subtotal
1398/// column groups in pre-order ("totals before"). Enum value names are
1399/// prefixed because proto enum values share their parent scope with
1400/// `GroupRollupMode`'s.
1401#[derive(serde::Serialize)]
1402#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1403#[repr(i32)]
1404pub enum SplitRollupMode {
1405    Flat = 0,
1406    Rollup = 1,
1407}
1408impl SplitRollupMode {
1409    /// String value of the enum field names used in the ProtoBuf definition.
1410    ///
1411    /// The values are not transformed in any way and thus are considered stable
1412    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1413    pub fn as_str_name(&self) -> &'static str {
1414        match self {
1415            SplitRollupMode::Flat => "SPLIT_ROLLUP_MODE_FLAT",
1416            SplitRollupMode::Rollup => "SPLIT_ROLLUP_MODE_ROLLUP",
1417        }
1418    }
1419    /// Creates an enum from field names used in the ProtoBuf definition.
1420    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1421        match value {
1422            "SPLIT_ROLLUP_MODE_FLAT" => Some(Self::Flat),
1423            "SPLIT_ROLLUP_MODE_ROLLUP" => Some(Self::Rollup),
1424            _ => None,
1425        }
1426    }
1427}
1428#[derive(serde::Deserialize, ts_rs::TS)]
1429#[serde(rename_all = "snake_case")]
1430#[derive(serde::Serialize)]
1431#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1432#[repr(i32)]
1433pub enum ListFlatten {
1434    Zip = 0,
1435    Cartesian = 1,
1436    Stringify = 2,
1437}
1438impl ListFlatten {
1439    /// String value of the enum field names used in the ProtoBuf definition.
1440    ///
1441    /// The values are not transformed in any way and thus are considered stable
1442    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1443    pub fn as_str_name(&self) -> &'static str {
1444        match self {
1445            ListFlatten::Zip => "LIST_FLATTEN_ZIP",
1446            ListFlatten::Cartesian => "LIST_FLATTEN_CARTESIAN",
1447            ListFlatten::Stringify => "LIST_FLATTEN_STRINGIFY",
1448        }
1449    }
1450    /// Creates an enum from field names used in the ProtoBuf definition.
1451    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1452        match value {
1453            "LIST_FLATTEN_ZIP" => Some(Self::Zip),
1454            "LIST_FLATTEN_CARTESIAN" => Some(Self::Cartesian),
1455            "LIST_FLATTEN_STRINGIFY" => Some(Self::Stringify),
1456            _ => None,
1457        }
1458    }
1459}
1460#[derive(serde::Deserialize, ts_rs::TS)]
1461#[serde(rename_all = "snake_case")]
1462#[derive(serde::Serialize)]
1463#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1464#[repr(i32)]
1465pub enum JoinType {
1466    Inner = 0,
1467    Left = 1,
1468    Outer = 2,
1469}
1470impl JoinType {
1471    /// String value of the enum field names used in the ProtoBuf definition.
1472    ///
1473    /// The values are not transformed in any way and thus are considered stable
1474    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1475    pub fn as_str_name(&self) -> &'static str {
1476        match self {
1477            JoinType::Inner => "INNER",
1478            JoinType::Left => "LEFT",
1479            JoinType::Outer => "OUTER",
1480        }
1481    }
1482    /// Creates an enum from field names used in the ProtoBuf definition.
1483    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1484        match value {
1485            "INNER" => Some(Self::Inner),
1486            "LEFT" => Some(Self::Left),
1487            "OUTER" => Some(Self::Outer),
1488            _ => None,
1489        }
1490    }
1491}