com.cakupan.xslt.util
Class CoverageIOUtil

java.lang.Object
  extended by com.cakupan.xslt.util.CoverageIOUtil

public class CoverageIOUtil
extends java.lang.Object

util class dealing with IO activities A part of the source is distributed with the Apache 2.0 License http://www.apache.org/licenses/LICENSE-2.0


Constructor Summary
CoverageIOUtil()
           
 
Method Summary
static int copy(java.io.InputStream input, java.io.OutputStream output)
           
static void copy(java.io.InputStream input, java.io.Writer output)
           
static int copy(java.io.Reader input, java.io.Writer output)
           
static long copyLarge(java.io.InputStream input, java.io.OutputStream output)
           
static java.lang.String getDestDir()
          Return the directory path where the coverage file has been written
static java.lang.String getXsltCoverageDir()
          Checks whether system variable xslt.coverage.dir is set to true in order to get the dir of the coverage xml
static void saveCSSFiles(java.lang.String content, java.net.URI remoteFile)
          save the css files
static void setDestDir(java.io.File destDir)
           
static java.lang.String toString(java.io.InputStream input)
           
static void write(java.lang.String content, java.io.OutputStream stream)
          write date to a outputstream
static void write(java.lang.String content, java.net.URI remoteFile)
          write files to a remote destination
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CoverageIOUtil

public CoverageIOUtil()
Method Detail

getDestDir

public static java.lang.String getDestDir()
                                   throws XSLTCoverageException
Return the directory path where the coverage file has been written

Returns:
the path of the coverage file or null if path not has been set
Throws:
XSLTCoverageException

setDestDir

public static void setDestDir(java.io.File destDir)
Parameters:
destDir - the destDir to set

saveCSSFiles

public static void saveCSSFiles(java.lang.String content,
                                java.net.URI remoteFile)
save the css files

Parameters:
content -
remoteFile -

getXsltCoverageDir

public static java.lang.String getXsltCoverageDir()
                                           throws XSLTCoverageException
Checks whether system variable xslt.coverage.dir is set to true in order to get the dir of the coverage xml

Returns:
coverage dir
Throws:
XSLTCoverageException

write

public static void write(java.lang.String content,
                         java.net.URI remoteFile)
                  throws java.io.IOException
write files to a remote destination

Parameters:
content -
remoteFile -
Throws:
java.io.IOException

write

public static void write(java.lang.String content,
                         java.io.OutputStream stream)
                  throws java.io.IOException
write date to a outputstream

Parameters:
content -
stream - outputstream
Throws:
java.io.IOException

copy

public static int copy(java.io.InputStream input,
                       java.io.OutputStream output)
                throws java.io.IOException
Throws:
java.io.IOException

copyLarge

public static long copyLarge(java.io.InputStream input,
                             java.io.OutputStream output)
                      throws java.io.IOException
Throws:
java.io.IOException

toString

public static java.lang.String toString(java.io.InputStream input)
                                 throws java.io.IOException
Throws:
java.io.IOException

copy

public static void copy(java.io.InputStream input,
                        java.io.Writer output)
                 throws java.io.IOException
Throws:
java.io.IOException

copy

public static int copy(java.io.Reader input,
                       java.io.Writer output)
                throws java.io.IOException
Throws:
java.io.IOException