Class OrderQueryNode.OrderSpec
- java.lang.Object
-
- org.apache.jackrabbit.spi.commons.query.OrderQueryNode.OrderSpec
-
- Enclosing class:
- OrderQueryNode
public static final class OrderQueryNode.OrderSpec extends java.lang.ObjectImplements a single order specification. Contains a property name and whether it is ordered ascending or descending.
-
-
Constructor Summary
Constructors Constructor Description OrderSpec(Name property, boolean ascending)Deprecated.useOrderSpec(Path, boolean)instead.OrderSpec(Path property, boolean ascending)Creates a newOrderSpecforproperty.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)Returnstrueifthisorder spec is equal toobjjava.lang.StringgetFunction()NamegetProperty()Deprecated.usegetPropertyPath()instead.PathgetPropertyPath()Returns the relative path of the property.booleanisAscending()Iftruethe property is ordered ascending, otherwise descending.voidsetAscending(boolean ascending)Sets the new value for the ascending property.voidsetFunction(java.lang.String name)Set a new value for a functionvoidsetPath(Path path)Set a new value for the path
-
-
-
Constructor Detail
-
OrderSpec
public OrderSpec(Name property, boolean ascending)
Deprecated.useOrderSpec(Path, boolean)instead.Creates a newOrderSpecforproperty.- Parameters:
property- the name of the property.ascending- iftruethe property is ordered ascending, otherwise descending.
-
OrderSpec
public OrderSpec(Path property, boolean ascending)
Creates a newOrderSpecforproperty.- Parameters:
property- the relative path of the property.ascending- iftruethe property is ordered ascending, otherwise descending.
-
-
Method Detail
-
getProperty
public Name getProperty()
Deprecated.usegetPropertyPath()instead.Returns the name of the property.- Returns:
- the name of the property.
-
getPropertyPath
public Path getPropertyPath()
Returns the relative path of the property.- Returns:
- the relative path of the property.
-
isAscending
public boolean isAscending()
Iftruethe property is ordered ascending, otherwise descending.- Returns:
truefor ascending;falsefor descending.
-
setAscending
public void setAscending(boolean ascending)
Sets the new value for the ascending property.- Parameters:
ascending-truefor ascending;falsefor descending.
-
setPath
public void setPath(Path path)
Set a new value for the path- Parameters:
path- a path
-
setFunction
public void setFunction(java.lang.String name)
Set a new value for a function- Parameters:
name- a function name
-
getFunction
public java.lang.String getFunction()
- Returns:
- name of the function
-
equals
public boolean equals(java.lang.Object obj)
Returnstrueifthisorder spec is equal toobj- Overrides:
equalsin classjava.lang.Object- Parameters:
obj- the reference object with which to compare.- Returns:
trueifthisorder spec is equal toobj;falseotherwise.
-
-