|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.spicefactory.pimento.io.AbstractEntitySnapshot
org.spicefactory.pimento.io.AbstractApplicableEntitySnapshot
org.spicefactory.pimento.io.PartialEntitySnapshot
public class PartialEntitySnapshot
Represents an entity with a subset of its property values. This snaphsot is used when receiving changesets of modified entities from the client or sending partial updates for refreshable properties to the client and should contain only the values for properties that were actually changed.
| Constructor Summary | |
|---|---|
PartialEntitySnapshot()
Creates a new instance. |
|
PartialEntitySnapshot(int metadataId,
Object entityId)
Creates a new instance. |
|
PartialEntitySnapshot(int metadataId,
Object entityId,
int temporaryEntityId)
Creates a new instance representing a transient entity. |
|
| Method Summary | |
|---|---|
void |
addProperty(Object value,
int index)
Adds the specified property value for the specified index position. |
String |
getLogString(EntityMetadata metadata,
boolean includeProperties)
Returns a log String for this snapshot. |
EntityUpdate |
prepareUpdate(Object entity,
EntityMetadata metadata,
IoContext context)
Creates and returns an EntityUpdate instance that reflects the state of this instance. |
void |
readExternal(DataInput input)
Restores the content of this object from the DataInput instance. |
void |
writeExternal(DataOutput output)
Saves the content of this object to the DataOutput instance. |
| Methods inherited from class org.spicefactory.pimento.io.AbstractApplicableEntitySnapshot |
|---|
clearInvocationCache, getEntity, getProperties, hasEntity, isTransient, setEntity |
| Methods inherited from class org.spicefactory.pimento.io.AbstractEntitySnapshot |
|---|
equals, getEntityId, getMetadataId, hashCode, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.spicefactory.pimento.io.EntitySnapshot |
|---|
getEntityId, getMetadataId |
| Constructor Detail |
|---|
public PartialEntitySnapshot()
public PartialEntitySnapshot(int metadataId,
Object entityId)
metadataId - the id of the metadata for this entityentityId - the id of the entity
public PartialEntitySnapshot(int metadataId,
Object entityId,
int temporaryEntityId)
metadataId - the id of the metadata for this entityentityId - the id of the entitytemporaryEntityId - the temporary id of the transient entity| Method Detail |
|---|
public void addProperty(Object value,
int index)
value - the property value to add to this snapshotindex - the index position of the property (determined by the order of properties
in the associated EntityMetadata instance).
public EntityUpdate prepareUpdate(Object entity,
EntityMetadata metadata,
IoContext context)
ApplicableEntitySnapshot
entity - the entity the update will later be applied tometadata - the metadata for the specified entitycontext - the active IoContext
public void readExternal(DataInput input)
Externalizable
readExternal in interface ExternalizablereadExternal in class AbstractApplicableEntitySnapshotinput - the AMF3 data to read frompublic void writeExternal(DataOutput output)
Externalizable
writeExternal in interface ExternalizablewriteExternal in class AbstractApplicableEntitySnapshotoutput - the output to write to
public String getLogString(EntityMetadata metadata,
boolean includeProperties)
EntitySnapshot
getLogString in interface EntitySnapshotgetLogString in class AbstractEntitySnapshotmetadata - the metadata associated with this snapshotincludeProperties - whether properties should be included in the log
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||