Hi all,
This is the situation. I have method send() defined as follows:
public Boolean sendSimple(String message, String rec);
public boolean send(SMSMessageText smsMessage, Recipient rec);
The first method works fine.
When I call the second method, a RemoteException is being throwed (on
client side). When I echo the stack trace it says:
UndeclaredThrowableException.
I guess there is something in my SMSMessageText or Recipient classes
that is not handled correctly by the wsdl2java (or vice versa) code
emitter. Or I use some construct that is not supported by SOAP/Axis.
Definitions for Recipient and SMSMessageText follow:
/** Holds Recipient information */
public class Recipient implements Serializable
{
final static int UNSPECIFIED = -1;
private String msisdn = "";
private int providerID = UNSPECIFIED;
private int deviceID = UNSPECIFIED;
private int deviceTypeID = UNSPECIFIED;
private boolean allowBackup = true;
public Recipient() {}
public Recipient(String msisdn) {
this.msisdn = msisdn;
}
public Recipient(String msisdn, int providerID) {
this.msisdn = msisdn;
this.providerID = providerID;
}
public Recipient(String msisdn, int providerID, int deviceID) {
this.msisdn = msisdn;
this.providerID = providerID;
this.deviceID = deviceID;
}
public void setProviderID(int providerID) {
this.providerID = providerID;
}
public int getProviderID() { return providerID; }
public void setMSISDN(String msisdn) { this.msisdn = msisdn; }
public String getMSISDN() { return msisdn; }
public void setDeviceID(int deviceID) { this.deviceID =
deviceID; }
public int getDeviceID() { return deviceID; }
public void setDeviceTypeID(int deviceTypeID) {
this.deviceTypeID = deviceTypeID;
}
public int getDeviceTypeID() { return deviceTypeID; }
public boolean getAllowBackup() { return allowBackup; }
public void setAllowBackup(boolean backup) { allowBackup =
backup; }
public boolean validate() { return true; }
}
/** A SMS message */
public class SMSMessageText extends SMSMessage implements Serializable
{
private final static int SMS_MAXLENGTH = 160;
public final static int TYPE_SIMPLE = 0;
public final static int TYPE_FLASH = 1;
private String smsText;
public SMSMessageText() {}
public SMSMessageText(String smsText) {
super();
setText(smsText);
}
}