public interface VariantProducer
A variant producer may be invoked from multiple threads at once, so should not keep any state information except in the Context object.
Created: May 09 2005
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
prepareNextVariant(Context pContext,
java.lang.String pPropertyName,
RepositoryItem pItem,
int pIndex,
java.util.Map pUniqueParams)
Prepare for the next (perhaps only) variant.
|
static final java.lang.String CLASS_VERSION
boolean prepareNextVariant(Context pContext, java.lang.String pPropertyName, RepositoryItem pItem, int pIndex, java.util.Map pUniqueParams)
pIndex is 0). Implementations
typically use the pIndex parameter to determine which
variant to produce.pContext - The current context. Contains the current URL,
the stack of parent items, etc.pPropertyName - the name of the property that corresponds
to pItem. For a top-level item, will be null.pItem - the document-level (is-document) repository item.pIndex - the index/count for the variant. The first
time the prepareNextVariant() is invoked for a RepositoryItem
for a given parent, pIndex will be zero. As long as
this method returns true, prepareNextVariant will
be invoked again, with pIndex incremented.pUniqueParams - the parameters that will be added
to the item's URI to differentiate it from
other documents representing the same repository item.
Keys and values should all be strings.