org.apache.jackrabbit.spi.commons.nodetype.compact
Class QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder

java.lang.Object
  extended by org.apache.jackrabbit.spi.commons.nodetype.compact.QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder
Direct Known Subclasses:
QNodeTypeDefinitionsBuilderImpl.QNodeTypeDefinitionBuilderImpl
Enclosing class:
QNodeTypeDefinitionsBuilder

public abstract class QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder
extends Object

A builder for a QNodeTypeDefinition


Constructor Summary
QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder()
           
 
Method Summary
abstract  QNodeTypeDefinition build()
          Creates a new QNodeTypeDefinition instance based on the state of this builder.
 QNodeDefinition[] getChildNodeDefs()
           
 boolean getMixin()
           
 Name getName()
           
 boolean getOrderableChildNodes()
           
 Name getPrimaryItemName()
           
 QPropertyDefinition[] getPropertyDefs()
           
 Name[] getSuperTypes()
          Returns an array containing the names of the supertypes of the node type definition being built.
abstract  QNodeTypeDefinitionsBuilder.QNodeDefinitionBuilder newQNodeDefinitionBuilder()
           
abstract  QNodeTypeDefinitionsBuilder.QPropertyDefinitionBuilder newQPropertyDefinition()
           
 void setChildNodeDefs(QNodeDefinition[] childDefs)
           
 void setMixin(boolean isMixin)
           
 void setName(Name name)
          Set the name of the node type definition being built
 void setOrderableChildNodes(boolean isOrderable)
           
 void setPrimaryItemName(Name primaryItemName)
           
 void setPropertyDefs(QPropertyDefinition[] propDefs)
           
 void setSupertypes(Name[] supertypes)
          Specifies the supertypes of the node type definition being built
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder

public QNodeTypeDefinitionsBuilder.QNodeTypeDefinitionBuilder()
Method Detail

setName

public void setName(Name name)
Set the name of the node type definition being built

Parameters:
name -

getName

public Name getName()
Returns:
the name of the node type definition being built or null if not set.

setSupertypes

public void setSupertypes(Name[] supertypes)
Specifies the supertypes of the node type definition being built

Parameters:
supertypes -

getSuperTypes

public Name[] getSuperTypes()
Returns an array containing the names of the supertypes of the node type definition being built.

Returns:
an array of supertype names

setMixin

public void setMixin(boolean isMixin)
Parameters:
isMixin - true if building a mixin node type definition; false otherwise.

getMixin

public boolean getMixin()
Returns:
true if building a mixin node type definition; false otherwise.

setOrderableChildNodes

public void setOrderableChildNodes(boolean isOrderable)
Parameters:
isOrderable - true if building a node type having orderable child nodes; false otherwise.

getOrderableChildNodes

public boolean getOrderableChildNodes()
Returns:
true if building a node type having orderable child nodes; false otherwise.

setPrimaryItemName

public void setPrimaryItemName(Name primaryItemName)
Parameters:
primaryItemName - the name of the primary item or null if not set.

getPrimaryItemName

public Name getPrimaryItemName()
Returns:
the name of the primary item or null if not set.

setPropertyDefs

public void setPropertyDefs(QPropertyDefinition[] propDefs)
Parameters:
propDefs - an array containing the property definitions of the node type definition being built.

getPropertyDefs

public QPropertyDefinition[] getPropertyDefs()
Returns:
an array containing the property definitions of the node type definition being built or null if not set.

setChildNodeDefs

public void setChildNodeDefs(QNodeDefinition[] childDefs)
Parameters:
childDefs - an array containing the child node definitions of the node type definition being.

getChildNodeDefs

public QNodeDefinition[] getChildNodeDefs()
Returns:
an array containing the child node definitions of the node type definition being built or null if not set.

newQPropertyDefinition

public abstract QNodeTypeDefinitionsBuilder.QPropertyDefinitionBuilder newQPropertyDefinition()
Returns:
a new instance of a builder for a QNodeDefinition.

newQNodeDefinitionBuilder

public abstract QNodeTypeDefinitionsBuilder.QNodeDefinitionBuilder newQNodeDefinitionBuilder()
Returns:
a new instance of a builder for a QNodeDefinition.

build

public abstract QNodeTypeDefinition build()
                                   throws IllegalStateException
Creates a new QNodeTypeDefinition instance based on the state of this builder.

Returns:
a new QNodeTypeDefinition instance.
Throws:
IllegalStateException - if the instance has not the necessary information to build the QNodeTypeDefinition instance.


Copyright © 2004-2008 The Apache Software Foundation. All Rights Reserved.