You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Dmitri Colebatch <di...@bigpond.net.au> on 2001/08/16 04:41:57 UTC

configuring java class service

hey all,

I'm relatively new to soap and hence the apache soap package.  My
understanding is that you can (serlialization issues aside) basically grab
any java class, and expose it through soap.  Now what apache soap does is
create an instance of the class at the appropriate time (depending on the
scope of the class).  My question is related to this point - soap uses the
default constructor yes?  What I think might be worthwhile would be to
allow the deployment descriptor to look like:

  <isd:provider type="java"
                scope="Application"
                methods="foo bar">
    <isd:java class="MyClass" static="false">
      <arg type="java.lang.String">to be passed to constructor</arg>
    </isd:java>
  </isd:provider>

which would then use the constructor MyClass("to be passed to
constructor") instead of MyClass() - following JMX's flavour.  Does this
make sense?  

I suppose my first question is, am I missing something here?  Obviously
what I'm trying to do is customize the class performing the service, in
this case, know where to get a db connection from.  If there's another way
to do this already, then I'd love to know it, otherwise, does anyone else
see a need for this?

cheesr
dim