|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthu.midori.kosmos.server.AbstractKosmosService
public abstract class AbstractKosmosService
Each Kosmos service must extend this baseclass. Services are implemented as POJOs.
Field Summary | |
---|---|
protected org.springframework.web.context.WebApplicationContext |
applicationContext
Spring web-application context. |
protected static int |
MAX_LIST_SIZE
Heavy lists will be trimmed to this size or set to -1 if you want to disable trimming. |
Constructor Summary | |
---|---|
AbstractKosmosService()
|
Method Summary | |
---|---|
protected void |
beginStoreSession()
Must be called before the first file gets stored. |
protected void |
endStoreSession()
Must be called after the last file got stored. |
protected java.lang.String |
getResourceString(java.lang.String baseName,
java.lang.String key)
Returns the localized string resource from the given resource bundle. |
java.util.Date |
getTimestamp()
Returns the timestamp when the cache was most recently updated. |
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
|
void |
setStore(StaticContentStore store)
|
protected ZoomableImageLocator |
storeChart(java.lang.String fileName,
org.jfree.chart.JFreeChart chart)
Stores the images generated from the passed chart in 2 resolutions. |
protected java.lang.String |
storeFile(java.lang.String fileName,
java.io.InputStream in)
Stores the passed stream to an implementation-dependent "storage". |
protected java.util.List |
trimList(java.util.List data)
Trims long lists to some limited size to avoid large datasets that would result in huge network transfers and unuseable web pages. |
protected void |
updateTimestamp()
Updates the timestamp at service method calls. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final int MAX_LIST_SIZE
trimList(List)
,
Constant Field Valuesprotected org.springframework.web.context.WebApplicationContext applicationContext
Constructor Detail |
---|
public AbstractKosmosService()
Method Detail |
---|
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
org.springframework.beans.BeansException
public void setStore(StaticContentStore store)
public java.util.Date getTimestamp()
protected void updateTimestamp()
protected java.lang.String getResourceString(java.lang.String baseName, java.lang.String key)
protected void beginStoreSession()
StaticContentStore
protected void endStoreSession()
StaticContentStore
protected java.lang.String storeFile(java.lang.String fileName, java.io.InputStream in)
StaticContentStore
protected ZoomableImageLocator storeChart(java.lang.String fileName, org.jfree.chart.JFreeChart chart)
fileName
- must not contain the file extension.
storeFile(String, InputStream)
protected java.util.List trimList(java.util.List data)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |