Enum aws_smithy_eventstream::frame::HeaderValue
source · [−]#[non_exhaustive]
pub enum HeaderValue {
Bool(bool),
Byte(i8),
Int16(i16),
Int32(i32),
Int64(i64),
ByteArray(Bytes),
String(StrBytes),
Timestamp(DateTime),
Uuid(u128),
}
Expand description
Event Stream frame header value.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Bool(bool)
Byte(i8)
Int16(i16)
Int32(i32)
Int64(i64)
ByteArray(Bytes)
String(StrBytes)
Timestamp(DateTime)
Uuid(u128)
Implementations
sourceimpl HeaderValue
impl HeaderValue
pub fn as_bool(&self) -> Result<bool, &Self>
pub fn as_byte(&self) -> Result<i8, &Self>
pub fn as_int16(&self) -> Result<i16, &Self>
pub fn as_int32(&self) -> Result<i32, &Self>
pub fn as_int64(&self) -> Result<i64, &Self>
pub fn as_byte_array(&self) -> Result<&Bytes, &Self>
pub fn as_string(&self) -> Result<&StrBytes, &Self>
pub fn as_timestamp(&self) -> Result<DateTime, &Self>
pub fn as_uuid(&self) -> Result<u128, &Self>
Trait Implementations
sourceimpl<'a> Arbitrary<'a> for HeaderValue
impl<'a> Arbitrary<'a> for HeaderValue
sourcefn arbitrary(unstruct: &mut Unstructured<'a>) -> Result<Self>
fn arbitrary(unstruct: &mut Unstructured<'a>) -> Result<Self>
Generate an arbitrary value of Self
from the given unstructured data. Read more
sourcefn arbitrary_take_rest(u: Unstructured<'a>) -> Result<Self, Error>
fn arbitrary_take_rest(u: Unstructured<'a>) -> Result<Self, Error>
Generate an arbitrary value of Self
from the entirety of the given unstructured data. Read more
sourceimpl Clone for HeaderValue
impl Clone for HeaderValue
sourcefn clone(&self) -> HeaderValue
fn clone(&self) -> HeaderValue
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for HeaderValue
impl Debug for HeaderValue
sourceimpl PartialEq<HeaderValue> for HeaderValue
impl PartialEq<HeaderValue> for HeaderValue
sourcefn eq(&self, other: &HeaderValue) -> bool
fn eq(&self, other: &HeaderValue) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &HeaderValue) -> bool
fn ne(&self, other: &HeaderValue) -> bool
This method tests for !=
.
impl StructuralPartialEq for HeaderValue
Auto Trait Implementations
impl RefUnwindSafe for HeaderValue
impl Send for HeaderValue
impl Sync for HeaderValue
impl Unpin for HeaderValue
impl UnwindSafe for HeaderValue
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more