gov.sns.xal.smf.impl.qualify
Class ElementTypeManager

java.lang.Object
  |
  +--gov.sns.xal.smf.impl.qualify.ElementTypeManager

public class ElementTypeManager
extends java.lang.Object

ElementTypeManager keeps track of which types are associated with which subclass of AcceleratorNode. It is used for filtering nodes by type.


Constructor Summary
ElementTypeManager()
          Creates new ElementTypeManager
 
Method Summary
static ElementTypeManager defaultManager()
          default element type manager
 boolean match(AcceleratorNode node, java.lang.String type)
          Check if the node is of the specified type.
 boolean match(java.lang.Class cls, java.lang.String type)
          Check if the class or one of its superclasses is associated with the type.
 void registerType(java.lang.Class cls, java.lang.String type)
          Register the type to specified class to be of the specified type
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ElementTypeManager

public ElementTypeManager()
Creates new ElementTypeManager

Method Detail

defaultManager

public static ElementTypeManager defaultManager()
default element type manager


registerType

public void registerType(java.lang.Class cls,
                         java.lang.String type)
Register the type to specified class to be of the specified type


match

public boolean match(AcceleratorNode node,
                     java.lang.String type)
Check if the node is of the specified type. A node may belong to more than one type due to inheritance.


match

public boolean match(java.lang.Class cls,
                     java.lang.String type)
Check if the class or one of its superclasses is associated with the type.