PySNMP: ASN.1: Base: Asn1Object methods

### Objects of the base.Asn1Object class

Instances of base.Asn1Object use a set of instance variables for controlling ASN.1 object properties, each of which falls into one of the following categories:

ASN.1 object tagging

tagClass

  This instance variable should be initialized to ASN.1 object class identifier (integer). Possible values held in tagClasses dictionary.

  The default value for tagClass is tagClasses['UNIVERSAL'].

tagFormat

  This instance variable should be initialized to ASN.1 object format identifier (integer). Possible values held in tagFormats dictionary.

tagId

  This instance variable should be initialized to ASN.1 object tag (integer).

tagCategory

  This instance variable should be initialized to ASN.1 object tagging method identifier (integer). Possible values held in tagCategories dictionary.

  The default value for tagCategory is tagCategories['IMPLICIT'].

ASN.1 object initializer verification

allowedTypes

  This instance variable should be initialized to a list of Python types allowed for loading into ASN.1 object.

ASN.1 subtyping

The ASN.1 standard specifies a method of deriving a subtype by restricting the set of values defined for a parent type. Six different forms of notations for restricting the value set of a subtype are provided in the standard. The following instance variables can be used for specifying these subtyping constraints:

singleValueConstraint

  This instance variable can be initialized to a list of ASN.1 object-specific set of values that the subtype may take on.

  For example, for a numeric object: singleValueConstraint = [1, 3, 5]

containedSubtypeConstraint

  This instance variable can be initialized to a list of ASN.1 object-specific set of values of the subtypes that this object contains.

valueRangeConstraint

  This instance variable can be initialized to a tuple of numerical values of the endponts of the range that this ASN.1 object may take.

  For example, for a numeric object: valueRangeConstraint = (0, 65535)

sizeConstraint

  This instance variable can be initialized to a tuple of numerical values of the number of items in a type that ASN.1 object may take.

  For example, for a structured object that takes from one to 16 components: sizeConstraint = (1, 16)

permittedAlphabetConstraint

  This instance variable can be initialized to a list of all values that can be constructed using the sub-alphabet of the parent ASN.1 object type.

  For example, for a string object that implements telephone tone buttons, permittedAlphabetConstraint = [ '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'].

innerSubtypeConstraint

  This is not yet implemented.