public class DmoVersioning
extends java.lang.Object
Note: This class keeps track of changes made within the FWD application server only. No version information is stored within the database, as that would involve an intrusive schema change. So, if a record is modified externally, this tracker will be unaware of the change.
Modifier and Type | Field and Description |
---|---|
private static int |
REFCOUNT
Index of reference count in atomic integer array
|
(package private) static int |
UNVERSIONED
DMO version value which indicates the DMO is not currently being tracked for versioning
|
(package private) static int |
VERSION
Index of current version in atomic integer array
|
private java.util.concurrent.ConcurrentMap<RecordIdentifier<java.lang.String>,java.util.concurrent.atomic.AtomicIntegerArray> |
versions
Map of record identifier to current version information for tracked records
|
Constructor and Description |
---|
DmoVersioning()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
deregister(RecordIdentifier<java.lang.String> ident)
Stop tracking the
|
java.util.concurrent.atomic.AtomicIntegerArray |
register(RecordIdentifier<java.lang.String> ident)
Begin tracking the record represented by the given identifier.
|
static final int UNVERSIONED
static final int VERSION
private static final int REFCOUNT
private java.util.concurrent.ConcurrentMap<RecordIdentifier<java.lang.String>,java.util.concurrent.atomic.AtomicIntegerArray> versions
public java.util.concurrent.atomic.AtomicIntegerArray register(RecordIdentifier<java.lang.String> ident)
Since the data structure uses reference counting to determine whether any user contexts are interested
in this record, it is essential that this method and deregister(RecordIdentifier)
are called
in matching pairs for any record. Otherwise the reference count could get out of balance, creating a
memory leak, or releasing an entry too soon.
ident
- Record identifier unique to the associated database.public void deregister(RecordIdentifier<java.lang.String> ident)
Since the data structure uses reference counting to determine whether any user contexts are interested
in this record, it is essential that this method and register(RecordIdentifier)
are called
in matching pairs for any record. Otherwise the reference count could get out of balance, creating a
memory leak, or releasing an entry too soon.
ident
- Record identifier unique to the associated database.