java.lang.Objectcom.ibm.ivj.ejb.runtime.AbstractEntityAccessBean
com.ibm.commerce.common.objects.StoreAccessBean
com.ibm.commerce.common.beans.StoreDataBean
This data bean represents a Store
Field Summary | |
static java.lang.String | COPYRIGHT Copyright |
static java.lang.String | URL_PATH_SEPARATOR The URL separator |
Constructor Summary | |
StoreDataBean() Creates an empty StoreDataBean. |
|
StoreDataBean(StoreAccessBean abStore) Creates a StoreDataBean from a StoreAccessBean |
Method Summary | |
CommandContext | getCommandContext() Gets the command context set within this bean. |
StoreEntityDescriptionAccessBean | getDescription(java.lang.Integer aLanguageId) Gets the store description access bean for the specified language. |
java.lang.String | getFilePath() Returns the path that has to be prepended to the front of a static assets for a store |
java.lang.String | getFilePath(java.lang.String filename) Returns the path that has to be prepended to the front of a static assets for a store. |
java.lang.String | getJspPath() Returns the path that has to be prepended to the front of a store related JSP |
java.lang.String | getJspPath(java.lang.String filename) Returns the path that has to be prepended to the front of a store related JSP. |
java.lang.String | getJspStoreDirFilePath() Returns the path that has to be prepended to the front of a static assets for a store |
CatalogAccessBean | getMasterCatalog() Gets the master catalog access bean for the store. |
TypedProperty | getRequestProperties() Gets the request property set within this bean. |
java.util.ResourceBundle | getResourceBundle(java.lang.String resourceName) Gets a property resource bundle from a store directory. |
java.util.ResourceBundle | getResourceBundle(java.lang.String resourceName, java.lang.Integer languageId) Gets a property resource bundle from a store directory. |
CatalogDataBean[] | getStoreCatalogs() Returns a list of beans that represent catalogs in the store |
static java.lang.String | getStoreContextPath() Returns the context path for the store servlet. |
java.lang.String | getStoreId() Gets the store ID that represents the primary key for this store |
void | populate() Fetches and populates information needed by the bean. |
void | setCommandContext(CommandContext commandContext) Sets the command context within this bean. |
void | setFilePath(java.lang.String filePath) Sets the path for static resources |
void | setJspPath(java.lang.String jspPath) Sets the path for jsps. |
void | setRequestProperties(TypedProperty requestProperty) Sets the request property within this bean. |
void | setStoreId(java.lang.String storeId) Sets the store ID that represents the primary key for this store |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String COPYRIGHT
public static final java.lang.String URL_PATH_SEPARATOR
Constructor Detail |
public StoreDataBean()
public StoreDataBean(StoreAccessBean abStore) throws java.rmi.RemoteException, javax.ejb.FinderException, javax.naming.NamingException, javax.ejb.CreateException
Method Detail |
public CommandContext getCommandContext()
public java.lang.String getFilePath() throws java.lang.Exception
public java.lang.String getFilePath(java.lang.String filename) throws java.lang.Exception
If a file is added/removed/changed in a store directory, and the store has 'com.ibm.commerce.view' store relationships, then the StoreRegistry for the corresponding store must be refreshed before retrieving the resource using this method.
If an alias for the store is defined, this method will return the store alias followed by the store directory as the file path. If the alias is not defined, it will just return the store directory.
If the store does not have any active 'com.ibm.commerce.view' store relationships, then this store's directory is used in the path. Otherwise, if the file exists in this store's public directory, then this store's directory is used in the path. Otherwise, the store directory in the request properties is used in the path.
e.g. If the store alias is "storeAlias", and the store directory is "storeDir", and this store has no 'com.ibm.commerce.view' store relationships, the result is "/storeAlias/storeDir/filename".
e.g. If the store alias is "storeAlias", and the store directory is "storeDir", and this store has the 'com.ibm.commerce.view' store relationships, and the file does not exist in this store's directory, and the request properties has a ECConstants.EC_JSP_STORE_DIR parameter value "jspStoreDir", then the result is "/storeAlias/jspStoreDir/filename"
public java.lang.String getJspPath() throws java.lang.Exception
public java.lang.String getJspPath(java.lang.String filename) throws java.lang.Exception
If a JSP is added/removed/changed in a store directory, and the store has 'com.ibm.commerce.view' store relationships, then the StoreRegistry for the corresponding store must be refreshed before retrieving the resource using this method.
If the store does not have any active 'com.ibm.commerce.view' store relationships, then this store's directory is used in the path. Otherwise, if the file exists in this store's public directory, then this store's directory is used in the path. Otherwise, the store directory in the request properties is used in the path.
e.g. If the store directory is "storeDir", and this store has no 'com.ibm.commerce.view' store relationships, the result is "/storeDir/filename".
e.g. If the store directory is "storeDir", and this store has the 'com.ibm.commerce.view' store relationships, and the file does not exist in this store's directory, and the request properties has a ECConstants.EC_JSP_STORE_DIR parameter value "jspStoreDir", then the result is "/jspStoreDir/filename"
public java.lang.String getJspStoreDirFilePath() throws java.lang.Exception
The jspStoreDir request attribute value is used when building this path.
public java.util.ResourceBundle getResourceBundle(java.lang.String resourceName) throws ECException
If a properties file is added/removed/changed in a store directory, then the StoreRegistry for the corresponding store must be refreshed before retrieving the resource using this method.
The store path for the 'com.ibm.commerce.view' relationship type is used as the basis for the search of the resource.
For each store, the search consists of searching for ".properties" files with the locale as set in the command context. If a file with the command context locale cannot be found, then a file with no locale is searched for.
eg. The command context locale is "en_US", and there are two stores in the store path with directories "storeA" and "storeB". The search order is:
storeA/resourceName_en_US.properties storeA/resourceName.properties storeB/resourceName_en_US.properties storeB/resourceName.properties
public java.util.ResourceBundle getResourceBundle(java.lang.String resourceName, java.lang.Integer languageId) throws ECException
If a properties file is added/removed/changed in a store directory, then the StoreRegistry for the corresponding store must be refreshed before retrieving the resource using this method.
The store path for the 'com.ibm.commerce.view' relationship type is used as the basis for the search of the resource.
For each store, the search consists of searching for ".properties" files with the locale as set in the command context. If a file with the locale of the specified language cannot be found, then a file with no locale is searched for.
eg. The locale for the specified language id is "en_US", and there are two stores in the store path with directories "storeA" and "storeB". The search order is:
storeA/resourceName_en_US.properties storeA/resourceName.properties storeB/resourceName_en_US.properties storeB/resourceName.properties
public TypedProperty getRequestProperties()
public CatalogDataBean[] getStoreCatalogs() throws ECException
public java.lang.String getStoreId()
public void populate() throws java.lang.Exception
public void setCommandContext(CommandContext commandContext)
public void setFilePath(java.lang.String filePath)
public void setJspPath(java.lang.String jspPath)
public void setRequestProperties(TypedProperty requestProperty) throws ECException
public void setStoreId(java.lang.String storeId)
public static java.lang.String getStoreContextPath() throws java.lang.Exception
public StoreEntityDescriptionAccessBean getDescription(java.lang.Integer aLanguageId) throws javax.naming.NamingException, javax.ejb.CreateException, javax.ejb.FinderException, java.rmi.RemoteException
public CatalogAccessBean getMasterCatalog() throws javax.naming.NamingException, java.rmi.RemoteException, javax.ejb.FinderException
(C) Copyright IBM Corporation 1996, 2005. All Rights Reserved.