[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sandesha-dev
Subject:    [jira] [Updated] (AXIS2-5201) A parameterized List object is
From:       "TAM Tenfold5 (Updated) (JIRA)" <jira () apache ! org>
Date:       2011-11-29 6:19:39
Message-ID: 1432689765.21165.1322547579981.JavaMail.tomcat () hel ! zones ! apache ! org
[Download RAW message or body]


     [ https://issues.apache.org/jira/browse/AXIS2-5201?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel \
]

TAM Tenfold5 updated AXIS2-5201:
--------------------------------

    Description: 
I have described beans as follows:
public class A implements Serializable {
          private String prop1;
          private Date prop2;
          private Integer prop3;
          private Double prop4;
          private List<B> propListB;
         //getter and setter methods
} 

public class B implements Serializable {
          private String prop1;
          private Date prop2;
          private Integer prop3;
          private Double prop4;
         //getter and setter methods
} 

I have described few operations in web-service implementation class as follows:
public void saveBes(String param1, List<B> bes) {....}  //1
public B[] getBes1(String param1) {...}  //2
public List<B> getBes2(String param1) {...}  //3
public A getA(String param1) {...}  //4

There are several issues that I have identified here:
1) If I have only operation 4 in WS implementation class, structure of Class B is not \
found in the WSDL. The type for property B within the structure of A in WSDL is \
'xs:anyType'. 'maxOccurs=unbounded' is not defined for such property. 2) If I add an \
operation in WS implementation class with Class B as an input param, WSDL only then \
described the structure of class B. (But issue-1 still remains). 3) If I have \
operations like 3 and 4 in the WS Impl class, then structure of Class B is not \
described in WSDL.The response element property (for 3) and Class A property (for 4) \
appear as type 'xs:anyType' and 'maxOccurs=unbounded' is not defined. 4) Only when I \
change the type of  'propListB' in class A to B[], can the structure of Class B \
resolved in WSDL. In this case the property B within the structure of A in WSDL is \
'ax23:B'  and 'maxOccurs=unbounded' is defined.. 5) If I have operation like 2, then \
the structure of Class B resolved in WSDL.

So, the conclusion is when parametrized List object is used within a POJO or return \
type of WS operation, its structure is not described in WSDL. 

I have not checked for other collection classes like java.util.Set.

Regards,
TAM Tenfold5, GDev.

  was:
I have described beans as follows:
public class A implements Serializable {
          private String prop1;
          private Date prop2;
          private Integer prop3;
          private Double prop4;
          private List<B> propListB;
         //getter and setter methods
} 

public class B implements Serializable {
          private String prop1;
          private Date prop2;
          private Integer prop3;
          private Double prop4;
         //getter and setter methods
} 

I have described few operations in web-service implementation class as follows:
public void saveBes(String param1, List<B> bes) {....}  //1
public B[] getBes1(String param1) {...}  //2
public List<B> getBes2(String param1) {...}  //3
public A getA(String param1) {...}  //4

There are several issues that I have identified here:
1) If I have only operation 4 in WS implementation class, structure of Class B is not \
found in the WSDL. The type for property B within the structure of A in WSDL is \
'xs:anyType'. 2) If I add an operation in WS implementation class with Class B as an \
input param, WSDL only then described the structure of class B. (But issue-1 still \
remains). 3) If I have operations like 3 and 4 in the WS Impl class, then structure \
of Class B is not described in WSDL. 4) Only when I change the type of  'propListB' \
in class A to B[], can the structure of Class B resolved in WSDL. In this case the \
property B within the structure of A in WSDL is 'ax23:B'. 5) If I have operation like \
2, then the structure of Class B resolved in WSDL.

So, the conclusion is when parametrized List object is used within a POJO or return \
type of WS operation, its structure is not described in WSDL. 

I have not checked for other collection classes like java.util.Set.

Regards,
TAM Tenfold5, GDev.

    
> A parameterized List object is assigned type 'xs:anyType' in WSDL when the list is \
>                 part of a POJO or object returned by a web-service operation
> -----------------------------------------------------------------------------------------------------------------------------------------------
>  
> Key: AXIS2-5201
> URL: https://issues.apache.org/jira/browse/AXIS2-5201
> Project: Axis2
> Issue Type: Bug
> Components: codegen, wsdl
> Affects Versions: 1.6.0
> Environment: axis2 version is 1.6.0. 
> Reporter: TAM Tenfold5
> 
> I have described beans as follows:
> public class A implements Serializable {
> private String prop1;
> private Date prop2;
> private Integer prop3;
> private Double prop4;
> private List<B> propListB;
> //getter and setter methods
> } 
> public class B implements Serializable {
> private String prop1;
> private Date prop2;
> private Integer prop3;
> private Double prop4;
> //getter and setter methods
> } 
> I have described few operations in web-service implementation class as follows:
> public void saveBes(String param1, List<B> bes) {....}  //1
> public B[] getBes1(String param1) {...}  //2
> public List<B> getBes2(String param1) {...}  //3
> public A getA(String param1) {...}  //4
> There are several issues that I have identified here:
> 1) If I have only operation 4 in WS implementation class, structure of Class B is \
> not found in the WSDL. The type for property B within the structure of A in WSDL is \
> 'xs:anyType'. 'maxOccurs=unbounded' is not defined for such property. 2) If I add \
> an operation in WS implementation class with Class B as an input param, WSDL only \
> then described the structure of class B. (But issue-1 still remains). 3) If I have \
> operations like 3 and 4 in the WS Impl class, then structure of Class B is not \
> described in WSDL.The response element property (for 3) and Class A property (for \
> 4) appear as type 'xs:anyType' and 'maxOccurs=unbounded' is not defined. 4) Only \
> when I change the type of  'propListB' in class A to B[], can the structure of \
> Class B resolved in WSDL. In this case the property B within the structure of A in \
> WSDL is 'ax23:B'  and 'maxOccurs=unbounded' is defined.. 5) If I have operation \
> like 2, then the structure of Class B resolved in WSDL. So, the conclusion is when \
> parametrized List object is used within a POJO or return type of WS operation, its \
> structure is not described in WSDL.  I have not checked for other collection \
> classes like java.util.Set. Regards,
> TAM Tenfold5, GDev.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: \
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more \
information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: java-dev-help@axis.apache.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic