[][src]Type Definition rdp::nla::asn1::Enumerate

type Enumerate = i64;

An ASN1 Enumerate

Trait Implementations

impl ASN1 for Enumerate[src]

fn write_asn1(&self, writer: DERWriter) -> RdpResult<()>[src]

Write an ASN1 Enumerate Node using a DERWriter

Example

    let s = 4 as Enumerate;
    assert_eq!(to_der(&s), [10, 1, 4]);

fn read_asn1(&mut self, reader: BERReader) -> RdpResult<()>[src]

Read an ASN1 Enumerate using a BerReader

Example

    let mut s = 0 as Enumerate;
    from_der(&mut s, &[10, 1, 4]).unwrap();
    assert_eq!(s, 4);

fn visit(&self) -> ASN1Type[src]

Allow to cast an ASN1 node into enumerate using a BerReader

Example

    let mut s = 0 as Enumerate;
    from_der(&mut s, &[10, 1, 4]).unwrap();
    assert_eq!(cast!(ASN1Type::Enumerate, s).unwrap(), 4);