[−][src]Struct simple_tlv::Tag
The tag field consists of a single byte encoding a tag number from 1 to 254. The values '00' and 'FF' are invalid.
Implementations
impl Tag
[src]
pub fn assert_eq(self, expected: Tag) -> Result<Tag>
[src]
Assert that this Tag
matches the provided expected tag.
On mismatch, returns an Error
with ErrorKind::UnexpectedTag
.
pub fn with_value<V>(self, value: V) -> TaggedValue<V>
[src]
Trait Implementations
impl Clone for Tag
[src]
fn clone(&self) -> Tag
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for Tag
[src]
impl Debug for Tag
[src]
impl Decodable<'_> for Tag
[src]
fn decode(decoder: &mut Decoder<'_>) -> Result<Self>
[src]
fn from_bytes(bytes: &'a [u8]) -> Result<Self>
[src]
impl Display for Tag
[src]
impl Encodable for Tag
[src]
fn encoded_length(&self) -> Result<Length>
[src]
fn encode(&self, encoder: &mut Encoder<'_>) -> Result<()>
[src]
fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8]>
[src]
impl Eq for Tag
[src]
impl PartialEq<Tag> for Tag
[src]
impl StructuralEq for Tag
[src]
impl StructuralPartialEq for Tag
[src]
impl TryFrom<u8> for Tag
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub 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>,