Package httl.spi

Examples of httl.spi.Filter


    if (result instanceof Template) {
      ((Template) result).render(out);
    } else {
      Formatter<Object> format = (Formatter<Object>) Context.getContext().get(formatterVariable, formatter);
      String text = format == null ? StringUtils.toString(result) : format.toString(null, result);
      Filter filter = (Filter) Context.getContext().get(filterVariable, valueFilter);
      if (! node.isNoFilter() && filter != null) {
        text =  filter.filter(node.getExpression().toString(), text);
      }
      try {
        if (text != null) {
          if (out instanceof Writer) {
            ((Writer) out).write(text);
View Full Code Here


  }

  @Override
  public void visit(Text node) throws IOException, ParseException {
    String txt = node.getContent();
    Filter filter = filterReference.get();
    if (textFilterSwitcher != null || valueFilterSwitcher != null || formatterSwitcher != null) {
      Set<String> locations = new HashSet<String>();
      List<String> textLocations = textFilterSwitcher == null ? null : textFilterSwitcher.locations();
      if (textLocations != null) {
        locations.addAll(textLocations);
View Full Code Here

TOP

Related Classes of httl.spi.Filter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.