Skip to main content

TpmTaggedField

Trait TpmTaggedField 

Source
pub trait TpmTaggedField<'a, Tag> {
    type View;

    // Required method
    fn cast_tagged_prefix_field(
        tag: Tag,
        buf: &'a [u8],
    ) -> TpmResult<(Self::View, &'a [u8])>;
}
Expand description

Reads a union field selected by a previously-read tag.

Required Associated Types§

Required Methods§

Source

fn cast_tagged_prefix_field( tag: Tag, buf: &'a [u8], ) -> TpmResult<(Self::View, &'a [u8])>

Reads the tagged field from buf and returns the remaining bytes.

§Errors

Returns Err(TpmError) when tag does not select a valid variant or buf does not start with a valid selected field.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuAsymScheme

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuHa

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuKdfScheme

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuKeyedhashScheme

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuPublicId

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuPublicParms

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuSensitiveComposite

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuSigScheme

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuSignature

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuSymKeyBits

Source§

impl<'a> TpmTaggedField<'a, TpmAlgId> for TpmuSymMode
where TpmAlgId: TpmField<'a>,

Source§

impl<'a> TpmTaggedField<'a, TpmCap> for TpmuCapabilities

Source§

impl<'a> TpmTaggedField<'a, TpmHt> for TpmuNvPublic2

Source§

impl<'a> TpmTaggedField<'a, TpmSt> for TpmuAttest