public String outputAST(String treeString, PrintStream out,
      boolean jsonOutput, int indent) throws JSONException {
    if (out != null) {
      out.print(indentString(indent));
      out.println("ABSTRACT SYNTAX TREE:");
      out.print(indentString(indent + 2));
      out.println(treeString);
    }

    return jsonOutput ? treeString : null;
  }
use case: we want to print the object in explain only if it is true
how to do : print it unless the following 3 are all true:
1. displayOnlyOnTrue tag is on
2. object is boolean
3. object is false
@param exp
@param val
@return
ql/src/java/org/apache/hadoop/hive/ql/exec/ExplainTask.java