|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mobicents.protocols.smpp.gsm.UserDataImpl
public class UserDataImpl
Implementation of UserData.
This implementation automatically handles the inclusion of the
concatenated SMS HeaderElement. Calling code should not
attempt to add a ConcatenatedSms header element
via addHeaderElement(HeaderElement).
| Constructor Summary | |
|---|---|
UserDataImpl()
Create a new UserDataImpl that uses 8-bit reference numbers, if concatenated SMS is required. |
|
UserDataImpl(boolean useConcat16)
Create a new UserDataImpl. |
|
| Method Summary | |
|---|---|
void |
addHeaderElement(HeaderElement element)
Add a HeaderElement to this user data implementation. |
byte[] |
getData()
Get the payload of this user data. |
boolean |
isMultiMessage()
Calculate if this user data requires multiple SMS segments. |
void |
setData(byte[] data)
Set the payload of this user data. |
byte[][] |
toSegments()
Get the user data SMS segments. |
byte[] |
toSingleSms()
Get the user data as a single message. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UserDataImpl()
public UserDataImpl(boolean useConcat16)
useConcat16 - If concatenated SMS is required, pass true
for this value to use 16-bit segment reference numbers or false
to use 8-bit segment reference numbers.| Method Detail |
|---|
public void addHeaderElement(HeaderElement element)
HeaderElement to this user data implementation.
addHeaderElement in interface UserDataelement - The header element to add.
IllegalArgumentException - If element is an instance of
ConcatenatedSms.public byte[] toSingleSms()
UserDataUserData.isMultiMessage() returns false.
toSingleSms in interface UserDatapublic byte[][] toSegments()
UserData
toSegments in interface UserDatapublic boolean isMultiMessage()
UserData
isMultiMessage in interface UserDatapublic byte[] getData()
UserData
getData in interface UserDatapublic void setData(byte[] data)
UserData
setData in interface UserDatadata - The payload of this user data.UserData.getData()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||