|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.objectxp.msg.Message
com.objectxp.msg.SmsMessage
com.objectxp.msg.smart.SmartMessage
public abstract class SmartMessage
Abstract class that serves as base class for sending "Smart" Messages.
| Field Summary |
|---|
| Fields inherited from class com.objectxp.msg.SmsMessage |
|---|
CLASS_0, CLASS_1, CLASS_2, CLASS_3, DC_8BIT, DC_DEFAULT, DC_GROUP_DATA, DC_GROUP_GENERAL, DC_GROUP_MSG_WAITING_DISCARD, DC_GROUP_MSG_WAITING_STORE, DC_UCS2, INDICATION_ACTIVE, INDICATION_INACTIVE, INDICATION_TYPE_EMAIL, INDICATION_TYPE_FAX, INDICATION_TYPE_OTHER, INDICATION_TYPE_VOICEMAIL, NO_CLASS |
| Fields inherited from class com.objectxp.msg.Message |
|---|
ACK_TIME, MT_BINARY, MT_STATUS, MT_TEXT, SENDER_TYPE_ALPHA, SENDER_TYPE_GUESS, SENDER_TYPE_NUMBER |
| Method Summary | |
|---|---|
void |
buildParts(java.lang.Class type,
int refnr)
Fragmentize the Multipart message. |
void |
buildParts(int refnr)
This method will be called by SmsService implementations prior to
sending a MultiPartMessage. |
SmsMessage[] |
getParts()
Returns the parts (fragments). |
| Methods inherited from class com.objectxp.msg.Message |
|---|
clone, getProperty, getSenderType, getTimestamp, setID, setProperty, setSenderType |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public final void buildParts(int refnr)
MultiPartMessageSmsService implementations prior to
sending a MultiPartMessage.
buildParts() will split the message into multiple parts if necessary. The
parts can then be accessed by calling MultiPartMessage.getParts().
Please note that there is no need to invoke this method directly since SmsService implementations call this method automatically.
buildParts in interface MultiPartMessagerefnr - the reference-number to use for concatenated messages.
public final void buildParts(java.lang.Class type,
int refnr)
MultiPartMessageInvoke this method before sending a Multipart message if you want to specify the type of the resulting fragments.
Example
The following example shows how to set the CIMD2 specific priority flag
on all fragments of a Multipart message:
Ringtone rt = new Ringtone("...");
rt.buildParts(Cimd2Message.class, myRefnr++);
Cimd2Message[] fragments = (Cimd2Message[]) rt.getParts();
for( int i=0; i < fragments.length; i++ ) {
fragments[i].setPriority(new Integer(5));
}
cimd2Service.sendMessage(rt);
buildParts in interface MultiPartMessagetype - the type used for the fragments. Must be an instance of SmsMessage.refnr - the reference-number to use for the concatenated messages.public SmsMessage[] getParts()
MultiPartMessage
getParts in interface MultiPartMessage
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||