Friday 20 April 2018

ASN.1: SET: Define composite type

Type: SET 

Description: It is like SEQUENCE except the type of each identifier must be different from other identifier in the set and order of the elements doesn’t matter here.

Example Schema
Person ::= SET {
  name VisibleString,
  id INTEGER,
  salary REAL
}

Now you can model data in any order.

person Person ::= {
  name "Krishna",
  id 29,
  salary 56432.23
}

                  (or)

person Person ::= {
  salary 56432.23
  name "Krishna",
  id 29
}

                  (or)

person Person ::= {
  salary 56432.23
  id 29,
  name "Krishna"
}



Previous                                                 Next                                                 Home

No comments:

Post a Comment