AROM-2_2_13

arom.kr.model
Interface NameSpace

All Superinterfaces:
AMEntity, helix.util.beans.CompoundPropertySet, DocumentableObject, NamedEntity, helix.util.beans.PropertySet
All Known Subinterfaces:
AMAssociation, AMClass, KnowledgeBase, SpecializableEntity, Structure

public interface NameSpace
extends NamedEntity

A NameSpace is a NamedEntity that can contain other named entity objects. A name space defines the set of allowable names and the naming conventions.


Field Summary
 
Fields inherited from interface arom.kr.model.NamedEntity
NAME
 
Method Summary
 void isValidName(String name)
          Throws an exception if the supplied name is not valid in this name space.
 NamedEntity lookupEntity(String name)
          Searches for an entity contained in this name space whose name is equal to the supplied string.
 NamedEntity resolveQualifiedName(String name)
          Searches for an entity contained within this name space that is identified by the supplied qualified name.
 
Methods inherited from interface arom.kr.model.NamedEntity
getFQName, getName, getNameSpace, setName
 
Methods inherited from interface arom.kr.model.AMEntity
addEntityListener, delete, getContainer, getIdentifier, removeEntityListener, verify
 
Methods inherited from interface arom.kr.model.DocumentableObject
applyDocumentationModifier, cancelDocumentationModifier, documentationModifiers, getDocumentation, lookupDocumentationModifier
 
Methods inherited from interface helix.util.beans.PropertySet
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener
 
Methods inherited from interface helix.util.beans.CompoundPropertySet
addCompositionChangeListener, addCompositionChangeListener, addVetoableCompositionChangeListener, addVetoableCompositionChangeListener, removeCompositionChangeListener, removeCompositionChangeListener, removeVetoableCompositionChangeListener, removeVetoableCompositionChangeListener
 

Method Detail

lookupEntity

public NamedEntity lookupEntity(String name)
Searches for an entity contained in this name space whose name is equal to the supplied string. Returns null if no entity was found.

Parameters:
name - the name of the entity to search for.
Returns:
an entity whose name is equal to the supplied name or null if none was found.
Throws:
NullPointerException - if the name is null.

resolveQualifiedName

public NamedEntity resolveQualifiedName(String name)
Searches for an entity contained within this name space that is identified by the supplied qualified name. The qualified name is interpreted as a path starting from this name space. Returns null if the qualified name does not reference any entity in this name space.

Parameters:
name - the name of the entity to search for.
Returns:
an entity whose name is equal to the supplied name or null if none was found.

isValidName

public void isValidName(String name)
                 throws InvalidNameException
Throws an exception if the supplied name is not valid in this name space. The name can be rejected by the name space if :
  1. the string violate the naming conventions of the name space.
  2. the string already identify an entity contained by this name space.

Parameters:
name - the name to check.
Throws:
InvalidNameException - if the supplied name is rejected by this name space.

AROM-2_2_13