You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Wei Hsu <wh...@openharbor.com> on 2004/06/28 20:55:41 UTC

BeanSerializer and xml attributes

Hi all,

 

I was wondering if anyone knows whether axis's BeanSerializer actually
supports xml attributes.  Currently when I try to send a doc/lit wrapped
message with the following xml element:

 

<createStuff>

  <Stuff propStr2="b">

    <propStr1>a</propStr1>

    <propInt1>2</propInt1>

  </Stuff>

</createStuff>

 

The BeanSerializer always ignores the attribute "propStr2" and calls
createStuff("a", 2, null).  It seems somewhat intuitive that the
BeanSerializer should be configurable to take the attribute and use the
corresponding getters/setters on the server side.  Is there any reason why
that's not the case right now?  Do I have to create my own
serializer/deserializer if I want to use XML attributes?   I would really
appreciate any info or help.  Thanks!

 

-Wei


RE: BeanSerializer and xml attributes

Posted by Anne Thomas Manes <an...@manes.net>.
Per the definition of "wrapped" in JAX-RPC (and in the way .NET works),
wrapped does not support attributes - only a sequence of elements.
 
  _____  

From: Wei Hsu [mailto:whsu@openharbor.com] 
Sent: Monday, June 28, 2004 11:56 AM
To: axis-user@ws.apache.org
Subject: BeanSerializer and xml attributes
 
Hi all,
 
I was wondering if anyone knows whether axis's BeanSerializer actually
supports xml attributes.  Currently when I try to send a doc/lit wrapped
message with the following xml element:
 
<createStuff>
  <Stuff propStr2="b">
    <propStr1>a</propStr1>
    <propInt1>2</propInt1>
  </Stuff>
</createStuff>
 
The BeanSerializer always ignores the attribute "propStr2" and calls
createStuff("a", 2, null).  It seems somewhat intuitive that the
BeanSerializer should be configurable to take the attribute and use the
corresponding getters/setters on the server side.  Is there any reason why
that's not the case right now?  Do I have to create my own
serializer/deserializer if I want to use XML attributes?   I would really
appreciate any info or help.  Thanks!
 
-Wei

Echo base 64

Posted by Mayur Shetye <ma...@yahoo.com>.
hello friends 

i am writing a webservice which sends one or more
files from a directory encoded in base 64 format . The
web service echos them back. i wanted to know a couple
of things .
  1. how do I associate the name of the files with the
binary encoded data?

  2. I am sending you the WSDL .  What do I put in the
schema element , What shall be the input and output in
the <operation> tag ?

  The rudimentary WSDL is as follows . I shall
appreciate any help .

Thanks ,
Mayur
________

<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:y="http://new.webservice.namespace"
targetNamespace="http://new.webservice.namespace">
	<types>
		<xs:schema/>
	</types>
	<message name="messageName">
		<part name="parameter" element=""/>
	</message>
	<portType name="Base64ServiceSOAP">
		<operation name="echoBase64">
			<input name=""	/>
			<output name=""	/>
		</operation>
	</portType>
	<binding name="Base64ServiceSOAP"
type="y:Base64ServiceSOAP">
		<operation name="echoBase64">
			<input/>
			<output/>
		</operation>
	</binding>
	<service name="EchoBase64Service">
		<port name="Base64ServiceSOAP"
binding="y:Base64ServiceSOAP">
			<address
location="http://mustang.cs.binghamton.edu:8080"/>
		</port>
	</service>
</definitions>




		
__________________________________
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail