|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.elasticpath.domain.impl.ElasticPathImpl
public class ElasticPathImpl
This class provides elastic path configurations and context to others.
| Method Summary | |
|---|---|
void |
clearAllAttributeRanges()
Clears all attribute range information, including bottom level attribute ranges. |
void |
clearAllAttributeSimpleValues()
Clears all attribute simple value information. |
void |
clearAllPriceRanges()
Clears all price range information, including bottom level price ranges. |
java.lang.String |
get(java.lang.String name)
Return the value of a string property with the specified name from the dyanamic property map. |
java.lang.String |
get(java.lang.String name,
java.lang.String defaultValue)
Return the value of a string property with the specified name. |
float |
getAccuracy()
Returns the degree of similarity that a word must have to the original word in order to be suggested. |
java.util.Map |
getAll()
Return name and values of all properties as a map. |
java.util.Map |
getAllAttributeRanges()
Returns all defined attribute ranges as a Map. |
java.util.Map |
getAllAttributeSimpleValues()
Returns all defined attribute simple value filters as a Map. |
java.util.Map |
getAllAttributesMap()
This map contains all the attribute defined in the guided-navigation.xml. |
java.util.Map |
getAllCurrencies()
Return all supported currencies. |
java.util.Map |
getAllLocales()
Get a map of all supported locales. |
java.util.Map |
getAllPriceRanges()
Returns all defined price ranges as a Map. |
java.util.List |
getAllShipmentCarriers()
Return all supported shipment carrier. |
java.util.SortedMap |
getAttributeSimpleValuesMap(java.lang.String attributeCode)
Returns attribute ranges of the given attributeCode, which are defined at bottom level of the attribute-range-tree. |
java.lang.Object |
getBean(java.lang.String name)
Get the bean with the given id from spring ContextBeanFactory. |
java.util.Map |
getBoolMap()
Returns a map used by Spring/Velocity for checkboxes. |
java.util.SortedMap |
getBottomLevelAttributeRanges(java.lang.String attributeCode)
Returns attribute ranges of the given attributeCode, which are defined at bottom level of the attribute-range-tree. |
java.util.SortedMap |
getBottomLevelPriceRanges(java.util.Currency currency)
Returns price ranges of the given currency, which are defined at bottom level of the price-range-tree. |
java.lang.String |
getCatalogAssetPath()
Return the absolute asset directory path. |
int |
getCatalogViewPagination()
Return the catalog view pagination. |
CheckoutTransactionBehaviour |
getCheckoutTransactionBehaviour()
Return the CheckoutTransactionBehaviour object that defines how a checkout transaction is to be processed. |
java.lang.String |
getCmContextUrl()
Return the commerce manager context URL. |
java.lang.String |
getContentEncoding()
Returns the content encoding. |
Geography |
getCountries()
Return a Geography that provides geographical information. |
java.util.Map |
getCustomerProfileAttributes()
Returns a map of all customer profile attributes. |
java.sql.DatabaseMetaData |
getDatabaseMetaData()
Return database meta data. |
java.lang.String |
getDatabaseProductName()
Get the databse product name. |
java.lang.String |
getDataFileEncoding()
Returns the data file encoding. |
java.lang.String |
getDefaultCountry()
Returns the default country. |
java.util.Currency |
getDefaultCurrency()
Returns the default currency. |
java.text.SimpleDateFormat |
getDefaultDateFormat()
Returns the default date format. |
java.util.Locale |
getDefaultLocale()
Return the system default locale. |
PrototypeBeanFactory |
getDomainBeanFactory()
Returns PrototypeBeanFactory for domain objects. |
java.lang.String |
getEmailCmUrl()
Return the URL of the Commerce Manager to be used only in email messages. |
java.lang.String |
getEmailStoreUrl()
Return the URL of the store to be used only in email messages. |
java.lang.String |
getEpBuildNo()
Returns the Elastic Path build number. |
java.lang.String |
getEpVersion()
Returns the Elastic Path version number. |
java.lang.String |
getFileAssetPath()
Return the file asset directory path. |
java.lang.String |
getFileAssetSubFolder()
Return the file asset sub folder name. |
Geography |
getGeography()
Return a Geography that provides geographical information. |
java.lang.String |
getImageAssetSubFolder()
Return the image asset sub folder name. |
java.lang.String |
getImagePath()
Return the absolute images directory path. |
java.lang.String |
getImageUrl()
Return the image url. |
static ElasticPath |
getInstance()
Return the singleton ElasticPath. |
float |
getJPEGQuality()
Returns the jpeg quality to use when resizing a jpeg in the dynamic image resizing engine. |
java.util.Map |
getLocaleToLanguageMap()
Get a map of supported locales mapped to their language names. |
int |
getMaximumSuggestions()
Returns the maximum number of suggestions that will be returned with the search results. |
int |
getMaximumSuggestionsPerWord()
Returns the maximum number of suggestions per word that will be generated when generating search suggestions. |
int |
getMaxReturnNumber()
Returns the number of maximum results to return to the search client as the search result. |
java.lang.String |
getMessage(java.lang.String code,
java.lang.Object[] args,
java.lang.String defaultMessage,
java.util.Locale locale)
Gets the localized message. |
java.lang.String |
getMessageDefaultLocale(java.lang.String code,
java.lang.Object[] args,
java.lang.String defaultMessage)
Gets the localized message. |
int |
getMinimumResultsThreshold()
Returns the number of search results that, if not exceeded will trigger the generation of search suggestions. |
float |
getMinimumSimilarity()
Returns the minimum similarity fuzzy search setting, value should be between 0 and 1. |
java.lang.String |
getNoImage()
Returns the image to use when a catalog image does not exist. |
PaymentGateway |
getPaymentGateway(PaymentType paymentType)
Get the payment gateway for the given payment type (e.g. |
int |
getPowerReviewsMerchantId()
Returns the PowerReviews merchant id. |
int |
getPrefixLength()
Returns the fuzzy search setting for the length of common non-fuzzy prefix. |
java.util.Map |
getPropertiesWithNameStartsWith(java.lang.String prefix)
Return name and values of those properties starts with the given string. |
java.lang.String |
getSecureAssetPath()
Return the absolute secure asset (digital goods) directory path. |
java.lang.String |
getSecureAssetSubFolder()
Return the secure asset (digital goods) sub folder name. |
java.lang.String |
getSfContextUrl()
Return the store front context URL. |
int |
getTopSellerCount()
Returns the number of top seller products to display. |
java.lang.String |
getUnitsLength()
Returns the unit measurement of length. |
java.lang.String |
getUnitsWeight()
Returns the unit measurement of weight. |
int |
getUserIdMode()
Return the mode to generate user Id. |
int |
getUserMaintainMode()
Return the user maintenance mode. |
Utility |
getUtility()
Returns the Utility instance. |
org.springframework.web.context.WebApplicationContext |
getWebApplicationContext()
Return the web application context. |
java.lang.String |
getWebInfPath()
Return the absolute WEB-INF directory path. |
boolean |
isAttributeFilterEnabled()
check the attributeFilter is enabled. |
boolean |
isPowerReviewsEnabled()
Returns true if PowerReviews has been enabled, otherwise, false. |
boolean |
isSeoEnabled()
Returns true if SEO(Search Engine Optimization) has been enabled, otherwise, false. |
void |
setAccuracy(float accuracy)
Sets the degree of similarity that a word must have to the original word in order to be suggested. |
void |
setApplicationContext(org.springframework.context.ApplicationContext context)
Set the web application context. |
void |
setCheckoutTransactionBehaviour(CheckoutTransactionBehaviour behaviour)
Sets the checkoutTransactionBehaviour that defines how a checkout transaction is processed. |
void |
setCustomerProfileAttributes(java.util.Map customerProfileAttributes)
Sets the customer profile attribute map. |
void |
setDatabaseMetaData(java.sql.DatabaseMetaData databaseMetaData)
Called in EPContextListener to set the DatabaseMetaData at the start up time. |
void |
setDomainBeanFactory(PrototypeBeanFactory domainBeanFactory)
Sets PrototypeBeanFactory for domain objects. |
void |
setMaximumSuggestions(int suggestions)
Sets the maximum number of suggestions that will be returned with the search results. |
void |
setMaximumSuggestionsPerWord(int maximumSuggestionsPerWord)
Sets the maximum number of suggestions per word that will be generated when generating search suggestions. |
void |
setMaxReturnNumber(int number)
Sets the number of maximum results to return to the search client as the search result. |
void |
setMinimumResultsThreshold(int minimumResultsThreshold)
Sets the number of search results that, if not exceeded will trigger the generation of search suggestions. |
void |
setMinimumSimilarity(float minimumSimilarity)
Sets the minimum similarity fuzzy search setting, value should be between 0 and 1. |
void |
setPaymentGatewayMap(java.util.Map paymentGatewayMap)
Set the payment gateway map, keyed by the payment type (e.g. |
void |
setPrefixLength(int prefixLength)
Sets fuzzy search setting for the length of common non-fuzzy prefix. |
void |
setProperties(java.util.Map properties)
Set the properties. |
void |
setWebApplicationContext(org.springframework.web.context.WebApplicationContext context)
Set the web application context. |
void |
setWebInfPath(java.lang.String webInfPath)
Set the absolute path to the WEB-INF directory. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public void clearAllAttributeRanges()
clearAllAttributeRanges in interface ElasticPathpublic void clearAllAttributeSimpleValues()
clearAllAttributeSimpleValues in interface ElasticPathpublic void clearAllPriceRanges()
clearAllPriceRanges in interface ElasticPathpublic java.lang.String get(java.lang.String name)
get in interface ElasticPathname - Name of the property whose value is to be retrieved
public java.lang.String get(java.lang.String name,
java.lang.String defaultValue)
get in interface ElasticPathname - the property name to retrievedefaultValue - the default value to return if the given property is not defined
public float getAccuracy()
getAccuracy in interface ElasticPathpublic java.util.Map getAll()
getAll in interface ElasticPathpublic java.util.Map getAllAttributeRanges()
Map.
The attribute code will be used as the map key .
And the value will be a AttributeRangeFilter.
getAllAttributeRanges in interface ElasticPathMap.public java.util.Map getAllAttributeSimpleValues()
Map.
The filter id will be used as the map key .
And the value will be a AttributeFilter.
getAllAttributeSimpleValues in interface ElasticPathMap.public java.util.Map getAllAttributesMap()
Attribute.
getAllAttributesMap in interface ElasticPathpublic java.util.Map getAllCurrencies()
getAllCurrencies in interface ElasticPathpublic java.util.Map getAllLocales()
getAllLocales in interface ElasticPathLocale objectpublic java.util.Map getAllPriceRanges()
Map.
The key will be like : "price-between-USD-90-and-100".
And the value will be a PriceFilter.
getAllPriceRanges in interface ElasticPathMap.public java.util.List getAllShipmentCarriers()
getAllShipmentCarriers in interface ElasticPathpublic java.util.SortedMap getAttributeSimpleValuesMap(java.lang.String attributeCode)
Product to decide which attribute range it should belongs to.
The key and the value will be the same AttributeRangeFilter.
getAttributeSimpleValuesMap in interface ElasticPathattributeCode - the attributeCode
public java.lang.Object getBean(java.lang.String name)
getBean in interface ElasticPathname - bean id
public java.util.Map getBoolMap()
getBoolMap in interface ElasticPathpublic java.util.SortedMap getBottomLevelAttributeRanges(java.lang.String attributeCode)
Product to decide which attribute range it should belongs to.
The key and the value will be the same AttributeRangeFilter.
getBottomLevelAttributeRanges in interface ElasticPathattributeCode - the attributeCode
public java.util.SortedMap getBottomLevelPriceRanges(java.util.Currency currency)
Product to decide which price range it should belongs to.
The key and the value will be the same PriceFilter.
getBottomLevelPriceRanges in interface ElasticPathcurrency - the currency
public java.lang.String getCatalogAssetPath()
getCatalogAssetPath in interface ElasticPathpublic int getCatalogViewPagination()
getCatalogViewPagination in interface ElasticPathpublic CheckoutTransactionBehaviour getCheckoutTransactionBehaviour()
CheckoutTransactionBehaviour object that defines how a checkout transaction is to be processed.
getCheckoutTransactionBehaviour in interface ElasticPathCheckoutTransactionBehaviour objectpublic java.lang.String getCmContextUrl()
getCmContextUrl in interface ElasticPathpublic java.lang.String getContentEncoding()
getContentEncoding in interface ElasticPathpublic Geography getCountries()
Geography that provides geographical information.
getCountries in interface ElasticPathGeography objectpublic java.util.Map getCustomerProfileAttributes()
getCustomerProfileAttributes in interface ElasticPathpublic java.sql.DatabaseMetaData getDatabaseMetaData()
getDatabaseMetaData in interface ElasticPath
public java.lang.String getDatabaseProductName()
throws EpSystemException
getDatabaseProductName in interface ElasticPathEpSystemException - in case of errorpublic java.lang.String getDataFileEncoding()
getDataFileEncoding in interface ElasticPathpublic java.lang.String getDefaultCountry()
getDefaultCountry in interface ElasticPathpublic java.util.Currency getDefaultCurrency()
getDefaultCurrency in interface ElasticPathpublic java.text.SimpleDateFormat getDefaultDateFormat()
getDefaultDateFormat in interface ElasticPathpublic java.util.Locale getDefaultLocale()
getDefaultLocale in interface ElasticPathpublic PrototypeBeanFactory getDomainBeanFactory()
public java.lang.String getEmailCmUrl()
getEmailCmUrl in interface ElasticPathpublic java.lang.String getEmailStoreUrl()
getEmailStoreUrl in interface ElasticPathpublic java.lang.String getEpBuildNo()
getEpBuildNo in interface ElasticPathpublic java.lang.String getEpVersion()
getEpVersion in interface ElasticPathpublic java.lang.String getFileAssetPath()
getFileAssetPath in interface ElasticPathpublic java.lang.String getFileAssetSubFolder()
getFileAssetSubFolder in interface ElasticPathpublic Geography getGeography()
Geography that provides geographical information.
getGeography in interface ElasticPathGeography objectpublic java.lang.String getImageAssetSubFolder()
getImageAssetSubFolder in interface ElasticPathpublic java.lang.String getImagePath()
getImagePath in interface ElasticPathpublic java.lang.String getImageUrl()
getImageUrl in interface ElasticPathpublic static ElasticPath getInstance()
ElasticPath. Create default EP if one hasn't been created already.
ElasticPathpublic float getJPEGQuality()
getJPEGQuality in interface ElasticPathpublic java.util.Map getLocaleToLanguageMap()
getLocaleToLanguageMap in interface ElasticPathpublic int getMaximumSuggestions()
getMaximumSuggestions in interface ElasticPathpublic int getMaximumSuggestionsPerWord()
getMaximumSuggestionsPerWord in interface ElasticPathpublic int getMaxReturnNumber()
getMaxReturnNumber in interface ElasticPath
public java.lang.String getMessage(java.lang.String code,
java.lang.Object[] args,
java.lang.String defaultMessage,
java.util.Locale locale)
getMessage in interface ElasticPathcode - - the message key.args - - the args for the message if needed.defaultMessage - - the default message to display if the given message key does not exists.locale - - the locale that message needs to be in.
public java.lang.String getMessageDefaultLocale(java.lang.String code,
java.lang.Object[] args,
java.lang.String defaultMessage)
getMessageDefaultLocale in interface ElasticPathcode - - the message key.args - - the args for the message if needed.defaultMessage - - the default message to display if the given message key does not exists.
public int getMinimumResultsThreshold()
getMinimumResultsThreshold in interface ElasticPathpublic float getMinimumSimilarity()
getMinimumSimilarity in interface ElasticPathpublic java.lang.String getNoImage()
getNoImage in interface ElasticPathpublic PaymentGateway getPaymentGateway(PaymentType paymentType)
getPaymentGateway in interface ElasticPathpaymentType - the payment type
public int getPowerReviewsMerchantId()
getPowerReviewsMerchantId in interface ElasticPathpublic int getPrefixLength()
getPrefixLength in interface ElasticPathpublic java.util.Map getPropertiesWithNameStartsWith(java.lang.String prefix)
getPropertiesWithNameStartsWith in interface ElasticPathprefix - the prefix of the name
public java.lang.String getSecureAssetPath()
getSecureAssetPath in interface ElasticPathpublic java.lang.String getSecureAssetSubFolder()
getSecureAssetSubFolder in interface ElasticPathpublic java.lang.String getSfContextUrl()
getSfContextUrl in interface ElasticPathpublic int getTopSellerCount()
getTopSellerCount in interface ElasticPathpublic java.lang.String getUnitsLength()
getUnitsLength in interface ElasticPathpublic java.lang.String getUnitsWeight()
getUnitsWeight in interface ElasticPathpublic int getUserIdMode()
getUserIdMode in interface ElasticPathpublic int getUserMaintainMode()
getUserMaintainMode in interface ElasticPathpublic Utility getUtility()
Utility instance.
getUtility in interface ElasticPathpublic org.springframework.web.context.WebApplicationContext getWebApplicationContext()
getWebApplicationContext in interface ElasticPathpublic java.lang.String getWebInfPath()
getWebInfPath in interface ElasticPathpublic boolean isAttributeFilterEnabled()
isAttributeFilterEnabled in interface ElasticPathpublic boolean isPowerReviewsEnabled()
true if PowerReviews has been enabled, otherwise, false.
isPowerReviewsEnabled in interface ElasticPathtrue if PowerReviews has been enabled, otherwise, falsepublic boolean isSeoEnabled()
true if SEO(Search Engine Optimization) has been enabled, otherwise, false.
isSeoEnabled in interface ElasticPathtrue if SEO(Search Engine Optimization) has been enabled, otherwise, falsepublic void setAccuracy(float accuracy)
setAccuracy in interface ElasticPathaccuracy - the similaritypublic void setApplicationContext(org.springframework.context.ApplicationContext context)
setApplicationContext in interface org.springframework.context.ApplicationContextAwarecontext - the web application context to set.
EpSystemException - in case of errorpublic void setCheckoutTransactionBehaviour(CheckoutTransactionBehaviour behaviour)
checkoutTransactionBehaviour that defines how a checkout transaction is processed.
setCheckoutTransactionBehaviour in interface ElasticPathbehaviour - the behaviour enum objectpublic void setCustomerProfileAttributes(java.util.Map customerProfileAttributes)
setCustomerProfileAttributes in interface ElasticPathcustomerProfileAttributes - the customer profile attributes map
public void setDatabaseMetaData(java.sql.DatabaseMetaData databaseMetaData)
throws EpSystemException
EPContextListener to set the DatabaseMetaData at the start up time.
setDatabaseMetaData in interface ElasticPathdatabaseMetaData - Database metadata.
EpSystemException - in case of errorpublic void setDomainBeanFactory(PrototypeBeanFactory domainBeanFactory)
domainBeanFactory - PrototypeBeanFactory for domain objects.public void setMaximumSuggestions(int suggestions)
setMaximumSuggestions in interface ElasticPathsuggestions - the maximum number of suggestionspublic void setMaximumSuggestionsPerWord(int maximumSuggestionsPerWord)
setMaximumSuggestionsPerWord in interface ElasticPathmaximumSuggestionsPerWord - the maximum number of suggestions per wordpublic void setMaxReturnNumber(int number)
setMaxReturnNumber in interface ElasticPathnumber - the number of maximum results to return, set it to 0 for no limit.public void setMinimumResultsThreshold(int minimumResultsThreshold)
setMinimumResultsThreshold in interface ElasticPathminimumResultsThreshold - the minimum results thresholdpublic void setMinimumSimilarity(float minimumSimilarity)
setMinimumSimilarity in interface ElasticPathminimumSimilarity - the minimum similarity fuzzy search settingpublic void setPaymentGatewayMap(java.util.Map paymentGatewayMap)
setPaymentGatewayMap in interface ElasticPathpaymentGatewayMap - the payment gateway map.public void setPrefixLength(int prefixLength)
setPrefixLength in interface ElasticPathprefixLength - length of common non-fuzzy prefixpublic void setProperties(java.util.Map properties)
setProperties in interface ElasticPathproperties - the properties
public void setWebApplicationContext(org.springframework.web.context.WebApplicationContext context)
throws EpSystemException
setWebApplicationContext in interface ElasticPathcontext - the web application context to set.
EpSystemException - in case of errorpublic void setWebInfPath(java.lang.String webInfPath)
setWebInfPath in interface ElasticPathwebInfPath - the absolute path
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||