Class NodeTypeDefinitionImpl
- java.lang.Object
-
- org.apache.jackrabbit.core.nodetype.NodeTypeDefinitionImpl
-
- All Implemented Interfaces:
NodeTypeDefinition
public class NodeTypeDefinitionImpl extends Object implements NodeTypeDefinition
This class implements theNodeTypeDefinition
interface. All method calls are delegated to the wrappedQNodeTypeDefinition
, performing the translation fromName
s to JCR names (and vice versa) where necessary.
-
-
Constructor Summary
Constructors Constructor Description NodeTypeDefinitionImpl(QNodeTypeDefinition ntd, NamePathResolver resolver, ValueFactory valueFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NodeDefinition[]
getDeclaredChildNodeDefinitions()
PropertyDefinition[]
getDeclaredPropertyDefinitions()
String[]
getDeclaredSupertypeNames()
Returns the names of the supertypes actually declared in this node type.String
getName()
String
getPrimaryItemName()
boolean
hasOrderableChildNodes()
boolean
isAbstract()
Returnstrue
if this is an abstract node type; returnsfalse
otherwise.boolean
isMixin()
boolean
isQueryable()
Returnstrue
if the node type is queryable, meaning that the available-query-operators, full-text-searchable and query-orderable attributes of its property definitions take effect.
-
-
-
Constructor Detail
-
NodeTypeDefinitionImpl
public NodeTypeDefinitionImpl(QNodeTypeDefinition ntd, NamePathResolver resolver, ValueFactory valueFactory)
-
-
Method Detail
-
getName
public String getName()
- Specified by:
getName
in interfaceNodeTypeDefinition
-
getDeclaredSupertypeNames
public String[] getDeclaredSupertypeNames()
Returns the names of the supertypes actually declared in this node type.In implementations that support node type registration, if this
NodeTypeDefinition
object is actually a newly-created emptyNodeTypeTemplate
, then this method will return an array containing a single string indicating the node typent:base
.- Specified by:
getDeclaredSupertypeNames
in interfaceNodeTypeDefinition
- Returns:
- an array of
String
s - Since:
- JCR 2.0
-
isAbstract
public boolean isAbstract()
Returnstrue
if this is an abstract node type; returnsfalse
otherwise.An abstract node type is one that cannot be assigned as the primary or mixin type of a node but can be used in the definitions of other node types as a superclass.
In implementations that support node type registration, if this
NodeTypeDefinition
object is actually a newly-created emptyNodeTypeTemplate
, then this method will returnfalse
.- Specified by:
isAbstract
in interfaceNodeTypeDefinition
- Returns:
- a
boolean
- Since:
- JCR 2.0
-
isQueryable
public boolean isQueryable()
Returnstrue
if the node type is queryable, meaning that the available-query-operators, full-text-searchable and query-orderable attributes of its property definitions take effect. SeePropertyDefinition.getAvailableQueryOperators()
,PropertyDefinition.isFullTextSearchable()
andPropertyDefinition.isQueryOrderable()
.If a node type is declared non-queryable then these attributes of its property definitions have no effect.
- Specified by:
isQueryable
in interfaceNodeTypeDefinition
- Returns:
- a
boolean
- Since:
- JCR 2.0
-
isMixin
public boolean isMixin()
- Specified by:
isMixin
in interfaceNodeTypeDefinition
-
hasOrderableChildNodes
public boolean hasOrderableChildNodes()
- Specified by:
hasOrderableChildNodes
in interfaceNodeTypeDefinition
-
getPrimaryItemName
public String getPrimaryItemName()
- Specified by:
getPrimaryItemName
in interfaceNodeTypeDefinition
-
getDeclaredChildNodeDefinitions
public NodeDefinition[] getDeclaredChildNodeDefinitions()
- Specified by:
getDeclaredChildNodeDefinitions
in interfaceNodeTypeDefinition
-
getDeclaredPropertyDefinitions
public PropertyDefinition[] getDeclaredPropertyDefinitions()
- Specified by:
getDeclaredPropertyDefinitions
in interfaceNodeTypeDefinition
-
-