This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 161507 - Axis 2 support for inherited metods
Summary: Axis 2 support for inherited metods
Status: RESOLVED WONTFIX
Alias: None
Product: webservices
Classification: Unclassified
Component: Axis2 (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-30 18:17 UTC by sandi_ro
Modified: 2009-04-01 15:42 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description sandi_ro 2009-03-30 18:17:38 UTC
Hi,

I am not sure where to add this report. My best guess it is UI related.

Define a base service class to be used for diferent services. 
Some new services will inherit its methoods but stil the project tree.

Thanks.
Comment 1 Jiri Prox 2009-04-01 09:24:47 UTC
Reassigning to web service, please evaluate.

Anyway this seems like enhancement to me.
Comment 2 sandi_ro 2009-04-01 10:41:44 UTC
It may be a feature request, do we expect such inherited methods to appear in the project tree ? 
Comment 3 Milan Kuchtiak 2009-04-01 12:33:23 UTC
Is there anything in Axis2 runtime that supports this ?

It looks like you have a specific requirement that is not supported in Axis2:java2wsdl utility. 
Netbeans cannot do much about that.

As I understand you require this :
Example :

Super class:
=====
public class Hello {

    public String hello() {
        return "hello";
    }
}
=====
Service implementation class:
=====
public class HelloService extends Hello {

    public String hello1(String name) {
        return "Hello "+name;
    }   
}
=====
Axis configuration file (services.xml):
<?xml version="1.0" encoding="UTF-8"?>
<serviceGroup>
    <service name="HelloService" scope="application">
        <description>HelloService service</description>
        <messageReceivers>
            <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only"
class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/>
            <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out"
class="org.apache.axis2.rpc.receivers.RPCMessageReceiver"/>
        </messageReceivers>
        <parameter name="ServiceClass">services.hello.HelloService</parameter>
    </service>
</serviceGroup>
=====

Now, unfortunately, the generated wsdl file contains just one WS operation: operation generated for hello1 method.
Axis2:java2wsdl accepts just methods present in HelloService.java class, even when HelloService inherits another method
from Hello.java class.

The solution is to encapsulate hello() method in HelloService.java :
=====
public class HelloService extends Hello {

    public String hello1(String name) {
        return "Hello "+name;
    }

    public String hello() {
        return super.hello();
    }
    
}
=====

Or is there anything I miss ?
Please, send an example and attach the screenshot of the project tree to see what's bad there. 
Comment 4 sandi_ro 2009-04-01 12:43:29 UTC
Your understanding is correct.

I will fill a request to axis2 team .  Thanks.
Comment 5 Milan Kuchtiak 2009-04-01 15:42:34 UTC
Thanks.
So I am closing this enhancement as WONT FIX.