Author: ips
Date: Tue May 31 09:05:48 2005
New Revision: 179229
URL: http://svn.apache.org/viewcvs?rev=179229&view=rev
Log:
fixed addChildElement() so it returns a ref to the newly created/added child
element
Modified:
incubator/apollo/trunk/src/java/org/apache/ws/util/XmlBeanUtils.java
Modified: incubator/apollo/trunk/src/java/org/apache/ws/util/XmlBeanUtils.java
URL:
http://svn.apache.org/viewcvs/incubator/apollo/trunk/src/java/org/apache/ws/util/XmlBeanUtils.java?rev=179229&r1=179228&r2=179229&view=diff
==============================================================================
--- incubator/apollo/trunk/src/java/org/apache/ws/util/XmlBeanUtils.java
(original)
+++ incubator/apollo/trunk/src/java/org/apache/ws/util/XmlBeanUtils.java Tue
May 31 09:05:48 2005
@@ -347,6 +347,11 @@
}
newChildNode = parentNode.getOwnerDocument().importNode( newChildNode,
true ); //
parentNode.appendChild( newChildNode );
+ // get a ref to the XmlObject corresponding to the child we've just
added...
+ XmlCursor cursor = parent.newCursor();
+ cursor.toLastChild();
+ newChild = cursor.getObject();
+ cursor.dispose();
return newChild;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]