|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectatg.nucleus.logging.VariableArgumentApplicationLoggingImpl
atg.nucleus.GenericService
atg.droplet.EmptyFormHandler
atg.droplet.GenericFormHandler
atg.commerce.csr.search.SearchFormHandler
atg.commerce.csr.search.OrderSearchFormHandler
public class OrderSearchFormHandler
This OrderSearchFormHandler class is a subclass of SearchFormhandler and is used to search order on order repository and other order related repositories( Profile, Catalog). The class builds a Query object and generates search resultset
Example jhtml usage (as a FormHandler):
<FORM method="POST" action="searchresults.jhtml"> Profile ID: <input type=hidden bean="RepositorySearchForm.SearchAttributes[1].Name" value="profileId"> <input type=hidden bean="RepositorySearchForm.SearchAttributes[1].Method" value="0"> <input type=hidden bean="RepositorySearchForm.SearchAttributes[1].CaseSensitive" value="0"> <select bean="RepositorySearchForm.SearchAttributes[1].Relation"> <option value="=="> == <option value="!="> != <option value="<"> < <option value=">"> > <option value="<="> <= <option value=">="> >= </select> <input type="text" bean="RepositorySearchForm.SearchAttributes[1].Values" value=""> </td> <input type="submit" bean="RepositorySearchForm.Search" value="Search"> </FORM>
Field Summary | |
---|---|
protected static int |
CATALOG_SEARCH_METHOD
|
protected static java.lang.String |
CATALOG_SEARCH_PROPERTY
|
protected static java.lang.String |
CATALOG_SEARCH_RELATION
|
protected static java.lang.String |
CATALOG_SEARCH_VIEWNAME
|
static java.lang.String |
CLASS_VERSION
Class version string |
protected static int |
PROFILE_SEARCH_METHOD
|
protected static java.lang.String |
PROFILE_SEARCH_PROPERTY
|
protected static java.lang.String |
PROFILE_SEARCH_VIEWNAME
|
Fields inherited from class atg.commerce.csr.search.SearchFormHandler |
---|
OUTPUT, SEARCHFORMRESOURCES, sResourceBundle |
Fields inherited from class atg.droplet.GenericFormHandler |
---|
PARAM_DEFER_FORWARD_OR_REDIRECT, PARAM_USE_FORWARDS |
Fields inherited from class atg.nucleus.GenericService |
---|
SERVICE_INFO_KEY |
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging |
---|
DEFAULT_LOG_TRACE_STATUS |
Fields inherited from interface atg.nucleus.logging.ApplicationLogging |
---|
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS |
Constructor Summary | |
---|---|
OrderSearchFormHandler()
|
Method Summary | |
---|---|
protected atg.repository.Repository |
findLocaleCatalogRepository(atg.servlet.DynamoHttpServletRequest request)
------------------------------------- findLocaleRepository Use user's current locale to find the right catalog repository to search |
protected atg.repository.Query |
generateRepositorySearchQuery(atg.servlet.DynamoHttpServletRequest request,
atg.servlet.DynamoHttpServletResponse response,
SearchAttribute[] pSearchAttributes,
SearchAttribute pOrderSearchAttribute,
atg.repository.Repository pRepository,
java.lang.String pViewName)
generate the order search Query on order related repository (profile or catalog) |
protected atg.repository.Query |
generateSearchQuery(atg.servlet.DynamoHttpServletRequest request,
atg.servlet.DynamoHttpServletResponse response)
generate the search Query |
atg.repository.Repository |
getCatalogRepository()
Returns Catalog Repository which is being queried |
SearchAttribute |
getCatalogSearchAttribute(int pIndex)
Returns Catalog SearchAttribute by which the search is done |
SearchAttribute[] |
getCatalogSearchAttributes()
Returns Catalog SearchAttributes by which the search is done |
atg.commerce.catalog.CatalogTools |
getCatalogTools()
Returns property catalogTools. |
int |
getMaxProfileResults()
|
atg.repository.Repository |
getProfileRepository()
Returns profile Repository which is being queried |
SearchAttribute |
getProfileSearchAttribute(int pIndex)
Returns SearchAttribute by which the search is done |
SearchAttribute[] |
getProfileSearchAttributes()
Returns SearchAttributes by which the search is done |
boolean |
getSearchOnCatalog()
Returns mSearchOnCatalog |
boolean |
getSearchOnProfile()
Returns mSearchOnProfile |
void |
setCatalogRepository(atg.repository.Repository pRepository)
Sets Catalog Repository which is being queried |
void |
setCatalogSearchableAttributeNum(int pCatalogSearchableAttributeNum)
Sets property mCatalogSearchableAttributeNum |
void |
setCatalogSearchAttribute(int pIndex,
SearchAttribute pSearchAttribute)
Sets Catalog SearchAttribute by which the search is done |
void |
setCatalogSearchAttributes(SearchAttribute[] pSearchAttributes)
Sets SearchAttributes by which the search is done |
void |
setCatalogTools(atg.commerce.catalog.CatalogTools pCatalogTools)
Sets property catalogTools. |
void |
setMaxProfileResults(int maxProfileResults)
|
void |
setProfileRepository(atg.repository.Repository pRepository)
Sets profile Repository which is being queried |
void |
setProfileSearchableAttributeNum(int pProfileSearchableAttributeNum)
Sets property mProfileSearchableAttributeNum |
void |
setProfileSearchAttribute(int pIndex,
SearchAttribute pSearchAttribute)
Sets ProfileSearchAttribute by which the search is done |
void |
setProfileSearchAttributes(SearchAttribute[] pSearchAttributes)
Sets SearchAttributes by which the search is done |
void |
setSearchOnCatalog(boolean pSearchOnCatalog)
Sets mSearchOnCatalog |
void |
setSearchOnProfile(boolean pSearchOnProfile)
Sets mSearchOnProfile |
protected boolean |
validateSearchCriteria(atg.servlet.DynamoHttpServletRequest pRequest,
atg.servlet.DynamoHttpServletResponse pResponse)
validateSearchCriteria |
Methods inherited from class atg.droplet.GenericFormHandler |
---|
addFormException, addUncheckedFormException, afterSet, beforeSet, checkFormRedirect, createFormSubmissionMessage, getCheckForValidSession, getFormError, getFormExceptions, getFormName, getMessagePort, getMessageSource, getMessageType, getPropertyExceptions, getSendMessages, getUncheckedFormExceptions, handleCancel, handleFormException, handleUncheckedFormException, hasUncheckedFormExceptions, isDeferForwardsAndRedirects, isRestorableForm, isUseForwards, isValidSession, redirectOrForward, resetFormExceptions, setCheckForValidSession, setDeferForwardsAndRedirects, setFormName, setMessagePort, setMessageSource, setMessageType, setRestorableForm, setSendMessages, setUseForwards |
Methods inherited from class atg.droplet.EmptyFormHandler |
---|
afterGet, beforeGet |
Methods inherited from class atg.nucleus.GenericService |
---|
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.servlet.Servlet |
---|
destroy, getServletConfig, getServletInfo, init, service |
Field Detail |
---|
public static final java.lang.String CLASS_VERSION
protected static final java.lang.String PROFILE_SEARCH_PROPERTY
protected static final int PROFILE_SEARCH_METHOD
protected static final java.lang.String PROFILE_SEARCH_VIEWNAME
protected static final java.lang.String CATALOG_SEARCH_PROPERTY
protected static final int CATALOG_SEARCH_METHOD
protected static final java.lang.String CATALOG_SEARCH_RELATION
protected static final java.lang.String CATALOG_SEARCH_VIEWNAME
Constructor Detail |
---|
public OrderSearchFormHandler()
Method Detail |
---|
public void setProfileRepository(atg.repository.Repository pRepository)
pRepository
- the order Repository which is being queriedpublic atg.repository.Repository getProfileRepository()
public void setSearchOnProfile(boolean pSearchOnProfile)
pSearchOnProfile
- boolean determining whether to search on a profilepublic boolean getSearchOnProfile()
public void setCatalogRepository(atg.repository.Repository pRepository)
pRepsoitory
- the Catalog Repository which is being queriedpublic atg.repository.Repository getCatalogRepository()
public void setSearchOnCatalog(boolean pSearchOnCatalog)
pSearchOnCatalog
- a boolean determining whether to search the catalog repositorypublic boolean getSearchOnCatalog()
public void setProfileSearchAttributes(SearchAttribute[] pSearchAttributes)
pSearchAttributes
- the SearchAttributes by which the search is donepublic SearchAttribute[] getProfileSearchAttributes()
public void setProfileSearchAttribute(int pIndex, SearchAttribute pSearchAttribute)
public SearchAttribute getProfileSearchAttribute(int pIndex)
public void setCatalogSearchAttributes(SearchAttribute[] pSearchAttributes)
pSearchAttributes
- the SearchAttributes by which the search is donepublic SearchAttribute[] getCatalogSearchAttributes()
public void setCatalogSearchAttribute(int pIndex, SearchAttribute pSearchAttribute)
public SearchAttribute getCatalogSearchAttribute(int pIndex)
public void setCatalogTools(atg.commerce.catalog.CatalogTools pCatalogTools)
pCatalogTools
- the property to store the global service catalog tools factory to obtain the catalog to search in.public atg.commerce.catalog.CatalogTools getCatalogTools()
public void setCatalogSearchableAttributeNum(int pCatalogSearchableAttributeNum)
pCatalogSearchableAttributeNum
- the property to storepublic void setProfileSearchableAttributeNum(int pProfileSearchableAttributeNum)
mProfileSearchableAttributeNum
- the property to storeprotected atg.repository.Repository findLocaleCatalogRepository(atg.servlet.DynamoHttpServletRequest request)
request
-
protected atg.repository.Query generateSearchQuery(atg.servlet.DynamoHttpServletRequest request, atg.servlet.DynamoHttpServletResponse response) throws javax.servlet.ServletException, java.io.IOException
generateSearchQuery
in class SearchFormHandler
request
- response
-
javax.servlet.ServletException
java.io.IOException
protected atg.repository.Query generateRepositorySearchQuery(atg.servlet.DynamoHttpServletRequest request, atg.servlet.DynamoHttpServletResponse response, SearchAttribute[] pSearchAttributes, SearchAttribute pOrderSearchAttribute, atg.repository.Repository pRepository, java.lang.String pViewName) throws javax.servlet.ServletException, java.io.IOException
request
- response
- pSearchAttributes
- pOrderSearchattribute
- pRepository
- pViewName
-
javax.servlet.ServletException
java.io.IOException
protected boolean validateSearchCriteria(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse) throws javax.servlet.ServletException, java.io.IOException
validateSearchCriteria
in class SearchFormHandler
request
- response
-
javax.servlet.ServletException
java.io.IOException
public int getMaxProfileResults()
public void setMaxProfileResults(int maxProfileResults)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |