Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.endeca.portal.data.functions
Class RangeFilter

    java.lang.Object
      com.endeca.portal.data.functions.QueryFunction
          com.endeca.portal.data.functions.QueryFilter
              com.endeca.portal.data.functions.RangeFilter

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable

    public class RangeFilter

extends QueryFilter

This filter class allows range filters to be added to QueryState instances. Currently supported on: ENE presentation API data sources Discovery service data sources.

Author:
  Endeca Technologies, Inc.
See Also:
  Serialized Form

Nested Class Summary
`static class` | `RangeFilter.RangeFilterCreationException` This exception is thrown when a `RangeFilter` could not be created
`static class` | `RangeFilter.RangeOperator` Specifies the operator used in this `RangeFilter` Valid RangeOperators are LT: Less than LTEQ: Less than or equal to GT: Greater than GTEQ: Greater than or equal to BTWN: Between (inclusive) GCLT: Geocode less than (non-inclusive) GCGT: Geocode greater than (non-inclusive) CGBTWN: Geocode beween (inclusive)
`static class` | `RangeFilter.RangeOperatorNotSupportedException` This exception is thrown when an invalid `RangeFilter.RangeOperator` is present in a RangeFilter.
`static class` | `RangeFilter.RangeType` Specifies the type of `RangeFilter`
`static class` | `RangeFilter.RangeTypeNotSupportedException` This exception is thrown when an invalid `RangeFilter.RangeType` is present in a RangeFilter.

Field Summary

Fields inherited from class com.endeca.portal.data.functions.QueryFunction
`CLASS_PROPERTY`

Constructor Summary
`protected` | `RangeFilter()`
`` | `RangeFilter(org.json.JSONObject jsonObject)` Constructs a `RangeFilter` from the given JSON string
`` | `RangeFilter(java.lang.String property, RangeFilter.RangeType rangeType, RangeFilter.RangeOperator rangeOperator, java.lang.String value1)` Constructs a `RangeFilter`
`` | `RangeFilter(java.lang.String property, RangeFilter.RangeType rangeType, RangeFilter.RangeOperator rangeOperator, java.lang.String value1, java.lang.String value2)` Constructs a `RangeFilter`
`` | `RangeFilter(java.lang.String property, RangeFilter.RangeType rangeType, RangeFilter.RangeOperator rangeOperator, java.lang.String value1, java.lang.String value2, java.lang.String value3)` Constructs a `RangeFilter`

Method Summary
`void` | `applyToDiscoveryServiceQuery(com.endeca.mdex.conversation.Request query)` Apply this function to a Request.
`void` | `applyToENEQuery(com.endeca.navigation.ENEQuery query)` Apply this function to an ENEQuery.
`java.util.List<java.lang.reflect.Method>` | `getGetters()` Return the list of property getters on this function.
`java.lang.String` | `getProperty()`
`RangeFilter.RangeOperator` | `getRangeOperator()`
`RangeFilter.RangeType` | `getRangeType()`
`java.util.List<java.lang.reflect.Method>` | `getSetters()` Return the list of property setters on this function.
`java.lang.String` | `getValue1()`
`java.lang.String` | `getValue2()`
`java.lang.String` | `getValue3()`
`void` | `setProperty(java.lang.String property)`
`void` | `setRangeOperator(RangeFilter.RangeOperator rangeOperator)`
`void` | `setRangeOperator(java.lang.String rangeOperator)`
`void` | `setRangeType(RangeFilter.RangeType rangeType)`
`void` | `setRangeType(java.lang.String rangeType)`
`void` | `setValue1(java.lang.String value1)`
`void` | `setValue2(java.lang.String value2)`
`void` | `setValue3(java.lang.String value3)`
`java.lang.String` | `toString()` Creates a string representation of the `RangeFilter` that is in the format expected by MDEX 6 `ENEQuery` objects.

Methods inherited from class com.endeca.portal.data.functions.QueryFunction
`clone, equals, equals, getInstance, getInstance, getName, hashCode, init, setName, toJSON`

Methods inherited from class java.lang.Object
`finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### RangeFilter

    protected RangeFilter()

### RangeFilter

    public RangeFilter(org.json.JSONObject jsonObject)
                throws org.json.JSONException,
                       java.lang.IllegalArgumentException,
                       java.lang.ClassNotFoundException,
                       java.lang.IllegalAccessException,
                       java.lang.InstantiationException,
                       java.lang.reflect.InvocationTargetException,
                       RangeFilter.RangeFilterCreationException

  Constructs a `RangeFilter` from the given JSON string

  Parameters:
    `jsonObject` -
  Throws:
    `org.json.JSONException`
    `java.lang.IllegalArgumentException`
    `java.lang.ClassNotFoundException`
    `java.lang.IllegalAccessException`
    `java.lang.InstantiationException`
    `java.lang.reflect.InvocationTargetException`
    `RangeFilter.RangeFilterCreationException`

### RangeFilter

    public RangeFilter(java.lang.String property,
                       RangeFilter.RangeType rangeType,
                       RangeFilter.RangeOperator rangeOperator,
                       java.lang.String value1)
                throws RangeFilter.RangeFilterCreationException

  Constructs a `RangeFilter`

  Parameters:
    `property` - on which the range filter will operate
    `rangeType` -
    `rangeOperator` -
    `value1` -
  Throws:
    `RangeFilter.RangeFilterCreationException`

### RangeFilter

    public RangeFilter(java.lang.String property,
                       RangeFilter.RangeType rangeType,
                       RangeFilter.RangeOperator rangeOperator,
                       java.lang.String value1,
                       java.lang.String value2)
                throws RangeFilter.RangeFilterCreationException

  Constructs a `RangeFilter`

  Parameters:
    `property` -
    `rangeType` -
    `rangeOperator` -
    `value1` -
    `value2` -
  Throws:
    `RangeFilter.RangeFilterCreationException`

### RangeFilter

    public RangeFilter(java.lang.String property,
                       RangeFilter.RangeType rangeType,
                       RangeFilter.RangeOperator rangeOperator,
                       java.lang.String value1,
                       java.lang.String value2,
                       java.lang.String value3)
                throws RangeFilter.RangeFilterCreationException

  Constructs a `RangeFilter`

  Parameters:
    `property` -
    `rangeType` -
    `rangeOperator` -
    `value1` -
    `value2` -
    `value3` -
  Throws:
    `RangeFilter.RangeFilterCreationException`

Method Detail

### getProperty

    public java.lang.String getProperty()

  Returns:
    property on which this `RangeFilter` operates

### setProperty

    public void setProperty(java.lang.String property)

  Parameters:
    `property` - on which this `RangeFilter` operates

### getRangeType

    public RangeFilter.RangeType getRangeType()

  Returns:
    `RangeFilter.RangeType` of this `RangeFilter`

### setRangeType

    public void setRangeType(RangeFilter.RangeType rangeType)

  Parameters:
    `{@link` - RangeType} of this `RangeFilter`

### setRangeType

    public void setRangeType(java.lang.String rangeType)
                      throws RangeFilter.RangeTypeNotSupportedException

  Parameters:
    `String` - representing the type of this `RangeFilter`
  Throws:
    `RangeFilter.RangeTypeNotSupportedException`

### getRangeOperator

    public RangeFilter.RangeOperator getRangeOperator()

  Returns:
    `RangeFilter.RangeOperator` associated with this `RecordFilter`

### setRangeOperator

    public void setRangeOperator(RangeFilter.RangeOperator rangeOperator)

  Parameters:
    `rangeOperator` - associated with this `RecordFilter`

### setRangeOperator

    public void setRangeOperator(java.lang.String rangeOperator)
                          throws RangeFilter.RangeOperatorNotSupportedException

  Parameters:
    `String` - representing the `RangeFilter.RangeOperator` of this `RecordFilter`
  Throws:
    `RangeFilter.RangeOperatorNotSupportedException`

### getValue1

    public java.lang.String getValue1()

  Returns:
    value1

### setValue1

    public void setValue1(java.lang.String value1)

  Parameters:
    `value1` -

### getValue2

    public java.lang.String getValue2()

  Returns:
    value2

### setValue2

    public void setValue2(java.lang.String value2)

  Parameters:
    `value2` -

### getValue3

    public java.lang.String getValue3()

  Returns:
    value3

### setValue3

    public void setValue3(java.lang.String value3)

  Parameters:
    `value3` -

### getSetters

    public java.util.List<java.lang.reflect.Method> getSetters()

  Description copied from class: `QueryFunction`
  Return the list of property setters on this function. Must be implemented by subclass. Required for correct JSON serialization/deserialization support. For most subclasses, implementing this method should be simple, as long as your setter methods follow standard Java naming conventions (e.g. "setPropertyName(PropertyType)"). All you should need to write is: `

       private static List setters = Reflection.getSetters(MyFunctionClass.class);
       \@Override
       public List getSetters() {
              return setters;
       }

  `

  Specified by:
    `getSetters` in class `QueryFunction`
  Returns:
    the list of setters

### getGetters

    public java.util.List<java.lang.reflect.Method> getGetters()

  Description copied from class: `QueryFunction`
  Return the list of property getters on this function. Must be implemented by subclass. Required for correct JSON serialization/deserialization support. For most subclasses, implementing this method should be simple, as long as your getter methods follow standard Java naming conventions (e.g. "getPropertyName()"). All you should need to write is: `

       private static List getters = Reflection.getGetters(MyFunctionClass.class);
       \@Override
       public List getGetters() {
              return getters;
       }

  `

  Specified by:
    `getGetters` in class `QueryFunction`
  Returns:
    the list of getters

### applyToENEQuery

    public void applyToENEQuery(com.endeca.navigation.ENEQuery query)

  Apply this function to an ENEQuery. Must be implemented by subclass.

  Specified by:
    `applyToENEQuery` in class `QueryFunction`

### applyToDiscoveryServiceQuery

    public void applyToDiscoveryServiceQuery(com.endeca.mdex.conversation.Request query)
                                      throws QueryFunctionUnsupportedException

  Apply this function to a Request. Must be implemented by subclass.

  Specified by:
    `applyToDiscoveryServiceQuery` in class `QueryFunction`
  Throws:
    `QueryFunctionUnsupportedException`

### toString

    public java.lang.String toString()

  Creates a string representation of the `RangeFilter` that is in the format expected by MDEX 6 `ENEQuery` objects.

  Specified by:
    `toString` in class `QueryFunction`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD