java.lang.Object
colesico.framework.pebble.internal.T9nFilter
- All Implemented Interfaces:
io.pebbletemplates.pebble.extension.Filter,io.pebbletemplates.pebble.extension.NamedArguments
This filter perform string translation by previously loaded dictionary (with t9nDictionary tag)
Filter usage example: {{ "myStringKey" | t9n }} - for dictionary name 'messages' {{ "myStringKey" | t9n(myName) }} - for dictionary name 'myName' {{ "myStringKey" | t9n([param1, param2]) }} - for dictionary name 'messages' {{ "myStringKey" | t9n(myName,[param1, param2]) }} - for dictionary name 'myName'
- Author:
- Vladlen Larionov
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
FILTER_NAME
- See Also:
-
-
Constructor Details
-
T9nFilter
public T9nFilter()
-
-
Method Details
-
getArgumentNames
- Specified by:
getArgumentNamesin interfaceio.pebbletemplates.pebble.extension.NamedArguments
-
apply
public Object apply(Object input, Map<String, Object> args, io.pebbletemplates.pebble.template.PebbleTemplate pebbleTemplate, io.pebbletemplates.pebble.template.EvaluationContext evaluationContext, int lineNumber) throws io.pebbletemplates.pebble.error.PebbleException- Specified by:
applyin interfaceio.pebbletemplates.pebble.extension.Filter- Throws:
io.pebbletemplates.pebble.error.PebbleException
-