Thanks. I have also found apache org.apache.xmlbeans.XmlCalendar class
to convert a string to Calendar.

-----Original Message-----
From: Bhatra, Junaid [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, October 04, 2006 5:02 PM
To: [email protected]
Subject: RE: Axis2 questions

See org.apache.axis2.databinding.typemapping.SimpleTypeMapper. It has
utility methods for XML --> Java type conversions, including
Date/Calendar.

- Junaid

-----Original Message-----
From: Gul Onural [mailto:[EMAIL PROTECTED]
Sent: Wednesday, October 04, 2006 3:00 PM
To: [email protected]
Subject: RE: Axis2 questions



I am using raw XML message receivers. As a result of this, I have a
method accepts an OMElement. One of the xml elements in the OMElement is
in  xml dateTime type. 

Using OMElement method getText(), I can get the value of the element as
a string. However, this is not really useful by itself in my web service
implementation class. I need Java Calendar representation of this string
in my code.

I was wondering how you would construct a Java Calendar class out of
this string. 

Do I have to write my own code to parse this string to construct a Java
Calendar class or is there a way of doing this using Axiom APIs?

Note : I tried to use adb as data binding option. However our wsdl uses
includes of a few xml schemas and neither ADB schema compiler nor
wsdl2java compiler were able to generate binding classes for me. That's
why I use raw XML and avoid generating data binding classes with
wsdl2java, which basically throws whole bunch of exceptions. A JIRA is
yet to be open for this...

Gul
 

-----Original Message-----
From: Srinath Perera [mailto:[EMAIL PROTECTED] 
Sent: Sunday, October 01, 2006 11:51 AM
To: [email protected]
Subject: Re: Axis2 questions

Hi Gul;

Let me try to answer at least few of the questions

RawXMLMessageRecivers are at the top of the invocation of the service
implementation. RPC one is extension of RawXML Message reciver


If you recive RawXMLMessageReciver it does not manage data binding (As
name suggest .. ) it accept and respond with OMElements.

Apprently notion of "simple java class" of yours and same authors seem
to be different :)

If you are ready to handle XML .. you can do as the samples you
mentioned does.

hope this helps
Srinath


On 10/1/06, Gul Onural <[EMAIL PROTECTED]> wrote:
>
>
>
>
> I am trying to understand how to write a service without using the 
> wsdl2java. Our service interface uses fairly complex data types and 
> current status of the wsdl2java is not sufficiently bug-free for my 
> purposes.
>
> I have spent quite a bit time to browse through the samples come with 
> the std distribution and I would appreciate any help on the questions 
> below:
>
> - How does selection of the message receivers affect the service 
> implementation code?
> For example my (very simple) test service works with RPC message 
> receivers but throws type mismatch exception when I change the message

> receivers from RPC to RawXML.
>
> - What is the advantages/disadvantages of using RPC message receivers
vs.
> RawXML message receivers.
>
> - About the service implementation class : Axis2 document claims that 
> a simple Java class can be deployed as an Axis2 service (with a proper

> service.xml, etc...). However when I look at some sample services in
the 
> Axis2 distribution, their methods (operations) are implemented to 
> accept OMElement as input and they return OMElement.
> So, when do I need to deal with the OMElement, and when does a 
> straight forward Java class can be used to do the job as a service.
>
>
> Thanks,
>
>


--
============================
Srinath Perera:
   http://www.cs.indiana.edu/~hperera/
   http://www.bloglines.com/blog/hemapani

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to