public class SipAddress extends Object
SystemCapability.SysAppComponents#CONTACT| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static int |
CUSTOM_LABEL |
Indicates a custom label.
|
static int |
INVALID_LABEL_ID |
Indicates an invalid label ID.
|
static int |
SIP_HOME |
Indicates a home SIP address.
|
static int |
SIP_OTHER |
Indicates an SIP address of the
OTHER type. |
static int |
SIP_WORK |
Indicates a work SIP address.
|
| 构造器 | 说明 |
|---|---|
SipAddress(String sipAddress,
String customLabelName) |
A constructor used to create an
SipAddress instance based on a specified SIP address
and a custom label name. |
SipAddress(Context context,
String sipAddress,
int labelId) |
A constructor used to create an
SipAddress instance based on the application context
and a specified SIP address and label ID. |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
boolean |
equals(Object object) |
Indicates whether some other object is "equal to" this one.
|
String |
getLabelName() |
Obtains the label name of an attribute.
|
String |
getSipAddress() |
Obtains the SIP address.
|
int |
hashCode() |
Returns a hash code value for the object.
|
void |
setCustomLabelName(String labelName) |
Set custom label data.
|
void |
setLabelId(Context context,
int labelId) |
Set label id and name.
|
void |
setSipAddress(String sipAddress) |
Sets the SIP address.
|
public static final int CUSTOM_LABEL
If this label type is used, attribute CustomLabelName must be set.
public static final int INVALID_LABEL_ID
public static final int SIP_HOME
public static final int SIP_OTHER
OTHER type.public static final int SIP_WORK
public SipAddress(Context context, String sipAddress, int labelId)
SipAddress instance based on the application context
and a specified SIP address and label ID.
The label ID can be any of the following:
context - Indicates the application context.sipAddress - Indicates the SIP address.labelId - Indicates the label ID.public String getSipAddress()
public void setSipAddress(String sipAddress)
sipAddress - Indicates the SIP 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()