Thanks, Boon Pang. I will certainly take a look at your instructions.

-----Original Message-----
From: Ong Boon Pang [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 29, 2001 9:55 PM
To: [EMAIL PROTECTED]
Subject: Re: SOAP 2.2 plug-in for Tomcat 4.0.1 (Has anybody did it ?)


Hi Lakkavaram,

I wrote a detail step by step instruction in this mail list.
http://marc.theaimsgroup.com/?l=soap-user&m=100199111401559&w=2

This will only work fine if you are using a English/ASCII version of the 
Windows.

Platform I am using:
Sun JDK 1.3.1_01
Tomcat 4.0
SOAP2.2
Win2K

If it still dun work after following my steps.. ask me to sent the binaries 
I am using.

Hope this help.
Boon Pang

At 09:31 AM 10/29/2001 -0500, you wrote:
>Hi,
>
>Has anybody plugged SOAP 2.2 into Tomcat 4.0.1 ?
>At web site, there are instructions on how to plug into TomCat 3.2 and not
>for
>TomCat 4.0.1.
>For example, there is no "tomcat.bat" in TomCat 4.0.1 instllation where one
>is supposed to set the class path.
>
>Thanks,
>ashok
>
>-----Original Message-----
>From: Paramdeep Singh [mailto:[EMAIL PROTECTED]]
>Sent: Monday, October 29, 2001 9:19 AM
>To: [EMAIL PROTECTED]
>Subject: Re: Serializers/Deserializers
>
>
>I have developed some serializers for some classes.
>You can have a look at the WSTK from IBM.
>
>It automatically generates the serializers/deserializers for you.
>
>With warm regards
>Paramdeep
>
>----- Original Message -----
>From: "David Turner" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Sent: Thursday, October 25, 2001 7:42 PM
>Subject: Serializers/Deserializers
>
>
> > Has anyone developed their own serializers & deserializers for their
> > classes instead of using the BeanSerializer?
> >
> > I've attempted to write my own serializer/deserializer for the
> > java.net.URL class in order to pass URL's to my service method, but the
> > server sends back a fault:
> >       Fault Code = SOAP-ENV:Server.Exception:
> >       Fault String = org/apache/soap/util/xml/Deserializer
> >
> > I've attempted to write serializers/deserializers for a simple class
> > also (class contains only Strings) instead of the BeanSerializer and I
> > still get the above exception.
> >
> > Anybody know what's going wroing?  How do you set this up on both the
> > client and server (deployment descr)?
> >
> > Below is the code:
> >
> > Deployment Descriptor
> >
--------------------------------------------------------------------------
>------------------------------------
> >
> > <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment";
> >              id="urn:SimpleURLService">
> >   <isd:provider type="java"
> >                 scope="Session"
> >                 methods="serviceMethod">
> >     <isd:java
> > class="examples.omnitide.SimpleURLService.SimpleURLService"
> > static="false"/>
> >   </isd:provider>
> >
> >
> >
><isd:faultListener>org.apache.soap.server.DOMFaultListener</isd:faultListen
e
>r>
> >
> >   <isd:mappings>
> >     <isd:map encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";
> >              xmlns:xsd="http://www.w3.org/1999/XMLSchema";
> > qname="xsd:URL"
> >              javaType="java.net.URL"
> >
> > xml2JavaClassName="examples.omnitide.SimpleURLService.URLDeserializer"/>
> >
> >   </isd:mappings>
> >
> > </isd:service>
> >
> >
> >
> > Client that calls soap service
> >
--------------------------------------------------------------------------
>------------------------------------
> >
> >       // Map the types
> >        SOAPMappingRegistry smr = new SOAPMappingRegistry();
> >
> >        URLSerializer ser = new URLSerializer();
> >        URLDeserializer des = new URLDeserializer();
> >
> >        smr.mapTypes(Constants.NS_URI_SOAP_ENC, new
> > QName("urn:SimpleURLService", "URL"),
> >            URL.class, ser, des);
> >
> >        // Build the call
> >        Call call = new Call();
> >        call.setSOAPMappingRegistry(smr);
> >        call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
> >        call.setTargetObjectURI("urn:SimpleURLService");
> >        call.setMethodName("serviceMethod");
> >
> >        Vector params = new Vector();
> >        params.addElement(new Parameter("request", URL.class, url,
> > null));
> >        call.setParams(params);
> >
> >
> >
> > Serializer
> >
--------------------------------------------------------------------------
>------------------------------------
> >
> > import java.net.URL;
> >
> > public class URLSerializer implements Serializer
> > {
> >
> >   public void marshall(String inScopeEncStyle, Class javaType, Object
> > src,
> >                        Object context, Writer sink, NSStack nsStack,
> >                        XMLJavaMappingRegistry xjmr, SOAPContext ctx)
> >                         throws IllegalArgumentException, IOException
> >   {
> >       nsStack.pushScope();
> >
> >       SoapEncUtils.generateStructureHeader(inScopeEncStyle, javaType,
> > context,
> >                                           sink, nsStack, xjmr);
> >
> >       sink.write(StringUtils.lineSeparator);
> >
> >       URL src2 = (URL) src;
> >
> >       Parameter param;
> >
> >       param = new Parameter("URL", String.class, src2.toString(), null);
> >
> >       xjmr.marshall(inScopeEncStyle, Parameter.class, param, null,
> >                     sink, nsStack, ctx);
> >       sink.write(StringUtils.lineSeparator);
> >
> >       sink.write("</" + context + ">");
> >
> >       nsStack.popScope();
> >   }
> > }
> >
> >
> >
> > Deserializer
> >
--------------------------------------------------------------------------
>------------------------------------
> >
> > public class URLDeserializer implements Deserializer
> > {
> >   public Bean unmarshall(String inScopeEncStyle, QName elementType, Node
> > src,
> >                          XMLJavaMappingRegistry xjmr, SOAPContext ctx)
> >                           throws IllegalArgumentException
> >   {
> >     Element root = (Element)src;
> >     Element tempEl = DOMUtils.getFirstChildElement(root);
> >
> >     URL url = null;
> >
> >     while (tempEl != null)
> >     {
> >         Bean paramBean = xjmr.unmarshall(inScopeEncStyle,
> > RPCConstants.Q_ELEM_PARAMETER,
> >                                          tempEl, ctx);
> >         Parameter param = (Parameter)paramBean.value;
> >         String tagName = tempEl.getTagName();
> >
> >         if (tagName.equals("URL"))
> >         {
> >             try
> >             {
> >                 url = new URL( (String)param.getValue() );
> >             }
> >             catch (Exception e)
> >             {
> >                 throw new IllegalArgumentException("Problem
> > instantianting bean: " + e.getMessage());
> >             }
> >
> >         }
> >
> >         tempEl = DOMUtils.getNextSiblingElement(tempEl);
> >     }
> >
> >
> >     return new Bean(URL.class, url);
> >   }
> > }
>
>
>_________________________________________________________
>Do You Yahoo!?
>Get your free @yahoo.com address at http://mail.yahoo.com

Reply via email to