Hi all,
Newbie here, so please excuse if this is trivial or have been covered
before. I've inherited some web service code which uses Spring remoting for
XFire setup. I have an API which accepts, let's say, class A as a parameter.
When I invoke this API with an instance of A, everything is fine and dandy.
However, when I invoke this same API with a null value, I get the following
exception:
Caused by: javax.xml.stream.XMLStreamException: Trying to write an attribute
when there is no open start element.
at
com.ctc.wstx.sw.BaseStreamWriter.throwOutputError(BaseStreamWriter.java:1396)
at
com.ctc.wstx.sw.SimpleNsStreamWriter.writeAttribute(SimpleNsStreamWriter.java:94)
at
org.codehaus.xfire.aegis.stax.AttributeWriter.writeValue(AttributeWriter.java:45)
... 18 more
The call doesn't even reach my implementation method on the server host. Has
anyone seen this before? I'm guessing this is a configuration(?) problem so
if you need to see what my config files are like, I can post them as well.
One thing I forgot to mention - the parameter of class A is a simple POJO
where I've added the @XmlElement annotation to each attribute with the
nillable property set to "true". I thought that setting these attributes to
nillable would enable me to pass a null value parameter, but that didn't
work either. Any pointers for the newbie?
Thanks,
-Terry
--
View this message in context:
http://www.nabble.com/Passing-null-parameter-tf3837307.html#a10864739
Sent from the XFire - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email