XCMS Toolkit

schemajic.schema
Class BitStringType

java.lang.Object
  extended by schemajic.schema.Type
      extended by schemajic.schema.BitStringType

public class BitStringType
extends Type

Schema for ASN.1 BIT STRING type.

Universal class tag assignment is UNIVERSAL 3.

XML ASN.1 type name is BIT_STRING.

For more information on this ASN.1 type see Java class ASN1BitString

Version:
1.00 - 2006/02/09
Author:
support@phillipgriffin.com

Field Summary
 
Fields inherited from class schemajic.schema.Type
_tags
 
Constructor Summary
BitStringType(Module module, java.lang.String name, java.lang.String type, java.lang.String tags, java.lang.String bits)
          Constructor for BitStringType with ASN.1 module, defined type, builtin or reference type, tags and named bits parameters.
BitStringType(java.lang.String name)
          Constructor for BitStringType with String parameter.
 
Method Summary
 void accept(TypeVisitor v)
          Calls the visit method of the TypeVisitor, passing itself as an argument.
 NamedBit getNamedBit(int value)
          Gets a named bit defined for a value of ASN.1 type BIT STRING.
 NamedBit getNamedBit(java.lang.String name)
          Gets a named bit from a list of named bits.
 java.util.Iterator getNamedBits()
          Iterator for a list of named bits.
 boolean hasNamedBit(int value)
          Determines whether a value of a defined type specified in terms of ASN.1 type BIT STRING has a given named bit.
 boolean hasNamedBits()
          Determines whether a value of a defined type specified in terms of ASN.1 type BIT STRING has any named bits.
 java.lang.String toString()
          Formats a string for an ASN.1 type definition statement.
 
Methods inherited from class schemajic.schema.Type
createInstance, getJavaName, getModule, getName, getPackageName, getTags, getType, getTypeName, getXMLName, isChoice, isNull, isOpenType, isRoot
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BitStringType

public BitStringType(Module module,
                     java.lang.String name,
                     java.lang.String type,
                     java.lang.String tags,
                     java.lang.String bits)
Constructor for BitStringType with ASN.1 module, defined type, builtin or reference type, tags and named bits parameters.

Parameters:
module - the ASN.1 module where a user defined type name is specified
name - the name of a user defined type
type - a builtin or referenced type defined in the ASN.1 standards
tags - the tag class, tag number, and encoding type assigned in the ASN.1 standards to the type
bits - user defined named bits (such as "ver(1)")

BitStringType

public BitStringType(java.lang.String name)
Constructor for BitStringType with String parameter.

Parameters:
name - a string of bits
Method Detail

accept

public void accept(TypeVisitor v)
Calls the visit method of the TypeVisitor, passing itself as an argument.

Specified by:
accept in class Type
Parameters:
v - instance of the type visitor

getNamedBits

public java.util.Iterator getNamedBits()
Iterator for a list of named bits.

Returns:
the current named bits

getNamedBit

public NamedBit getNamedBit(java.lang.String name)
Gets a named bit from a list of named bits.

Parameters:
name - a bit name
Returns:
null or the named bit.

getNamedBit

public NamedBit getNamedBit(int value)
Gets a named bit defined for a value of ASN.1 type BIT STRING.

Parameters:
value - the value of the named bit

hasNamedBit

public boolean hasNamedBit(int value)
Determines whether a value of a defined type specified in terms of ASN.1 type BIT STRING has a given named bit.

Parameters:
value - an integer series of bits
Returns:
boolean true or false

hasNamedBits

public boolean hasNamedBits()
Determines whether a value of a defined type specified in terms of ASN.1 type BIT STRING has any named bits.

Returns:
boolean true or false

toString

public java.lang.String toString()
Description copied from class: Type
Formats a string for an ASN.1 type definition statement.

Overrides:
toString in class Type
Returns:
the formatted ASN.1 type definition statement

XCMS Toolkit


Copyright © 2005-2006 GRIFFIN Consulting. All Rights Reserved.