public class LinkedPropertyValue extends PropertyValue
Copyright Micro Focus GmbH.
| Constructor and Description |
|---|
LinkedPropertyValue(LinkedProperty pProp,
EPropertyValueType pType,
IExecutionContext pContext)
Tries to resolve a linked property resource identifier with the given
context.
|
LinkedPropertyValue(LinkedProperty pProp,
EPropertyValueType pType,
java.lang.String pResourceIdentifier)
Constructor for a linked property value and a specific resource
identifier.
|
LinkedPropertyValue(LinkedProperty pProperty,
IExecutionContext pContext)
Basic constructor.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getCachedValue()
Gets the cached value from this linked property.
|
java.lang.String |
getLabelOrValue()
Returns a label for a Property Value, if one was configured or set by a
retrieval tool.
|
java.lang.String |
getValue()
Gets the string value.
|
static java.lang.String |
resolveResourceIdentifier(LinkedProperty pLinkedProperty,
IExecutionContext pContext)
Searches a value for the given property in the execution context.
|
void |
setLinkedValue(java.lang.String pValue)
Sets the "real" value of the linked property.
|
void |
setValue(java.lang.String pValue)
Sets the cached value of this linked property.
|
addValue, getProperty, getType, getValues, isArray, setType, setValue, toStringpublic LinkedPropertyValue(LinkedProperty pProperty, IExecutionContext pContext)
LinkedPropertyValue(LinkedProperty, EPropertyValueType, IExecutionContext)
.pProperty - the linked propertypContext - the execution contextpublic LinkedPropertyValue(LinkedProperty pProp, EPropertyValueType pType, java.lang.String pResourceIdentifier)
pProp - the linked propertypType - the property type (can be null)pResourceIdentifier - the resource identifierpublic LinkedPropertyValue(LinkedProperty pProp, EPropertyValueType pType, IExecutionContext pContext)
pProp - the linked propertypType - the property type. Must not be nullpContext - the execution contextpublic java.lang.String getValue()
IPropertyValue
If the property is of the type ETypes.TEXT_ARRAY this method
returns the values of IPropertyValue.getValues() separated by the
Property.getStringDelimiterWithoutQuotes() as string.
getValue in interface IPropertyValuegetValue in class PropertyValuepublic void setValue(java.lang.String pValue)
setValue in interface IPropertyValuesetValue in class PropertyValuepValue - the new cached valuegetCachedValue(),
setLinkedValue(String)public void setLinkedValue(java.lang.String pValue)
pValue - the new valuepublic java.lang.String getCachedValue()
The cached value of a linked property value is a stored string which does
not represent the actual resource value (returned by getValue()
). It can be used by tools e.g. to support UPDATE resource operations by
setting the cached value without changing the resource the property is
linked to.
public static java.lang.String resolveResourceIdentifier(LinkedProperty pLinkedProperty, IExecutionContext pContext)
LinkedPropertys which require a resource
identifier.
The search order is:
pLinkedProperty - the linked propertypContext - the execution contextnull if it can't
be found in the context/memory.public java.lang.String getLabelOrValue()
IPropertyValueIf there is no label for this value, the value will be returned.
getLabelOrValue in interface IPropertyValuegetLabelOrValue in class PropertyValueCopyright © 2015 Micro Focus GmbH. All rights reserved.