Class QPropertyDefinitionImpl
- java.lang.Object
-
- org.apache.jackrabbit.spi.commons.QItemDefinitionImpl
-
- org.apache.jackrabbit.spi.commons.QPropertyDefinitionImpl
-
- All Implemented Interfaces:
Serializable,org.apache.jackrabbit.spi.QItemDefinition,org.apache.jackrabbit.spi.QPropertyDefinition
public class QPropertyDefinitionImpl extends QItemDefinitionImpl implements org.apache.jackrabbit.spi.QPropertyDefinition
QPropertyDefinitionImplimplements SPI property definition interface.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.jackrabbit.spi.commons.QItemDefinitionImpl
hashCode
-
-
Constructor Summary
Constructors Constructor Description QPropertyDefinitionImpl(PropertyDefinition propDef, NamePathResolver resolver, org.apache.jackrabbit.spi.QValueFactory qValueFactory)Creates a new property definition based onpropDef.QPropertyDefinitionImpl(org.apache.jackrabbit.spi.Name name, org.apache.jackrabbit.spi.Name declaringNodeType, boolean isAutoCreated, boolean isMandatory, int onParentVersion, boolean isProtected, org.apache.jackrabbit.spi.QValue[] defaultValues, boolean isMultiple, int requiredType, org.apache.jackrabbit.spi.QValueConstraint[] valueConstraints, String[] availableQueryOperators, boolean isFullTextSearchable, boolean isQueryOrderable)Creates a new serializable property definition.QPropertyDefinitionImpl(org.apache.jackrabbit.spi.QPropertyDefinition propDef)Copy constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandefinesNode()booleanequals(Object obj)Compares two property definitions for equality.String[]getAvailableQueryOperators()org.apache.jackrabbit.spi.QValue[]getDefaultValues()intgetRequiredType()org.apache.jackrabbit.spi.QValueConstraint[]getValueConstraints()inthashCode()OverridesQItemDefinitionImpl.hashCode().booleanisFullTextSearchable()booleanisMultiple()booleanisQueryOrderable()-
Methods inherited from class org.apache.jackrabbit.spi.commons.QItemDefinitionImpl
definesResidual, getDeclaringNodeType, getName, getOnParentVersion, isAutoCreated, isMandatory, isProtected
-
-
-
-
Constructor Detail
-
QPropertyDefinitionImpl
public QPropertyDefinitionImpl(org.apache.jackrabbit.spi.QPropertyDefinition propDef)
Copy constructor.- Parameters:
propDef- some other property definition.
-
QPropertyDefinitionImpl
public QPropertyDefinitionImpl(org.apache.jackrabbit.spi.Name name, org.apache.jackrabbit.spi.Name declaringNodeType, boolean isAutoCreated, boolean isMandatory, int onParentVersion, boolean isProtected, org.apache.jackrabbit.spi.QValue[] defaultValues, boolean isMultiple, int requiredType, org.apache.jackrabbit.spi.QValueConstraint[] valueConstraints, String[] availableQueryOperators, boolean isFullTextSearchable, boolean isQueryOrderable)Creates a new serializable property definition.- Parameters:
name- the name of the child item.declaringNodeType- the declaring node typeisAutoCreated- if this item is auto created.isMandatory- if this is a mandatory item.onParentVersion- the on parent version behaviour.isProtected- if this item is protected.defaultValues- the default values ornullif there are none.isMultiple- if this property is multi-valued.requiredType- the required type for this property.valueConstraints- the value constraints for this property. If none exist an empty array must be passed.availableQueryOperators- the available query operatorsisFullTextSearchable- if this is fulltext searchableisQueryOrderable- if this is queryable- Throws:
NullPointerException- ifvalueConstraintsoravailableQueryOperatorsisnull.- Since:
- JCR 2.0
-
QPropertyDefinitionImpl
public QPropertyDefinitionImpl(PropertyDefinition propDef, NamePathResolver resolver, org.apache.jackrabbit.spi.QValueFactory qValueFactory) throws RepositoryException
Creates a new property definition based onpropDef.- Parameters:
propDef- the JCR property definition.resolver- the name/path resolver of the session that provided the property definition.qValueFactory- the QValue factory.- Throws:
RepositoryException- if an error occurs while reading frompropDef.
-
-
Method Detail
-
getRequiredType
public int getRequiredType()
- Specified by:
getRequiredTypein interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
getValueConstraints
public org.apache.jackrabbit.spi.QValueConstraint[] getValueConstraints()
- Specified by:
getValueConstraintsin interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
getDefaultValues
public org.apache.jackrabbit.spi.QValue[] getDefaultValues()
- Specified by:
getDefaultValuesin interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
isMultiple
public boolean isMultiple()
- Specified by:
isMultiplein interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
getAvailableQueryOperators
public String[] getAvailableQueryOperators()
- Specified by:
getAvailableQueryOperatorsin interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
isFullTextSearchable
public boolean isFullTextSearchable()
- Specified by:
isFullTextSearchablein interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
isQueryOrderable
public boolean isQueryOrderable()
- Specified by:
isQueryOrderablein interfaceorg.apache.jackrabbit.spi.QPropertyDefinition
-
definesNode
public boolean definesNode()
- Specified by:
definesNodein interfaceorg.apache.jackrabbit.spi.QItemDefinition- Returns:
- always
false
-
equals
public boolean equals(Object obj)
Compares two property definitions for equality. Returnstrueif the given object is a property definition and has the same attributes as this property definition.- Overrides:
equalsin classQItemDefinitionImpl- Parameters:
obj- the object to compare this property definition with- Returns:
trueif the object is equal to this property definition,falseotherwise- See Also:
Object.equals(Object)
-
hashCode
public int hashCode()
OverridesQItemDefinitionImpl.hashCode().- Overrides:
hashCodein classQItemDefinitionImpl- Returns:
- the hash code
-
-