pub struct OpenStreamRequest {
pub stream_id: String,
pub purpose: i32,
pub mode: i32,
pub bidirectional: bool,
pub content_type: Option<String>,
pub correlation_id: Option<String>,
pub metadata_json: Option<String>,
pub expected_bytes: Option<u64>,
pub idle_timeout_ms: Option<u64>,
}Fields§
§stream_id: String§purpose: i32§mode: i32§bidirectional: bool§content_type: Option<String>§correlation_id: Option<String>§metadata_json: Option<String>§expected_bytes: Option<u64>§idle_timeout_ms: Option<u64>Implementations§
Source§impl OpenStreamRequest
impl OpenStreamRequest
Sourcepub fn purpose(&self) -> StreamPurpose
pub fn purpose(&self) -> StreamPurpose
Returns the enum value of purpose, or the default if the field is set to an invalid enum value.
Sourcepub fn set_purpose(&mut self, value: StreamPurpose)
pub fn set_purpose(&mut self, value: StreamPurpose)
Sets purpose to the provided enum value.
Sourcepub fn mode(&self) -> StreamMode
pub fn mode(&self) -> StreamMode
Returns the enum value of mode, or the default if the field is set to an invalid enum value.
Sourcepub fn set_mode(&mut self, value: StreamMode)
pub fn set_mode(&mut self, value: StreamMode)
Sets mode to the provided enum value.
Sourcepub fn content_type(&self) -> &str
pub fn content_type(&self) -> &str
Returns the value of content_type, or the default value if content_type is unset.
Sourcepub fn correlation_id(&self) -> &str
pub fn correlation_id(&self) -> &str
Returns the value of correlation_id, or the default value if correlation_id is unset.
Sourcepub fn metadata_json(&self) -> &str
pub fn metadata_json(&self) -> &str
Returns the value of metadata_json, or the default value if metadata_json is unset.
Sourcepub fn expected_bytes(&self) -> u64
pub fn expected_bytes(&self) -> u64
Returns the value of expected_bytes, or the default value if expected_bytes is unset.
Sourcepub fn idle_timeout_ms(&self) -> u64
pub fn idle_timeout_ms(&self) -> u64
Returns the value of idle_timeout_ms, or the default value if idle_timeout_ms is unset.
Trait Implementations§
Source§impl Clone for OpenStreamRequest
impl Clone for OpenStreamRequest
Source§fn clone(&self) -> OpenStreamRequest
fn clone(&self) -> OpenStreamRequest
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OpenStreamRequest
impl Debug for OpenStreamRequest
Source§impl Default for OpenStreamRequest
impl Default for OpenStreamRequest
Source§impl<'de> Deserialize<'de> for OpenStreamRequest
impl<'de> Deserialize<'de> for OpenStreamRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for OpenStreamRequest
Source§impl Hash for OpenStreamRequest
impl Hash for OpenStreamRequest
Source§impl Message for OpenStreamRequest
impl Message for OpenStreamRequest
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.Source§impl PartialEq for OpenStreamRequest
impl PartialEq for OpenStreamRequest
Source§impl Serialize for OpenStreamRequest
impl Serialize for OpenStreamRequest
impl StructuralPartialEq for OpenStreamRequest
Auto Trait Implementations§
impl Freeze for OpenStreamRequest
impl RefUnwindSafe for OpenStreamRequest
impl Send for OpenStreamRequest
impl Sync for OpenStreamRequest
impl Unpin for OpenStreamRequest
impl UnsafeUnpin for OpenStreamRequest
impl UnwindSafe for OpenStreamRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more