pasn
Class ASN1SimpleObject<T>

java.lang.Object
  extended by pasn.ASN1Object
      extended by pasn.ASN1SimpleObject<T>
Type Parameters:
T -
All Implemented Interfaces:
ASN1DefaultValuedObject, ASN1EncodingSpecificObject, ASN1GenericObject, ASN1PrimitiveObject<T>, ASN1Resetable
Direct Known Subclasses:
ASN1Boolean, ASN1Enumerated, ASN1Identifier, ASN1Integer, ASN1Null, ASN1String, ASN1Time

public abstract class ASN1SimpleObject<T>
extends ASN1Object
implements ASN1PrimitiveObject<T>

Concerns ASN.1 object encoded in PRIMITIVE form only

Author:
ncottin

Constructor Summary
ASN1SimpleObject(int type)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 T getDefaultValue()
           
 T getValue()
           
 T getValueOrDefault()
           
 boolean hasValueOrDefault()
           
 void setDefaultValue(T value)
           
 void setValue(T value)
           Initialializes this ASN.1 object with an appropriate value
 
Methods inherited from class pasn.ASN1Object
getAsnClass, getSpecificEncoding, getSpecificEncoding, getType, hasSpecificEncodings, setSpecificEncoding
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface pasn.ASN1PrimitiveObject
setDecodedValue, validateConstraints
 
Methods inherited from interface pasn.ASN1GenericObject
getASN1Name, getAsnClass, getType, hasValue
 
Methods inherited from interface pasn.ASN1DefaultValuedObject
hasDefaultValue, isValueDefault
 
Methods inherited from interface pasn.ASN1EncodingSpecificObject
getSpecificEncoding, hasSpecificEncodings
 
Methods inherited from interface pasn.ASN1Resetable
reset
 

Constructor Detail

ASN1SimpleObject

public ASN1SimpleObject(int type)
Parameters:
type -
Method Detail

setValue

public final void setValue(T value)
                    throws ASN1ConstraintException
Description copied from interface: ASN1PrimitiveObject

Initialializes this ASN.1 object with an appropriate value

Specified by:
setValue in interface ASN1PrimitiveObject<T>
Parameters:
value - A possibly null value
Throws:
ASN1ConstraintException

getValue

public final T getValue()
Specified by:
getValue in interface ASN1PrimitiveObject<T>

setDefaultValue

public final void setDefaultValue(T value)
                           throws ASN1ConstraintException
Throws:
ASN1ConstraintException

getDefaultValue

public final T getDefaultValue()
Specified by:
getDefaultValue in interface ASN1PrimitiveObject<T>

getValueOrDefault

public final T getValueOrDefault()
Specified by:
getValueOrDefault in interface ASN1PrimitiveObject<T>

hasValueOrDefault

public final boolean hasValueOrDefault()
Specified by:
hasValueOrDefault in interface ASN1DefaultValuedObject

equals

public final boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object