public class PageSubscriptionCounterImpl extends Object implements PageSubscriptionCounter
| Constructor and Description |
|---|
PageSubscriptionCounterImpl(StorageManager storage,
PageSubscription subscription,
Executor executor,
boolean persistent,
long subscriptionID) |
| Modifier and Type | Method and Description |
|---|---|
void |
addInc(long id,
int variance) |
void |
applyIncrement(Transaction tx,
long recordID1,
int add)
This method will install the prepared TXs
|
protected void |
cleanup()
This method should always be called from a single threaded executor
|
void |
delete() |
void |
delete(Transaction tx) |
long |
getValue() |
void |
increment(Transaction tx,
int add) |
void |
incrementProcessed(long id,
int add) |
void |
loadInc(long id,
int add) |
void |
loadValue(long recordID1,
long value1) |
void |
processReload()
This will process the reload
|
void |
setPersistent(boolean persistent)
used on testing only
|
public PageSubscriptionCounterImpl(StorageManager storage, PageSubscription subscription, Executor executor, boolean persistent, long subscriptionID)
public long getValue()
getValue in interface PageSubscriptionCounterpublic void increment(Transaction tx, int add) throws Exception
increment in interface PageSubscriptionCounterExceptionpublic void applyIncrement(Transaction tx, long recordID1, int add)
applyIncrement in interface PageSubscriptionCountertx - recordID1 - add - public void loadValue(long recordID1,
long value1)
loadValue in interface PageSubscriptionCounterpublic void incrementProcessed(long id,
int add)
public void delete()
throws Exception
delete in interface PageSubscriptionCounterExceptionpublic void delete(Transaction tx) throws Exception
delete in interface PageSubscriptionCounterExceptionpublic void loadInc(long id,
int add)
loadInc in interface PageSubscriptionCounterpublic void processReload()
PageSubscriptionCounterprocessReload in interface PageSubscriptionCounterpublic void addInc(long id,
int variance)
addInc in interface PageSubscriptionCounterpublic void setPersistent(boolean persistent)
protected void cleanup()
Copyright © 2013 JBoss, a division of Red Hat. All rights reserved.