1#[derive(Clone, Copy, PartialEq, ::prost::Message)]
4pub struct OpcAuthenticationConfig {
5 #[prost(oneof = "opc_authentication_config::OpcAuthenticationConfig", tags = "1")]
7 pub opc_authentication_config: ::core::option::Option<
8 opc_authentication_config::OpcAuthenticationConfig,
9 >,
10}
11pub mod opc_authentication_config {
13 #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
15 pub enum OpcAuthenticationConfig {
16 #[prost(message, tag = "1")]
17 Anonymous(super::super::super::super::google::protobuf::Empty),
18 }
19}
20#[derive(Clone, PartialEq, ::prost::Message)]
22pub struct OpcIdentifierValue {
23 #[prost(oneof = "opc_identifier_value::OpcIdentifierValue", tags = "1, 2")]
24 pub opc_identifier_value: ::core::option::Option<
25 opc_identifier_value::OpcIdentifierValue,
26 >,
27}
28pub mod opc_identifier_value {
30 #[derive(Clone, PartialEq, ::prost::Oneof)]
31 pub enum OpcIdentifierValue {
32 #[prost(int32, tag = "1")]
33 Numeric(i32),
34 #[prost(string, tag = "2")]
35 String(::prost::alloc::string::String),
36 }
37}
38#[derive(Clone, PartialEq, ::prost::Message)]
40pub struct OpcNode {
41 #[prost(uint32, optional, tag = "1")]
42 pub namespace: ::core::option::Option<u32>,
43 #[prost(message, optional, tag = "2")]
44 pub identifier: ::core::option::Option<OpcIdentifierValue>,
45}
46#[derive(Clone, PartialEq, ::prost::Message)]
48pub struct OpcUaChannelNamingConvention {
49 #[prost(
50 oneof = "opc_ua_channel_naming_convention::NamingConvention",
51 tags = "1, 2, 3, 4"
52 )]
53 pub naming_convention: ::core::option::Option<
54 opc_ua_channel_naming_convention::NamingConvention,
55 >,
56}
57pub mod opc_ua_channel_naming_convention {
59 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
60 pub struct OpcUaNodeId {}
61 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
62 pub struct OpcUaBrowseName {}
63 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
64 pub struct OpcUaDisplayName {}
65 #[derive(Clone, PartialEq, ::prost::Message)]
67 pub struct OpcUaFullPath {
68 #[prost(message, repeated, tag = "1")]
70 pub root_nodes: ::prost::alloc::vec::Vec<super::OpcNode>,
71 #[prost(string, tag = "2")]
73 pub delimiter: ::prost::alloc::string::String,
74 }
75 #[derive(Clone, PartialEq, ::prost::Oneof)]
76 pub enum NamingConvention {
77 #[prost(message, tag = "1")]
79 NodeId(OpcUaNodeId),
80 #[prost(message, tag = "2")]
82 BrowseName(OpcUaBrowseName),
83 #[prost(message, tag = "3")]
85 DisplayName(OpcUaDisplayName),
86 #[prost(message, tag = "4")]
88 FullPath(OpcUaFullPath),
89 }
90}
91#[derive(Clone, PartialEq, ::prost::Message)]
93pub struct OpcUaConnectionDetails {
94 #[prost(string, tag = "1")]
95 pub uri: ::prost::alloc::string::String,
96 #[prost(enumeration = "OpcSecurityPolicy", tag = "2")]
97 pub security_policy: i32,
98 #[prost(message, optional, tag = "3")]
99 pub authentication_config: ::core::option::Option<OpcAuthenticationConfig>,
100}
101#[derive(Clone, PartialEq, ::prost::Message)]
102pub struct OpcUaTraversalConfig {
103 #[prost(message, repeated, tag = "1")]
106 pub root_nodes: ::prost::alloc::vec::Vec<OpcNode>,
107 #[prost(message, repeated, tag = "2")]
109 pub skip_nodes: ::prost::alloc::vec::Vec<OpcNode>,
110 #[prost(enumeration = "OpcUaReferenceExplorationType", tag = "3")]
112 pub reference_exploration_type: i32,
113}
114#[derive(Clone, PartialEq, ::prost::Message)]
115pub struct OpcUaDirectNodeSubscription {
116 #[prost(message, repeated, tag = "1")]
117 pub nodes: ::prost::alloc::vec::Vec<OpcNode>,
118}
119#[derive(Clone, PartialEq, ::prost::Message)]
120pub struct OpcUaNodeExplorationConfig {
121 #[prost(
122 oneof = "opc_ua_node_exploration_config::OpcUaNodeExplorationConfig",
123 tags = "1, 2"
124 )]
125 pub opc_ua_node_exploration_config: ::core::option::Option<
126 opc_ua_node_exploration_config::OpcUaNodeExplorationConfig,
127 >,
128}
129pub mod opc_ua_node_exploration_config {
131 #[derive(Clone, PartialEq, ::prost::Oneof)]
132 pub enum OpcUaNodeExplorationConfig {
133 #[prost(message, tag = "1")]
134 OpcUaTraversalConfig(super::OpcUaTraversalConfig),
135 #[prost(message, tag = "2")]
136 OpcUaDirectNodeSubscription(super::OpcUaDirectNodeSubscription),
137 }
138}
139#[derive(Clone, Copy, PartialEq, ::prost::Message)]
140pub struct OpcUaTimestampHandling {
141 #[prost(oneof = "opc_ua_timestamp_handling::TimestampType", tags = "1, 2, 3")]
142 pub timestamp_type: ::core::option::Option<opc_ua_timestamp_handling::TimestampType>,
143}
144pub mod opc_ua_timestamp_handling {
146 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
148 pub struct OpcUaServerTime {}
149 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
151 pub struct OpcUaSourceTime {}
152 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
155 pub struct OpcUaRelativeTimestamp {
156 #[prost(message, optional, tag = "1")]
157 pub offset: ::core::option::Option<
158 super::super::super::super::google::protobuf::Timestamp,
159 >,
160 }
161 #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
162 pub enum TimestampType {
163 #[prost(message, tag = "1")]
164 Server(OpcUaServerTime),
165 #[prost(message, tag = "2")]
166 Source(OpcUaSourceTime),
167 #[prost(message, tag = "3")]
168 Relative(OpcUaRelativeTimestamp),
169 }
170}
171#[derive(Clone, Copy, PartialEq, ::prost::Message)]
172pub struct OpcUaDataChangeFilter {
173 #[prost(enumeration = "OpcUaDataChangeTrigger", tag = "1")]
175 pub trigger: i32,
176 #[prost(enumeration = "OpcUaDeadbandType", tag = "2")]
177 pub deadband_type: i32,
178 #[prost(double, tag = "3")]
179 pub deadband_value: f64,
180}
181#[derive(Clone, PartialEq, ::prost::Message)]
183pub struct OpcUaScrapingConfig {
184 #[prost(message, optional, tag = "1")]
185 pub node_exploration_config: ::core::option::Option<OpcUaNodeExplorationConfig>,
186 #[prost(string, tag = "2")]
188 pub unit_node_name: ::prost::alloc::string::String,
189 #[prost(message, optional, tag = "3")]
190 pub channel_naming_convention: ::core::option::Option<OpcUaChannelNamingConvention>,
191 #[prost(bool, tag = "4")]
193 pub override_host: bool,
194 #[prost(enumeration = "OpcUaUnknownDataTypeHandling", tag = "5")]
196 pub unknown_data_type_handling: i32,
197 #[prost(enumeration = "OpcUaFailedMonitorHandling", tag = "6")]
199 pub failed_monitor_handling: i32,
200 #[prost(message, optional, tag = "7")]
202 pub timestamp_handling: ::core::option::Option<OpcUaTimestampHandling>,
203 #[prost(message, optional, tag = "8")]
205 pub data_change_filter: ::core::option::Option<OpcUaDataChangeFilter>,
206}
207#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
210#[repr(i32)]
211pub enum OpcSecurityPolicy {
212 Unspecified = 0,
213 None = 1,
214}
215impl OpcSecurityPolicy {
216 pub fn as_str_name(&self) -> &'static str {
221 match self {
222 Self::Unspecified => "OPC_SECURITY_POLICY_UNSPECIFIED",
223 Self::None => "NONE",
224 }
225 }
226 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
228 match value {
229 "OPC_SECURITY_POLICY_UNSPECIFIED" => Some(Self::Unspecified),
230 "NONE" => Some(Self::None),
231 _ => None,
232 }
233 }
234}
235#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
236#[repr(i32)]
237pub enum OpcUaReferenceExplorationType {
238 Unspecified = 0,
239 Organizes = 1,
240 HierarchicalReferences = 2,
241}
242impl OpcUaReferenceExplorationType {
243 pub fn as_str_name(&self) -> &'static str {
248 match self {
249 Self::Unspecified => "OPC_UA_REFERENCE_EXPLORATION_TYPE_UNSPECIFIED",
250 Self::Organizes => "OPC_UA_REFERENCE_EXPLORATION_TYPE_ORGANIZES",
251 Self::HierarchicalReferences => {
252 "OPC_UA_REFERENCE_EXPLORATION_TYPE_HIERARCHICAL_REFERENCES"
253 }
254 }
255 }
256 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
258 match value {
259 "OPC_UA_REFERENCE_EXPLORATION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
260 "OPC_UA_REFERENCE_EXPLORATION_TYPE_ORGANIZES" => Some(Self::Organizes),
261 "OPC_UA_REFERENCE_EXPLORATION_TYPE_HIERARCHICAL_REFERENCES" => {
262 Some(Self::HierarchicalReferences)
263 }
264 _ => None,
265 }
266 }
267}
268#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
269#[repr(i32)]
270pub enum OpcUaUnknownDataTypeHandling {
271 Unspecified = 0,
272 Error = 1,
274 TreatAsDouble = 2,
276 TreatAsString = 3,
278}
279impl OpcUaUnknownDataTypeHandling {
280 pub fn as_str_name(&self) -> &'static str {
285 match self {
286 Self::Unspecified => "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_UNSPECIFIED",
287 Self::Error => "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_ERROR",
288 Self::TreatAsDouble => "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_TREAT_AS_DOUBLE",
289 Self::TreatAsString => "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_TREAT_AS_STRING",
290 }
291 }
292 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
294 match value {
295 "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_UNSPECIFIED" => Some(Self::Unspecified),
296 "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_ERROR" => Some(Self::Error),
297 "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_TREAT_AS_DOUBLE" => {
298 Some(Self::TreatAsDouble)
299 }
300 "OPC_UA_UNKNOWN_DATA_TYPE_HANDLING_TREAT_AS_STRING" => {
301 Some(Self::TreatAsString)
302 }
303 _ => None,
304 }
305 }
306}
307#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
308#[repr(i32)]
309pub enum OpcUaFailedMonitorHandling {
310 Unspecified = 0,
311 Error = 1,
312 Ignore = 2,
313}
314impl OpcUaFailedMonitorHandling {
315 pub fn as_str_name(&self) -> &'static str {
320 match self {
321 Self::Unspecified => "OPC_UA_FAILED_MONITOR_HANDLING_UNSPECIFIED",
322 Self::Error => "OPC_UA_FAILED_MONITOR_HANDLING_ERROR",
323 Self::Ignore => "OPC_UA_FAILED_MONITOR_HANDLING_IGNORE",
324 }
325 }
326 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
328 match value {
329 "OPC_UA_FAILED_MONITOR_HANDLING_UNSPECIFIED" => Some(Self::Unspecified),
330 "OPC_UA_FAILED_MONITOR_HANDLING_ERROR" => Some(Self::Error),
331 "OPC_UA_FAILED_MONITOR_HANDLING_IGNORE" => Some(Self::Ignore),
332 _ => None,
333 }
334 }
335}
336#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
337#[repr(i32)]
338pub enum OpcUaDataChangeTrigger {
339 Unspecified = 0,
340 StatusOnly = 1,
341 StatusValue = 2,
342 StatusValueTimestamp = 3,
343}
344impl OpcUaDataChangeTrigger {
345 pub fn as_str_name(&self) -> &'static str {
350 match self {
351 Self::Unspecified => "OPC_UA_DATA_CHANGE_TRIGGER_UNSPECIFIED",
352 Self::StatusOnly => "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_ONLY",
353 Self::StatusValue => "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_VALUE",
354 Self::StatusValueTimestamp => {
355 "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_VALUE_TIMESTAMP"
356 }
357 }
358 }
359 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
361 match value {
362 "OPC_UA_DATA_CHANGE_TRIGGER_UNSPECIFIED" => Some(Self::Unspecified),
363 "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_ONLY" => Some(Self::StatusOnly),
364 "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_VALUE" => Some(Self::StatusValue),
365 "OPC_UA_DATA_CHANGE_TRIGGER_STATUS_VALUE_TIMESTAMP" => {
366 Some(Self::StatusValueTimestamp)
367 }
368 _ => None,
369 }
370 }
371}
372#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
373#[repr(i32)]
374pub enum OpcUaDeadbandType {
375 Unspecified = 0,
376 None = 1,
377 Absolute = 2,
378 Percent = 3,
379}
380impl OpcUaDeadbandType {
381 pub fn as_str_name(&self) -> &'static str {
386 match self {
387 Self::Unspecified => "OPC_UA_DEADBAND_TYPE_UNSPECIFIED",
388 Self::None => "OPC_UA_DEADBAND_TYPE_NONE",
389 Self::Absolute => "OPC_UA_DEADBAND_TYPE_ABSOLUTE",
390 Self::Percent => "OPC_UA_DEADBAND_TYPE_PERCENT",
391 }
392 }
393 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
395 match value {
396 "OPC_UA_DEADBAND_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
397 "OPC_UA_DEADBAND_TYPE_NONE" => Some(Self::None),
398 "OPC_UA_DEADBAND_TYPE_ABSOLUTE" => Some(Self::Absolute),
399 "OPC_UA_DEADBAND_TYPE_PERCENT" => Some(Self::Percent),
400 _ => None,
401 }
402 }
403}
404#[derive(Clone, PartialEq, ::prost::Message)]
406pub struct CreateStreamingConnectionRequest {
407 #[prost(string, tag = "1")]
408 pub name: ::prost::alloc::string::String,
409 #[prost(string, optional, tag = "2")]
410 pub description: ::core::option::Option<::prost::alloc::string::String>,
411 #[prost(message, optional, tag = "3")]
412 pub connection_details: ::core::option::Option<StreamingConnectionDetails>,
413 #[prost(string, optional, tag = "4")]
414 pub workspace_rid: ::core::option::Option<::prost::alloc::string::String>,
415}
416#[derive(Clone, PartialEq, ::prost::Message)]
418pub struct CreateStreamingConnectionResponse {
419 #[prost(string, tag = "1")]
420 pub streaming_connection_rid: ::prost::alloc::string::String,
421}
422#[derive(Clone, Copy, PartialEq, ::prost::Message)]
424pub struct StopStreamResponse {
425 #[prost(bool, tag = "1")]
426 pub success: bool,
427}
428#[derive(Clone, Copy, PartialEq, ::prost::Message)]
429pub struct StartStreamResponse {
430 #[prost(bool, tag = "1")]
431 pub success: bool,
432}
433#[derive(Clone, PartialEq, ::prost::Message)]
435pub struct StreamingConnection {
436 #[prost(string, tag = "1")]
437 pub streaming_connection_rid: ::prost::alloc::string::String,
438 #[prost(string, tag = "2")]
439 pub name: ::prost::alloc::string::String,
440 #[prost(string, optional, tag = "3")]
441 pub description: ::core::option::Option<::prost::alloc::string::String>,
442 #[prost(message, optional, tag = "4")]
443 pub connection_details: ::core::option::Option<StreamingConnectionDetails>,
444 #[prost(enumeration = "StreamingConnectionStatus", tag = "6")]
445 pub status: i32,
446 #[prost(message, optional, tag = "7")]
447 pub created_at: ::core::option::Option<
448 super::super::super::google::protobuf::Timestamp,
449 >,
450}
451#[derive(Clone, PartialEq, ::prost::Message)]
453pub struct StreamingConnectionDetails {
454 #[prost(
456 oneof = "streaming_connection_details::StreamingConnectionDetails",
457 tags = "1"
458 )]
459 pub streaming_connection_details: ::core::option::Option<
460 streaming_connection_details::StreamingConnectionDetails,
461 >,
462}
463pub mod streaming_connection_details {
465 #[derive(Clone, PartialEq, ::prost::Oneof)]
467 pub enum StreamingConnectionDetails {
468 #[prost(message, tag = "1")]
469 OpcUa(super::OpcUaConnectionDetails),
470 }
471}
472#[derive(Clone, PartialEq, ::prost::Message)]
473pub struct StreamingScrapingConfig {
474 #[prost(oneof = "streaming_scraping_config::StreamingScrapingConfig", tags = "1")]
476 pub streaming_scraping_config: ::core::option::Option<
477 streaming_scraping_config::StreamingScrapingConfig,
478 >,
479}
480pub mod streaming_scraping_config {
482 #[derive(Clone, PartialEq, ::prost::Oneof)]
484 pub enum StreamingScrapingConfig {
485 #[prost(message, tag = "1")]
486 OpcUa(super::OpcUaScrapingConfig),
487 }
488}
489#[derive(Clone, PartialEq, ::prost::Message)]
490pub struct GetStreamingConnectionRequest {
491 #[prost(string, tag = "1")]
492 pub streaming_connection_rid: ::prost::alloc::string::String,
493}
494#[derive(Clone, PartialEq, ::prost::Message)]
495pub struct GetStreamingConnectionResponse {
496 #[prost(message, optional, tag = "1")]
497 pub streaming_connection: ::core::option::Option<StreamingConnection>,
498}
499#[derive(Clone, PartialEq, ::prost::Message)]
500pub struct ListStreamingConnectionsRequest {
501 #[prost(string, repeated, tag = "1")]
502 pub workspace_rids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
503}
504#[derive(Clone, PartialEq, ::prost::Message)]
505pub struct ListStreamingConnectionsResponse {
506 #[prost(message, repeated, tag = "1")]
507 pub streaming_connections: ::prost::alloc::vec::Vec<StreamingConnection>,
508}
509#[derive(Clone, PartialEq, ::prost::Message)]
510pub struct UpdateStreamingConnectionStatusRequest {
511 #[prost(string, tag = "1")]
512 pub streaming_connection_rid: ::prost::alloc::string::String,
513 #[prost(enumeration = "StreamingConnectionStatus", tag = "2")]
514 pub status: i32,
515}
516#[derive(Clone, PartialEq, ::prost::Message)]
517pub struct UpdateStreamingConnectionStatusResponse {
518 #[prost(message, optional, tag = "1")]
519 pub streaming_connection: ::core::option::Option<StreamingConnection>,
520}
521#[derive(Clone, PartialEq, ::prost::Message)]
522pub struct StartStreamRequest {
523 #[prost(string, tag = "1")]
524 pub streaming_connection_rid: ::prost::alloc::string::String,
525 #[prost(message, optional, tag = "2")]
526 pub scraping_config: ::core::option::Option<StreamingScrapingConfig>,
527 #[prost(string, tag = "3")]
528 pub target_dataset_rid: ::prost::alloc::string::String,
529}
530#[derive(Clone, PartialEq, ::prost::Message)]
531pub struct StopStreamRequest {
532 #[prost(string, tag = "1")]
533 pub streaming_connection_rid: ::prost::alloc::string::String,
534}
535#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
537#[repr(i32)]
538pub enum StreamingConnectionErrorType {
539 Unspecified = 0,
540 ConnectionNotFound = 1,
541 WorkflowNotFound = 2,
542 StreamingConnectionAlreadyRunning = 3,
543}
544impl StreamingConnectionErrorType {
545 pub fn as_str_name(&self) -> &'static str {
550 match self {
551 Self::Unspecified => "STREAMING_CONNECTION_ERROR_TYPE_UNSPECIFIED",
552 Self::ConnectionNotFound => {
553 "STREAMING_CONNECTION_ERROR_TYPE_CONNECTION_NOT_FOUND"
554 }
555 Self::WorkflowNotFound => {
556 "STREAMING_CONNECTION_ERROR_TYPE_WORKFLOW_NOT_FOUND"
557 }
558 Self::StreamingConnectionAlreadyRunning => {
559 "STREAMING_CONNECTION_ERROR_TYPE_STREAMING_CONNECTION_ALREADY_RUNNING"
560 }
561 }
562 }
563 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
565 match value {
566 "STREAMING_CONNECTION_ERROR_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
567 "STREAMING_CONNECTION_ERROR_TYPE_CONNECTION_NOT_FOUND" => {
568 Some(Self::ConnectionNotFound)
569 }
570 "STREAMING_CONNECTION_ERROR_TYPE_WORKFLOW_NOT_FOUND" => {
571 Some(Self::WorkflowNotFound)
572 }
573 "STREAMING_CONNECTION_ERROR_TYPE_STREAMING_CONNECTION_ALREADY_RUNNING" => {
574 Some(Self::StreamingConnectionAlreadyRunning)
575 }
576 _ => None,
577 }
578 }
579}
580#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
583#[repr(i32)]
584pub enum StreamingConnectionStatus {
585 Unspecified = 0,
586 Connected = 1,
587 Disconnected = 2,
588}
589impl StreamingConnectionStatus {
590 pub fn as_str_name(&self) -> &'static str {
595 match self {
596 Self::Unspecified => "STREAMING_CONNECTION_STATUS_UNSPECIFIED",
597 Self::Connected => "CONNECTED",
598 Self::Disconnected => "DISCONNECTED",
599 }
600 }
601 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
603 match value {
604 "STREAMING_CONNECTION_STATUS_UNSPECIFIED" => Some(Self::Unspecified),
605 "CONNECTED" => Some(Self::Connected),
606 "DISCONNECTED" => Some(Self::Disconnected),
607 _ => None,
608 }
609 }
610}
611pub mod streaming_connection_service_client {
613 #![allow(
614 unused_variables,
615 dead_code,
616 missing_docs,
617 clippy::wildcard_imports,
618 clippy::let_unit_value,
619 )]
620 use tonic::codegen::*;
621 use tonic::codegen::http::Uri;
622 #[derive(Debug, Clone)]
625 pub struct StreamingConnectionServiceClient<T> {
626 inner: tonic::client::Grpc<T>,
627 }
628 impl StreamingConnectionServiceClient<tonic::transport::Channel> {
629 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
631 where
632 D: TryInto<tonic::transport::Endpoint>,
633 D::Error: Into<StdError>,
634 {
635 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
636 Ok(Self::new(conn))
637 }
638 }
639 impl<T> StreamingConnectionServiceClient<T>
640 where
641 T: tonic::client::GrpcService<tonic::body::Body>,
642 T::Error: Into<StdError>,
643 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
644 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
645 {
646 pub fn new(inner: T) -> Self {
647 let inner = tonic::client::Grpc::new(inner);
648 Self { inner }
649 }
650 pub fn with_origin(inner: T, origin: Uri) -> Self {
651 let inner = tonic::client::Grpc::with_origin(inner, origin);
652 Self { inner }
653 }
654 pub fn with_interceptor<F>(
655 inner: T,
656 interceptor: F,
657 ) -> StreamingConnectionServiceClient<InterceptedService<T, F>>
658 where
659 F: tonic::service::Interceptor,
660 T::ResponseBody: Default,
661 T: tonic::codegen::Service<
662 http::Request<tonic::body::Body>,
663 Response = http::Response<
664 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
665 >,
666 >,
667 <T as tonic::codegen::Service<
668 http::Request<tonic::body::Body>,
669 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
670 {
671 StreamingConnectionServiceClient::new(
672 InterceptedService::new(inner, interceptor),
673 )
674 }
675 #[must_use]
680 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
681 self.inner = self.inner.send_compressed(encoding);
682 self
683 }
684 #[must_use]
686 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
687 self.inner = self.inner.accept_compressed(encoding);
688 self
689 }
690 #[must_use]
694 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
695 self.inner = self.inner.max_decoding_message_size(limit);
696 self
697 }
698 #[must_use]
702 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
703 self.inner = self.inner.max_encoding_message_size(limit);
704 self
705 }
706 pub async fn create_streaming_connection(
710 &mut self,
711 request: impl tonic::IntoRequest<super::CreateStreamingConnectionRequest>,
712 ) -> std::result::Result<
713 tonic::Response<super::CreateStreamingConnectionResponse>,
714 tonic::Status,
715 > {
716 self.inner
717 .ready()
718 .await
719 .map_err(|e| {
720 tonic::Status::unknown(
721 format!("Service was not ready: {}", e.into()),
722 )
723 })?;
724 let codec = tonic::codec::ProstCodec::default();
725 let path = http::uri::PathAndQuery::from_static(
726 "/nominal.streaming_connection_service.v1.StreamingConnectionService/CreateStreamingConnection",
727 );
728 let mut req = request.into_request();
729 req.extensions_mut()
730 .insert(
731 GrpcMethod::new(
732 "nominal.streaming_connection_service.v1.StreamingConnectionService",
733 "CreateStreamingConnection",
734 ),
735 );
736 self.inner.unary(req, path, codec).await
737 }
738 pub async fn get_streaming_connection(
740 &mut self,
741 request: impl tonic::IntoRequest<super::GetStreamingConnectionRequest>,
742 ) -> std::result::Result<
743 tonic::Response<super::GetStreamingConnectionResponse>,
744 tonic::Status,
745 > {
746 self.inner
747 .ready()
748 .await
749 .map_err(|e| {
750 tonic::Status::unknown(
751 format!("Service was not ready: {}", e.into()),
752 )
753 })?;
754 let codec = tonic::codec::ProstCodec::default();
755 let path = http::uri::PathAndQuery::from_static(
756 "/nominal.streaming_connection_service.v1.StreamingConnectionService/GetStreamingConnection",
757 );
758 let mut req = request.into_request();
759 req.extensions_mut()
760 .insert(
761 GrpcMethod::new(
762 "nominal.streaming_connection_service.v1.StreamingConnectionService",
763 "GetStreamingConnection",
764 ),
765 );
766 self.inner.unary(req, path, codec).await
767 }
768 pub async fn list_streaming_connections(
770 &mut self,
771 request: impl tonic::IntoRequest<super::ListStreamingConnectionsRequest>,
772 ) -> std::result::Result<
773 tonic::Response<super::ListStreamingConnectionsResponse>,
774 tonic::Status,
775 > {
776 self.inner
777 .ready()
778 .await
779 .map_err(|e| {
780 tonic::Status::unknown(
781 format!("Service was not ready: {}", e.into()),
782 )
783 })?;
784 let codec = tonic::codec::ProstCodec::default();
785 let path = http::uri::PathAndQuery::from_static(
786 "/nominal.streaming_connection_service.v1.StreamingConnectionService/ListStreamingConnections",
787 );
788 let mut req = request.into_request();
789 req.extensions_mut()
790 .insert(
791 GrpcMethod::new(
792 "nominal.streaming_connection_service.v1.StreamingConnectionService",
793 "ListStreamingConnections",
794 ),
795 );
796 self.inner.unary(req, path, codec).await
797 }
798 pub async fn update_streaming_connection_status(
800 &mut self,
801 request: impl tonic::IntoRequest<
802 super::UpdateStreamingConnectionStatusRequest,
803 >,
804 ) -> std::result::Result<
805 tonic::Response<super::UpdateStreamingConnectionStatusResponse>,
806 tonic::Status,
807 > {
808 self.inner
809 .ready()
810 .await
811 .map_err(|e| {
812 tonic::Status::unknown(
813 format!("Service was not ready: {}", e.into()),
814 )
815 })?;
816 let codec = tonic::codec::ProstCodec::default();
817 let path = http::uri::PathAndQuery::from_static(
818 "/nominal.streaming_connection_service.v1.StreamingConnectionService/UpdateStreamingConnectionStatus",
819 );
820 let mut req = request.into_request();
821 req.extensions_mut()
822 .insert(
823 GrpcMethod::new(
824 "nominal.streaming_connection_service.v1.StreamingConnectionService",
825 "UpdateStreamingConnectionStatus",
826 ),
827 );
828 self.inner.unary(req, path, codec).await
829 }
830 pub async fn start_stream(
832 &mut self,
833 request: impl tonic::IntoRequest<super::StartStreamRequest>,
834 ) -> std::result::Result<
835 tonic::Response<super::StartStreamResponse>,
836 tonic::Status,
837 > {
838 self.inner
839 .ready()
840 .await
841 .map_err(|e| {
842 tonic::Status::unknown(
843 format!("Service was not ready: {}", e.into()),
844 )
845 })?;
846 let codec = tonic::codec::ProstCodec::default();
847 let path = http::uri::PathAndQuery::from_static(
848 "/nominal.streaming_connection_service.v1.StreamingConnectionService/StartStream",
849 );
850 let mut req = request.into_request();
851 req.extensions_mut()
852 .insert(
853 GrpcMethod::new(
854 "nominal.streaming_connection_service.v1.StreamingConnectionService",
855 "StartStream",
856 ),
857 );
858 self.inner.unary(req, path, codec).await
859 }
860 pub async fn stop_stream(
862 &mut self,
863 request: impl tonic::IntoRequest<super::StopStreamRequest>,
864 ) -> std::result::Result<
865 tonic::Response<super::StopStreamResponse>,
866 tonic::Status,
867 > {
868 self.inner
869 .ready()
870 .await
871 .map_err(|e| {
872 tonic::Status::unknown(
873 format!("Service was not ready: {}", e.into()),
874 )
875 })?;
876 let codec = tonic::codec::ProstCodec::default();
877 let path = http::uri::PathAndQuery::from_static(
878 "/nominal.streaming_connection_service.v1.StreamingConnectionService/StopStream",
879 );
880 let mut req = request.into_request();
881 req.extensions_mut()
882 .insert(
883 GrpcMethod::new(
884 "nominal.streaming_connection_service.v1.StreamingConnectionService",
885 "StopStream",
886 ),
887 );
888 self.inner.unary(req, path, codec).await
889 }
890 }
891}