axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Neil Smyth <NSm...@ALTIO.com>
Subject RE: changing permissions on SymbolTable.add()
Date Fri, 19 Apr 2002 16:03:33 GMT
Thanks for the feedback Russell - I will keep an eye on things and chime in
if I can add anything useful. I guess what I am looking for is an easy way
to get at the populated symbol table without having to go through the
emitter, but can work with my own version just fine for now.

Regards,

Neil

-----Original Message-----
From: Russell Butek [mailto:butek@us.ibm.com]
Sent: 19 April 2002 16:28
To: axis-dev@xml.apache.org
Subject: RE: changing permissions on SymbolTable.add()


I will admit that the WSDL2Java and symbol table stuff is not very cleanly
extensible.  We want it to be, but somewhere along the line our concern
shifted from extensibility to functionality (we just wanted to get this
thing working).  Soon after beta 2 I hope to have time to address
extensibility in WSDL2Java again.

However, I am not going to expose SymbolTable.add.  Even if you're not
doing anything bad with it, it could be misused (and when something is made
available, SOMEONE will try to use it in ways you never imagined!).  You'll
have to live with your modifications until after beta 2.

Watch this space in the weeks following beta2 and let me know whether my
changes to the framework help or hinder you.

Russell Butek
butek@us.ibm.com


Neil Smyth <NSmyth@ALTIO.com> on 04/19/2002 08:40:51 AM

Please respond to axis-dev@xml.apache.org

To:    "'axis-dev@xml.apache.org'" <axis-dev@xml.apache.org>
cc:
Subject:    RE: changing permissions on SymbolTable.add()



The situation I am in is already having the WSDL definition and wish to
generate some sample XML for each part in the wsdl definition. Once I have
the symbol table populated, I then query it for the various type/element
definitions and loop through the structure to generate XML. I am not adding
extra information to the symbol table once it is populated via the add()
method. For example, the WSDL segment
....
<s:element name="StockGetter">
 <s:complexType>
  <s:sequence>
   <s:element maxOccurs="1" minOccurs="1"
name="StockPrice" type="s:double"/>
             <s:element maxOccurs="1" minOccurs="1"
name="ExercisePrice" type="s:double"/>
   </s:sequence>
 </s:complexType>
</s:element>
...
<message name="SomeMessage">
 <part name="StockPrice" element="s:StockGetter"/>
</message>
...

should generate sample XML (ignoring namespaces for simplicity) along the
lines of
<StockGetter>
 <StockPrice>10</StockPrice>
 <ExercisePrice>1</ExercisePrice>
</StockGetter>

I would like to use Axis's support in this area in order to leverage the
JAX-RPC schema subset support.

The current code setup requires that you create an emitter, which you then
call emit() on with the definiton to generate all the output. I'd like to
avoid creating the emitter and providing it with a Noop writer factory etc
just to get access to a populated symbol table.

Regards,

Neil



-----Original Message-----
From: Russell Butek [mailto:butek@us.ibm.com]
Sent: 19 April 2002 14:07
To: axis-dev@xml.apache.org
Subject: Re: changing permissions on SymbolTable.add()


SymbolTable is populated by reading in a WSDL file.  Users of the symbol
table are allowed to add info to the existing symbol table entries but
they're not allowed to change the symbol table.  Before the symbol table is
given to the back end there is some verification and conflict resolution
done on it.  You could end up with an inconsistent symbol table if you
added symbols after this stage.

What exactly are you trying to accomplish here?  Why do you have to add
things to the symbol table?

Russell Butek
butek@us.ibm.com


Neil Smyth <NSmyth@ALTIO.com> on 04/19/2002 05:04:50 AM

Please respond to axis-dev@xml.apache.org

To:    axis-dev@xml.apache.org
cc:
Subject:    changing permissions on SymbolTable.add()



I am looking to leverage the code in wsdl.toJava.SymbolTable and the
wsdl.toJava package in general, to generate sample XML for a given message
part. Currently I am using a slightly modified version of beta1 where I
have
upgraded the permission on SymbolTable.add() to public as it is currently
protected, and with beta2 coming down the pipeline I was hoping this change
could make it into it.

The only information I am interested in from the wsdl file is the parts
description, so going through the whole writerFactory/writer mechanism is
overkill. I think the symbol table is useful in its own right but keeping
the add method protected makes it difficult to get a populated symbol
table,
though not impossible, from the current API.

I am happy to update my code as the toJava package changes as I am aware
that it is not a stable API.

Regards,

Neil



Mime
View raw message