com.sap.caf.rt.bol.util

Class QueryFilter

java.lang.Object
  extended by com.sap.caf.rt.bol.util.QueryFilter
All Implemented Interfaces:
Serializable

public class QueryFilter
extends Object
implements Serializable

This class is used to describe a query filter for use with BO node query methods.

See Also:
Serialized Form

Field Summary
static String ACTION_EXACT
          Deprecated. 
static String ACTION_FUZZY
          Deprecated. 
static String ACTION_LINGUISTIC
          Deprecated. 
static QueryFilter AND
          Deprecated. 
static QueryFilter CLOSE_BRACKET
          Deprecated. 
static QueryFilter NOT
          Deprecated. 
static QueryFilter OPEN_BRACKET
          Deprecated. 
static String OPERATION_AND
          Deprecated. 
static String OPERATION_ATTRIBUTE
          Deprecated. 
static String OPERATION_BRACKET_CLOSE
          Deprecated. 
static String OPERATION_BRACKET_OPEN
          Deprecated. 
static String OPERATION_CATEGORY
          Deprecated. 
static String OPERATION_NOT
          Deprecated. 
static String OPERATION_OR
          Deprecated. 
static String OPERATION_TERM
          Deprecated. 
static QueryFilter OR
          Deprecated. 
static String WILDCARD_SYMBOL
           
 
Constructor Summary
QueryFilter()
          Deprecated. 
QueryFilter(Object value)
          Deprecated. 
QueryFilter(Object value, Condition condition)
          Deprecated. 
QueryFilter(QueryFilter qFilter)
          Deprecated. 
 
Method Summary
 String getAction()
          Deprecated. 
 String getAttribute()
          Returns the attribute which this query filter instance is for.
 Condition getCondition()
          Gets the search condition of this query filter instance.
 String getConditionAsString()
          Returns a string representation of this query filter's condition.
 String getOperation()
          Returns the operation which this instance represents.
 Object getProperty(String propertyName)
          A convenience method to get the "value" and "operation" properties of this query filter instance.
 Object getValue()
          Returns the value which this query filter instance will search for.
 Object getValueHigh()
          Returns the high value which this query filter instance will search for.
 Object getValueLow()
          Returns the low value which this query filter instance will search for.
 boolean isAssociation()
          Deprecated. 
 boolean isAssociationAttribute()
          Deprecated. 
 void setAction(String action)
          Deprecated. 
 void setAttribute(String attribute)
          Sets the attribute which this query filter instance is for.
 void setCondition(Condition condition)
          Sets the search condition for this query filter instance.
 void setOperation(String operation)
          Deprecated. 
 void setValue(Object value)
          Sets the value which this query filter instance will search for.
 void setValueHigh(Object value)
          Sets the high value which this query filter instance will search for.
 void setValueLow(Object value)
          Sets the low value which this query filter instance will search for.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WILDCARD_SYMBOL

public static final String WILDCARD_SYMBOL
See Also:
Constant Field Values

AND

@Deprecated
public static final QueryFilter AND
Deprecated. 
A convenience constant which is used when creating a search condition for the findByMultipleParamers operation.


OR

@Deprecated
public static final QueryFilter OR
Deprecated. 
A convenience constant which is used when creating a search condition for the findByMultipleParamers operation.


NOT

@Deprecated
public static final QueryFilter NOT
Deprecated. 
A convenience constant which is used when creating a search condition for the findByMultipleParamers operation.


OPEN_BRACKET

@Deprecated
public static final QueryFilter OPEN_BRACKET
Deprecated. 
A convenience constant which is used when creating a search condition for the findByMultipleParamers operation.


CLOSE_BRACKET

@Deprecated
public static final QueryFilter CLOSE_BRACKET
Deprecated. 
A convenience constant which is used when creating a search condition for the findByMultipleParamers operation.


OPERATION_CATEGORY

@Deprecated
public static String OPERATION_CATEGORY
Deprecated. 
A constant which is used to specify TREX search by category.

See Also:
setOperation(String)

OPERATION_ATTRIBUTE

@Deprecated
public static String OPERATION_ATTRIBUTE
Deprecated. 
A constant which is used to specify TREX search by attribute.

See Also:
setOperation(String)

OPERATION_TERM

@Deprecated
public static String OPERATION_TERM
Deprecated. 
A constant which is used to specify TREX search by term.

See Also:
setOperation(String)

OPERATION_AND

@Deprecated
public static String OPERATION_AND
Deprecated. 
A constant which is used to specify that this instance won't be treated as a search constraint but as a logical operator "and".

See Also:
setOperation(String)

OPERATION_OR

@Deprecated
public static String OPERATION_OR
Deprecated. 
A constant which is used to specify that this instance won't be treated as a search constraint but as a logical operator "or".

See Also:
setOperation(String)

OPERATION_NOT

@Deprecated
public static String OPERATION_NOT
Deprecated. 
A constant which is used to specify that this instance won't be treated as a search constraint but as a logical operator "no".

See Also:
setOperation(String)

OPERATION_BRACKET_OPEN

@Deprecated
public static String OPERATION_BRACKET_OPEN
Deprecated. 
A constant which is used to specify that this instance won't be treated as a search constraint but as an opening bracket.

See Also:
setOperation(String)

OPERATION_BRACKET_CLOSE

@Deprecated
public static String OPERATION_BRACKET_CLOSE
Deprecated. 
A constant which is used to specify that this instance won't be treated as a search constraint but as a closing bracket.

See Also:
setOperation(String)

ACTION_LINGUISTIC

@Deprecated
public static String ACTION_LINGUISTIC
Deprecated. 
A constant which is used to specify TREX liguistic search.

See Also:
setOperation(String)

ACTION_FUZZY

@Deprecated
public static String ACTION_FUZZY
Deprecated. 
A constant which is used to specify TREX fuzzy search.

See Also:
setOperation(String)

ACTION_EXACT

@Deprecated
public static String ACTION_EXACT
Deprecated. 
A constant which is used to specify TREX exact search.

See Also:
setOperation(String)
Constructor Detail

QueryFilter

@Deprecated
public QueryFilter()
Deprecated. 

Creates an empty query filter instance. This method is deprecated, use QueryFilterFactory.createFilter(Object) instead.


QueryFilter

@Deprecated
public QueryFilter(QueryFilter qFilter)
Deprecated. 

Creates a copy of a query filter instance. This method is deprecated, use QueryFilterFactory.createFilter(Object) instead.

Parameters:
qFilter - filter to copy

QueryFilter

@Deprecated
public QueryFilter(Object value)
Deprecated. 

Creates a query filter instance for a given value. This method is deprecated, use QueryFilterFactory.createFilter(Object) instead.

Parameters:
value - the value to be searched for

QueryFilter

@Deprecated
public QueryFilter(Object value,
                              Condition condition)
Deprecated. 

Creates a query filter instance for a given value and condition. This method is deprecated, use QueryFilterFactory.createFilter(Object, Condition) instead.

Parameters:
value - the value to be searched for
condition - the search condition
Method Detail

setOperation

@Deprecated
public void setOperation(String operation)
Deprecated. 

Transforms this query filter instance to an operator (or, and, etc). This method is deprecated because direct use of the findByMultipleParameter operation is discouraged.

Parameters:
operation - one of the following: OPERATION_AND, OPERATION_OR, OPERATION_NOT, OPERATION_BRACKET_OPEN, OPERATION_BRACKET_CLOSE
See Also:
getOperation()

getOperation

public String getOperation()
Returns the operation which this instance represents.

Returns:
the operation
See Also:
setOperation(String)

setAction

@Deprecated
public void setAction(String action)
Deprecated. 

Sets the action for TREX search.

Parameters:
action - the TREX action
See Also:
getAction()

getAction

@Deprecated
public String getAction()
Deprecated. 

Gets the action for TREX search.

Returns:
action for TREX search
See Also:
setAction(String)

setAttribute

public void setAttribute(String attribute)
Sets the attribute which this query filter instance is for.

Parameters:
attribute - the BO Node attribute which will be queried
See Also:
QueryFilterFactory.createFilter(String, Condition, Object), getAttribute()

getAttribute

public String getAttribute()
Returns the attribute which this query filter instance is for.

Returns:
the BO Node attribute which will be queried
See Also:
setAttribute(String), QueryFilterFactory.createFilter(String, Condition, Object)

getValue

public Object getValue()
Returns the value which this query filter instance will search for.

Returns:
the value which will be searched
See Also:
setValue(Object)

setValue

public void setValue(Object value)
Sets the value which this query filter instance will search for.

Parameters:
value - the value which will be searched
See Also:
QueryFilterFactory.createFilter(Object), getValue()

getValueLow

public Object getValueLow()
Returns the low value which this query filter instance will search for. Should be used only if the query filter represents a "between" search.

Returns:
the low bound of the search range
See Also:
QueryFilterFactory.createFilterForBetween(Object, Object), setValueLow(Object)

getValueHigh

public Object getValueHigh()
Returns the high value which this query filter instance will search for. Should be used only if the query filter represents a "between" search.

Returns:
the high bound of the search range
See Also:
QueryFilterFactory.createFilterForBetween(Object, Object), setValueHigh(Object)

setValueLow

public void setValueLow(Object value)
Sets the low value which this query filter instance will search for. Should be used only if the query filter represents a "between" search.

Parameters:
value - the low bound of the search range
See Also:
QueryFilterFactory.createFilterForBetween(Object, Object), getValueLow()

setValueHigh

public void setValueHigh(Object value)
Sets the high value which this query filter instance will search for. Should be used only if the query filter represents a "between" search.

Parameters:
value - the high bound of the search range
See Also:
QueryFilterFactory.createFilterForBetween(Object, Object), getValueHigh()

getProperty

public Object getProperty(String propertyName)
A convenience method to get the "value" and "operation" properties of this query filter instance.

Parameters:
propertyName - the name of the propery; valid values are: "minValue", "maxValue", "operation"
Returns:
the value of the requested property
See Also:
getValueLow(), getValueHigh(), getOperation()

isAssociation

@Deprecated
public boolean isAssociation()
Deprecated. 

Indicates whether the search will be performed over a BO node association.

Returns:
true if the search will be over a BO Node association, false if the search will be over a regular BO Node attribute
See Also:
QueryFilterFactory.createFilter(String, Condition, Object)

isAssociationAttribute

@Deprecated
public boolean isAssociationAttribute()
Deprecated. 

Indicates whether the search will be performed over a BO node association and is about the association itself rather than for a regular attribute of the associated BO Node.

Returns:
true if the search is for a BO Node association
See Also:
QueryFilterFactory.createFilter(String, Condition, Object)

setCondition

public void setCondition(Condition condition)
Sets the search condition for this query filter instance.

Parameters:
condition - the search condition
See Also:
Condition, getCondition()

getCondition

public Condition getCondition()
Gets the search condition of this query filter instance.

Returns:
the search condition of this instance
See Also:
Condition, setCondition(Condition)

getConditionAsString

public String getConditionAsString()
Returns a string representation of this query filter's condition.

Returns:
the string representation of the condition


Copyright 2009 SAP AG Complete Copyright Notice