Hi Isuru,

Usually a web service needs to be accessible from any language. So they are
not using the same collection frameworks as in java or any other language.
So you should not use language specific collection types when returning
data from Axis2.

Thanks

Hasanthi Dissanayake

Software Engineer | WSO2

E: hasan...@wso2.com <nirosh...@wso2.com>
M :0718407133| http://wso2.com <http://wso2.com/>

On Tue, May 12, 2015 at 9:29 AM, Thusitha Thilina Dayaratne <
thusit...@wso2.com> wrote:

> Hi Isuru,
>
> ArrayList is a Java specific implementation (Most of the Collections are
> too). Since Webservices have to deal with in language independent manner it
> is always good to return an POJO/bean So you can return a array instead of
> ArrayList
>
> Thanks
>
> On Tue, May 12, 2015 at 8:22 AM, Isuru Wijesinghe <isur...@wso2.com>
> wrote:
>
>> Hi All,
>>
>> I have a method which I am trying to expose as a web service and the
>> response object is an array list. On creating the web service in axis 2
>> can't I use Collection types such as ArrayList when returning data from
>> Axis2 Web Service Objects?.
>>
>>  But when I return arrays of objects it  works correctly. Any help will
>> be appreciated.
>>
>> --
>> Isuru Wijesinghe
>> *Software Engineer*
>> Mobile: 0710933706
>> isur...@wso2.com
>>
>
>
>
> --
> Thusitha Dayaratne
> Software Engineer
> WSO2 Inc. - lean . enterprise . middleware |  wso2.com
>
> Mobile  +94712756809
> Blog      alokayasoya.blogspot.com
> About    http://about.me/thusithathilina
>
>
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to