Class TypeConstraint

java.lang.Object
com.oss.metadata.Constraints
com.oss.metadata.TypeConstraint

public class TypeConstraint extends Constraints
The TypeConstraint class represents the ASN.1 type constraint. This is used to constrain open types. For example A is constrained to be of type B:
    B ::= SEQUENCE {
        a INTEGER,
        b VisibleString
   }
   A ::= ABSTRACT-SYNTAX.&Type (B)
    
Since:
ASN.1/Java 2.1
  • Method Details

    • getTypeInfo

      public TypeInfo getTypeInfo() throws ClassNotFoundException, MetadataException
      Return the metadata for the type that is constraining this type.
      Returns:
      type info object
      Throws:
      ClassNotFoundException - if type typeinfo reference points to a class that could not be found
      MetadataException - if the class pointed to by the element typeinfo reference does not contain c_typeinfo field or access to the field was denied
    • getTypeInfo

      public TypeInfo getTypeInfo(Object context) throws ClassNotFoundException, MetadataException
      Return the metadata for the type that is constraining this type.
      Parameters:
      context - project environment
      Returns:
      type info object
      Throws:
      ClassNotFoundException - if type typeinfo reference points to a class that could not be found
      MetadataException - if the class pointed to by the element typeinfo reference does not contain c_typeinfo field or access to the field was denied