public class PageCursorProviderImpl extends Object implements PageCursorProvider
| Constructor and Description |
|---|
PageCursorProviderImpl(PagingStore pagingStore,
StorageManager storageManager,
Executor executor,
int maxCacheSize) |
| Modifier and Type | Method and Description |
|---|---|
void |
addPageCache(PageCache cache) |
void |
cleanup() |
void |
close(PageSubscription cursor) |
protected PageCacheImpl |
createPageCache(long pageId) |
PageSubscription |
createSubscription(long cursorID,
Filter filter,
boolean persistent) |
void |
flushExecutors() |
PagingStore |
getAssociatedStore() |
int |
getCacheMaxSize() |
int |
getCacheSize() |
PagedMessage |
getMessage(PagePosition pos) |
PageCache |
getPageCache(long pageId) |
PageCache |
getPageCache(PagePosition pos)
No need to synchronize this method since the private getPageCache will have a synchronized call
|
PageSubscription |
getSubscription(long cursorID) |
PagedReference |
newReference(PagePosition pos,
PagedMessage msg,
PageSubscription subscription) |
void |
printDebug() |
void |
processReload() |
void |
scheduleCleanup() |
void |
setCacheMaxSize(int size) |
void |
stop() |
protected void |
storePositions(ArrayList<PageSubscription> cursorList,
Page currentPage) |
public PageCursorProviderImpl(PagingStore pagingStore, StorageManager storageManager, Executor executor, int maxCacheSize)
public PagingStore getAssociatedStore()
getAssociatedStore in interface PageCursorProviderpublic PageSubscription createSubscription(long cursorID, Filter filter, boolean persistent)
createSubscription in interface PageCursorProviderpublic PageSubscription getSubscription(long cursorID)
getSubscription in interface PageCursorProvidercursorID - The cursorID should be the same as the queueId associated for persistancepublic PagedMessage getMessage(PagePosition pos) throws Exception
getMessage in interface PageCursorProviderExceptionpublic PagedReference newReference(PagePosition pos, PagedMessage msg, PageSubscription subscription)
newReference in interface PageCursorProviderpublic PageCache getPageCache(PagePosition pos)
getPageCache in interface PageCursorProviderpublic PageCache getPageCache(long pageId)
public void addPageCache(PageCache cache)
addPageCache in interface PageCursorProviderpublic int getCacheMaxSize()
getCacheMaxSize in interface PageCursorProviderpublic void setCacheMaxSize(int size)
setCacheMaxSize in interface PageCursorProviderpublic int getCacheSize()
getCacheSize in interface PageCursorProviderpublic void processReload()
throws Exception
processReload in interface PageCursorProviderExceptionpublic void stop()
stop in interface PageCursorProviderpublic void flushExecutors()
flushExecutors in interface PageCursorProviderpublic void close(PageSubscription cursor)
close in interface PageCursorProviderpublic void scheduleCleanup()
scheduleCleanup in interface PageCursorProviderpublic void cleanup()
cleanup in interface PageCursorProviderprotected void storePositions(ArrayList<PageSubscription> cursorList, Page currentPage) throws Exception
cursorList - currentPage - Exceptionpublic void printDebug()
printDebug in interface PageCursorProviderprotected PageCacheImpl createPageCache(long pageId) throws Exception
ExceptionCopyright © 2012 JBoss by Red Hat. All Rights Reserved.