public class S_LibraryObjectData extends Object implements Serializable, LooselyBoundedCacheable
Modifier and Type | Field and Description |
---|---|
protected AttributeValue[] |
m_Attributes
The values of the effective attributes of the LIBRARYOBJECT.
|
protected Long |
m_ClassId
The class id of the LIBRARYOBJECT.
|
protected boolean |
m_FullySelected
Whether this S_LibraryObjectData is fully selected.
|
protected Long |
m_Id
The id of the LIBRARYOBJECT.
|
protected long |
m_Rsn
The resolution sequence number of this S_LibraryObjectData.
|
Constructor and Description |
---|
S_LibraryObjectData(Long id,
Long classId,
AttributeValue[] attributes,
boolean fullySelected,
S_LibrarySession session)
Constructs an S_LibraryObjectData.
|
Modifier and Type | Method and Description |
---|---|
void |
added(Object id)
Called when an instance is added to the cache.
|
boolean |
canPurge()
Gets whether the item can be purged from the
the BoundedCache.
|
S_LibraryObjectDataSharedState |
findOrCreateSharedState()
Gets the shared state, creating it if it doesn't exist.
|
S_LibraryObjectDataSharedState |
findOrCreateSharedState(S_LibraryObjectDataSharedStateFactory ssFactory)
Gets the shared state, creating it if it doesn't exist.
|
S_LibraryObjectDataSharedState |
findOrCreateSharedState(S_LibrarySession session)
Gets the shared state, creating it if it doesn't exist.
|
S_LibraryObjectDataSharedState |
findOrCreateSharedState(S_LibrarySession session,
boolean applyMutations)
Gets the shared state, creating it if it doesn't exist.
|
S_LibraryObjectDataSharedState |
findOrCreateSharedState(S_LibrarySession session,
S_LibraryObjectDataSharedStateFactory ssFactory,
boolean applyMutations)
Gets the shared state, creating it if it doesn't exist.
|
AttributeValue |
getAttribute(String name,
LibrarySession session)
Gets the value of the specified attribute for the LIBRARYOBJECT
represented by this S_LibraryObjectData.
|
AttributeValue |
getAttribute(String name,
S_LibrarySession session)
Gets the value of the specified attribute for the LIBRARYOBJECT
represented by this S_LibraryObjectData.
|
AttributeValue[] |
getAttributes()
Gets the values of the attributes of the LIBRARYOBJECT
represented by this S_LibraryObjectData.
|
Long |
getClassId()
Gets the class id of LIBRARYOBJECT represented by this
S_LibraryObjectData.
|
Long |
getId()
Gets the id of LIBRARYOBJECT represented by this
S_LibraryObjectData.
|
long |
getRsn()
Gets the resolution sequence number of this S_LibraryObjectData.
|
boolean |
isFullySelected()
Gets whether this S_LibraryObjectData is fully selected.
|
void |
removed(Object id)
Called when an instance is removed to the cache.
|
void |
resetSharedState()
Resets the shared state in a course-grained manner.
|
void |
resetSharedState(IfsEvent event)
Resets the shared state because of an event, in a fine-grained manner.
|
protected void |
setSharedState(S_LibraryObjectDataSharedState state)
Sets the S_LibraryObjectDataSharedState for this S_LibraryObjectData
|
protected Long m_Id
protected Long m_ClassId
protected AttributeValue[] m_Attributes
protected boolean m_FullySelected
protected long m_Rsn
public S_LibraryObjectData(Long id, Long classId, AttributeValue[] attributes, boolean fullySelected, S_LibrarySession session) throws IfsException
id
- the id of the LIBRARYOBJECTclassId
- the class id of the LIBRARYOBJECTattributes
- the values of the effective attributes
of the LIBRARYOBJECTfullySelected
- whether attributes
contains
the value of every effective attribute
the LIBRARYOBJECTsession
- the sessionIfsException
- (IFS-30000) if the operation failspublic boolean canPurge() throws IfsException
The caller of this method indicates a desire to purge the object. The implementation should treat this as a purge request, but can return false if the item should not be purged.
canPurge
in interface LooselyBoundedCacheable
IfsException
- if operation fails.public void added(Object id)
added
in interface LooselyBoundedCacheable
id
- the id used for this entry in the cachepublic void removed(Object id)
removed
in interface LooselyBoundedCacheable
id
- the id used for this entry in the cachepublic Long getId() throws IfsException
IfsException
- if the operation failspublic Long getClassId() throws IfsException
IfsException
- if the operation failspublic AttributeValue[] getAttributes() throws IfsException
If isFullySelected
is false
,
only a subset of the attributes are returned.
IfsException
- if the operation failspublic boolean isFullySelected() throws IfsException
It is fully selected if it has the value of every effective attribute of the LIBRARYOBJECT.
IfsException
- if the operation failspublic long getRsn() throws IfsException
IfsException
- if the operation failspublic AttributeValue getAttribute(String name, S_LibrarySession session) throws IfsException
name
- the name of the attributesession
- the sessionIfsException
- if the operation failspublic AttributeValue getAttribute(String name, LibrarySession session) throws IfsException
name
- the name of the attributesession
- the sessionIfsException
- if the operation failspublic final S_LibraryObjectDataSharedState findOrCreateSharedState()
Uses the default factory. This variant can be used in bean-side code. This variant does not perform any mutations on the shared state.
public final S_LibraryObjectDataSharedState findOrCreateSharedState(S_LibraryObjectDataSharedStateFactory ssFactory)
This variant can be used in bean-side code. A null factory can be passed.
ssFactory
- the server-side session contextpublic final S_LibraryObjectDataSharedState findOrCreateSharedState(S_LibrarySession session)
Uses factory defined in server-side session context, and delegates to the variant that takes a shared state factory. This variant does not perform any mutations on the shared state.
session
- the server-side session contextpublic final S_LibraryObjectDataSharedState findOrCreateSharedState(S_LibrarySession session, boolean applyMutations)
Uses factory defined in server-side session context, and delegates to the variant that takes a shared state factory.
session
- the server-side session contextapplyMutations
- whether to apply shared state mutationspublic final S_LibraryObjectDataSharedState findOrCreateSharedState(S_LibrarySession session, S_LibraryObjectDataSharedStateFactory ssFactory, boolean applyMutations)
session
- the server-side session contextssFactory
- the server-side session contextapplyMutations
- whether to apply shared state mutationspublic final void resetSharedState()
public final void resetSharedState(IfsEvent event)
event
- the event that triggered the resetprotected void setSharedState(S_LibraryObjectDataSharedState state)
state
- the S_LibraryObjectDataSharedStateCopyright © 2023. All rights reserved.