org.apache.jackrabbit.spi.commons
Class QNodeTypeDefinitionImpl

java.lang.Object
  extended by org.apache.jackrabbit.spi.commons.QNodeTypeDefinitionImpl
All Implemented Interfaces:
Serializable, QNodeTypeDefinition

public class QNodeTypeDefinitionImpl
extends Object
implements QNodeTypeDefinition, Serializable

QNodeTypeDefinitionImpl implements a serializable SPI node type definition.

See Also:
Serialized Form

Constructor Summary
QNodeTypeDefinitionImpl()
          Default constructor.
QNodeTypeDefinitionImpl(Name name, Name[] supertypes, Name[] supportedMixins, boolean isMixin, boolean isAbstract, boolean isQueryable, boolean hasOrderableChildNodes, Name primaryItemName, QPropertyDefinition[] declaredPropDefs, QNodeDefinition[] declaredNodeDefs)
          Creates a new serializable SPI node type definition.
QNodeTypeDefinitionImpl(NodeTypeDefinition def, NamePathResolver resolver, QValueFactory qValueFactory)
          Createa a new QNodeTypeDefinitionImpl from a JCR NodeType definition.
QNodeTypeDefinitionImpl(QNodeTypeDefinition nt)
          Copy constructor.
 
Method Summary
 boolean equals(Object obj)
           
 QNodeDefinition[] getChildNodeDefs()
          
 Collection<Name> getDependencies()
          
 Name getName()
          
 Name getPrimaryItemName()
          
 QPropertyDefinition[] getPropertyDefs()
          
 Name[] getSupertypes()
          
 Name[] getSupportedMixinTypes()
          
 int hashCode()
          Returns zero to satisfy the Object equals/hashCode contract.
 boolean hasOrderableChildNodes()
          
 boolean isAbstract()
          
 boolean isMixin()
          
 boolean isQueryable()
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QNodeTypeDefinitionImpl

public QNodeTypeDefinitionImpl()
Default constructor.


QNodeTypeDefinitionImpl

public QNodeTypeDefinitionImpl(QNodeTypeDefinition nt)
Copy constructor.

Parameters:
nt - the node type definition.

QNodeTypeDefinitionImpl

public QNodeTypeDefinitionImpl(Name name,
                               Name[] supertypes,
                               Name[] supportedMixins,
                               boolean isMixin,
                               boolean isAbstract,
                               boolean isQueryable,
                               boolean hasOrderableChildNodes,
                               Name primaryItemName,
                               QPropertyDefinition[] declaredPropDefs,
                               QNodeDefinition[] declaredNodeDefs)
Creates a new serializable SPI node type definition.

Parameters:
name - the name of the node type
supertypes - the names of the supertypes
supportedMixins - the names of supported mixins (or null)
isMixin - if this is a mixin node type
isAbstract - if this is an abstract node type definition.
isQueryable - if this is a queryable node type definition.
hasOrderableChildNodes - if this node type has orderable child nodes.
primaryItemName - the name of the primary item, or null.
declaredPropDefs - the declared property definitions.
declaredNodeDefs - the declared child node definitions.

QNodeTypeDefinitionImpl

public QNodeTypeDefinitionImpl(NodeTypeDefinition def,
                               NamePathResolver resolver,
                               QValueFactory qValueFactory)
                        throws RepositoryException
Createa a new QNodeTypeDefinitionImpl from a JCR NodeType definition.

Parameters:
def - node type definition
resolver - resolver
qValueFactory - value factory
Throws:
RepositoryException - if an error occurs
Method Detail

getName

public Name getName()

Specified by:
getName in interface QNodeTypeDefinition

getSupertypes

public Name[] getSupertypes()

Specified by:
getSupertypes in interface QNodeTypeDefinition

isMixin

public boolean isMixin()

Specified by:
isMixin in interface QNodeTypeDefinition

isAbstract

public boolean isAbstract()

Specified by:
isAbstract in interface QNodeTypeDefinition

isQueryable

public boolean isQueryable()

Specified by:
isQueryable in interface QNodeTypeDefinition

hasOrderableChildNodes

public boolean hasOrderableChildNodes()

Specified by:
hasOrderableChildNodes in interface QNodeTypeDefinition

getPrimaryItemName

public Name getPrimaryItemName()

Specified by:
getPrimaryItemName in interface QNodeTypeDefinition

getPropertyDefs

public QPropertyDefinition[] getPropertyDefs()

Specified by:
getPropertyDefs in interface QNodeTypeDefinition

getChildNodeDefs

public QNodeDefinition[] getChildNodeDefs()

Specified by:
getChildNodeDefs in interface QNodeTypeDefinition

getDependencies

public Collection<Name> getDependencies()

Specified by:
getDependencies in interface QNodeTypeDefinition

getSupportedMixinTypes

public Name[] getSupportedMixinTypes()

Specified by:
getSupportedMixinTypes in interface QNodeTypeDefinition

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Returns zero to satisfy the Object equals/hashCode contract. This class is mutable and not meant to be used as a hash key.

Overrides:
hashCode in class Object
Returns:
always zero
See Also:
Object.hashCode()


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