org.infoglue.cms.controllers.kernel.impl.simple
Class ExtendedSearchCriterias

java.lang.Object
  extended by org.infoglue.cms.controllers.kernel.impl.simple.ExtendedSearchCriterias

public class ExtendedSearchCriterias
extends java.lang.Object

Criterias for the ExtendedSearchController.


Field Summary
static int BOTH_DATE_CRITERIA_TYPE
          Indicates that the between date criteria should be used.
static int FROM_DATE_CRITERIA_TYPE
          Indicates that the from date criteria should be used.
static int NO_DATE_CRITERIA_TYPE
          Indicates that no date criteria should be used.
static int TO_DATE_CRITERIA_TYPE
          Indicates that the to date criteria should be used.
 
Constructor Summary
ExtendedSearchCriterias()
          Constructs a criteria object with the state critera set to ContentVersionVO.WORKING_STATE.
ExtendedSearchCriterias(int stateId)
          Constructs a criteria object with the specified state critera.
 
Method Summary
 CategoryConditions getCategories()
          Returns the category condition to use in the category condition criteria.
 java.util.List getContentTypeDefinitions()
          Returns the content type definitions to use in the content type definition criteria.
 int getDateCriteriaType()
          Returns the type of date critiera to use.
 java.lang.String getFreetext()
          Returns the freetext to use in the freetext criteria.
 java.sql.Timestamp getFromDate()
          Returns the from date to use in the date criteria.
 LanguageVO getLanguage()
          Returns the language to use in the language criteria.
 java.lang.Integer getStateId()
          Returns the state to use in the state criteria.
 java.sql.Timestamp getToDate()
          Returns the to date to use in the date criteria.
 java.util.List getXmlAttributes()
          Returns the attributes to use in the freetext criteria.
 boolean hasCategoryConditions()
          Returns true if the category criteria should be used; false otherwise.
 boolean hasContentTypeDefinitionVOsCriteria()
          Returns true if the content type definition criteria should be used; false otherwise.
 boolean hasFreetextCritera()
          Returns true if the freetext criteria should be used; false otherwise.
 boolean hasLanguageCriteria()
          Returns true if the language criteria should be used; false otherwise.
 void setCategoryConditions(CategoryConditions categories)
          Sets the category criteria.
 void setContentTypeDefinitions(ContentTypeDefinitionVO contentTypeDefinitionVO)
          Sets the content type definition critiera.
 void setContentTypeDefinitions(java.util.List contentTypeDefinitionVOs)
          Sets the content type definition critiera.
 void setDates(java.util.Date from, java.util.Date to)
          Sets the date critiera.
 void setFreetext(java.lang.String freetext, java.util.List xmlAttributes)
          Sets the freetext critera.
 void setLanguage(LanguageVO languageVO)
          Sets the language criteria.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NO_DATE_CRITERIA_TYPE

public static final int NO_DATE_CRITERIA_TYPE
Indicates that no date criteria should be used.

See Also:
Constant Field Values

FROM_DATE_CRITERIA_TYPE

public static final int FROM_DATE_CRITERIA_TYPE
Indicates that the from date criteria should be used.

See Also:
Constant Field Values

TO_DATE_CRITERIA_TYPE

public static final int TO_DATE_CRITERIA_TYPE
Indicates that the to date criteria should be used.

See Also:
Constant Field Values

BOTH_DATE_CRITERIA_TYPE

public static final int BOTH_DATE_CRITERIA_TYPE
Indicates that the between date criteria should be used.

See Also:
Constant Field Values
Constructor Detail

ExtendedSearchCriterias

public ExtendedSearchCriterias()
Constructs a criteria object with the state critera set to ContentVersionVO.WORKING_STATE.


ExtendedSearchCriterias

public ExtendedSearchCriterias(int stateId)
Constructs a criteria object with the specified state critera.

Parameters:
stateId - the stateId to use.
Method Detail

setFreetext

public void setFreetext(java.lang.String freetext,
                        java.util.List xmlAttributes)
Sets the freetext critera. Note that at least one attribute must be specified to enabled freetext search.

Parameters:
freetext - the freetext to use.
xmlAttributes - the list of attribute names to use.

setLanguage

public void setLanguage(LanguageVO languageVO)
Sets the language criteria.

Parameters:
languageVO - the language to use.

setContentTypeDefinitions

public void setContentTypeDefinitions(ContentTypeDefinitionVO contentTypeDefinitionVO)
Sets the content type definition critiera.

Parameters:
contentTypeDefinitionVO - the content type definition to use.

setContentTypeDefinitions

public void setContentTypeDefinitions(java.util.List contentTypeDefinitionVOs)
Sets the content type definition critiera.

Parameters:
contentTypeDefinitionVOs - the list of ContentTypeDefinitionVO to use.

setCategoryConditions

public void setCategoryConditions(CategoryConditions categories)
Sets the category criteria.

Parameters:
categories - the category condition to use.

setDates

public void setDates(java.util.Date from,
                     java.util.Date to)
Sets the date critiera.

Parameters:
from - the from date to use (null is used to indicate an open end).
to - the to date to use (null is used to indicate an open end).

hasFreetextCritera

public boolean hasFreetextCritera()
Returns true if the freetext criteria should be used; false otherwise.

Returns:
true if the criteria should be used; false otherwise.

hasLanguageCriteria

public boolean hasLanguageCriteria()
Returns true if the language criteria should be used; false otherwise.

Returns:
true if the criteria should be used; false otherwise.

hasContentTypeDefinitionVOsCriteria

public boolean hasContentTypeDefinitionVOsCriteria()
Returns true if the content type definition criteria should be used; false otherwise.

Returns:
true if the criteria should be used; false otherwise.

hasCategoryConditions

public boolean hasCategoryConditions()
Returns true if the category criteria should be used; false otherwise.

Returns:
true if the criteria should be used; false otherwise.

getDateCriteriaType

public int getDateCriteriaType()
Returns the type of date critiera to use.

Returns:
the type of date criteria to use.

getStateId

public java.lang.Integer getStateId()
Returns the state to use in the state criteria.

Returns:
the state.

getFreetext

public java.lang.String getFreetext()
Returns the freetext to use in the freetext criteria.

Returns:
the freetext.

getXmlAttributes

public java.util.List getXmlAttributes()
Returns the attributes to use in the freetext criteria.

Returns:
the list of attribute names.

getLanguage

public LanguageVO getLanguage()
Returns the language to use in the language criteria.

Returns:
the language.

getContentTypeDefinitions

public java.util.List getContentTypeDefinitions()
Returns the content type definitions to use in the content type definition criteria.

Returns:
the list of ContentTypeDefinitionVO:s.

getCategories

public CategoryConditions getCategories()
Returns the category condition to use in the category condition criteria.

Returns:
the category condition.

getFromDate

public java.sql.Timestamp getFromDate()
Returns the from date to use in the date criteria.

Returns:
the from date.

getToDate

public java.sql.Timestamp getToDate()
Returns the to date to use in the date criteria.

Returns:
the to date.


Copyright © 2005 InfoGlue.org All Rights Reserved.