com.elasticpath.domain.misc.impl
Class LocalizedPropertiesImpl

java.lang.Object
  extended by com.elasticpath.domain.impl.AbstractEpDomainImpl
      extended by com.elasticpath.domain.impl.AbstractPersistenceImpl
          extended by com.elasticpath.domain.impl.AbstractValueObjectImpl
              extended by com.elasticpath.domain.misc.impl.LocalizedPropertiesImpl
All Implemented Interfaces:
EpDomain, LocalizedProperties, Persistence, ValueObject, java.io.Serializable

public class LocalizedPropertiesImpl
extends AbstractValueObjectImpl
implements LocalizedProperties

Represents a default implementation of LocalizedProperties.

See Also:
Serialized Form

Field Summary
static long serialVersionUID
          Serial version id.
 
Constructor Summary
LocalizedPropertiesImpl()
           
 
Method Summary
 ElasticPath getElasticPath()
          Get the ElasticPath singleton.
 java.util.Map getLocalizedPropertiesMap()
          Returns the localized properties map.
 java.lang.String getValue(java.lang.String propertyName, java.util.Locale locale)
          Returns the value of the given property and locale.
 java.lang.String getValueWithoutFallBack(java.lang.String propertyName, java.util.Locale locale)
          Returns the value of the given property and locale.
 void setLocalizedPropertiesMap(java.util.Map map)
          Sets the localized properties map.
 void setValue(java.lang.String propertyName, java.util.Locale locale, java.lang.String value)
          Sets the given value with the given property and locale.
 
Methods inherited from class com.elasticpath.domain.impl.AbstractPersistenceImpl
executeBeforePersistAction, getUidPk, isPersistent, setDefaultValues, setUidPk
 
Methods inherited from class com.elasticpath.domain.impl.AbstractEpDomainImpl
setElasticPath
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.elasticpath.domain.Persistence
executeBeforePersistAction, getUidPk, isPersistent, setDefaultValues, setUidPk
 
Methods inherited from interface com.elasticpath.domain.EpDomain
setElasticPath
 

Field Detail

serialVersionUID

public static final long serialVersionUID
Serial version id.

See Also:
Constant Field Values
Constructor Detail

LocalizedPropertiesImpl

public LocalizedPropertiesImpl()
Method Detail

getElasticPath

public ElasticPath getElasticPath()
Get the ElasticPath singleton.

Specified by:
getElasticPath in interface EpDomain
Overrides:
getElasticPath in class AbstractEpDomainImpl
Returns:
elasticpath the ElasticPath singleton.

getLocalizedPropertiesMap

public java.util.Map getLocalizedPropertiesMap()
Returns the localized properties map.

Returns:
the localized properties map.

getValue

public java.lang.String getValue(java.lang.String propertyName,
                                 java.util.Locale locale)
Returns the value of the given property and locale.

Specified by:
getValue in interface LocalizedProperties
Parameters:
propertyName - the property name
locale - the locale
Returns:
the value of the given property and locale.

getValueWithoutFallBack

public java.lang.String getValueWithoutFallBack(java.lang.String propertyName,
                                                java.util.Locale locale)
Returns the value of the given property and locale. If the value doesn't exist, return null.

Specified by:
getValueWithoutFallBack in interface LocalizedProperties
Parameters:
propertyName - the property name
locale - the locale
Returns:
the value of the given property and locale.

setLocalizedPropertiesMap

public void setLocalizedPropertiesMap(java.util.Map map)
Sets the localized properties map.

Parameters:
map - the map to set

setValue

public void setValue(java.lang.String propertyName,
                     java.util.Locale locale,
                     java.lang.String value)
Sets the given value with the given property and locale.

Specified by:
setValue in interface LocalizedProperties
Parameters:
propertyName - the property name
locale - the locale
value - the value to set