The Moria2-enabled service asks Moria2 whether the user with the
username somebody@my.org
exists.
The SOAP implementation used in this example is Axis.
import javax.xml.namespace.QName; import org.apache.axis.client.Call; ... Call call = new Call("http://localhost:8080/moria/v2_1/Authentication?WSDL")); call.setUsername("service_username"); call.setPassword("service_password"); final Object[] parameters = { "somebody@my.org" }; final boolean userExists = (boolean) call.invoke(new QName("verifyUserExistence"), parameters);
The above code assumes that Moria2 is deployed locally.