pub struct SequenceOrSetOf {
pub constraints: Vec<Constraint>,
pub element_type: Box<ASN1Type>,
pub is_recursive: bool,
}
Expand description
Representation of an ASN1 SEQUENCE OF and SET OF data element
with corresponding constraints and element type info
Whether the struct describes a SEQUENCE OF or a SET OF
is identified by the ASN1Type
enum variant that
holds this struct as a value (i.e. ASN1Type::SetOf(SequenceOrSetOf { .. })
or ASN1Type::SequenceOf(SequenceOrSetOf { .. })
).
As defined in Rec. ITU-T X.680 (02/2021) §26 and §28
Fields§
§constraints: Vec<Constraint>
§element_type: Box<ASN1Type>
ASN.1 type of the individual elements of the collection
§Example
The ASN.1 type
ⓘ
Sequence-of-booleans ::= SEQUENCE OF BOOLEAN
will have an element_type
field of
Box::new(ASN1Type::Boolean(Boolean { constraints: vec![] } ))
is_recursive: bool
Trait Implementations§
source§impl Clone for SequenceOrSetOf
impl Clone for SequenceOrSetOf
source§fn clone(&self) -> SequenceOrSetOf
fn clone(&self) -> SequenceOrSetOf
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Constrainable for SequenceOrSetOf
impl Constrainable for SequenceOrSetOf
source§fn constraints(&self) -> &Vec<Constraint>
fn constraints(&self) -> &Vec<Constraint>
returns a reference to the type’s constraints
source§fn constraints_mut(&mut self) -> &mut Vec<Constraint>
fn constraints_mut(&mut self) -> &mut Vec<Constraint>
returns a mutable reference to the type’s constraints
source§impl Debug for SequenceOrSetOf
impl Debug for SequenceOrSetOf
source§impl From<(Option<Vec<Constraint>>, ASN1Type)> for SequenceOrSetOf
impl From<(Option<Vec<Constraint>>, ASN1Type)> for SequenceOrSetOf
source§impl PartialEq for SequenceOrSetOf
impl PartialEq for SequenceOrSetOf
impl StructuralPartialEq for SequenceOrSetOf
Auto Trait Implementations§
impl Freeze for SequenceOrSetOf
impl RefUnwindSafe for SequenceOrSetOf
impl Send for SequenceOrSetOf
impl Sync for SequenceOrSetOf
impl Unpin for SequenceOrSetOf
impl UnwindSafe for SequenceOrSetOf
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)