|
||||||||||
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.commerce.catalog.CatalogTools
atg.commerce.catalog.custom.CustomCatalogTools
atg.projects.store.catalog.StoreCatalogTools
public class StoreCatalogTools
The extensions to ootb CatalogTools. At the time of its writing, all it contained were the ids of the Store catalog and the corresponding repository items.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string. |
Fields inherited from class atg.commerce.catalog.CatalogTools |
---|
DEFAULT_CATEGORY_ITEM_TYPE, DEFAULT_PRODUCT_ITEM_TYPE, DEFAULT_SKU_ITEM_TYPE |
Fields inherited from class atg.nucleus.GenericService |
---|
SERVICE_INFO_KEY |
Fields inherited from interface atg.commerce.catalog.CMSConstants |
---|
AGS_GENANCESTORS, AGS_GENCATALOGS, AGS_GENPARENTCATS, ANCESTORS_GENERATED, CATALOGS_UPDATED, CATALOGS_VERIFIED, CATEGORIES_VERIFIED, CUS_INVALID_PARENT_BRANCH, CUS_NAME_ALREADY_IN_USE, CUS_UNABLE_TO_GET_WS, CUS_UPDATECATALOGS, CUS_USING_CHECKED_IN_WS, CUS_VM_NOT_SET, CUS_WS_NOT_CREATED, CUS_WS_NOT_CREATED_INVALID_PARENT_BRANCH, CUS_WS_REQUIRED, CVS_VERIFYCATALOGS, CVS_VERIFYCATEGORIES, CVS_VERIFYPRODUCTS, CVS_VERIFYSKUS, DEFAULT_CATALOG_ITEM_TYPE, DEFAULT_MAP_SIZE, GENERATED_ANCESTORS, INFOS_GENERATED, IS_ANCESTORS_GENERATED, LEVEL_DEBUG, LEVEL_ERROR, LEVEL_INFO, LEVEL_WARNING, MY_RESOURCE_NAME, NO_PATH, NOT_GENERATOR, sResourceBundle, TYPE_ANCESTOR, TYPE_CATALOGMAINTENANCE, TYPE_CUSTOM_MIGRATION, TYPE_MIGRATION, TYPE_UPDATE, TYPE_VERIFY, VALID_PATH |
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 | |
---|---|
StoreCatalogTools()
|
Method Summary | |
---|---|
void |
doStartService()
The E-commerce catalog id is set in a property file. |
atg.repository.RepositoryItem |
findSku(java.util.Collection pSkus,
java.lang.String pColor,
java.lang.String pSize)
Finds the sku with the matching color and size. |
atg.repository.RepositoryItem |
getCatalog(java.lang.String pCatalogId)
Get the catalog with the given id. |
java.util.List |
getPossibleColors(java.util.Collection pSkus)
Returns a list of possible colors for a collection of skus. |
java.util.Map |
getPossibleColorSwatches(java.util.Collection pSkus)
Creates a map of color names to swatch items. |
java.util.List |
getPossibleSizes(java.util.Collection pSkus)
Returns the list of possible sizes for a given collection of skus. |
java.util.List |
getPossibleValuesForSkus(java.util.Collection pSkus,
java.lang.String pPropertyName)
Returns the list of possible values for a given collection of skus. |
java.util.Collection |
getProductChildSkus(atg.repository.RepositoryItem pProduct)
Returns a product's child skus. |
java.lang.String |
getRootNavigationCategoryId()
|
java.lang.String[] |
getSizeSortOrder()
|
atg.repository.RepositoryItem |
getStoreCatalog()
|
java.lang.String |
getStoreCatalogId()
|
void |
setRootNavigationCategoryId(java.lang.String pRootNavigationCategoryId)
|
void |
setSizeSortOrder(java.lang.String[] pSizeSortOrder)
|
void |
setStoreCatalog(atg.repository.RepositoryItem item)
|
void |
setStoreCatalogId(java.lang.String pStoreCatalogId)
|
java.util.List |
sortColors(java.util.List pColors)
Sorts a list of colors. |
java.util.List |
sortSizes(java.util.List pSizes)
Sorts sizes accoring to the configured template. |
java.util.List |
sortStrings(java.util.List pStrings,
java.lang.String[] pSortOrder)
Sorts the collection of strings relative to their ordinal position in the sort order array. |
Methods inherited from class atg.commerce.catalog.custom.CustomCatalogTools |
---|
computeRecursedRootSubCatalogs, filterCollectionByCatalog, findCatalogItem, findCatalogItem, findCatalogItems, findCatalogItems, findCategories, findCategories, findCategories, findCategories, findCategory, findCategory, findCategory, findCategory, findProduct, findProduct, findProduct, findProduct, findProducts, findProducts, findProducts, findProducts, findSKU, findSKU, findSKU, findSKU, findSKUs, findSKUs, findSKUs, findSKUs, getAllAncestorCategories, getAncestors, getAncestors, getBaseCatalogItemType, getCatalogBeanInfos, getCatalogItemTypes, getCatalogProperties, getCatalogsContainingThisCatalog, getCatalogsForRepository, getCatalogsProperty, getCatalogsThatIncludeCatalogInRootSubCatalogs, getCatalogsWithCategoryAsRoot, getCategoriesContainingThisCatalog, getCategoriesContainingThisCategorysCatalog, getCategoriesInCatalog, getCategoriesWithCatalogAsSubCatalog, getCategoriesWithIndirectPathToCatalog, getCategoriesWithIndirectPathToCategory, getCategorysInfoMapProperty, getCurrentCatalog, getParentCategories, getProductsCategories, getProductsInfoMapProperty, getProfileCatalogPropertyName, getRootCategoriesForCatalog, getSkusInfoMapProperty, getStatePropertyName, getTrackState, getTransactionManager, isCategoryReferenced, isReturnEmptyResults, isSaveCachedAncestors, setBaseCatalogItemType, setCatalogItemTypes, setCatalogProperties, setCatalogsProperty, setCategorysInfoMapProperty, setProductsInfoMapProperty, setProfileCatalogPropertyName, setReturnEmptyResults, setSaveCachedAncestors, setSkusInfoMapProperty, setState, setState, setStatePropertyName, setTrackState, setTransactionManager, verifyCatalog, verifyCatalog |
Methods inherited from class atg.commerce.catalog.CatalogTools |
---|
findCatalog, getAlternateCatalogs, getBaseCategoryItemType, getBaseMediaItemType, getBaseProductItemType, getBaseSKUItemType, getBeanInfo, getCatalog, getCatalogServiceLockName, getCatalogServiceLockTimeOut, getCategoryBeanInfos, getCategoryItemTypes, getParentCategoryPropertyName, getProductBeanInfos, getProductItemTypes, getSKUBeanInfos, getSKUItemTypes, getTypeInfo, isProduct, isUseDefaultCatalog, setAlternateCatalogs, setBaseCategoryItemType, setBaseMediaItemType, setBaseProductItemType, setBaseSKUItemType, setCatalog, setCatalogServiceLockName, setCatalogServiceLockTimeOut, setCategoryItemTypes, setParentCategoryPropertyName, setProductItemTypes, setSKUItemTypes, setUseDefaultCatalog |
Methods inherited from class atg.nucleus.GenericService |
---|
addLogListener, createAdminServlet, 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 |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public StoreCatalogTools()
Method Detail |
---|
public java.lang.String getRootNavigationCategoryId()
public void setRootNavigationCategoryId(java.lang.String pRootNavigationCategoryId)
pRootNavigationCategoryId
- - new RootNavigationCategoryId.public java.lang.String[] getSizeSortOrder()
public void setSizeSortOrder(java.lang.String[] pSizeSortOrder)
pSizeSortOrder
- The SizeSortOrder used for displaying sizes.public java.lang.String getStoreCatalogId()
public void setStoreCatalogId(java.lang.String pStoreCatalogId)
pStoreCatalogId
- - The Store Catalog Id.public atg.repository.RepositoryItem getStoreCatalog()
public void setStoreCatalog(atg.repository.RepositoryItem item)
item
- - The StoreCatalog.public void doStartService() throws atg.nucleus.ServiceException
The E-commerce catalog id is set in a property file. The doStartService verifies that the catalog id does indeed refer to actual catalog in the repository.
doStartService
in class atg.commerce.catalog.CatalogTools
atg.nucleus.ServiceException
- if error occurspublic atg.repository.RepositoryItem getCatalog(java.lang.String pCatalogId) throws atg.repository.RepositoryException
pCatalogId
- - catalog id
atg.repository.RepositoryException
- if error occurspublic java.util.List getPossibleColors(java.util.Collection pSkus)
pSkus
- collection of skus
public java.util.Map getPossibleColorSwatches(java.util.Collection pSkus)
pSkus
- - sku collection
public java.util.List getPossibleSizes(java.util.Collection pSkus)
pSkus
- collection of skus
public java.util.List getPossibleValuesForSkus(java.util.Collection pSkus, java.lang.String pPropertyName)
pSkus
- collection of skuspPropertyName
- the property name of the sku to use.
public atg.repository.RepositoryItem findSku(java.util.Collection pSkus, java.lang.String pColor, java.lang.String pSize)
pSkus
- collection of skuspColor
- - color namepSize
- - size name
public java.util.Collection getProductChildSkus(atg.repository.RepositoryItem pProduct)
pProduct
- - product
public java.util.List sortColors(java.util.List pColors)
pColors
- - list of pColors
public java.util.List sortSizes(java.util.List pSizes)
pSizes
- - list of sizes
getSizeSortOrder()
public java.util.List sortStrings(java.util.List pStrings, java.lang.String[] pSortOrder)
pStrings
- a collection of strings to sortpSortOrder
- the string array of possible values and their relative order.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |