iaik.asn1.structures
Class AttributeValue

java.lang.Object
  |
  +--iaik.asn1.structures.AttributeValue
All Implemented Interfaces:
ASN1Type
Direct Known Subclasses:
ChallengePassword, ExtensionRequest, UnknownAttributeValue

public abstract class AttributeValue
extends Object
implements ASN1Type

This class is the basic implementation for Attribute Values. Any class which implements some specific Attribute Value must be derived from this class.

An Attribute consists of an attribute type (specified by an object identifier) and one or more attribute values:

 Attribute ::= SEQUENCE {
  type    AttributeType,
  values  SET OF AttributeValue
    -- at least one value is required --
 }

 AttributeType           ::=   OBJECT IDENTIFIER
 AttributeValue          ::=   ANY DEFINED BY type
 

Any class implementing a particular attribute value has to extend this class and therefore has to implement the abstract methods decode, toASN1Object and getAttributeType. The attribute type to be returned by method getAttributeType is the one identifying the particular Attribute and shall be used for registering the corresponding class as implemenation for this Attribute value, e.g.:

 public class MyAttributeValue extends AttributeValue {
 ...
 // the attribute type:
   public static final ObjectID attributeType = ...;
 ...
 }
 ...
 // register the implementation:
 Attribute.register(MyAttributeValue.attributeType, MyAttributeValue.class);
 
When implementing a statement info by extending this class please be aware that methods toASN1Object and decode only have to convert the attribute value itself (and NOT the attribute type OID) into respectively from an ASN1Object.

Version:
File Revision 9
See Also:
Attribute

Constructor Summary
AttributeValue()
           
 
Method Summary
abstract  ObjectID getAttributeType()
          Returns the attribute type OID identifying the type to which this Attribute Value belongs.
 String getName()
          Returns the Attribute type name.
abstract  String toString()
          Returns a String representation of the AttributeValue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface iaik.asn1.ASN1Type
decode, toASN1Object
 

Constructor Detail

AttributeValue

public AttributeValue()
Method Detail

getAttributeType

public abstract ObjectID getAttributeType()
Returns the attribute type OID identifying the type to which this Attribute Value belongs.
Returns:
the attribute type OID identifying the type of Attribute value this class implements

toString

public abstract String toString()
Returns a String representation of the AttributeValue.
Overrides:
toString in class Object
Returns:
a String representation of the AttributeValue.

getName

public String getName()
Returns the Attribute type name.
Returns:
the name of the attribute

This Javadoc may contain text parts from Internet Standard specifications (RFC 2459, 3280, 3039, 2560, 1521, 821, 822, 2253, 1319, 1321, ,2630, 2631, 2268, 3058, 2984, 2104, 2144, 2040, 2311, 2279, see copyright note) and RSA Data Security Public-Key Cryptography Standards (PKCS#1,3,5,7,8,9,10,12, see copyright note).

IAIK-JCE 3.1 with IAIK-JCE CC Core 3.1, (c) 1997-2004 IAIK