Class TemplateBuilderFactory.NodeTypeTemplateBuilder
- java.lang.Object
-
- org.apache.jackrabbit.commons.cnd.DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>
-
- org.apache.jackrabbit.commons.cnd.TemplateBuilderFactory.NodeTypeTemplateBuilder
-
- Enclosing class:
- TemplateBuilderFactory
public class TemplateBuilderFactory.NodeTypeTemplateBuilder extends DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>
-
-
Constructor Summary
Constructors Constructor Description NodeTypeTemplateBuilder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddSupertype(java.lang.String name)Add the given name to the set of supertypes of the node type definition being builtjavax.jcr.nodetype.NodeTypeTemplatebuild()Build this node type definitionDefinitionBuilderFactory.AbstractNodeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>newNodeDefinitionBuilder()Create a new instance fo aDefinitionBuilderFactory.AbstractNodeDefinitionBuilderwhich can be used to add child node definitions to the node type definition being built.DefinitionBuilderFactory.AbstractPropertyDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>newPropertyDefinitionBuilder()Create a new instance of aDefinitionBuilderFactory.AbstractPropertyDefinitionBuilderwhich can be used to add property definitions to the node type definition being built.voidsetName(java.lang.String name)Set the name of the node type definition being builtvoidsetPrimaryItemName(java.lang.String name)-
Methods inherited from class org.apache.jackrabbit.commons.cnd.DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder
getName, setAbstract, setMixin, setOrderableChildNodes, setQueryable
-
-
-
-
Method Detail
-
newNodeDefinitionBuilder
public DefinitionBuilderFactory.AbstractNodeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate> newNodeDefinitionBuilder() throws javax.jcr.UnsupportedRepositoryOperationException, javax.jcr.RepositoryException
Description copied from class:DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilderCreate a new instance fo aDefinitionBuilderFactory.AbstractNodeDefinitionBuilderwhich can be used to add child node definitions to the node type definition being built.- Specified by:
newNodeDefinitionBuilderin classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Returns:
- Throws:
javax.jcr.RepositoryExceptionjavax.jcr.UnsupportedRepositoryOperationException
-
newPropertyDefinitionBuilder
public DefinitionBuilderFactory.AbstractPropertyDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate> newPropertyDefinitionBuilder() throws javax.jcr.UnsupportedRepositoryOperationException, javax.jcr.RepositoryException
Description copied from class:DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilderCreate a new instance of aDefinitionBuilderFactory.AbstractPropertyDefinitionBuilderwhich can be used to add property definitions to the node type definition being built.- Specified by:
newPropertyDefinitionBuilderin classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Returns:
- Throws:
javax.jcr.RepositoryExceptionjavax.jcr.UnsupportedRepositoryOperationException
-
build
public javax.jcr.nodetype.NodeTypeTemplate build() throws javax.jcr.nodetype.ConstraintViolationExceptionDescription copied from class:DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilderBuild this node type definition- Specified by:
buildin classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Returns:
- Throws:
javax.jcr.nodetype.ConstraintViolationException
-
setName
public void setName(java.lang.String name) throws javax.jcr.RepositoryExceptionDescription copied from class:DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilderSet the name of the node type definition being built- Overrides:
setNamein classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Throws:
javax.jcr.RepositoryException- if the name is not valid- See Also:
NodeTypeDefinition.getName()
-
addSupertype
public void addSupertype(java.lang.String name)
Description copied from class:DefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilderAdd the given name to the set of supertypes of the node type definition being built- Specified by:
addSupertypein classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Parameters:
name- name of the the supertype- See Also:
NodeTypeDefinition.getDeclaredSupertypeNames()
-
setPrimaryItemName
public void setPrimaryItemName(java.lang.String name) throws javax.jcr.nodetype.ConstraintViolationException- Specified by:
setPrimaryItemNamein classDefinitionBuilderFactory.AbstractNodeTypeDefinitionBuilder<javax.jcr.nodetype.NodeTypeTemplate>- Parameters:
name- the name of the primary item.- Throws:
javax.jcr.nodetype.ConstraintViolationException- See Also:
NodeTypeDefinition.getPrimaryItemName()
-
-