You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by ia...@apache.org on 2004/07/02 15:17:19 UTC
cvs commit: ws-axis/java/src/org/apache/axis/wsdl/fromJava Types.java
ias 2004/07/02 06:17:19
Modified: java/src/org/apache/axis/wsdl/fromJava Types.java
Log:
Handles global attributes more precisely. Now a global attribute is considered roughly the same as global element by representing Element in entries of SymbolTable.
Revision Changes Path
1.98 +7 -3 ws-axis/java/src/org/apache/axis/wsdl/fromJava/Types.java
Index: Types.java
===================================================================
RCS file: /home/cvs/ws-axis/java/src/org/apache/axis/wsdl/fromJava/Types.java,v
retrieving revision 1.97
retrieving revision 1.98
diff -u -r1.97 -r1.98
--- Types.java 22 Jun 2004 18:01:20 -0000 1.97
+++ Types.java 2 Jul 2004 13:17:19 -0000 1.98
@@ -1722,8 +1722,8 @@
// If we've already got this type (because it's a native type or
// because we've already written it), just add the type="" attribute
// (if appropriate) and return.
- if (!addToTypesList(qName)) {
- if (containingElement != null) {
+ if (!addToTypesList(qName) && !anonymous) {
+ if (containingElement != null) {
containingElement.setAttribute("type", getQNameString(qName));
}
@@ -1775,7 +1775,11 @@
// containingElement to the right QName, and make sure the type is
// correctly written into the appropriate <schema> element.
if (anonymous) {
- containingElement.appendChild(typeEl);
+ if (typeEl == null) {
+ containingElement.setAttribute("type", getQNameString(getTypeQName(type)));
+ } else {
+ containingElement.appendChild(typeEl);
+ }
} else {
if (typeEl != null) {
typeEl.setAttribute("name", qName.getLocalPart());
RE: cvs commit: ws-axis/java/src/org/apache/axis/wsdl/fromJava Types.java
Posted by Ias <ia...@tmax.co.kr>.
> -----Original Message-----
> From: ias@apache.org [mailto:ias@apache.org]
> Sent: Friday, July 02, 2004 10:17 PM
> To: ws-axis-cvs@apache.org
> Subject: cvs commit:
> ws-axis/java/src/org/apache/axis/wsdl/fromJava Types.java
>
> ias 2004/07/02 06:17:19
>
> Modified: java/src/org/apache/axis/wsdl/fromJava Types.java
> Log:
> Handles global attributes more precisely. Now a global
> attribute is considered roughly the same as global element by
> representing Element in entries of SymbolTable.
Sorry. The above log message is a little awkward. The right one is
Handles anonymous types more precisely.
Thanks,
Ias
>
> Revision Changes Path
> 1.98 +7 -3
> ws-axis/java/src/org/apache/axis/wsdl/fromJava/Types.java
>
> Index: Types.java
> ===================================================================
> RCS file:
> /home/cvs/ws-axis/java/src/org/apache/axis/wsdl/fromJava/Types.java,v
> retrieving revision 1.97
> retrieving revision 1.98
> diff -u -r1.97 -r1.98
> --- Types.java 22 Jun 2004 18:01:20 -0000 1.97
> +++ Types.java 2 Jul 2004 13:17:19 -0000 1.98
> @@ -1722,8 +1722,8 @@
> // If we've already got this type (because it's a
> native type or
> // because we've already written it), just add the
> type="" attribute
> // (if appropriate) and return.
> - if (!addToTypesList(qName)) {
> - if (containingElement != null) {
> + if (!addToTypesList(qName) && !anonymous) {
> + if (containingElement != null) {
> containingElement.setAttribute("type",
> getQNameString(qName));
> }
>
> @@ -1775,7 +1775,11 @@
> // containingElement to the right QName, and make
> sure the type is
> // correctly written into the appropriate <schema> element.
> if (anonymous) {
> - containingElement.appendChild(typeEl);
> + if (typeEl == null) {
> + containingElement.setAttribute("type",
> getQNameString(getTypeQName(type)));
> + } else {
> + containingElement.appendChild(typeEl);
> + }
> } else {
> if (typeEl != null) {
> typeEl.setAttribute("name", qName.getLocalPart());
>
>
>
>