|
SAP NetWeaver '04 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Represents a cacheable area. A cacheable area is identified by its unique ID. An area is either in state valid or invalid. These states are toggled by the following events:
| from | event | to | side-effect | |
|---|---|---|---|---|
VALID | validate() |
VALID |
initial state, calling validate() won't do anything. |
|
VALID | invalidate() |
VALID |
calling invalidate() will send an INVALIDATE event and update the getLastNodeInvalidation() timestamp. |
|
VALID | INVALIDATE | INVALID |
an INVALIDATE event from other cluster nodes invalidates the cache area and updates the getLastClusterInvalidation() timestamp. |
|
INVALID | INVALIDATE | INVALID |
INVALIDATE event in INVALID state just update the getLastClusterInvalidation() timestamp. |
|
INVALID | invalidate() |
INVALID |
calling invalidate() will send an INVALIDATE event and update the getLastNodeInvalidation() timestamp. |
|
INVALID | validate() |
VALID |
calling validate() toogles the state back to VALID. |
IDMapper.
| Method Summary | |
java.lang.String |
getAreaID()
Get the area's ID. |
long |
getClusterTimeout()
Get the cluster cache timeout. |
long |
getLastClusterInvalidation()
Get the timestamp of the last (external) invalidation from other cluster nodes. |
long |
getLastInvalidation()
Get the timestamp of the last invalidation (internally or externally, the later one). |
long |
getLastNodeInvalidation()
Get the timestamp of the last (internal) invalidation from this node. |
void |
invalidate()
Mark this cache area as invalid. |
boolean |
isCluster()
Get the cluster's cache flag. |
boolean |
isValid()
Check, if this cache area is marked as invalid. |
void |
refresh(ICache cache)
Remove all expired entries from the given cache (does a cache.removeEntriesOlderThan(getLastClusterInvalidation())). |
void |
validate()
Mark this cache area as valid. |
| Method Detail |
public java.lang.String getAreaID()
String, which holds the area's ID.public boolean isCluster()
true if the system is running in cluster mode.public long getClusterTimeout()
long with the system's cluster cache timeout in
msec.public void validate()
INVALID to VALID.
public void refresh(ICache cache)
throws CacheException
cache.removeEntriesOlderThan(getLastClusterInvalidation())).cache - the ICache to remove expired entries from.public void invalidate()
public boolean isValid()
true, if state is VALID.public long getLastInvalidation()
getLastExternalInvalidation() and
getLastInternalInvalidation().public long getLastClusterInvalidation()
long with the timestamp of the last incoming
INVALIDATE event.public long getLastNodeInvalidation()
long with the timestamp of the last call to
invalidate().
|
SAP NetWeaver '04 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||