public class DefinitionPath extends Object
Constructor and Description |
---|
DefinitionPath(DefinitionPath basePath)
Create a definition path beginning with the given base path
|
DefinitionPath(List<PathElement> elements)
Create a path with at least one element.
|
DefinitionPath(TypeDefinition firstType,
QName elementName,
boolean unique)
Create an empty definition path
|
Modifier and Type | Method and Description |
---|---|
DefinitionPath |
add(ChildDefinition<?> child)
Add a child to the path
|
DefinitionPath |
addDowncast(TypeDefinition subtype)
Add a downcast
|
DefinitionPath |
addGroup(GroupPropertyDefinition groupDef)
Add a group to the path
|
DefinitionPath |
addProperty(PropertyDefinition property)
Add a property
|
GeometryWriter<?> |
getGeometryWriter() |
PathElement |
getLastElement()
Get the last path element
|
QName |
getLastName()
Get the last name of the path.
|
TypeDefinition |
getLastType()
Get the last type of the path.
|
List<PathElement> |
getSteps() |
boolean |
isEmpty()
Determines if the path is empty
|
boolean |
isLastUnique()
Get if the last element in the path is unique, which means that it cannot
be repeated XXX not if last is a group
|
void |
setGeometryWriter(GeometryWriter<?> geometryWriter) |
String |
toString() |
public DefinitionPath(DefinitionPath basePath)
basePath
- the base pathpublic DefinitionPath(TypeDefinition firstType, QName elementName, boolean unique)
firstType
- the type starting the pathelementName
- the corresponding element nameunique
- if the element starting the path cannot be repeatedpublic DefinitionPath(List<PathElement> elements)
elements
- the path elementspublic DefinitionPath addDowncast(TypeDefinition subtype)
subtype
- the definition of the sub-type that is to be cast topublic DefinitionPath addGroup(GroupPropertyDefinition groupDef)
groupDef
- the group definitionpublic DefinitionPath add(ChildDefinition<?> child)
child
- the child, either a group or propertypublic DefinitionPath addProperty(PropertyDefinition property)
property
- the property definitionpublic GeometryWriter<?> getGeometryWriter()
public void setGeometryWriter(GeometryWriter<?> geometryWriter)
geometryWriter
- the geometryWriter to setpublic List<PathElement> getSteps()
public boolean isEmpty()
public TypeDefinition getLastType()
public QName getLastName()
public boolean isLastUnique()
public String toString()
toString
in class Object
Object.toString()
public PathElement getLastElement()
null
if it's emptyBuild 2013-10-07_11-27-38
Revision 99b27713a799a59a21b0b166eaaea8aaefbf125a