@StableMinor(version="12.4", sinceVersion="5.0") public interface IPropertyBagManager
Modifier and Type | Method and Description |
---|---|
void |
add(PropertyBag bag)
Persists a property bag.
|
void |
delete(PropertyBag bag)
Deletes the given property bag.
|
PropertyBag |
get(String propertyBagId)
Returns the property bag with the given identifier.
|
String |
getValue(String propertyBagId,
String propertyName,
String defaultValue)
Returns the value of the property with the given name for the property bag with the given identifier and, if no value was found, return the given default value.
The calculated value will be calculated considering the inherited values. When changing some property bag values, the new values will only be available in this method after the transaction that changed the property bag values is commited. This method is preferable to PropertyBag.getValue(String, String) . |
Map<String,List<String>> |
getValueMap(String propertyBagId)
Returns the value map for the property bag with the given identifier.
The resulting map will be calculated considering the inherited values and will be an unmodifiable map. When changing some property bag values, the new values will only be available in this method after the transaction that changed the property bag values is commited. This method is preferable to PropertyBag.getValueMap() . |
List<String> |
getValues(String propertyBagId,
String propertyName,
List<String> defaultValues)
Returns the values of the property with the given name for the property bag with the given identifier and, if no value was found, return the given default values.
The calculated value will be calculated considering the inherited values. When changing some property bag values, the new values will only be available in this method after the transaction that changed the property bag values is commited. If the values could be calculated (and, thus, the default values are not used), the returned list will be immutable. If the values couldn't be found, the default values will be returned and, whether it is an immutable list is not defined. This method is preferable to PropertyBag.getValues(String, List) . |
void add(PropertyBag bag) throws PortalException
bag
- the property bag to persist.PortalException
PropertyBag get(String propertyBagId) throws PortalException
propertyBagId
- identifier of the property bag.PortalException
void delete(PropertyBag bag) throws PortalException
Delete is not done recursively. There must not be any child property bags that have the given property bag as its parent.
bag
- the property bag to be deleted.PortalException
String getValue(String propertyBagId, String propertyName, String defaultValue) throws PortalException
PropertyBag.getValue(String, String)
.propertyBagId
- the property bag identifier.propertyName
- the property name.defaultValue
- the default value.PortalObjectNotFoundException
- if no property bag with the given identifier was found.PortalException
List<String> getValues(String propertyBagId, String propertyName, List<String> defaultValues) throws PortalException
PropertyBag.getValues(String, List)
.propertyBagId
- the property bag identifier.propertyName
- the property name.defaultValue
- the default values.PortalObjectNotFoundException
- if no property bag with the given identifier was found.PortalException
Map<String,List<String>> getValueMap(String propertyBagId) throws PortalException
PropertyBag.getValueMap()
.propertyBagId
- the property bag identifier.PortalObjectNotFoundException
- if no property bag with the given identifier was found.PortalException
LumisXP 12.4.0.200625 - Copyright © 2006–2020 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.