Class TruncateHtmlFilter

    • Constructor Detail

      • TruncateHtmlFilter

        public TruncateHtmlFilter()
    • Method Detail

      • filter

        public Object filter​(Object var,
                             JinjavaInterpreter interpreter,
                             Object[] args,
                             Map<String,​Object> kwargs)
        Description copied from interface: AdvancedFilter
        Filter the specified template variable within the context of a render process. {{ myvar|myfiltername(arg1,arg2) }}
        Specified by:
        filter in interface AdvancedFilter
        Specified by:
        filter in interface Filter
        Parameters:
        var - the variable which this filter should operate on
        interpreter - current interpreter context
        args - any positional arguments passed to this filter invocation
        kwargs - any named arguments passed to this filter invocation
        Returns:
        the filtered form of the given variable
      • filter

        public Object filter​(Object var,
                             JinjavaInterpreter interpreter,
                             String... args)
        Description copied from interface: Filter
        Filter the specified template variable within the context of a render process. {{ myvar|myfiltername(arg1,arg2) }}
        Specified by:
        filter in interface AdvancedFilter
        Specified by:
        filter in interface Filter
        Parameters:
        var - the variable which this filter should operate on
        interpreter - current interpreter context
        args - any arguments passed to this filter invocation
        Returns:
        the filtered form of the given variable