|
SMSLib 3.5.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.smslib.Message
public abstract class Message
The parent of all message-related classes. Most of common fields and attributes of both inbound and outbound messages are placed in this class.
Nested Class Summary | |
---|---|
static class |
Message.MessageClasses
Enumeration representing the different message classes. |
static class |
Message.MessageEncodings
Enumeration representing available message encodings. |
static class |
Message.MessageTypes
Enumeration representing the different types of messages. |
Constructor Summary | |
---|---|
Message(Message.MessageTypes myType,
java.util.Date myDate,
java.lang.String myText)
|
Method Summary | |
---|---|
void |
addText(java.lang.String addText)
|
java.util.Date |
getDate()
Returns the creation date. |
Message.MessageClasses |
getDCSMessageClass()
Returns the message Class. |
int |
getDstPort()
Returns the destination port of the message. |
Message.MessageEncodings |
getEncoding()
Returns the message encoding. |
java.lang.String |
getGatewayId()
Returns the ID of the gateway which the message was received from (for inbound messages) or the message was dispatched from (outbound messages). |
java.lang.String |
getId()
Returns the message ID. |
long |
getMessageId()
Returns the auto-generated, internal message ID. |
abstract java.lang.String |
getPduUserData()
|
abstract java.lang.String |
getPduUserDataHeader()
|
int |
getSrcPort()
Returns the source port of the message. |
java.lang.String |
getText()
Returns the message text. |
Message.MessageTypes |
getType()
Returns the message type. |
java.lang.String |
getUuid()
|
void |
setDate(java.util.Date myDate)
Sets the creation date to a specific date. |
void |
setDCSMessageClass(Message.MessageClasses messageClass)
Sets the message Class to the specified one. |
void |
setDstPort(int myDstPort)
Sets the destination port of the message. |
void |
setEncoding(Message.MessageEncodings myEncoding)
Sets the message encoding to the specified one. |
void |
setGatewayId(java.lang.String myGtwId)
Sets the message's Gateway ID to a specific value. |
void |
setId(java.lang.String myId)
Sets the message ID to a specific value. |
void |
setSrcPort(int mySrcPort)
Sets the source port of the message. |
void |
setText(java.lang.String myText)
Sets the message text. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Message(Message.MessageTypes myType, java.util.Date myDate, java.lang.String myText)
Method Detail |
---|
public java.util.Date getDate()
setDate(Date)
public void setDate(java.util.Date myDate)
myDate
- A custom date.getDate()
public Message.MessageEncodings getEncoding()
setEncoding(MessageEncodings)
,
Message.MessageEncodings
public Message.MessageClasses getDCSMessageClass()
setDCSMessageClass(org.smslib.Message.MessageClasses)
,
Message.MessageClasses
public void setDCSMessageClass(Message.MessageClasses messageClass)
messageClass
- The message Class.getDCSMessageClass()
,
Message.MessageClasses
public java.lang.String getGatewayId()
setGatewayId(String)
public void setGatewayId(java.lang.String myGtwId)
myGtwId
- The Gateway ID.getGatewayId()
public java.lang.String getId()
setId(String)
public void setId(java.lang.String myId)
myId
- The new message ID.getId()
public long getMessageId()
public java.lang.String getText()
setText(String)
public void setText(java.lang.String myText)
myText
- The message text.getText()
public void addText(java.lang.String addText) throws java.io.UnsupportedEncodingException
java.io.UnsupportedEncodingException
public Message.MessageTypes getType()
Message.MessageTypes
,
setType(MessageTypes)
public int getDstPort()
getDstPort()
,
setSrcPort(int)
,
getSrcPort()
public void setDstPort(int myDstPort)
The default is (-1).
myDstPort
- The destination port.setDstPort(int)
,
setSrcPort(int)
,
getSrcPort()
public int getSrcPort()
setSrcPort(int)
,
setDstPort(int)
,
getDstPort()
public void setSrcPort(int mySrcPort)
The default is (-1).
mySrcPort
- The source port.setDstPort(int)
,
setSrcPort(int)
,
getSrcPort()
public void setEncoding(Message.MessageEncodings myEncoding)
myEncoding
- The message encoding.getEncoding()
,
Message.MessageEncodings
public abstract java.lang.String getPduUserData()
public abstract java.lang.String getPduUserDataHeader()
public java.lang.String getUuid()
|
SMSLib 3.5.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |