Class DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<T>
- java.lang.Object
-
- org.apache.jackrabbit.commons.cnd.DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<T>
-
- Type Parameters:
T
-
- Direct Known Subclasses:
TemplateBuilderFactory.NodeTypeTemplateBuilder
- Enclosing class:
- DefinitionBuilderFactory<T,N>
public abstract static class DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<T> extends Object
Builder for a node type definition of type T.
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
isAbstract
protected boolean
isMixin
protected boolean
isOrderable
protected String
name
SeesetName(String)
protected boolean
queryable
-
Constructor Summary
Constructors Constructor Description AbstractNodeTypeDefinitionBuilder()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
addSupertype(String name)
Add the given name to the set of supertypes of the node type definition being builtabstract T
build()
Build this node type definitionString
getName()
Returns the name of the node type definition being builtabstract DefinitionBuilderFactory.AbstractNodeDefinitionBuilder<T>
newNodeDefinitionBuilder()
Create a new instance fo aDefinitionBuilderFactory.AbstractNodeDefinitionBuilder
which can be used to add child node definitions to the node type definition being built.abstract DefinitionBuilderFactory.AbstractPropertyDefinitionBuilder<T>
newPropertyDefinitionBuilder()
Create a new instance of aDefinitionBuilderFactory.AbstractPropertyDefinitionBuilder
which can be used to add property definitions to the node type definition being built.void
setAbstract(boolean isAbstract)
void
setMixin(boolean isMixin)
void
setName(String name)
Set the name of the node type definition being builtvoid
setOrderableChildNodes(boolean isOrderable)
abstract void
setPrimaryItemName(String name)
void
setQueryable(boolean queryable)
-
-
-
Field Detail
-
name
protected String name
SeesetName(String)
-
isMixin
protected boolean isMixin
-
isOrderable
protected boolean isOrderable
-
isAbstract
protected boolean isAbstract
-
queryable
protected boolean queryable
-
-
Method Detail
-
setName
public void setName(String name) throws RepositoryException
Set the name of the node type definition being built- Parameters:
name
-- Throws:
RepositoryException
- if the name is not valid- See Also:
NodeTypeDefinition.getName()
-
getName
public String getName()
Returns the name of the node type definition being built- Returns:
-
addSupertype
public abstract void addSupertype(String name) throws RepositoryException
Add the given name to the set of supertypes of the node type definition being built- Parameters:
name
- name of the the supertype- Throws:
RepositoryException
- if the name is not valid- See Also:
NodeTypeDefinition.getDeclaredSupertypeNames()
-
setMixin
public void setMixin(boolean isMixin) throws RepositoryException
- Parameters:
isMixin
-true
if building a mixin node type definition;false
otherwise.- Throws:
RepositoryException
- See Also:
NodeTypeDefinition.isMixin()
-
setOrderableChildNodes
public void setOrderableChildNodes(boolean isOrderable) throws RepositoryException
- Parameters:
isOrderable
-true
if building a node type having orderable child nodes;false
otherwise.- Throws:
RepositoryException
- See Also:
NodeTypeDefinition.hasOrderableChildNodes()
-
setPrimaryItemName
public abstract void setPrimaryItemName(String name) throws RepositoryException
- Parameters:
name
- the name of the primary item.- Throws:
RepositoryException
- See Also:
NodeTypeDefinition.getPrimaryItemName()
-
setAbstract
public void setAbstract(boolean isAbstract) throws RepositoryException
- Parameters:
isAbstract
-true
if building a node type that is abstract.- Throws:
RepositoryException
- See Also:
NodeTypeDefinition.isAbstract()
-
setQueryable
public void setQueryable(boolean queryable) throws RepositoryException
- Parameters:
queryable
-true
if building a node type that is queryable- Throws:
RepositoryException
- See Also:
NodeTypeDefinition.isQueryable()
-
newPropertyDefinitionBuilder
public abstract DefinitionBuilderFactory.AbstractPropertyDefinitionBuilder<T> newPropertyDefinitionBuilder() throws RepositoryException
Create a new instance of aDefinitionBuilderFactory.AbstractPropertyDefinitionBuilder
which can be used to add property definitions to the node type definition being built.- Returns:
- Throws:
RepositoryException
-
newNodeDefinitionBuilder
public abstract DefinitionBuilderFactory.AbstractNodeDefinitionBuilder<T> newNodeDefinitionBuilder() throws RepositoryException
Create a new instance fo aDefinitionBuilderFactory.AbstractNodeDefinitionBuilder
which can be used to add child node definitions to the node type definition being built.- Returns:
- Throws:
RepositoryException
-
build
public abstract T build() throws RepositoryException
Build this node type definition- Returns:
- Throws:
RepositoryException
-
-