P - The type of the page to be storedpublic abstract class AbstractCachingPageStore<P> extends AbstractPageStore
IPageStore that uses
SecondLevelPageCache to cache the stored pages in memory| Modifier and Type | Field and Description |
|---|---|
protected SecondLevelPageCache<String,Integer,P> |
pagesCache
The cache implementation
|
dataStore, pageSerializer| Modifier | Constructor and Description |
|---|---|
protected |
AbstractCachingPageStore(ISerializer pageSerializer,
IDataStore dataStore,
SecondLevelPageCache<String,Integer,P> pagesCache)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Destroy the store.
|
IManageablePage |
getPage(String sessionId,
int pageId)
Restores a page from the persistent layer.
|
void |
removePage(String sessionId,
int pageId)
Removes a page from the persistent layer.
|
void |
storePage(String sessionId,
IManageablePage page)
Stores the page to a persistent layer.
|
void |
unbind(String sessionId)
The page store should cleanup all the pages for that sessionid.
|
deserializePage, getPageData, prepareForSerialization, removePageData, removePageData, restoreAfterSerialization, serializePage, storePageDataclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitconvertToPageprotected final SecondLevelPageCache<String,Integer,P> pagesCache
protected AbstractCachingPageStore(ISerializer pageSerializer, IDataStore dataStore, SecondLevelPageCache<String,Integer,P> pagesCache)
pageSerializer - The serializer that will convert pages to/from byte[]dataStore - The third level page cachepagesCache - The cache to use as a second level storepublic IManageablePage getPage(String sessionId, int pageId)
IPageStoresessionId - The session of the page that must be removedpageId - The id of the page.public void removePage(String sessionId, int pageId)
IPageStoresessionId - The session of the page that must be removedpageId - The id of the page.public void storePage(String sessionId, IManageablePage page)
IPageStoresessionId - The session of the page that must be removedpage - The page to storepublic void unbind(String sessionId)
IPageStoresessionId - The session of the page that must be removedpublic void destroy()
IPageStoredestroy in interface IPageStoredestroy in class AbstractPageStoreCopyright © 2006–2014 Apache Software Foundation. All rights reserved.