org.apache.hivemind.schema
Interface ElementModel

All Superinterfaces:
AnnotationHolder, Locatable
All Known Implementing Classes:
ElementModelImpl

public interface ElementModel
extends AnnotationHolder, Locatable

Identifies an element that may occur within some schema. Because elements may be nested, an ElementModel is also a Schema.

Author:
Howard Lewis Ship

Method Summary
 AttributeModel getAttributeModel(java.lang.String name)
           
 java.util.List getAttributeModels()
          Returns a List of AttributeModels.
 java.lang.String getContentTranslator()
          Returns the translator used for character content within the body of the element; may return null.
 java.util.List getElementModel()
          Returns a List of ElementModel, identifing the elements which may be enclosed by the modeled element.
 java.lang.String getElementName()
          Returns the name of the element.
 java.lang.String getKeyAttribute()
          Returns the name of the attribute whose value can be used as a key for an instance of an Element with this ElementModel.
 java.util.List getRules()
          Returns a List of Rule.
 
Methods inherited from interface org.apache.hivemind.parse.AnnotationHolder
getAnnotation, setAnnotation
 
Methods inherited from interface org.apache.hivemind.Locatable
getLocation
 

Method Detail

getElementName

java.lang.String getElementName()
Returns the name of the element.


getElementModel

java.util.List getElementModel()
Returns a List of ElementModel, identifing the elements which may be enclosed by the modeled element.

The returned list is unmodifiabled and may be empty, but won't be null.


getAttributeModels

java.util.List getAttributeModels()
Returns a List of AttributeModels. The List is unmodifiable and won't be null, but may be empty.


getAttributeModel

AttributeModel getAttributeModel(java.lang.String name)

getKeyAttribute

java.lang.String getKeyAttribute()
Returns the name of the attribute whose value can be used as a key for an instance of an Element with this ElementModel. This key is usually used to index a configuration contribution inside a Map.

Since:
1.1

getRules

java.util.List getRules()
Returns a List of Rule. The List is unmodifiable and won't but null, but could be empty.


getContentTranslator

java.lang.String getContentTranslator()
Returns the translator used for character content within the body of the element; may return null.