Package org.spincast.plugins.pebble
Class SpincastPebbleTemplatingEngineConfigDefault
java.lang.Object
org.spincast.plugins.pebble.SpincastPebbleTemplatingEngineConfigDefault
- All Implemented Interfaces:
SpincastPebbleTemplatingEngineConfig
public class SpincastPebbleTemplatingEngineConfigDefault
extends Object
implements SpincastPebbleTemplatingEngineConfig
Default implementation for the configurations of
the Pebble templating engine plugin.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncom.mitchellbosecke.pebble.extension.Extension
Pebble extension to register: allows you to add custom filters, functions, etc.protected SpincastConfig
int
The number of "cache" tag item to keep in cache.int
The number of template item to keep in cache.The path to the template to use to display the validation messages of a Form's field group.The path to the template to use to display the validation messages of a Form' field.boolean
Is the strict variable policy on?
-
Constructor Details
-
SpincastPebbleTemplatingEngineConfigDefault
-
-
Method Details
-
getSpincastConfig
-
getExtension
public com.mitchellbosecke.pebble.extension.Extension getExtension()Description copied from interface:SpincastPebbleTemplatingEngineConfig
Pebble extension to register: allows you to add custom filters, functions, etc.- Specified by:
getExtension
in interfaceSpincastPebbleTemplatingEngineConfig
-
getTemplateCacheItemNbr
public int getTemplateCacheItemNbr()Description copied from interface:SpincastPebbleTemplatingEngineConfig
The number of template item to keep in cache.- Specified by:
getTemplateCacheItemNbr
in interfaceSpincastPebbleTemplatingEngineConfig
- Returns:
- the max number of items to cache. If
<= 0
, thi cache will be disabled.
-
getTagCacheTypeItemNbr
public int getTagCacheTypeItemNbr()Description copied from interface:SpincastPebbleTemplatingEngineConfig
The number of "cache" tag item to keep in cache. more info- Specified by:
getTagCacheTypeItemNbr
in interfaceSpincastPebbleTemplatingEngineConfig
- Returns:
- the max number of items to cache. If
<= 0
, this cache will be disabled.
-
isStrictVariablesEnabled
public boolean isStrictVariablesEnabled()Description copied from interface:SpincastPebbleTemplatingEngineConfig
Is the strict variable policy on?From the doc : "If set to true, Pebble will throw an exception if you try to access a variable or attribute that does not exist (or an attribute of a null variable). If set to false, your template will treat non-existing variables/attributes as null without ever skipping a beat."
- Specified by:
isStrictVariablesEnabled
in interfaceSpincastPebbleTemplatingEngineConfig
-
getValidationMessagesTemplatePath
Description copied from interface:SpincastPebbleTemplatingEngineConfig
The path to the template to use to display the validation messages of a Form' field.- Specified by:
getValidationMessagesTemplatePath
in interfaceSpincastPebbleTemplatingEngineConfig
-
getValidationGroupMessagesTemplatePath
Description copied from interface:SpincastPebbleTemplatingEngineConfig
The path to the template to use to display the validation messages of a Form's field group.- Specified by:
getValidationGroupMessagesTemplatePath
in interfaceSpincastPebbleTemplatingEngineConfig
-