Package org.craftercms.core.service
Class ContextImpl
java.lang.Object
org.craftercms.core.service.ContextImpl
- Direct Known Subclasses:
FileSystemContext
Default
Context implementation.- Author:
- Sumer Jabri, Alfonso Vásquez
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected booleanprotected longprotected Stringprotected booleanprotected intprotected booleanprotected Stringprotected ContentStoreAdapterFields inherited from interface org.craftercms.core.service.Context
DEFAULT_CACHE_ON, DEFAULT_IGNORE_HIDDEN_FILES, DEFAULT_MAX_ALLOWED_ITEMS_IN_CACHE, DEFAULT_MERGING_ON -
Constructor Summary
ConstructorsConstructorDescriptionContextImpl(String id, ContentStoreAdapter storeAdapter, String rootFolderPath, boolean mergingOn, boolean cacheOn, int maxAllowedItemsInCache, boolean ignoreHiddenFiles, Map<String, String> configurationVariables) -
Method Summary
Modifier and TypeMethodDescriptionclone()booleanlongConfig variables for the context. e.g.: ${siteName} will be replaced by the value of the siteName variablegetId()intinthashCode()booleanbooleanbooleanvoidsetCacheVersion(long cacheVersion) toString()
-
Field Details
-
CACHE_SCOPE_FORMAT
- See Also:
-
id
-
storeAdapter
-
rootFolderPath
-
mergingOn
protected boolean mergingOn -
cacheOn
protected boolean cacheOn -
cacheVersion
protected volatile long cacheVersion -
maxAllowedItemsInCache
protected int maxAllowedItemsInCache -
ignoreHiddenFiles
protected boolean ignoreHiddenFiles -
configurationVariables
-
-
Constructor Details
-
ContextImpl
-
-
Method Details
-
getId
-
getCacheVersion
public long getCacheVersion()- Specified by:
getCacheVersionin interfaceContext
-
setCacheVersion
public void setCacheVersion(long cacheVersion) - Specified by:
setCacheVersionin interfaceContext
-
getCacheScope
- Specified by:
getCacheScopein interfaceContext
-
getStoreAdapter
- Specified by:
getStoreAdapterin interfaceContext
-
isMergingOn
public boolean isMergingOn()- Specified by:
isMergingOnin interfaceContext
-
isCacheOn
public boolean isCacheOn() -
getMaxAllowedItemsInCache
public int getMaxAllowedItemsInCache()- Specified by:
getMaxAllowedItemsInCachein interfaceContext
-
ignoreHiddenFiles
public boolean ignoreHiddenFiles()- Specified by:
ignoreHiddenFilesin interfaceContext
-
getConfigLookupVariables
Description copied from interface:ContextConfig variables for the context. e.g.: ${siteName} will be replaced by the value of the siteName variable- Specified by:
getConfigLookupVariablesin interfaceContext- Returns:
- Return a map of variables to be used when loading configuration files.
-
clone
-
equals
-
hashCode
public int hashCode() -
toString
-