Package railo.runtime.dump

Examples of railo.runtime.dump.DumpWriter


        pageContext.setVariable(variable,new Double(exe));
    }
    else {
      DumpTable table = new DumpTable("#ff9900","#ffcc00","#000000");
      table.appendRow(1,new SimpleDumpData(label==null?"Stopwatch":label),new SimpleDumpData(exe));
      DumpWriter writer=pageContext.getConfig().getDefaultDumpWriter(DumpWriter.DEFAULT_RICH);
      try {
       
        pageContext.forceWrite(writer.toString(pageContext,table,true));
      }
      catch (IOException e) {}
    }
    return EVAL_PAGE;
  }
View Full Code Here


          outputRes=ResourceUtil.toResourceNotExisting(pc, output);
        }
      }
     
      // format
      DumpWriter writer=pc.getConfig().getDumpWriter(format,defType);
     
      Set setShow=(show!=null)?ListUtil.listToSet(show.toLowerCase(),",",true):null;
      Set setHide=(hide!=null)?ListUtil.listToSet(hide.toLowerCase(),",",true):null;
     
      DumpProperties properties=new DumpProperties((int)maxLevel,setShow,setHide,(int)keys,metainfo,showUDFs);
      DumpData dd = DumpUtil.toDumpData(object, pc,(int)maxLevel,properties);
     
      if(!StringUtil.isEmpty(label)) {
        DumpTable table=new DumpTable("#ffffff","#cccccc","#000000");
        table.appendRow(1,new SimpleDumpData(label));
        //table.appendRow(1,new SimpleDumpData(getContext()));
        table.appendRow(0,dd);
        dd=table;
      }
     
      boolean isText="text".equalsIgnoreCase(format);//formatType==FORMAT_TYPE_TEXT
      if(OUTPUT_TYPE_BROWSER==outputType || outputType==OUTPUT_TYPE_NONE) {
        if(isText) pc.forceWrite("<pre>");
        pc.forceWrite(writer.toString(pc,dd,expand));
        if(isText) pc.forceWrite("</pre>");
      }
      else if(OUTPUT_TYPE_CONSOLE==outputType)
        System.out.println(writer.toString(pc,dd,expand));
      else if(OUTPUT_TYPE_RESOURCE==outputType)
        IOUtil.write(
            outputRes,
            writer.toString(pc,dd,expand)+
            "\n************************************************************************************\n",
            pc.getConfig().getResourceCharset(), true);
     
    }
    catch (IOException e) {
View Full Code Here

TOP

Related Classes of railo.runtime.dump.DumpWriter

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.