public class ImAddress extends Object
SystemCapability.SysAppComponents#CONTACT| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static int |
CUSTOM_LABEL |
TYPE_CUSTOM
|
static int |
IM_AIM |
Indicates an AIM instant message.
|
static int |
IM_ICQ |
Indicates an ICQ instant message.
|
static int |
IM_JABBER |
Indicates a Jabber instant message.
|
static int |
IM_MSN |
Indicates a Windows Live instant message.
|
static int |
IM_QQ |
Indicates a QQ instant message.
|
static int |
IM_SKYPE |
Indicates a Skype instant message.
|
static int |
IM_YAHOO |
Indicates a Yahoo instant message.
|
static int |
INVALID_LABEL_ID |
INVALID_LABEL_ID
|
| 构造器 | 说明 |
|---|---|
ImAddress(String imAddress,
String customLabelName) |
A constructor used to create an
ImAddress instance based on a specified IM address
and a custom label name. |
ImAddress(Context context,
String imAddress,
int labelId) |
A constructor used to create an
ImAddress instance based on the application context
and a specified IM address and label ID. |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
boolean |
equals(Object object) |
Indicates whether some other object is "equal to" this one.
|
String |
getImAddress() |
Obtains the IM address.
|
String |
getLabelName() |
Obtains the label name of an attribute.
|
int |
hashCode() |
Returns a hash code value for the object.
|
void |
setCustomLabelName(String labelName) |
Set custom label data.
|
void |
setImAddress(String imAddress) |
Sets the IM address.
|
void |
setLabelId(Context context,
int labelId) |
Set label id and name.
|
public static final int CUSTOM_LABEL
public static final int IM_AIM
public static final int IM_ICQ
public static final int IM_JABBER
public static final int IM_MSN
public static final int IM_QQ
public static final int IM_SKYPE
public static final int IM_YAHOO
public static final int INVALID_LABEL_ID
public ImAddress(Context context, String imAddress, int labelId)
ImAddress instance based on the application context
and a specified IM address and label ID.
The label ID can be any of the following:
context - Indicates the application context.imAddress - Indicates the IM address.labelId - Indicates the label ID.public String getImAddress()
public void setImAddress(String imAddress)
imAddress - Indicates the IM address to set.public void setCustomLabelName(String labelName)
labelName - Indicates the custom label name to set.public int hashCode()
HashMap.hashCode 在类中 ObjectObject.equals(java.lang.Object),
System.identityHashCode(java.lang.Object)public void setLabelId(Context context, int labelId)
context - Indicates the application context.labelId - Indicates the label ID to set.public boolean equals(Object object)
equals 在类中 Objectobj - the reference object with which to compare.true if this object is the same as the obj argument;
false otherwise.Object.hashCode(),
HashMappublic String getLabelName()