users@glassfish.java.net

Re: No Complex Types in WebService Operations?

From: NBW <emailnbw_at_gmail.com>
Date: Tue, 17 Feb 2009 14:41:49 -0500

There is no support for interfaces, the closest you can get is to use an
abstract base class as your return type. Then you can use
@XmlSeeAlso({SubClass1.class, SubClass2.class}) on your abstract class. This
will tell JAXB to take care of the binding associations. Check out the JAXB
annotations java doc for more info on it.

Yes, I agree not supporting interfaces is a weakness. Also JAXB does not
seem to support static properties either.

As to your other point, I work Java classes -> WSDL.

On Tue, Feb 17, 2009 at 2:11 PM, <glassfish_at_javadesktop.org> wrote:

> Yes, I am using NetBeans, which is fairly new to me (I've used Eclipse for
> years). I'll look into maven2 as you suggest.
>
> That's interesting what you say about the absence of support for
> interfaces. I would much rather use Interfaces to define all my types. Is
> there NO support or is there a workaround?
>
> Currently our philosophy is to go Schema and WSDL first. Then go from
> there. But I've been running into some limitations on how I can arrange my
> WSDL and Schema files. We keep our common types in a centralized Schema xsd
> (CommonTypes.xsd). We also keep some common WSDL constructs (like Fault
> Messages) in a common.wsdl file that we import into most of our service
> specific WSDL files. I'm finding that if you have multiple imports to the
> same schema file, the ws-import fails because it finds the generated class
> is already present. Do you know if there's a way to tell the importer to
> ignore that?
>
> Thanks for you time and effort...
>
> Mike
>
>
> Thanks,
>
> Mike
> [Message sent by forum member 'foobycho' (foobycho)]
>
> http://forums.java.net/jive/thread.jspa?messageID=332397
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>