|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.skype.ipc.SidObject
com.skype.api.Sms
public final class Sms
Wrapper class that includes SMS-specific properties and methods, such as P_BODY and GetTargetPrice. Instantiate SMS instances using Skype.CreateOutgoingSms; post SMS messages to a Conversation using Conversation.PostSMS. Each SMS can have multiple targets (normalized phone numbers). Note that in a Conversation context, every SMS instance has a corresponding Message instance. Once you've posted an SMS, you can retrieve its corresponding Message instance using Sms.GetPropChatmsgId. That Message instance's P_BODY_XML property contains the SMS message data, such as price, target phone number(s), failure codes, and so forth, which you can parsed out and display in the UI. To put it another way, the object chain goes like this:
| Nested Class Summary | |
|---|---|
static class |
Sms.ConfirmType
|
static class |
Sms.FailureReason
|
class |
Sms.GetBodyChunksResponse
|
static class |
Sms.Property
Properties of the Sms class |
class |
Sms.SetBodyResponse
|
static class |
Sms.SetBodyResult
|
static class |
Sms.Status
|
static class |
Sms.TargetStatus
|
static class |
Sms.Type
|
| Field Summary | |
|---|---|
java.lang.String |
mBody
|
Message |
mChatMsg
|
Sms.FailureReason |
mFailureReason
|
boolean |
mIsFailedUnseen
|
int |
mPrice
|
java.lang.String |
mPriceCurrency
|
int |
mPricePrecision
|
java.lang.String |
mReplyToNumber
|
Sms.Status |
mStatus
|
java.lang.String |
mTargetNumbers
|
byte[] |
mTargetStatuses
|
int |
mTimestamp
|
Sms.Type |
mType
|
| Fields inherited from class com.skype.ipc.SidObject |
|---|
mSidCached, mSidOid, mSidRoot, mSidTimestamp |
| Constructor Summary | |
|---|---|
Sms(int oid,
SidRoot root)
|
|
| Method Summary | |
|---|---|
java.lang.String |
getBody()
actual payload |
Sms.GetBodyChunksResponse |
getBodyChunks()
Retrieves string list of SMS text chunks in first argument, while the second argument contains the number of available characters until creation of the next chunk becomes necessary. |
Message |
getChatMsg()
reference to Message |
Sms.FailureReason |
getFailureReason()
Set asynchronously and meaningful only after invoking Conversation.PostSMS and detecting Sms.STATUS of SOME_TARGETS_FAILED or FAILED. |
boolean |
getIsFailedUnseen()
set to 1 when status goes to FAILED. |
int |
getPrice()
The total price of sending this SMS message (sum of the individual prices to send to each recipient). |
java.lang.String |
getPriceCurrency()
should be same as account currency at the time of composing/sending |
int |
getPricePrecision()
The decimal precision of the SMS price values, both individual and total. |
java.lang.String |
getPropertyAsString(int prop)
|
java.lang.String |
getPropertyAsString(Sms.Property prop)
|
java.lang.String |
getReplyToNumber()
number that should receive the replies |
Sms.Status |
getStatus()
|
java.lang.String |
getTargetNumbers()
space-separated normalised pstn numbers |
int |
getTargetPrice(java.lang.String target)
Retrieves the amount of Skype credit necessary to send the SMS to a particular recipient. |
Sms.TargetStatus |
getTargetStatus(java.lang.String target)
Retrieves the send status of this SMS to a particular recipient (P_TARGET_STATUSES) either prior to or after invoking Conversation.PostSMS. |
byte[] |
getTargetStatuses()
binary blob. |
int |
getTimestamp()
unix timestamp of message submission |
Sms.Type |
getType()
|
int |
moduleId()
|
Sms.SetBodyResponse |
setBody(java.lang.String text)
-The- method for setting the body text of this SMS. |
boolean |
setTargets(java.lang.String[] numbers)
Sets the recipient(s) of this SMS. |
byte[] |
sidGetBinaryProperty(PropertyEnumConverting prop)
|
boolean |
sidGetBoolProperty(PropertyEnumConverting prop)
|
EnumConverting |
sidGetEnumProperty(PropertyEnumConverting prop)
|
int |
sidGetIntProperty(PropertyEnumConverting prop)
|
SidObject |
sidGetObjectProperty(PropertyEnumConverting prop)
|
java.lang.String |
sidGetStringProperty(PropertyEnumConverting prop)
|
SidGetResponding |
sidMultiGet(Sms.Property[] requested)
generic multiget of a list of Property |
static SidGetResponding[] |
sidMultiGet(Sms.Property[] requested,
Sms[] objects)
generic multiget of list of Property for a list of Sms |
protected void |
sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
byte[] newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
int newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
SidObject newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public Sms.Type mType
public Sms.Status mStatus
public Sms.FailureReason mFailureReason
public boolean mIsFailedUnseen
public int mTimestamp
public int mPrice
public int mPricePrecision
public java.lang.String mPriceCurrency
public java.lang.String mReplyToNumber
public java.lang.String mTargetNumbers
public byte[] mTargetStatuses
public java.lang.String mBody
public Message mChatMsg
| Constructor Detail |
|---|
public Sms(int oid,
SidRoot root)
| Method Detail |
|---|
public Sms.TargetStatus getTargetStatus(java.lang.String target)
public int getTargetPrice(java.lang.String target)
target - The normalized phone number of the target recipient.
public boolean setTargets(java.lang.String[] numbers)
public Sms.SetBodyResponse setBody(java.lang.String text)
public Sms.GetBodyChunksResponse getBodyChunks()
public SidGetResponding sidMultiGet(Sms.Property[] requested)
requested - the list of requested properties of Sms
public static SidGetResponding[] sidMultiGet(Sms.Property[] requested,
Sms[] objects)
requested - the list of requested properties
public Sms.Type getType()
public Sms.Status getStatus()
public Sms.FailureReason getFailureReason()
public boolean getIsFailedUnseen()
public int getTimestamp()
public int getPrice()
public int getPricePrecision()
public java.lang.String getPriceCurrency()
public java.lang.String getReplyToNumber()
public java.lang.String getTargetNumbers()
public byte[] getTargetStatuses()
public java.lang.String getBody()
public Message getChatMsg()
public java.lang.String sidGetStringProperty(PropertyEnumConverting prop)
sidGetStringProperty in interface SidGetRespondingsidGetStringProperty in class SidObjectpublic SidObject sidGetObjectProperty(PropertyEnumConverting prop)
sidGetObjectProperty in interface SidGetRespondingsidGetObjectProperty in class SidObjectpublic boolean sidGetBoolProperty(PropertyEnumConverting prop)
sidGetBoolProperty in interface SidGetRespondingsidGetBoolProperty in class SidObjectpublic int sidGetIntProperty(PropertyEnumConverting prop)
sidGetIntProperty in interface SidGetRespondingsidGetIntProperty in class SidObjectpublic EnumConverting sidGetEnumProperty(PropertyEnumConverting prop)
sidGetEnumProperty in interface SidGetRespondingsidGetEnumProperty in class SidObjectpublic byte[] sidGetBinaryProperty(PropertyEnumConverting prop)
sidGetBinaryProperty in interface SidGetRespondingsidGetBinaryProperty in class SidObjectpublic java.lang.String getPropertyAsString(int prop)
public java.lang.String getPropertyAsString(Sms.Property prop)
protected void sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
sidOnChangedProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
SidObject newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
int newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
byte[] newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObjectpublic int moduleId()
moduleId in class SidObject
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||