org.jboss.errai.otec.client.operation
Class OTOperationImpl
java.lang.Object
org.jboss.errai.otec.client.operation.OTOperationImpl
- All Implemented Interfaces:
- Comparable<OTOperation>, OTOperation
public class OTOperationImpl
- extends Object
- implements OTOperation
- Author:
- Christian Sadilek, Mike Brock
Method Summary |
boolean |
apply(OTEntity entity)
|
boolean |
apply(OTEntity entity,
boolean transiently)
|
int |
compareTo(OTOperation o)
|
static OTOperation |
createLocalOnlyOperation(OTEngine engine,
OTOperation operation)
|
static OTOperation |
createLocalOnlyOperation(OTEngine engine,
OTOperation operation,
int lastRevisionTx)
|
static OTOperation |
createLocalOnlyOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
OTEntity entity,
int revision,
OpPair pair)
|
static OTOperation |
createLocalOnlyOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
OTEntity entity,
OpPair pair)
|
static OTOperation |
createOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
int entityId,
int revision,
String revisionHash)
|
static OTOperation |
createOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
int entityId,
int revision,
String revisionHash,
OpPair transformedFrom,
int lastRevisionTx)
|
static OTOperation |
createOperation(OTOperation op)
|
static OTOperation |
createOperation(OTOperation op,
OpPair transformedFrom)
|
boolean |
equals(Object o)
|
String |
getAgentId()
|
OTOperation |
getBasedOn(int revision)
|
OTEngine |
getEngine()
|
int |
getEntityId()
|
int |
getLastRevisionTx()
|
List<Mutation> |
getMutations()
|
OTOperation |
getOuterPath()
|
int |
getRevision()
|
String |
getRevisionHash()
|
OpPair |
getTransformedFrom()
|
int |
hashCode()
|
void |
invalidate()
|
boolean |
isCanon()
|
boolean |
isNoop()
|
boolean |
isResolvedConflict()
|
boolean |
isValid()
|
void |
markAsResolvedConflict()
|
void |
removeFromCanonHistory()
|
void |
setOuterPath(OTOperation outerPath)
|
boolean |
shouldPropagate()
|
String |
toString()
|
void |
unmarkAsResolvedConflict()
|
createLocalOnlyOperation
public static OTOperation createLocalOnlyOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
OTEntity entity,
OpPair pair)
createLocalOnlyOperation
public static OTOperation createLocalOnlyOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
OTEntity entity,
int revision,
OpPair pair)
createOperation
public static OTOperation createOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
int entityId,
int revision,
String revisionHash)
createOperation
public static OTOperation createOperation(OTEngine engine,
String agentId,
List<Mutation> mutationList,
int entityId,
int revision,
String revisionHash,
OpPair transformedFrom,
int lastRevisionTx)
createLocalOnlyOperation
public static OTOperation createLocalOnlyOperation(OTEngine engine,
OTOperation operation)
createLocalOnlyOperation
public static OTOperation createLocalOnlyOperation(OTEngine engine,
OTOperation operation,
int lastRevisionTx)
createOperation
public static OTOperation createOperation(OTOperation op)
createOperation
public static OTOperation createOperation(OTOperation op,
OpPair transformedFrom)
getMutations
public List<Mutation> getMutations()
- Specified by:
getMutations
in interface OTOperation
getEntityId
public int getEntityId()
- Specified by:
getEntityId
in interface OTOperation
getRevision
public int getRevision()
- Specified by:
getRevision
in interface OTOperation
getAgentId
public String getAgentId()
- Specified by:
getAgentId
in interface OTOperation
apply
public boolean apply(OTEntity entity)
- Specified by:
apply
in interface OTOperation
apply
public boolean apply(OTEntity entity,
boolean transiently)
- Specified by:
apply
in interface OTOperation
removeFromCanonHistory
public void removeFromCanonHistory()
- Specified by:
removeFromCanonHistory
in interface OTOperation
markAsResolvedConflict
public void markAsResolvedConflict()
- Specified by:
markAsResolvedConflict
in interface OTOperation
unmarkAsResolvedConflict
public void unmarkAsResolvedConflict()
- Specified by:
unmarkAsResolvedConflict
in interface OTOperation
isCanon
public boolean isCanon()
- Specified by:
isCanon
in interface OTOperation
shouldPropagate
public boolean shouldPropagate()
- Specified by:
shouldPropagate
in interface OTOperation
getEngine
public OTEngine getEngine()
- Specified by:
getEngine
in interface OTOperation
isNoop
public boolean isNoop()
- Specified by:
isNoop
in interface OTOperation
isResolvedConflict
public boolean isResolvedConflict()
- Specified by:
isResolvedConflict
in interface OTOperation
getBasedOn
public OTOperation getBasedOn(int revision)
- Specified by:
getBasedOn
in interface OTOperation
getTransformedFrom
public OpPair getTransformedFrom()
- Specified by:
getTransformedFrom
in interface OTOperation
setOuterPath
public void setOuterPath(OTOperation outerPath)
- Specified by:
setOuterPath
in interface OTOperation
getOuterPath
public OTOperation getOuterPath()
- Specified by:
getOuterPath
in interface OTOperation
isValid
public boolean isValid()
- Specified by:
isValid
in interface OTOperation
invalidate
public void invalidate()
- Specified by:
invalidate
in interface OTOperation
compareTo
public int compareTo(OTOperation o)
- Specified by:
compareTo
in interface Comparable<OTOperation>
equals
public boolean equals(Object o)
- Overrides:
equals
in class Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
toString
public String toString()
- Overrides:
toString
in class Object
getRevisionHash
public String getRevisionHash()
- Specified by:
getRevisionHash
in interface OTOperation
getLastRevisionTx
public int getLastRevisionTx()
- Specified by:
getLastRevisionTx
in interface OTOperation
Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.