You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Peter Danielsen <wi...@gmail.com> on 2007/05/26 18:58:15 UTC
Accessing WSDL2 styles in Axis2 codegen emitter templates
Hi,
I've been trying to create an Axis2 code generation template
that would make some decisions based on the value of the "style"
attribute in a WSDL2 document. I'm unable to do so because
that value doesn't appear in the DOM created by the
AxisServiceBasedMultiLanguageEmitter. There is a "style" attribute,
but it's related to WSDL1.1.
To accommodate this looks like it would require changes to
1. org.apache.axis2.description.AxisOperation to either
a. change the existing "style" field to a list (since WSDL2
allows multiple styles for an operation) and modifying
getStyle() and setStyle(String) accordingly, or
b. adding a new List<URI> field with something like
List getStyles() and void addStyle(URI style) methods, and
possibly deprecate the existing style-related methods.
2. WSDL20ToAxisServiceBuilder.populateOperations to add the styles
from the Woden InterfaceOperation object to the AxisOperation
object.
3. AxisServiceBasedMultiLanguageEmitter.generateMethodElement to
add an attribute for the styles to the method Element it builds.
While the styles defined in the WSDL2 Adjuncts specification can
be represented by constants, new styles can be defined by anyone
so it would be very useful to preserve the style URIs unchanged
from the WSDL all the way through to the DOMs used by the templates.
Please let me know if I should open a JIRA for this.
Peter Danielsen
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by Peter Danielsen <wi...@gmail.com>.
Sanjiva,
Thanks for your reply. Here are some thoughts on improving codegen's
extensibility. They're from my perspective trying to extend WSDL2.
It would be great to have some documentation describing codegen's
extension architecture.
Woden has a very valuable wiki page at
http://wiki.apache.org/ws/FrontPage/Woden/WSDLExtensions that we used
to successfully add extensions. For Axis2, we're working our way
through the code to learn how it works. It would be helpful to have
something like Woden has. More Javadoc in codegen would also help.
The WSDL2 working group has done a nice job of segregating the work
into the Core spec and the Adjuncts spec. I think it would be
valuable to reflect this in the code. As someone trying to extend
codegen, I'd prefer not to modify codegen framework code because it
does most of what I need. Also, if I change it then I have my own
version and have to periodically check it against the official version
and copy over any bug fixes. That gets tedious and error-prone
quickly.
It would help to refactor some code to modularize support for the main
extension mechanisms of WSDL2: styles, MEPs, and bindings. Currently,
the code supports those that are defined in WSDL2 Adjuncts, but it's
not easy to add support for others since it's often the case that
codegen framework classes also contain Adjuncts-driven code (e.g. SOAP
and HTTP bindings, MEPs).
Examples are WSDL20ToAxisServiceBuilder and
AxisServiceBasedMultilanguageEmitter. It might be easier to
understand and maintain the framework classes if logic specific to
Adjuncts items were factored out to classes devoted to them and
invoked via lookups driven by a properties file, like codegen-config.
An example might be a "BindingProcessor" interface with a SOAP
implementation class and an HTTP implementation class.
WSDL20ToAxisServiceBuilder's "processBinding" method could do a lookup
of a binding URI to find a BindingProcessor and delegate the SOAP or
HTTP work to the appropriate BindingProcessor. I think this would be
preferable to users hand-editing WSDL20ToAxisServiceBuilder.
AxisServiceBasedMultiLanguageEmitter's generateMethodElement has a
similar mixing of framework and Adjuncts work.
A properties file might also be leveraged to register the mapping of
MEP URIs to AxisOperation sub-classes. This would eliminate the need
for users of the framework to directly modify AxisOperationFactory to
add new <MEP, AxisOperation> mappings.
This thread started with my request to have the value of the WSDL2
"style" attribute available to the XSLT templates. I like the XSLT
template approach. I believe it can be improved by ensuring that when
the Emitter produces the DOMs for transformation it doesn't assume
that the templates to be used in the next step are those that shipped
with Axis2. Codegen-config.properties allows users to introduce
others, so I think it's reasonable for template developers to expect
that items defined in WSDL2 Core should be visible somewhere in those
DOMs. This includes the "style" attribute as well as items like
message labels (see
http://marc.info/?l=axis-dev&m=118019901127507&w=2)
I've covered a lot here and offered some possible solutions, but I
think the first step is to look at the codegen architecture and its
extension development process covering new MEPs, new styles, and new
bindings. I hope these comments are useful.
Peter
On 6/1/07, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
> Peter Danielsen wrote:
> >
> > I'm quite interested in Axis2's plans for the accommodation of 3rd
> > party MEPs, styles, and bindings allowed by WSDL2.
>
> We carefully designed Axis2 to support 3rd party MEPs, styles and
> bindings. Please let us know areas where you are having trouble with as
> that shouldn't be the case! Specific suggestions greatly appreciated ..
> and of course code is better!
>
> Thanks,
>
> Sanjiva.
> --
> Sanjiva Weerawarana, Ph.D.
> Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
> Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
> Director; Open Source Initiative; http://www.opensource.org/
> Member; Apache Software Foundation; http://www.apache.org/
> Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
Peter Danielsen wrote:
>
> I'm quite interested in Axis2's plans for the accommodation of 3rd
> party MEPs, styles, and bindings allowed by WSDL2.
We carefully designed Axis2 to support 3rd party MEPs, styles and
bindings. Please let us know areas where you are having trouble with as
that shouldn't be the case! Specific suggestions greatly appreciated ..
and of course code is better!
Thanks,
Sanjiva.
--
Sanjiva Weerawarana, Ph.D.
Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
Director; Open Source Initiative; http://www.opensource.org/
Member; Apache Software Foundation; http://www.apache.org/
Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by Peter Danielsen <wi...@gmail.com>.
Keith,
I agree that the adjuncts spec reference you provided identifies the
pre-defined styles, but I was thinking more about this section in the
core spec:
http://www.w3.org/TR/2007/PR-wsdl20-20070523/#InterfaceOperationStyle
There isn't anything in this section that limits the styles to those
pre-defined in the adjuncts spec and the sentence
"However, the additional information can be used for other purposes,
for example, improved code generation."
was the one that caught my eye and suggested that the styles need to
be available to the codegen XSLT templates.
I'm glad you've added support for WSDL2 styles to AxisOperation, it
just seems like there should be explicit methods to set/get them since
they're part of WSDL2 core, rather than a Parameter which is used for
extensions like wsdlx:safe in WSDL2 adjuncts.
Regarding support for 3rd party MEPs, it looks like this could be
accomplished by restructuring AxisOperationFactory to use a
Map<String, Class> which maps MEP URIs to a sub-class of
AxisOperation, and providing a new static method to allow the
registration of new MEPs.
I'm quite interested in Axis2's plans for the accommodation of 3rd
party MEPs, styles, and bindings allowed by WSDL2.
Peter
On 5/30/07, keith chapman <ke...@gmail.com> wrote:
> We do support all WSDL 2.0 MEPS at the moment. The WSDL 2.0 style has no
> relationship to the WSDL 1.1 Styles (rpc, document), they just enforce
> restrictions on how the element itself will look like. WSDL 2 has defined
> three styles IRI, rpc and multipart. If you look at the spec [1] you will
> see that they just gives a message to the user saying that the messages
> exchange follow this general style.
>
> [1]
> http://dev.w3.org/cvsweb/~checkout~/2002/ws/desc/wsdl20/wsdl20-adjuncts.html?content-type=text/html;%20charset=utf-8#styles
>
> Thanks,
> Keith.
>
>
> On 5/30/07, Peter Danielsen <wi...@gmail.com> wrote:
> > Keith,
> >
> > Thanks for the quick response on this, however, I still have some
> > concerns.
> >
> > I thought that WSDL2's "style" was intended to be a more general
> > replacement for WSDL1's? If that's correct, why is a WSDL2
> > "style" attribute an AxisOperation Parameter while a WSDL1 "style"
> > attribute is a first class member? (It seems like Parameters are
> > intended for extensions). I think it's natural to provide explicit
> > methods for the WSDL2 styles, rather than using Parameters.
> >
> > In general, what's Axis2's plan for accommodating 3rd party styles
> > and MEPs allowed by WSDL2?
> >
> > Thanks,
> >
> >
> > Peter
> >
> >
> > On 5/29/07, keith chapman < keithgchapman@gmail.com> wrote:
> > > Hi Peter,
> > >
> > > I've added the syle attribute to the axisOperation via a Parameter
> > > (WSDL2Constants.OPERATION_STYLE ). I serialize this in ?wsdl2 too. But
> still
> > > we dont capture it in the intermidiate format.
> > >
> > > Thanks,
> > > Keith.
> > >
> > >
> > > On 5/29/07, keith chapman < keithgchapman@gmail.com> wrote:
> > > > Hi Peter,
> > > >
> > > > The reason we didnt capture the style parameter in the intermidiate
> DOM
> > > was because we didnt have to change the stub depending on the style.
> > > Therefore its not captured in axisOperation. May be we should capture it
> so
> > > that we can serialize it into ?wsdl2.
> > > >
> > > > Thanks,
> > > > Keith
> > > >
> > > >
> > > > On 5/26/07, Peter Danielsen < wiscal@gmail.com> wrote:
> > > >
> > > > > Hi,
> > > > >
> > > > > I've been trying to create an Axis2 code generation template
> > > > > that would make some decisions based on the value of the "style"
> > > > > attribute in a WSDL2 document. I'm unable to do so because
> > > > > that value doesn't appear in the DOM created by the
> > > > > AxisServiceBasedMultiLanguageEmitter. There is a
> > > "style" attribute,
> > > > > but it's related to WSDL1.1.
> > > > >
> > > > > To accommodate this looks like it would require changes to
> > > > >
> > > > > 1. org.apache.axis2.description.AxisOperation to
> either
> > > > > a. change the existing "style" field to a list (since WSDL2
> > > > > allows multiple styles for an operation) and modifying
> > > > > getStyle() and setStyle(String) accordingly, or
> > > > > b. adding a new List<URI> field with something like
> > > > > List getStyles() and void addStyle(URI style) methods, and
> > > > > possibly deprecate the existing style-related methods.
> > > > > 2. WSDL20ToAxisServiceBuilder.populateOperations to
> add
> > > the styles
> > > > > from the Woden InterfaceOperation object to the AxisOperation
> > > > > object.
> > > > > 3.
> > >
> AxisServiceBasedMultiLanguageEmitter.generateMethodElement
> > > to
> > > > > add an attribute for the styles to the method Element it builds.
> > > > >
> > > > > While the styles defined in the WSDL2 Adjuncts specification can
> > > > > be represented by constants, new styles can be defined by anyone
> > > > > so it would be very useful to preserve the style URIs unchanged
> > > > > from the WSDL all the way through to the DOMs used by the templates.
> > > > >
> > > > > Please let me know if I should open a JIRA for this.
> > > > >
> > > > > Peter Danielsen
> > > > >
> > > > >
> > >
> ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail:
> > > axis-dev-unsubscribe@ws.apache.org
> > > > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Keith Chapman
> > > > WSO2 Inc.
> > > > Oxygen for Web Services Developers.
> > > > http://wso2.org/
> > >
> > >
> > >
> > > --
> > > Keith Chapman
> > > WSO2 Inc.
> > > Oxygen for Web Services Developers.
> > > http://wso2.org/
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> axis-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-dev-help@ws.apache.org
> >
> >
>
>
>
> --
> Keith Chapman
> WSO2 Inc.
> Oxygen for Web Services Developers.
> http://wso2.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by keith chapman <ke...@gmail.com>.
We do support all WSDL 2.0 MEPS at the moment. The WSDL 2.0 style has no
relationship to the WSDL 1.1 Styles (rpc, document), they just enforce
restrictions on how the element itself will look like. WSDL 2 has defined
three styles IRI, rpc and multipart. If you look at the spec [1] you will
see that they just gives a message to the user saying that the messages
exchange follow this general style.
[1]
http://dev.w3.org/cvsweb/~checkout~/2002/ws/desc/wsdl20/wsdl20-adjuncts.html?content-type=text/html;%20charset=utf-8#styles
Thanks,
Keith.
On 5/30/07, Peter Danielsen <wi...@gmail.com> wrote:
>
> Keith,
>
> Thanks for the quick response on this, however, I still have some
> concerns.
>
> I thought that WSDL2's "style" was intended to be a more general
> replacement for WSDL1's? If that's correct, why is a WSDL2
> "style" attribute an AxisOperation Parameter while a WSDL1 "style"
> attribute is a first class member? (It seems like Parameters are
> intended for extensions). I think it's natural to provide explicit
> methods for the WSDL2 styles, rather than using Parameters.
>
> In general, what's Axis2's plan for accommodating 3rd party styles
> and MEPs allowed by WSDL2?
>
> Thanks,
>
>
> Peter
>
>
> On 5/29/07, keith chapman <ke...@gmail.com> wrote:
> > Hi Peter,
> >
> > I've added the syle attribute to the axisOperation via a Parameter
> > (WSDL2Constants.OPERATION_STYLE). I serialize this in ?wsdl2 too. But
> still
> > we dont capture it in the intermidiate format.
> >
> > Thanks,
> > Keith.
> >
> >
> > On 5/29/07, keith chapman <ke...@gmail.com> wrote:
> > > Hi Peter,
> > >
> > > The reason we didnt capture the style parameter in the intermidiate
> DOM
> > was because we didnt have to change the stub depending on the style.
> > Therefore its not captured in axisOperation. May be we should capture it
> so
> > that we can serialize it into ?wsdl2.
> > >
> > > Thanks,
> > > Keith
> > >
> > >
> > > On 5/26/07, Peter Danielsen < wiscal@gmail.com> wrote:
> > >
> > > > Hi,
> > > >
> > > > I've been trying to create an Axis2 code generation template
> > > > that would make some decisions based on the value of the "style"
> > > > attribute in a WSDL2 document. I'm unable to do so because
> > > > that value doesn't appear in the DOM created by the
> > > > AxisServiceBasedMultiLanguageEmitter. There is a
> > "style" attribute,
> > > > but it's related to WSDL1.1.
> > > >
> > > > To accommodate this looks like it would require changes to
> > > >
> > > > 1. org.apache.axis2.description.AxisOperation to either
> > > > a. change the existing "style" field to a list (since WSDL2
> > > > allows multiple styles for an operation) and modifying
> > > > getStyle() and setStyle(String) accordingly, or
> > > > b. adding a new List<URI> field with something like
> > > > List getStyles() and void addStyle(URI style) methods, and
> > > > possibly deprecate the existing style-related methods.
> > > > 2. WSDL20ToAxisServiceBuilder.populateOperations to add
> > the styles
> > > > from the Woden InterfaceOperation object to the AxisOperation
> > > > object.
> > > > 3.
> > AxisServiceBasedMultiLanguageEmitter.generateMethodElement
> > to
> > > > add an attribute for the styles to the method Element it builds.
> > > >
> > > > While the styles defined in the WSDL2 Adjuncts specification can
> > > > be represented by constants, new styles can be defined by anyone
> > > > so it would be very useful to preserve the style URIs unchanged
> > > > from the WSDL all the way through to the DOMs used by the templates.
> > > >
> > > > Please let me know if I should open a JIRA for this.
> > > >
> > > > Peter Danielsen
> > > >
> > > >
> > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail:
> > axis-dev-unsubscribe@ws.apache.org
> > > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > > >
> > > >
> > >
> > >
> > >
> > >
> > > --
> > > Keith Chapman
> > > WSO2 Inc.
> > > Oxygen for Web Services Developers.
> > > http://wso2.org/
> >
> >
> >
> > --
> > Keith Chapman
> > WSO2 Inc.
> > Oxygen for Web Services Developers.
> > http://wso2.org/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>
--
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by Peter Danielsen <wi...@gmail.com>.
Keith,
Thanks for the quick response on this, however, I still have some
concerns.
I thought that WSDL2's "style" was intended to be a more general
replacement for WSDL1's? If that's correct, why is a WSDL2
"style" attribute an AxisOperation Parameter while a WSDL1 "style"
attribute is a first class member? (It seems like Parameters are
intended for extensions). I think it's natural to provide explicit
methods for the WSDL2 styles, rather than using Parameters.
In general, what's Axis2's plan for accommodating 3rd party styles
and MEPs allowed by WSDL2?
Thanks,
Peter
On 5/29/07, keith chapman <ke...@gmail.com> wrote:
> Hi Peter,
>
> I've added the syle attribute to the axisOperation via a Parameter
> (WSDL2Constants.OPERATION_STYLE). I serialize this in ?wsdl2 too. But still
> we dont capture it in the intermidiate format.
>
> Thanks,
> Keith.
>
>
> On 5/29/07, keith chapman <ke...@gmail.com> wrote:
> > Hi Peter,
> >
> > The reason we didnt capture the style parameter in the intermidiate DOM
> was because we didnt have to change the stub depending on the style.
> Therefore its not captured in axisOperation. May be we should capture it so
> that we can serialize it into ?wsdl2.
> >
> > Thanks,
> > Keith
> >
> >
> > On 5/26/07, Peter Danielsen < wiscal@gmail.com> wrote:
> >
> > > Hi,
> > >
> > > I've been trying to create an Axis2 code generation template
> > > that would make some decisions based on the value of the "style"
> > > attribute in a WSDL2 document. I'm unable to do so because
> > > that value doesn't appear in the DOM created by the
> > > AxisServiceBasedMultiLanguageEmitter. There is a
> "style" attribute,
> > > but it's related to WSDL1.1.
> > >
> > > To accommodate this looks like it would require changes to
> > >
> > > 1. org.apache.axis2.description.AxisOperation to either
> > > a. change the existing "style" field to a list (since WSDL2
> > > allows multiple styles for an operation) and modifying
> > > getStyle() and setStyle(String) accordingly, or
> > > b. adding a new List<URI> field with something like
> > > List getStyles() and void addStyle(URI style) methods, and
> > > possibly deprecate the existing style-related methods.
> > > 2. WSDL20ToAxisServiceBuilder.populateOperations to add
> the styles
> > > from the Woden InterfaceOperation object to the AxisOperation
> > > object.
> > > 3.
> AxisServiceBasedMultiLanguageEmitter.generateMethodElement
> to
> > > add an attribute for the styles to the method Element it builds.
> > >
> > > While the styles defined in the WSDL2 Adjuncts specification can
> > > be represented by constants, new styles can be defined by anyone
> > > so it would be very useful to preserve the style URIs unchanged
> > > from the WSDL all the way through to the DOMs used by the templates.
> > >
> > > Please let me know if I should open a JIRA for this.
> > >
> > > Peter Danielsen
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> axis-dev-unsubscribe@ws.apache.org
> > > For additional commands, e-mail: axis-dev-help@ws.apache.org
> > >
> > >
> >
> >
> >
> >
> > --
> > Keith Chapman
> > WSO2 Inc.
> > Oxygen for Web Services Developers.
> > http://wso2.org/
>
>
>
> --
> Keith Chapman
> WSO2 Inc.
> Oxygen for Web Services Developers.
> http://wso2.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by keith chapman <ke...@gmail.com>.
Hi Peter,
I've added the syle attribute to the axisOperation via a Parameter (
WSDL2Constants.OPERATION_STYLE). I serialize this in ?wsdl2 too. But still
we dont capture it in the intermidiate format.
Thanks,
Keith.
On 5/29/07, keith chapman <ke...@gmail.com> wrote:
>
> Hi Peter,
>
> The reason we didnt capture the style parameter in the intermidiate DOM
> was because we didnt have to change the stub depending on the style.
> Therefore its not captured in axisOperation. May be we should capture it so
> that we can serialize it into ?wsdl2.
>
> Thanks,
> Keith
>
> On 5/26/07, Peter Danielsen <wi...@gmail.com> wrote:
> >
> > Hi,
> >
> > I've been trying to create an Axis2 code generation template
> > that would make some decisions based on the value of the "style"
> > attribute in a WSDL2 document. I'm unable to do so because
> > that value doesn't appear in the DOM created by the
> > AxisServiceBasedMultiLanguageEmitter. There is a "style" attribute,
> > but it's related to WSDL1.1.
> >
> > To accommodate this looks like it would require changes to
> >
> > 1. org.apache.axis2.description.AxisOperation to either
> > a. change the existing "style" field to a list (since WSDL2
> > allows multiple styles for an operation) and modifying
> > getStyle() and setStyle(String) accordingly, or
> > b. adding a new List<URI> field with something like
> > List getStyles() and void addStyle(URI style) methods, and
> > possibly deprecate the existing style-related methods.
> > 2. WSDL20ToAxisServiceBuilder.populateOperations to add the styles
> > from the Woden InterfaceOperation object to the AxisOperation
> > object.
> > 3. AxisServiceBasedMultiLanguageEmitter.generateMethodElement to
> > add an attribute for the styles to the method Element it builds.
> >
> > While the styles defined in the WSDL2 Adjuncts specification can
> > be represented by constants, new styles can be defined by anyone
> > so it would be very useful to preserve the style URIs unchanged
> > from the WSDL all the way through to the DOMs used by the templates.
> >
> > Please let me know if I should open a JIRA for this.
> >
> > Peter Danielsen
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-dev-help@ws.apache.org
> >
> >
>
>
> --
> Keith Chapman
> WSO2 Inc.
> Oxygen for Web Services Developers.
> http://wso2.org/
>
--
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by keith chapman <ke...@gmail.com>.
Hi Peter,
The reason we didnt capture the style parameter in the intermidiate DOM was
because we didnt have to change the stub depending on the style. Therefore
its not captured in axisOperation. May be we should capture it so that we
can serialize it into ?wsdl2.
Thanks,
Keith
On 5/26/07, Peter Danielsen <wi...@gmail.com> wrote:
>
> Hi,
>
> I've been trying to create an Axis2 code generation template
> that would make some decisions based on the value of the "style"
> attribute in a WSDL2 document. I'm unable to do so because
> that value doesn't appear in the DOM created by the
> AxisServiceBasedMultiLanguageEmitter. There is a "style" attribute,
> but it's related to WSDL1.1.
>
> To accommodate this looks like it would require changes to
>
> 1. org.apache.axis2.description.AxisOperation to either
> a. change the existing "style" field to a list (since WSDL2
> allows multiple styles for an operation) and modifying
> getStyle() and setStyle(String) accordingly, or
> b. adding a new List<URI> field with something like
> List getStyles() and void addStyle(URI style) methods, and
> possibly deprecate the existing style-related methods.
> 2. WSDL20ToAxisServiceBuilder.populateOperations to add the styles
> from the Woden InterfaceOperation object to the AxisOperation
> object.
> 3. AxisServiceBasedMultiLanguageEmitter.generateMethodElement to
> add an attribute for the styles to the method Element it builds.
>
> While the styles defined in the WSDL2 Adjuncts specification can
> be represented by constants, new styles can be defined by anyone
> so it would be very useful to preserve the style URIs unchanged
> from the WSDL all the way through to the DOMs used by the templates.
>
> Please let me know if I should open a JIRA for this.
>
> Peter Danielsen
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>
--
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by keith chapman <ke...@gmail.com>.
Yes we dont take the style into account at the moment. Kindly Open a jira
for this.
Thanks,
Keith.
On 5/26/07, Peter Danielsen <wi...@gmail.com> wrote:
>
> Hi,
>
> I've been trying to create an Axis2 code generation template
> that would make some decisions based on the value of the "style"
> attribute in a WSDL2 document. I'm unable to do so because
> that value doesn't appear in the DOM created by the
> AxisServiceBasedMultiLanguageEmitter. There is a "style" attribute,
> but it's related to WSDL1.1.
>
> To accommodate this looks like it would require changes to
>
> 1. org.apache.axis2.description.AxisOperation to either
> a. change the existing "style" field to a list (since WSDL2
> allows multiple styles for an operation) and modifying
> getStyle() and setStyle(String) accordingly, or
> b. adding a new List<URI> field with something like
> List getStyles() and void addStyle(URI style) methods, and
> possibly deprecate the existing style-related methods.
> 2. WSDL20ToAxisServiceBuilder.populateOperations to add the styles
> from the Woden InterfaceOperation object to the AxisOperation
> object.
> 3. AxisServiceBasedMultiLanguageEmitter.generateMethodElement to
> add an attribute for the styles to the method Element it builds.
>
> While the styles defined in the WSDL2 Adjuncts specification can
> be represented by constants, new styles can be defined by anyone
> so it would be very useful to preserve the style URIs unchanged
> from the WSDL all the way through to the DOMs used by the templates.
>
> Please let me know if I should open a JIRA for this.
>
> Peter Danielsen
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>
--
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/
Re: Accessing WSDL2 styles in Axis2 codegen emitter templates
Posted by Amila Suriarachchi <am...@gmail.com>.
style in wsdl 1.1 means either rpc or document. which is not there with the
wsdl 2.0.
these are the binding styles we can use with the wsdl 1.1.
So that can not be changed.
We can add new attribute (If need ) to add your feature.
On 5/26/07, Peter Danielsen <wi...@gmail.com> wrote:
>
> Hi,
>
> I've been trying to create an Axis2 code generation template
> that would make some decisions based on the value of the "style"
> attribute in a WSDL2 document. I'm unable to do so because
> that value doesn't appear in the DOM created by the
> AxisServiceBasedMultiLanguageEmitter. There is a "style" attribute,
> but it's related to WSDL1.1.
>
> To accommodate this looks like it would require changes to
>
> 1. org.apache.axis2.description.AxisOperation to either
> a. change the existing "style" field to a list (since WSDL2
> allows multiple styles for an operation) and modifying
> getStyle() and setStyle(String) accordingly, or
> b. adding a new List<URI> field with something like
> List getStyles() and void addStyle(URI style) methods, and
> possibly deprecate the existing style-related methods.
> 2. WSDL20ToAxisServiceBuilder.populateOperations to add the styles
> from the Woden InterfaceOperation object to the AxisOperation
> object.
> 3. AxisServiceBasedMultiLanguageEmitter.generateMethodElement to
> add an attribute for the styles to the method Element it builds.
>
> While the styles defined in the WSDL2 Adjuncts specification can
> be represented by constants, new styles can be defined by anyone
> so it would be very useful to preserve the style URIs unchanged
> from the WSDL all the way through to the DOMs used by the templates.
>
> Please let me know if I should open a JIRA for this.
>
> Peter Danielsen
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>
--
Amila Suriarachchi,
WSO2 Inc.