jp.bitmeister.asn1.type.builtin
Class SEQUENCE_OF<T extends ASN1Type>

java.lang.Object
  extended by jp.bitmeister.asn1.type.ASN1Type
      extended by jp.bitmeister.asn1.type.CollectionType<T>
          extended by jp.bitmeister.asn1.type.builtin.SEQUENCE_OF<T>
All Implemented Interfaces:
java.lang.Cloneable, SizeCountable
Direct Known Subclasses:
BuiltInModule.UnknownSequence

public class SEQUENCE_OF<T extends ASN1Type>
extends CollectionType<T>

Represents ASN.1 'SEQUENCE OF' type.

This is the class used for defining 'SEQUENCE OF' types. Generic type parameter T indicates component type of the 'SEQUENCE OF' type. Constructors of a sub-class of SEQUENCE_OF must call parent constructor with componentType parameter that is the class object of T in them.

Author:
WATANABE, Jun.

Field Summary
 
Fields inherited from class jp.bitmeister.asn1.type.ASN1Type
stringBuilder
 
Constructor Summary
SEQUENCE_OF(java.lang.Class<T> componentType)
          Instantiate an empty SEQUENCE_OF.
 
Method Summary
<E extends java.lang.Throwable>
void
accept(ASN1Visitor<E> visitor)
          Accepts the ASN1Visitor and calls a visit method of the visitor.
protected  java.util.Collection<T> newCollection()
          Instantiates a new collection of the component type.
 
Methods inherited from class jp.bitmeister.asn1.type.CollectionType
clear, clone, collection, componentSpecification, componentType, hashCode, hasValue, size, valueEquals
 
Methods inherited from class jp.bitmeister.asn1.type.ASN1Type
equals, instantiate, matches, specification, toString, validate
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SEQUENCE_OF

public SEQUENCE_OF(java.lang.Class<T> componentType)
Instantiate an empty SEQUENCE_OF.

Parameters:
componentType - The class instance of component type.
Method Detail

newCollection

protected java.util.Collection<T> newCollection()
Description copied from class: CollectionType
Instantiates a new collection of the component type.

Specified by:
newCollection in class CollectionType<T extends ASN1Type>
Returns:
A new collection.

accept

public <E extends java.lang.Throwable> void accept(ASN1Visitor<E> visitor)
            throws E extends java.lang.Throwable
Description copied from class: ASN1Type
Accepts the ASN1Visitor and calls a visit method of the visitor.

Specified by:
accept in class ASN1Type
Parameters:
visitor - The visitor.
Throws:
E extends java.lang.Throwable