public class ExternalValue extends ComplexValue implements RecordChangeProxy, CommonRecordValue
modelInstance
Constructor and Description |
---|
ExternalValue(long id,
ModelInstance modelInstance,
String type,
String objectIdentification,
Long processInstanceId,
Long version,
boolean renewVersion,
boolean register,
Long auditRevision)
Creates new instance of
ExternalValue . |
ExternalValue(ModelInstance modelInstance,
String type,
String objectIdentification,
Long processInstanceId,
Long auditRevision)
Creates new instance of
ExternalValue . |
ExternalValue(SExternalValue source,
ModelInstance modelInstance)
Creates a new instance from the serialized companion.
|
Modifier and Type | Method and Description |
---|---|
<T,E extends Throwable> |
accept(ValueVisitor<T,E> visitor)
Accepts visitor.
|
void |
addToCachedNonsharedAssociations(String name,
ComplexValue value)
Adds to cache of nonshared associations.
|
void |
cleanAndSetRenewVersion()
Cleans version string and sets renewVersion to true.
|
protected void |
convertToDirectReferences() |
RecordValue |
createChangeProxy(RecordProxySetValue proxySet,
boolean isLazySpreading)
Created a change proxy on this object.
|
protected Context |
createContext(long parentContextId) |
ExternalValue |
createCopy(ModelInstance targetModelInstance)
Creates a copy without references to other objects.
|
void |
finishCopy(com.whitestein.lsps.engine.state.xml.Copiable source,
CopyHelper helper)
Copy references.
|
Long |
getAuditRevision()
Returns audit revision.
|
ComplexValue |
getFromCachedNonsharedAssociations(String name)
Returns value from to cache of nonshared associations.
|
Handle |
getHandle()
Returns handle.
|
String |
getObjectIdentification()
Returns the object identification.
|
String[] |
getObjectIdentificationSegments()
Returns segments of the identification.
|
RecordChangeProxy |
getOriginalRecord()
Returns a record object that is original non-proxy record.
|
Context |
getOwnContext(long parentContextId)
Returns own context
|
ProcessInstance |
getProcessInstance()
Deprecated.
information about process instance id is stored in the objectIdentificationSegments
|
Long |
getProcessInstanceId()
Deprecated.
information about process instance id is stored in the objectIdentificationSegments
|
int |
getProxyLevel()
Gets number of proxies from this object to original non-proxy record.
|
RecordProxySetValue |
getProxySet()
Returns proxy set in which the proxy is registered.
|
Collection<Collectible> |
getReferences()
Returns collection of all referenced collectible objects.
|
Long |
getVersion()
Returns shared entity version.
|
boolean |
hasObjectIdentification()
Returns true if object identification is set.
|
boolean |
isLazySpreadingProxy()
Returns true if the proxy is lazy spreading.
|
boolean |
isProxyOf(RecordChangeProxy record)
Returns true if this is direct or non-direct proxy of the record.
|
boolean |
isRemoved()
Returns true if value is removed
|
boolean |
isRenewVersion()
Returns true if the version should be set to new value.
|
void |
rebind(ModelInstance modelInstance)
Re-binds to a model instance.
|
void |
refreshDirectReferences()
Re-set references to elements from the same model instance.
|
void |
remove()
Set this value to removed.
|
void |
removeFromCacheNonsharedAssociation(String name)
Removes from the nonshared association cache.
|
void |
replaceReferencedIds(Map<Long,Long> replacementMap)
Replace referenced ids according to mappings in the replacement map.
|
void |
revertRemove()
Set this value to not removed.
|
void |
setObjectIdentification(String objectIdentification)
Sets the object identification.
|
void |
setProcessInstanceId(Long processInstanceId)
Deprecated.
information about process instance id is stored in the objectIdentificationSegments
|
void |
setRenewVersion(boolean renewVersion)
Sets renewVersion value.
|
void |
setVersion(Long versionValue)
Sets shared entity version.
|
SExternalValue |
toSerializable(SModelInstance smi,
MarshallerConfig config)
Creates a serializable object.
|
String |
toString() |
ExternalValueUniqueKey |
toUniqueKey()
Returns unique key for this instance.
|
clear, collect, fillSerializable, findReplacementId, getBaseLevelEntity, getBaseLevelEntityId, getCompiledType, getEvaluationLevel, getId, getLowerLevelEntity, getLowerLevelEntityId, getModelInstance, getType, isPersistent, replaceIdAndEvaluationLevel, setLowerLevelEntity, toSimpleValue, toValue
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getId, getModelInstance
getCompiledType, getType, toSimpleValue, toValue
collect, isPersistent
public ExternalValue(SExternalValue source, ModelInstance modelInstance)
source
- modelInstance
- public ExternalValue(ModelInstance modelInstance, String type, String objectIdentification, Long processInstanceId, Long auditRevision)
ExternalValue
.modelInstance
- type
- objectIdentification
- processInstanceId
- auditRevision
- NullPointerException
- if modelInstance
or type
is nullpublic ExternalValue(long id, ModelInstance modelInstance, String type, String objectIdentification, Long processInstanceId, Long version, boolean renewVersion, boolean register, Long auditRevision)
ExternalValue
.id
- modelInstance
- type
- objectIdentification
- processInstanceId
- version
- renewVersion
- register
- auditRevision
- NullPointerException
- if modelInstance
or type
is nullpublic SExternalValue toSerializable(SModelInstance smi, MarshallerConfig config)
ComplexValue
toSerializable
in interface Value
toSerializable
in class ComplexValue
public String getObjectIdentification()
public boolean hasObjectIdentification()
public void setObjectIdentification(String objectIdentification)
objectIdentification
- @Deprecated public ProcessInstance getProcessInstance()
@Deprecated public Long getProcessInstanceId()
@Deprecated public void setProcessInstanceId(Long processInstanceId)
processInstanceId
- public Handle getHandle()
ComplexValue
getHandle
in class ComplexValue
public <T,E extends Throwable> T accept(ValueVisitor<T,E> visitor) throws E extends Throwable
Value
public ExternalValueUniqueKey toUniqueKey()
public void replaceReferencedIds(Map<Long,Long> replacementMap)
ComplexValue
replaceReferencedIds
in interface EvaluationLevelAware
replaceReferencedIds
in class ComplexValue
public void rebind(ModelInstance modelInstance)
ComplexValue
rebind
in interface ModelInstanceAware
rebind
in class ComplexValue
public Collection<Collectible> getReferences()
Collectible
getReferences
in interface Collectible
public void remove()
public void revertRemove()
public boolean isRemoved()
Value
isRemoved
in interface Value
isRemoved
in class ComplexValue
public void addToCachedNonsharedAssociations(String name, ComplexValue value)
name
- value
- public void removeFromCacheNonsharedAssociation(String name)
name
- public ComplexValue getFromCachedNonsharedAssociations(String name)
name
- public ExternalValue createCopy(ModelInstance targetModelInstance)
public void finishCopy(com.whitestein.lsps.engine.state.xml.Copiable source, CopyHelper helper)
finishCopy
in class ComplexValue
public Long getVersion()
public void setVersion(Long versionValue)
versionValue
- public boolean isRenewVersion()
public void setRenewVersion(boolean renewVersion)
renewVersion
- public void cleanAndSetRenewVersion()
public Long getAuditRevision()
public String[] getObjectIdentificationSegments()
public RecordValue createChangeProxy(RecordProxySetValue proxySet, boolean isLazySpreading)
RecordChangeProxy
createChangeProxy
in interface RecordChangeProxy
public int getProxyLevel()
RecordChangeProxy
getProxyLevel
in interface RecordChangeProxy
public RecordProxySetValue getProxySet()
RecordChangeProxy
getProxySet
in interface RecordChangeProxy
public boolean isLazySpreadingProxy()
RecordChangeProxy
isLazySpreadingProxy
in interface RecordChangeProxy
public RecordChangeProxy getOriginalRecord()
RecordChangeProxy
getOriginalRecord
in interface RecordChangeProxy
public boolean isProxyOf(RecordChangeProxy record)
RecordChangeProxy
isProxyOf
in interface RecordChangeProxy
protected void convertToDirectReferences()
convertToDirectReferences
in class ComplexValue
public void refreshDirectReferences()
EvaluationLevelAware
refreshDirectReferences
in interface EvaluationLevelAware
refreshDirectReferences
in class ComplexValue
protected Context createContext(long parentContextId)
public Context getOwnContext(long parentContextId)
getOwnContext
in interface CommonRecordValue
parentContextId
- Copyright © 2007-2020 Whitestein Technologies. All Rights Reserved.