[−][src]Enum amqp_codec::types::Variant
Represents an AMQP type for use in polymorphic collections
Variants
Indicates an empty value.
Boolean(bool)
Represents a true or false value.
Ubyte(u8)
Integer in the range 0 to 2^8 - 1 inclusive.
Ushort(u16)
Integer in the range 0 to 2^16 - 1 inclusive.
Uint(u32)
Integer in the range 0 to 2^32 - 1 inclusive.
Ulong(u64)
Integer in the range 0 to 2^64 - 1 inclusive.
Byte(i8)
Integer in the range 0 to 2^7 - 1 inclusive.
Short(i16)
Integer in the range 0 to 2^15 - 1 inclusive.
Int(i32)
Integer in the range 0 to 2^32 - 1 inclusive.
Long(i64)
Integer in the range 0 to 2^64 - 1 inclusive.
Float(OrderedFloat<f32>)
32-bit floating point number (IEEE 754-2008 binary32).
Double(OrderedFloat<f64>)
64-bit floating point number (IEEE 754-2008 binary64).
Char(char)
A single Unicode character.
An absolute point in time. Represents an approximate point in time using the Unix time encoding of UTC with a precision of milliseconds. For example, 1311704463521 represents the moment 2011-07-26T18:21:03.521Z.
Uuid(Uuid)
A universally unique identifier as defined by RFC-4122 section 4.1.2
Binary(Bytes)
A sequence of octets.
String(Str)
A sequence of Unicode characters
Symbol(Symbol)
Symbolic values from a constrained domain.
StaticSymbol(StaticSymbol)
Same as Symbol but for static refs
List(List)
List
Map(VariantMap)
Map
Described((Descriptor, Box<Variant>))
Described value
Methods
impl Variant
[src]
pub fn as_str(&self) -> Option<&str>
[src]
pub fn as_int(&self) -> Option<i32>
[src]
pub fn as_long(&self) -> Option<i64>
[src]
pub fn to_bytes_str(&self) -> Option<ByteString>
[src]
Trait Implementations
impl Encode for Variant
[src]
fn encoded_size(&self) -> usize
[src]
fn encode(&self, buf: &mut BytesMut)
[src]
Encodes Variant
into provided BytesMut
impl From<OrderedFloat<f32>> for Variant
[src]
fn from(original: OrderedFloat<f32>) -> Variant
[src]
impl From<OrderedFloat<f64>> for Variant
[src]
fn from(original: OrderedFloat<f64>) -> Variant
[src]
impl From<()> for Variant
[src]
impl From<List> for Variant
[src]
impl From<Bytes> for Variant
[src]
impl From<i64> for Variant
[src]
impl From<i8> for Variant
[src]
impl From<u64> for Variant
[src]
impl From<u8> for Variant
[src]
impl From<u32> for Variant
[src]
impl From<bool> for Variant
[src]
impl From<i16> for Variant
[src]
impl From<char> for Variant
[src]
impl From<Uuid> for Variant
[src]
impl From<i32> for Variant
[src]
impl From<DateTime<Utc>> for Variant
[src]
impl From<Str> for Variant
[src]
impl From<Symbol> for Variant
[src]
impl From<StaticSymbol> for Variant
[src]
fn from(original: StaticSymbol) -> Variant
[src]
impl From<VariantMap> for Variant
[src]
fn from(original: VariantMap) -> Variant
[src]
impl From<u16> for Variant
[src]
impl From<(Descriptor, Box<Variant>)> for Variant
[src]
impl From<ByteString> for Variant
[src]
fn from(s: ByteString) -> Self
[src]
impl From<String> for Variant
[src]
impl From<&'static str> for Variant
[src]
impl Clone for Variant
[src]
impl Eq for Variant
[src]
impl PartialEq<Variant> for Variant
[src]
impl PartialEq<str> for Variant
[src]
impl Debug for Variant
[src]
impl Display for Variant
[src]
impl Hash for Variant
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl StructuralPartialEq for Variant
[src]
impl StructuralEq for Variant
[src]
Auto Trait Implementations
impl Send for Variant
impl Sync for Variant
impl Unpin for Variant
impl UnwindSafe for Variant
impl RefUnwindSafe for Variant
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,