org.apache.axis2.transport.sms
Class SMSMessage

java.lang.Object
  extended by org.apache.axis2.transport.sms.SMSMessage

public class SMSMessage
extends java.lang.Object

SMS message is a atomic object wich carries a SMS SMS has can be either a IN message or a OUT message which will have the details sender , receiver ,Content and properties sender , receiver has a implied meaning with the Message direction
eg: in a IN_MESSAGE sender : the phone number of the phone that sms has been sent to axis2 receiver : the phone number given from the SMSC to the Axis2 in a OUT_MESSAGE sender : the phone number given from the SMSC to the Axis2 receiver : the phone number of the phone that sms created from Axis2 must deliver to


Field Summary
static int IN_MESSAGE
           
static int OUT_MESSAGE
           
 
Constructor Summary
SMSMessage(java.lang.String sender, java.lang.String reciever, java.lang.String content, int direction)
           
 
Method Summary
 void addProperty(java.lang.String key, java.lang.Object value)
          add the Implementation level properties that properties will be add to the Axis2 Message Context
 java.lang.String getContent()
          Return The Contect that will be send with the SMS
 int getDirection()
          return the Message Direction of the SMSMessage That should be either SMS_IN_MESSAGE :1 Or SMS_OUT_MESSAGE : 2
 java.util.Map<java.lang.String,java.lang.Object> getProperties()
          Return the properties of the SMS message
 java.lang.String getReceiver()
          Return the phone Number that SMS must be received to
 java.lang.String getSender()
          Retuen the Phone Number of the Sender
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IN_MESSAGE

public static int IN_MESSAGE

OUT_MESSAGE

public static int OUT_MESSAGE
Constructor Detail

SMSMessage

public SMSMessage(java.lang.String sender,
                  java.lang.String reciever,
                  java.lang.String content,
                  int direction)
           throws org.apache.axis2.AxisFault
Parameters:
sender -
reciever -
content -
direction -
Throws:
org.apache.axis2.AxisFault
Method Detail

getSender

public java.lang.String getSender()
Retuen the Phone Number of the Sender

Returns:
String that contain the senders phone Number

getReceiver

public java.lang.String getReceiver()
Return the phone Number that SMS must be received to

Returns:
String that Contain the receivers phone Number

getContent

public java.lang.String getContent()
Return The Contect that will be send with the SMS

Returns:
String that contain the content

getDirection

public int getDirection()
return the Message Direction of the SMSMessage That should be either SMS_IN_MESSAGE :1 Or SMS_OUT_MESSAGE : 2

Returns:
int that will infer the message direction

addProperty

public void addProperty(java.lang.String key,
                        java.lang.Object value)
add the Implementation level properties that properties will be add to the Axis2 Message Context

Parameters:
key -
value -

getProperties

public java.util.Map<java.lang.String,java.lang.Object> getProperties()
Return the properties of the SMS message

Returns:


Copyright © 2004-2009 The Apache Software Foundation. All Rights Reserved.