|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object atg.nucleus.logging.VariableArgumentApplicationLoggingImpl atg.nucleus.GenericService atg.commerce.util.ContextValueRetriever
public class ContextValueRetriever
Determines the appropriate value for a profile property based on a site, and possibly what is already in the profile. Example uses of this class include determining the catalog or price list to use for a storefront page request or a call center agent helping the shopper associated with the profile.
For a multisite application that gets profile settings from the current site,
configure useProfile
to false
. For an application
that sets profile values at registration time, for example,
configure useProfile
to true
.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string |
protected boolean |
mUseProfile
|
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 | |
---|---|
ContextValueRetriever()
|
Method Summary | |
---|---|
boolean |
isUseProfile()
Indicates if profile properties have already been set to their correct values or should be assumed to be unreliable. |
RepositoryItem |
retrieveValue(atg.commerce.util.ContextValueRetrieverArguments pArguments)
Determine the appropriate value for one profile property based on information provided in an arguments object. |
void |
setUseProfile(boolean pUseProfile)
Sets property useProfile |
boolean |
shouldUseProfile(RepositoryItem pProfile)
Indicates if profile properties have already been set to their correct values or should be ignored. |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, 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 |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
protected boolean mUseProfile
Constructor Detail |
---|
public ContextValueRetriever()
Method Detail |
---|
public boolean isUseProfile()
public void setUseProfile(boolean pUseProfile)
public RepositoryItem retrieveValue(atg.commerce.util.ContextValueRetrieverArguments pArguments) throws RepositoryException
Customers who need different logic for different profile properties (e.g., catalogs vs. price lists) should configure additional instances of the ContextValueRetriever component and reconfigure references to the original component.
pArguments
- an object containing properties that define possible sources for the value
to be retrieved
RepositoryException
public boolean shouldUseProfile(RepositoryItem pProfile)
useProfile
property. Override this method to make a determination
based on information stored in the profile.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |