public interface ConfigurationCache
Modifier and Type | Method and Description |
---|---|
void |
appendImage(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Appends an image to cache.
|
long |
getAnImageSize(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Gets an image size in memory.
|
java.util.Vector |
getCachedCatalogs()
Returns the file name of the catalog needed to be cached.
|
java.util.Vector |
getCachedImages()
Returns the file name of the image needed to be cached.
|
java.util.Vector |
getCachedReports()
Returns the file names of the report needed to be cached.
|
java.util.Vector |
getCachedReportsWithStyles()
Returns the file names and styles of the report needed to be cached.
|
int |
getCRDMemoryUsage()
Gets the CRD memory usage.
|
boolean |
getDisplayImageDetail()
Returns whether to display the cached images detail.
|
boolean |
getEnableCacheCatelog()
Returns whether to cache the catalog.
|
boolean |
getEnableCacheImage()
Returns whether to cache the image.
|
boolean |
getEnableCacheReport()
Returns whether to cache report.
|
int |
getEngineSortBufferSize()
Gets the size of engine sort buffer from the configuration properties.
|
long |
getExpiredTime()
Gets the expired time of the automatic cache data.
|
java.lang.String |
getImageBelongedCatalog(java.lang.String fullImagePath)
Gets the catalog which the special image belongs to.
|
int |
getMaxCacheCatalogSize()
Returns the max number of the catalogs to be cached.
|
int |
getMaxCacheImageSize()
Returns the max number of the images to be cached.
|
int |
getMaxCacheReportSize()
Returns max number of the reports to be cached.
|
double |
getMaxCubeMemory()
Returns Maximum Cube Memory Allowed, unit is MB.
|
int |
getMaxDiskUsage()
Gets the maximum hard disk space which is used to automatically cache data.
|
int |
getSecurityCacheExpireTime()
Gets the expire time of the security cache object.
|
int |
getSecurityGroupCacheSize()
Gets the security group cache size.
|
int |
getSecurityProectionCacheSize()
Gets the security protection cache size.
|
int |
getSecurityRoleCacheSize()
Gets the security role cache size.
|
int |
getSecurityUserCacheSize()
Gets the security user cache size.
|
long |
getUsedImageCacheSize()
Gets the used image cache size.
|
boolean |
isAutoCache()
Checks whether the automatic cache is enabled.
|
boolean |
isCacheAllImages()
Checks whether to cache all the images.
|
boolean |
isLockedImage(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Checks if the image is locked.
|
boolean |
isNeverExpire()
Checks whether the automatic cache data is never expired.
|
void |
loadProperties()
Loads the properties of server.
|
boolean |
lockCachedImage(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Locks a cached image.
|
void |
removeAllImages()
Removes all the images.
|
void |
removeImage(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Removes an image.
|
void |
saveProperties()
Saves the modified settings to the configuration file (server.properties).
|
void |
setCacheAllImages(boolean isCacheAllImages)
Sets whether to cache all the images.
|
boolean |
setCachedCatalogs(java.lang.String user,
java.util.Vector cachedCatalogs)
Sets the file name of the catalog needed to be cached.
|
boolean |
setCachedCatalogs(java.util.Vector<java.lang.String> cachedCatalogs)
Sets the file names of the catalog needed to be cached.
|
boolean |
setCachedReports(java.util.Vector cachedReports)
Sets the file name of the report needed to be cached.
|
boolean |
setCachedReportsWithStyles(java.lang.String user,
java.util.Vector cachedReportsWithStyles)
Sets the file names and styles of the report needed to be cached.If set successfully, return true;
|
boolean |
setCachedReportsWithStyles(java.util.Vector cachedReportsWithStyles)
Sets the file names and styles of the report needed to cached.
|
void |
setCRDMemoryUsage(int maxMemoryUsage)
Sets the CRD memory usage.
|
void |
setDisplayImageDetail(boolean isDisplay)
Sets whether to display the cached images detail.
|
void |
setEnableAutoCache(boolean isEnableAutoCache)
Enables/disables the automatic cache.
|
void |
setEnableCacheCatelog(boolean isEnableCacheCatelog)
Sets whether to cache the catalog.
|
void |
setEnableCacheImage(boolean isEnableCacheImage)
Sets whether to cache the image.
|
void |
setEnableCacheReport(boolean isEnableCacheReport)
Sets whether to cache report.
|
void |
setEngineSortBufferSize(int size)
Sets the size of the engine sort buffer.
|
void |
setExpiredTime(long expiredTime)
Sets the expired time of the automatic cache data.
|
void |
setMaxCacheCatalogSize(int maxCacheCatalog)
Sets the max number of the catalogs to be cached.
|
void |
setMaxCacheImageSize(int maxCacheImage)
Sets the max number of the images to be cached.
|
void |
setMaxCacheReportSize(int maxCacheReport)
Sets max number of the reports to be cached.
|
void |
setMaxCubeMemory(double memorySize)
Sets Maximum Cube Memory Allowed, unit is MB.
|
void |
setMaxDiskUsage(int maxDiskUsage)
Sets the maximum hard disk space which is used to automatically cache data.
|
void |
setNeverExpire(boolean isNeverExpire)
Sets whether the automatic cache data is never expired.
|
void |
setSecurityCacheExpireTime(int expireTime)
Set the expire time of the security cache object.
|
void |
setSecurityGroupCacheSize(int size)
Sets the security group cache size.
|
void |
setSecurityProtectionCacheSize(int size)
Sets the security protection cache size.
|
void |
setSecurityRoleCacheSize(int size)
Sets the security role cache size.
|
void |
setSecurityUserCacheSize(int size)
Sets the security user cache size.
|
void |
unloadCatalogs(java.lang.String user,
java.util.Vector catalogNames)
Unloads the file name of the catalog form cache.
|
void |
unloadCatalogs(java.util.Vector catalogNames)
Unloads the file name of the catalog form cache.
|
void |
unloadReports(java.util.Vector reportNames)
Unloads the file name of the report needed to be cached.
|
void |
unloadReportsWithStyles(java.lang.String user,
java.util.Vector reportNamesWithStyles)
Unloads the file name and style of the report needed to be cached.
|
void |
unloadReportsWithStyles(java.util.Vector reportNamesWithStyles)
Unloads the file name and style of the report needed to be cached.
|
boolean |
unlockCachedImage(java.lang.String catFile,
java.lang.String imgFile,
java.lang.String user)
Unlocks a cached image.
|
void setEnableCacheCatelog(boolean isEnableCacheCatelog)
isEnableCacheCatelog
- whether to cache the catalog.boolean getEnableCacheCatelog()
void setMaxCacheCatalogSize(int maxCacheCatalog)
maxCacheCatalog
- the max number of the catalogs to be cached.int getMaxCacheCatalogSize()
void setEnableCacheImage(boolean isEnableCacheImage)
isEnableCacheImage
- whether to cache the image.void setDisplayImageDetail(boolean isDisplay)
isDisplay
- whether to display the cached images detail.boolean getEnableCacheImage()
boolean getDisplayImageDetail()
void setMaxCacheImageSize(int maxCacheImage)
maxCacheImage
- the max number of the images to be cached.int getMaxCacheImageSize()
boolean setCachedCatalogs(java.util.Vector<java.lang.String> cachedCatalogs)
cachedCatalogs
- the file name of the catalog needed to be cached.boolean setCachedCatalogs(java.lang.String user, java.util.Vector cachedCatalogs)
user
- the user processing cache.cachedCatalogs
- the file name of the catalog needed to cached.java.util.Vector getCachedImages()
void appendImage(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- catalog file's full path name.imgFileName
- the file name of the image to be appended.user
- the user ID.void removeImage(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- catalog file's full path name.imgFile
- file name of the image to be removed.user
- the user ID.void removeAllImages()
boolean lockCachedImage(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- full path name of the catalog.imgFileName
- file name of the image.user
- the user ID.boolean unlockCachedImage(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- full path name of the catalog.imgFileName
- file name of the image.user
- the user ID.java.lang.String getImageBelongedCatalog(java.lang.String fullImagePath)
fullImagePath
- full path name of the image.boolean isLockedImage(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- : full path name of the catalog file.imgFileName
- the image file name.user
- the user ID.boolean isCacheAllImages()
void setCacheAllImages(boolean isCacheAllImages)
long getUsedImageCacheSize()
long getAnImageSize(java.lang.String catFile, java.lang.String imgFile, java.lang.String user)
catFile
- full path name of the catalog file, such as /SampleReports/Sample.cat.imgFileName
- the image file name.user
- the user ID.java.util.Vector getCachedCatalogs()
void setEnableCacheReport(boolean isEnableCacheReport)
isEnableCacheReport
- whether to cache report.boolean getEnableCacheReport()
void setMaxCacheReportSize(int maxCacheReport)
maxCacheReport
- max number of the reports to be cached.int getMaxCacheReportSize()
boolean setCachedReports(java.util.Vector cachedReports)
cachedReports
- the file name of the report needed to be cached.boolean setCachedReportsWithStyles(java.util.Vector cachedReportsWithStyles)
cachedReportsWithStyles
- the file names and styles of the report needed to be cached.boolean setCachedReportsWithStyles(java.lang.String user, java.util.Vector cachedReportsWithStyles)
cachedReportsWithStyles
- the file names and styles of the report needed to be cached.user
- the user processing cache.java.util.Vector getCachedReports()
java.util.Vector getCachedReportsWithStyles()
void unloadCatalogs(java.util.Vector catalogNames)
catalogNames
- the vector which is the file name of the catalog needed to be unloaded.void unloadCatalogs(java.lang.String user, java.util.Vector catalogNames)
catalogNames
- the vector which is the file name of the catalog needed to be unloaded.void unloadReports(java.util.Vector reportNames)
reportNames
- the vector which is the file name of the report needed to be unloaded.void unloadReportsWithStyles(java.util.Vector reportNamesWithStyles)
reportNamesWithStyles
- the vector which is the file name and style of the report needed to be unloaded.void unloadReportsWithStyles(java.lang.String user, java.util.Vector reportNamesWithStyles)
reportNamesWithStyles
- the vector which is file name and style of the report needed to be unloaded.user
- the user processing cache.void setSecurityUserCacheSize(int size)
size
- int getSecurityUserCacheSize()
void setSecurityRoleCacheSize(int size)
size
- int getSecurityRoleCacheSize()
void setSecurityGroupCacheSize(int size)
size
- int getSecurityGroupCacheSize()
void setSecurityProtectionCacheSize(int size)
size
- int getSecurityProectionCacheSize()
int getSecurityCacheExpireTime()
void setSecurityCacheExpireTime(int expireTime)
the
- expire time of the security cache object, the 0 indicates the cached object will never expire.void loadProperties()
void saveProperties()
int getEngineSortBufferSize()
void setEngineSortBufferSize(int size)
size
- the size of the engine sort buffer.void setCRDMemoryUsage(int maxMemoryUsage)
maxMemoryUsage
- the maximum memory which is used to cache CRD data.
the minimum value of it is 4MB, and it can increase the times of the MB.
the maximum value is JVM current max heap size*80%.int getCRDMemoryUsage()
boolean isAutoCache()
void setEnableAutoCache(boolean isEnableAutoCache)
isEnableAutoCache
- true if the automatic cache is enabled.void setMaxDiskUsage(int maxDiskUsage)
maxDiskUsage
- the maximum hard disk space which is used to cache CRD data.
the minimum value of it is 4MB.
the maximum value is 1024*1024 MB.int getMaxDiskUsage()
boolean isNeverExpire()
void setNeverExpire(boolean isNeverExpire)
isNeverExpire
- true if the automatic cache data is never expired,
false if the expired time is customized.void setExpiredTime(long expiredTime)
expiredTime
- the customized expired time of the automatic cache data.
the unit is second.long getExpiredTime()
double getMaxCubeMemory()
void setMaxCubeMemory(double memorySize)
memorySize
- Maximum Cube Memory Allowed, unit is MB.