|
|||||||||
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.catalog.custom.CatalogCompletionService
public class CatalogCompletionService
This service performs incremental maintenance on the catalog system
after changes have been made to the catalog structure in the UI. Methods
are called from CatalogChangesListener
when a catalog is
created or when a catalog or category is added or removed as a child from
another category or catalog. Properties computed by this service:
catalog.directAncestorCatalogsAndSelf
catalog.allRootCategories
catalog.indirectAncestorCatalogs
catalog.ancestorCategories
category.parentCategory
category.parentCatalog
Optionally, catalog.subCatalogs will be maintained
CatalogChangesListener
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string |
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 | |
---|---|
CatalogCompletionService()
|
Method Summary | |
---|---|
void |
addCatalogToCatalog(MutableRepositoryItem pParentCatalog,
MutableRepositoryItem pChildCatalog)
This method performs the operations related to adding a catalog to another catalog's rootSubCatalogs. |
void |
addCatalogToCategory(MutableRepositoryItem pCategory,
MutableRepositoryItem pCatalog)
This method performs the operations related to adding a catalog to a category's subCatalogs. |
void |
addCategoryToCatalog(MutableRepositoryItem pCatalog,
MutableRepositoryItem pCategory)
This method performs the operations related to adding a category to a catalog's rootCategories. |
void |
addCategoryToCategory(MutableRepositoryItem pParentCategory,
MutableRepositoryItem pChildCategory)
This method performs the operations related to adding a category to another category's fixedChildCategories. |
void |
createCatalog(MutableRepositoryItem pCatalog)
This method performs the operations related to the creation of a catalog. |
CatalogProperties |
getCatalogProperties()
A helper class that holds commonly accessed reposority property and item names |
MutableRepository |
getCatalogRepository()
Returns property catalogRepository |
CustomCatalogTools |
getCatalogTools()
Returns property catalogTools |
javax.transaction.TransactionManager |
getTransactionManager()
The beginning and ending of transactions are handled by the transaction manager. |
boolean |
isComputeSubCatalogs()
Returns property computeSubCatalogs |
boolean |
isEnabled()
Returns property enabled, which indicates if this service should compute any properties. |
void |
removeCatalogFromCatalog(MutableRepositoryItem pParentCatalog,
MutableRepositoryItem pChildCatalog)
This method performs the operations related to removing a catalog from another catalog's rootSubCatalogs. |
void |
removeCatalogFromCategory(MutableRepositoryItem pCategory,
MutableRepositoryItem pCatalog)
This method performs the operations related to removing a catalog from a category's subCatalogs. |
void |
removeCategoryFromCatalog(MutableRepositoryItem pCatalog,
MutableRepositoryItem pCategory)
This method performs the operations related to removing a category from a catalog's rootCategories. |
void |
removeCategoryFromCategory(MutableRepositoryItem pParentCategory,
MutableRepositoryItem pChildCategory)
This method performs the operations related to removing a category from another category's fixedChildCategories. |
void |
setCatalogProperties(CatalogProperties pCatalogProperties)
|
void |
setCatalogRepository(MutableRepository pCatalogRepository)
Sets the GSA repository instance to modify. |
void |
setCatalogTools(CustomCatalogTools pCatalogTools)
Sets the instance of CatalogTools to be used |
void |
setComputeSubCatalogs(boolean pComputeSubCatalogs)
Sets boolean property indicating whether to compute the catalogs' subCatalogs property. |
void |
setEnabled(boolean pEnabled)
Sets boolean indicating if this service should compute any properties |
void |
setTransactionManager(javax.transaction.TransactionManager pTransactionManager)
|
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 |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public CatalogCompletionService()
Method Detail |
---|
public void setTransactionManager(javax.transaction.TransactionManager pTransactionManager)
public javax.transaction.TransactionManager getTransactionManager()
public void setCatalogProperties(CatalogProperties pCatalogProperties)
public CatalogProperties getCatalogProperties()
public void setCatalogTools(CustomCatalogTools pCatalogTools)
public CustomCatalogTools getCatalogTools()
public void setCatalogRepository(MutableRepository pCatalogRepository)
public MutableRepository getCatalogRepository()
public void setComputeSubCatalogs(boolean pComputeSubCatalogs)
public boolean isComputeSubCatalogs()
public void setEnabled(boolean pEnabled)
public boolean isEnabled()
public void addCategoryToCatalog(MutableRepositoryItem pCatalog, MutableRepositoryItem pCategory) throws RepositoryException, MultipleCatalogException
pCatalog
- - The repository item representing the parent catalogpCategory
- - The repository item representing the child category
RepositoryException
- if there is an error in any of the property
changes
MultipleCatalogException
- if the category already exists in a different
catalogpublic void addCatalogToCatalog(MutableRepositoryItem pParentCatalog, MutableRepositoryItem pChildCatalog) throws RepositoryException, CatalogLoopException
pParentCatalog
- - The repository item representing the parent catalogpChildCatalog
- - The repository item representing the child catalog
RepositoryException
- if there is an error in any of the property
changes
CatalogLoopException
- if the operation creates a situation where a
catalog is an ancestor of itselfpublic void addCatalogToCategory(MutableRepositoryItem pCategory, MutableRepositoryItem pCatalog) throws RepositoryException, CatalogLoopException
pCategory
- - The repository item representing the parent category.pCatalog
- - The repository item representing the child catalog.
RepositoryException
- if there is an error in any of the property
changes
CatalogLoopException
- if the operation creates a situation where a
catalog is an ancestor of itselfpublic void addCategoryToCategory(MutableRepositoryItem pParentCategory, MutableRepositoryItem pChildCategory) throws RepositoryException, MultipleCatalogException
pParentCategory
- - The repository item representing the parent category.pChildCategory
- - The repository item representing the child category.
RepositoryException
- if there is an error in any of the property
changes
MultipleCatalogException
- if the category already exists in a different
catalogpublic void removeCategoryFromCatalog(MutableRepositoryItem pCatalog, MutableRepositoryItem pCategory) throws RepositoryException
pCatalog
- - The repository item representing the former parent catalogpCategory
- - The repository item representing the former child category
RepositoryException
- if there is an error in any of the property
changespublic void removeCatalogFromCatalog(MutableRepositoryItem pParentCatalog, MutableRepositoryItem pChildCatalog) throws RepositoryException
pParentCatalog
- - The repository item representing the former parent
catalog.pChildCatalog
- - The repository item representing the former child catalog.
RepositoryException
- if there is an error in any of the property changespublic void removeCatalogFromCategory(MutableRepositoryItem pCategory, MutableRepositoryItem pCatalog) throws RepositoryException
pCategory
- - The repository item representing the former parent categorypCatalog
- - The repository item representing the former child catalog
RepositoryException
- if there is an error in any of the property changespublic void removeCategoryFromCategory(MutableRepositoryItem pParentCategory, MutableRepositoryItem pChildCategory) throws RepositoryException
pParentCategory
- - The repository item representing the former parent
categorypChildCategory
- - The repository item representing the former child
category
RepositoryException
- if there is an error in any of the property changespublic void createCatalog(MutableRepositoryItem pCatalog) throws RepositoryException
pCatalog
- - The repository item representing the newly created catalog
RepositoryException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |