edu.sdsc.mbt
Class StructureComponentRegistry

java.lang.Object
  extended byedu.sdsc.mbt.StructureComponentRegistry
All Implemented Interfaces:
java.io.Serializable

public class StructureComponentRegistry
extends java.lang.Object
implements java.io.Serializable

A class used to register StructureComponent types and their relationships (much like a database schema defines tables and their relational links).

Each StructureComponent is like a table in a database. Each StructureComponent type is like a table ID in a database. Each StructureComponent relation is like a relational link between tables in a database.

A set of public static final String variables whos names begin with "TYPE_" are defined to enable users (eg: StructureLoader, Structure, etc) to perform very fast StructureComponent runtime type comparisions by simply comparing object references (ie: not the actual String values).

Since each StructureComponent type value is simply the fully qualified String name of the class, the type values may also be used

Author:
John L. Moreland
See Also:
Serialized Form

Field Summary
static java.lang.String RELATION_CONFORMATION_ATOMS
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached relation.
static java.lang.String TYPE_ACTIVE_SITE
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_ATOM
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_BOND
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_CHAIN
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_COIL
          Secondary structure conformation for a Coil.
static java.lang.String TYPE_DISULPHIDE
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_FRAGMENT
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_HELIX
          Secondary structure conformation for a Helix.
static java.lang.String TYPE_MODEL
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_NONPOLYMER
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_POLYMER
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_RESIDUE
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_SALT_BRIDGE
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_STRAND
          Secondary structure conformation for a Strand.
static java.lang.String TYPE_STRUCTURE
          This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.
static java.lang.String TYPE_TURN
          Secondary structure conformation for a Turn.
 
Constructor Summary
StructureComponentRegistry()
           
 
Method Summary
static void addRelation(StructureComponentRelation relation)
          Register a new StructureComponent relation.
static void addType(java.lang.String name)
          Register a new StructureComponent type.
static StructureComponentRelation getRelation(java.lang.String name)
          Get an existing StructureComponent relation.
static int getRelationCount()
          Return the number of registered StructureComponent relations.
static java.util.Enumeration getRelationNames()
          Return an Enumeration of String values for all registered StructureComponent relations.
static int getTypeCount()
          Return the number of registered StructureComponent types.
static java.lang.String getTypeName(java.lang.String name)
          Get an existing StructureComponent type name for the given String.
static java.util.Enumeration getTypeNames()
          Return an Enumeration of String values for all registered StructureComponent types.
static void removeRelation(java.lang.String name)
          Un-register an existing StructureComponent relation.
static void removeType(java.lang.String name)
          Un-register an existing StructureComponent type.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_STRUCTURE

public static final java.lang.String TYPE_STRUCTURE
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_CHAIN

public static final java.lang.String TYPE_CHAIN
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_COIL

public static final java.lang.String TYPE_COIL
Secondary structure conformation for a Coil. This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_HELIX

public static final java.lang.String TYPE_HELIX
Secondary structure conformation for a Helix. This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_STRAND

public static final java.lang.String TYPE_STRAND
Secondary structure conformation for a Strand. This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_TURN

public static final java.lang.String TYPE_TURN
Secondary structure conformation for a Turn. This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_RESIDUE

public static final java.lang.String TYPE_RESIDUE
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_FRAGMENT

public static final java.lang.String TYPE_FRAGMENT
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_ATOM

public static final java.lang.String TYPE_ATOM
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_BOND

public static final java.lang.String TYPE_BOND
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_MODEL

public static final java.lang.String TYPE_MODEL
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_ACTIVE_SITE

public static final java.lang.String TYPE_ACTIVE_SITE
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_POLYMER

public static final java.lang.String TYPE_POLYMER
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_NONPOLYMER

public static final java.lang.String TYPE_NONPOLYMER
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_DISULPHIDE

public static final java.lang.String TYPE_DISULPHIDE
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


TYPE_SALT_BRIDGE

public static final java.lang.String TYPE_SALT_BRIDGE
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached type.


RELATION_CONFORMATION_ATOMS

public static final java.lang.String RELATION_CONFORMATION_ATOMS
This is a static convenience field provided so that user code does not have to create a local variable name to store a cached relation.

Constructor Detail

StructureComponentRegistry

public StructureComponentRegistry()
Method Detail

getTypeCount

public static int getTypeCount()
Return the number of registered StructureComponent types.


addType

public static void addType(java.lang.String name)
Register a new StructureComponent type.


removeType

public static void removeType(java.lang.String name)
Un-register an existing StructureComponent type.


getTypeName

public static java.lang.String getTypeName(java.lang.String name)
Get an existing StructureComponent type name for the given String. Note that while the "name" parameter may contain the same characters, the returned String object is the actual registered String instance. This enables fast "==" comparisons throughout the toolkit. This method is also handy to check whether a type is registered, since a "null" value is returned if it is not registered.


getTypeNames

public static java.util.Enumeration getTypeNames()
Return an Enumeration of String values for all registered StructureComponent types.


getRelationCount

public static int getRelationCount()
Return the number of registered StructureComponent relations.


addRelation

public static void addRelation(StructureComponentRelation relation)
Register a new StructureComponent relation.


getRelation

public static StructureComponentRelation getRelation(java.lang.String name)
Get an existing StructureComponent relation.


removeRelation

public static void removeRelation(java.lang.String name)
Un-register an existing StructureComponent relation.


getRelationNames

public static java.util.Enumeration getRelationNames()
Return an Enumeration of String values for all registered StructureComponent relations.