W-Beans for XML

com.oldlight.weaver.weaverbeans.xml
Class XParseBean

java.lang.Object
  extended bycom.oldlight.weaver.weaverbeans.xml.XParseBean

public class XParseBean
extends Object

XParseBean parses an XML file in to a DOM tree which it then stores in a scoped attribute.

Author:
Paul Harvey
WBean Parameters
NameScopeClassMandatoryComment
xmlbeanString,Reader,InputStreamYesThis attribute may evaluate to a java.io.Reader, to a java.io.InputStream or to a String. If the value is a Reader or an InputStream then its content is read and parsed. If the value is a String and it begins with "file://" then the remainder of the value is assumed to be the path to a file containing the XML to parse, otherwise the String is assumed to contain the XML itself.
varbeanjava.lang.StringYesThe name of the attribute to store the DOM tree in.
scopebeanjava.lang.StringNoThe scope from which the attribute to store the DOM tree in. If scope is not specified then the local scope is used.

To use in your wad.xml import as follows:

<load-beans>
...
   <bean name="CHOOSE_A_NAME" class="com.oldlight.weaver.weaverbeans.xml.XParseBean"/>
...
</load-beans>

Constructor Summary
XParseBean()
           
 
Method Summary
 void handle(WeaverExecutionContext context)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XParseBean

public XParseBean()
Method Detail

handle

public void handle(WeaverExecutionContext context)
            throws WeaverClientException
Throws:
WeaverClientException

Copyright ©Paul Harvey