The Artima Developer Community
Sponsored Link

Web Services Forum
Object Array problem in Websphere WebServices

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Prashanth Manjapara

Posts: 1
Nickname: prashanth2
Registered: Nov, 2005

Object Array problem in Websphere WebServices Posted: Nov 3, 2005 8:44 AM
Reply to this message Reply
Advertisement
Hi,

Can you help me out with a situation that we are stuck with in WebServices.

I have a WebService which returns a DTO which has a getter and setter for an array of another type of DTO object.

Sample:-

public class MyDTO extends AnotherDTO implements Serializable {
private InnerDTO qcDtoList[] = new InnerDTO[0];

public MyDTO() {
}

public InnerDTO[] getQcDtoList() {
return qcDtoList;
}

public void setQcDtoList(InnerDTO[] resEDXDTOs) {
qcDtoList = resEDXDTOs;
}
}

But when I generate the WSDL for the webservice using WSAD 5.1 that uses the above DTO, the server side generated skeleton file looks like:-

public class MyDTO extends AnotherDTO implements java.io.Serializable {
private InnerDTO[] qcDtoList;
public MyDTO() {
}
public InnerDTO[] getQcDtoList() {
return qcDtoList;
}
public void setQcDtoList(InnerDTO[] qcDtoList) {
this.qcDtoList = qcDtoList;
}
}

As you can see from above, my initialization info is not available in the generated skeleton. I also tried putting the initialization in the constructor, with no effect.

What could be the reason for this? And is it possible to initialize my InnerDTO without losing it in the generated skeleton?
I simply want to initialize the object array.
If I need to modify my WSDL, what additional annotations should I add on the WSDL to get the desired effect?

I would really appreciate if you can throw light on this?

Thanx and Regds,
Prashanth.

Topic: Hello, we can provide you with PHP/MySql help Previous Topic   Next Topic Topic: Axis WebService: get Client IP-Address

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use