Top Methods
net.sf.ehcache.transaction.xa.commands

public Interface Command

Known Direct Implementers
net.sf.ehcache.transaction.xa.commands.AbstractStoreCommand
Imports
net.sf.ehcache.store.ElementValueComparator, .Store, net.sf.ehcache.transaction.SoftLockManager, net.sf.ehcache.transaction.xa.XidTransactionID

Author
Ludovic Orban

Method Summary

Modifier and TypeMethod and Description
public Object

Returns:

the element's key
getObjectKey
()

Get the key of the element this command is working on

public boolean

Returns:

true, if this command would try to add an Element for key, otherwise false
isPut
(Object
the key
key
)

Is this command represents adding a key to the store

public boolean

Returns:

true, if this command would try to remove an Element for key, otherwise false
isRemove
(Object
the key
key
)

Is this command represents removing a key to the store

public boolean

Returns:

true if prepare updated the store, false otherwise
prepare
(Store
the underdyling store
store
,
SoftLockManager
the soft lock manager
softLockManager
,
XidTransactionID
the transaction ID
transactionId
,
ElementValueComparator
the element value comparator
comparator
)

Prepare the commmand un the underlying store

public void
rollback(Store
the underlying store
store
,
SoftLockManager
the soft lock manager
softLockManager
)

Rollback the prepared change

Method Detail

getObjectKeyback to summary
public Object getObjectKey()

Get the key of the element this command is working on

Returns:Object

the element's key

isPutback to summary
public boolean isPut(Object key)

Is this command represents adding a key to the store

Parameters
key:Object

the key

Returns:boolean

true, if this command would try to add an Element for key, otherwise false

isRemoveback to summary
public boolean isRemove(Object key)

Is this command represents removing a key to the store

Parameters
key:Object

the key

Returns:boolean

true, if this command would try to remove an Element for key, otherwise false

prepareback to summary
public boolean prepare(Store store, SoftLockManager softLockManager, XidTransactionID transactionId, ElementValueComparator comparator)

Prepare the commmand un the underlying store

Parameters
store:Store

the underdyling store

softLockManager:SoftLockManager

the soft lock manager

transactionId:XidTransactionID

the transaction ID

comparator:ElementValueComparator

the element value comparator

Returns:boolean

true if prepare updated the store, false otherwise

rollbackback to summary
public void rollback(Store store, SoftLockManager softLockManager)

Rollback the prepared change

Parameters
store:Store

the underlying store

softLockManager:SoftLockManager

the soft lock manager