axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sagar Pidaparthi" <Sagar.Pidapar...@chordiant.com>
Subject RE: Java2WSDL Error - Please register a typemapping/beanmapping for
Date Fri, 27 Aug 2004 21:02:12 GMT

If you don't use an ant task here is a possible solution.

Edit and copy the following line to your Server-config.wsdd and restart
your server.

<beanMapping qname="ns:local" 
		 xmlns:ns="someNamespace"
    		 languageSpecificType="java:my.package.MyException"/>


here is another example

<beanMapping 	qname="ns60:Customer" 
  			xmlns:ns60="urn:com.c.bs.cib"/>
	
languageSpecificType="java:com.c.bs.cib.Customer"

It is also possible to auto generate all the required mappings using
wsdl2java command to wsdd file and then use deploy command to copy the
mapping to server-config file.

You may find it easier to edit server-config.wsdd if you are dealing
with just one case.


I hope this helps.

Sagar


Ps:  Please find below the relevant documentation about adding
beenmapping information to your server-config
file.___________________________________________



Encoding Your Beans - the BeanSerializer
Axis includes the ability to serialize/deserialize, without writing any
code, arbitrary Java classes which follow the standard JavaBean pattern
of get/set accessors. All you need to do is tell Axis which Java classes
map to which XML Schema types. Configuring a bean mapping looks like
this:

<beanMapping qname="ns:local" xmlns:ns="someNamespace"
    languageSpecificType="java:my.java.thingy"/>
The <beanMapping> tag maps a Java class (presumably a bean) to an XML
QName. You'll note that it has two important attributes, qname and
languageSpecificType. So in this case, we'd be mapping the
"my.java.thingy" class to the XML QName [someNamespace]:[local].


-----Original Message-----
From: Gerlach, Daryl CTR (NAVSISA Code 942)
[mailto:daryl.gerlach@navy.mil] 
Sent: Friday, August 27, 2004 1:37 PM
To: axis-user@ws.apache.org
Subject: Java2WSDL Error - Please register a typemapping/beanmapping for

I have an existing application that I am attempting to turn into a web
service. I am using Axis 1.2 beta Java2WSDL using Document/Literal
settings to generate the WSDL from Java source. The methods return
custom exceptions.  When I run Java2WSDL I get the following error
message:

Please register a typemapping/beanmapping for 'my.package.MyException'

Where and how I a register this custom exception type?

MyException extends java.lang.Exception

Daryl E. Gerlach

Mime
View raw message