rasn/types/
open.rs

1use super::*;
2use crate::{Decode, Encode};
3
4/// An "open" type representing any valid ASN.1 type.
5#[derive(AsnType, Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Decode, Encode)]
6#[rasn(crate_root = "crate")]
7#[rasn(choice)]
8pub enum Open {
9    /// A bit string value.
10    BitString(BitString),
11    // BmpString(BmpString),
12    /// A bool value.
13    Bool(bool),
14    /// A generalized time value.
15    GeneralizedTime(GeneralizedTime),
16    // Ia5String(Ia5String),
17    /// A integer value.
18    Integer(Integer),
19    /// A null value.
20    Null,
21    /// A object identifier value.
22    ObjectIdentifier(ObjectIdentifier),
23    /// A octet string value.
24    OctetString(OctetString),
25    // PrintableString(PrintableString),
26    /// A universal string value.
27    UniversalString(UniversalString),
28    /// A utc time value.
29    UtcTime(UtcTime),
30    /// A visible string value.
31    VisibleString(VisibleString),
32    /// An "instance of" value.
33    InstanceOf(alloc::boxed::Box<InstanceOf<Open>>),
34}