atg.repository.search.refinement
Class RangeFacetValue

java.lang.Object
  extended by atg.repository.search.refinement.FacetValue
      extended by atg.repository.search.refinement.RangeFacetValue
All Implemented Interfaces:
java.lang.Cloneable
Direct Known Subclasses:
RangeFacetDisjunctionMultiValue

public class RangeFacetValue
extends FacetValue

An extension to the FacetValue class which represents a range value


Field Summary
static java.lang.String CLASS_VERSION
          Class version string
static java.lang.String DEFAULT_LAST_INDICATOR
          String constant for the default last range value indicator
static java.lang.String DEFAULT_RANGE_SEPARATOR
          String constant for splitting range values
static java.lang.String DEFAULT_VALUEINDICATOR_SEPARATOR
          String constant for the default value indicator separator
protected  java.lang.String mIndicatorSeparator
          Separator used to separate the range value from the last range value indicator.
protected  java.lang.String mLastIndicator
          Indicator string used to indicate that the range value is the last one.
protected  boolean mLastRangeValue
          Indicates whether this range value is the last one.
 
Fields inherited from class atg.repository.search.refinement.FacetValue
DEFAULT_IDVALUE_SEPARATOR, mFacet, mMatchingDocsCount, mRefinementValue, mScore, mSeparator, mValue
 
Constructor Summary
RangeFacetValue(Facet pFacet, java.lang.Object pValue, long pMatchingDocsCount, int pScore, boolean pIsLastRangeValue)
          Constructor method
RangeFacetValue(Facet pFacet, java.lang.Object pValue, java.lang.String pSeparator, boolean pIsLastRangeValue, java.lang.String pLastIndicator, java.lang.String pIndicatorSeparator)
          Constructor method.
RangeFacetValue(Facet pFacet, RefinementValue pRefinementValue, int pScore, boolean pIsLastRangeValue)
          Constructor method
 
Method Summary
 java.lang.Object clone()
          Override clone to copy this object
 java.lang.String getIndicatorSeparator()
          Getter method for indicator separator
 java.lang.String getLastIndicator()
          Getter method for last indicator
 java.lang.String getRangeEnd()
          Gets the end value of the range.
 java.lang.String getRangeStart()
          Gets the start value of the range
 java.lang.String getTrailString()
          Returns a String representation of the facet value intended for use in a URL trail parameter.
 boolean isLastRangeValue()
          Indicates whether this range value is the last one in the range
 void setIndicatorSeparator(java.lang.String pIndicatorSeparator)
          Setter method for indicator separator
 void setLastIndicator(java.lang.String pLastIndicator)
          Setter method for last indicator
 void setLastRangeValue(boolean pIsLastRangeValue)
          Sets whether this is the last range value
 
Methods inherited from class atg.repository.search.refinement.FacetValue
equals, getDebug, getFacet, getMatchingDocsCount, getRefinementValue, getScore, getSeparator, getValue, hashCode, setFacet, setMatchingDocsCount, setRefinementValue, setScore, setSeparator, setValue, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION
Class version string


DEFAULT_LAST_INDICATOR

public static final java.lang.String DEFAULT_LAST_INDICATOR
String constant for the default last range value indicator

See Also:
Constant Field Values

DEFAULT_VALUEINDICATOR_SEPARATOR

public static final java.lang.String DEFAULT_VALUEINDICATOR_SEPARATOR
String constant for the default value indicator separator

See Also:
Constant Field Values

DEFAULT_RANGE_SEPARATOR

public static final java.lang.String DEFAULT_RANGE_SEPARATOR
String constant for splitting range values

See Also:
Constant Field Values

mLastRangeValue

protected boolean mLastRangeValue
Indicates whether this range value is the last one.


mIndicatorSeparator

protected java.lang.String mIndicatorSeparator
Separator used to separate the range value from the last range value indicator.


mLastIndicator

protected java.lang.String mLastIndicator
Indicator string used to indicate that the range value is the last one.

Constructor Detail

RangeFacetValue

public RangeFacetValue(Facet pFacet,
                       java.lang.Object pValue,
                       long pMatchingDocsCount,
                       int pScore,
                       boolean pIsLastRangeValue)
Constructor method

Parameters:
pFacet - Facet reference
pValue - Object value
pMatchingDocsCount - The number of matching documents for this facet value.
pScore - The relevancy of this facet value
pIsLastRangeValue - Indicates whether this is the last range value

RangeFacetValue

public RangeFacetValue(Facet pFacet,
                       RefinementValue pRefinementValue,
                       int pScore,
                       boolean pIsLastRangeValue)
Constructor method

Parameters:
pFacet - Facet reference
pRefinementValue - RefinementValue from response
pScore - The relevancy of this facet value
pIsLastRangeValue - Indicates whether this is the last range value

RangeFacetValue

public RangeFacetValue(Facet pFacet,
                       java.lang.Object pValue,
                       java.lang.String pSeparator,
                       boolean pIsLastRangeValue,
                       java.lang.String pLastIndicator,
                       java.lang.String pIndicatorSeparator)
Constructor method.

Parameters:
pFacet - Facet reference
pValue - Object value
pSeparator - String separator
pIsLastRangeValue - Indicates whether this is the last range value
pLastIndicator - Last indicator string
pindicatorSeparator - Separator used to separate value from last range value indicator
Method Detail

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Override clone to copy this object

Overrides:
clone in class FacetValue
Throws:
java.lang.CloneNotSupportedException
See Also:
Object.clone()

isLastRangeValue

public boolean isLastRangeValue()
Indicates whether this range value is the last one in the range

Returns:
true if this is the last one, false otherwise

setLastRangeValue

public void setLastRangeValue(boolean pIsLastRangeValue)
Sets whether this is the last range value

Parameters:
pIsLastRangeValue - The value to set.

getRangeStart

public java.lang.String getRangeStart()
Gets the start value of the range

Returns:
String start value

getRangeEnd

public java.lang.String getRangeEnd()
Gets the end value of the range.

Returns:
String end value

getIndicatorSeparator

public java.lang.String getIndicatorSeparator()
Getter method for indicator separator

Returns:
String separator

setIndicatorSeparator

public void setIndicatorSeparator(java.lang.String pIndicatorSeparator)
Setter method for indicator separator

Parameters:
pIndicatorSeparator - String indicator separator

getLastIndicator

public java.lang.String getLastIndicator()
Getter method for last indicator

Returns:
String last indicator

setLastIndicator

public void setLastIndicator(java.lang.String pLastIndicator)
Setter method for last indicator

Parameters:
pLastIndicator - String last indicator

getTrailString

public java.lang.String getTrailString()
Returns a String representation of the facet value intended for use in a URL trail parameter.

Overrides:
getTrailString in class FacetValue
Returns:
A String of the format ""