8
To send a primitive data is simple, but when it comes to complex data as shown below, an exception is thrown:
java.lang.Runtimeexception: Cannot serialize: Person{name=given, address=given etc...}
Most tutorials and examples address the use of primitive types and not complex types as the question here presents.
Given an object represented below:
public class Pessoa {
private String nome;
private String endereco;
private List<String> emails;
private boolean ativo;
// getters e setters
@Override
public String toString(){
return "Pessoa{nome="+dado+", endereco="+dado+" etc...}";
}
}
How to send it to a SOAP standard web service using the kSOAP library?
Quite broad this question, no? It seems to me that the valid for Sopt would be you do the implementation and post here the problems encountered. Apparently kSOAP is most commonly used on Android (http://www.emersonbarros.com.br/ksoap-2-consumindo-webservice-com-android/). Is this your requirement? For other needs I have always used JAX-WS for SOAP webservices.
– Caffé
Your link does not meet my need, because I need to send complex, not primitive types. But I will give an improvement on the question.
– Luídne