com.ebmwebsourcing.easycommons.xml
Class SourceHelper

java.lang.Object
  extended by com.ebmwebsourcing.easycommons.xml.SourceHelper

public class SourceHelper
extends Object

Author:
Mathieu CARROLLE - EBM WebSourcing

Constructor Summary
SourceHelper()
           
 
Method Summary
static Source fork(Source source)
          Fork, if necessary, a Source so that consuming the forked one does not consume the original one.
static InputSource sourceToInputSource(Source source, String publicId, String systemId)
          Utility to get the bytes uri
static void toFile(Source source, File fileToWrite)
           
static String toString(Source source)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SourceHelper

public SourceHelper()
Method Detail

toFile

public static void toFile(Source source,
                          File fileToWrite)
                   throws TransformerException,
                          IOException
Throws:
TransformerException
IOException

toString

public static String toString(Source source)
                       throws TransformerException
Throws:
TransformerException

fork

public static Source fork(Source source)
                   throws IOException
Fork, if necessary, a Source so that consuming the forked one does not consume the original one.

Parameters:
source - Source to be forked.
Returns:
Forked Source.
Throws:
IOException

sourceToInputSource

public static InputSource sourceToInputSource(Source source,
                                              String publicId,
                                              String systemId)
Utility to get the bytes uri

Parameters:
source - the resource to get
resolvedUri -
publicId -


Copyright © 2012 Petals Link. All Rights Reserved.