Package org.apache.tools.ant.util

Examples of org.apache.tools.ant.util.TeeOutputStream


        if (command == null) {
            throw new BuildException("Command is required.");
        }

        ByteArrayOutputStream out = new ByteArrayOutputStream();
        TeeOutputStream tee = new TeeOutputStream(out, System.out);

        try {
            // execute the command
            Session session = openSession();
            session.setTimeout((int) maxwait);
View Full Code Here


    /** execute in a forked VM */
    private int run(String[] command) throws BuildException {
        PumpStreamHandler psh =
            new PumpStreamHandler(new LogOutputStream(this, Project.MSG_INFO),
                                  new TeeOutputStream(
                                                      new LogOutputStream(this,
                                                                          Project.MSG_WARN),
                                                      bos)
                                  );
        Execute exe = new Execute(psh, null);
View Full Code Here

            }
            if (logTo.getValue().equals(SendLogTo.FILE)) {
                return f;
            }
        }
        return new TeeOutputStream(l, f);
    }
View Full Code Here

            out = new ByteArrayOutputStream();
        }else{
            out=null;
        }
        if(null!=getSecondaryStream() && null!=out) {
            teeout= new TeeOutputStream(out, getSecondaryStream());
        } else if(null!= getSecondaryStream()){
            teeout= getSecondaryStream();
        }else if(null!=out){
            teeout=out;
        }else{
            teeout=null;
        }
        if(null!=teeout){
            tee = new TeeOutputStream(teeout, new KeepAliveOutputStream(System.out));
        }else{
            tee= new KeepAliveOutputStream(System.out);
        }

        InputStream istream = null ;
View Full Code Here

TOP

Related Classes of org.apache.tools.ant.util.TeeOutputStream

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.