|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdanger.app.Listener
danger.contacts.Dialable
danger.contacts.Contact
public abstract class Contact
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface danger.util.ActiveObject |
|---|
ActiveObject.Delegate, ActiveObject.WeakDelegateList |
| Field Summary | |
|---|---|
static int |
CHANGETYPE_DELETION
Deprecated. |
static int |
CHANGETYPE_MODIFICATION
Deprecated. |
static int |
EVENT_CHANGETYPE_DELETION
EVENT_CHANGETYPE_DELETION - The Contact was deleted This event type is broadcast to Listeners registered for Contact Change Events when this Contact is deleted. |
static int |
EVENT_CHANGETYPE_MODIFICATION
EVENT_CHANGETYPE_MODIFICATION - The Contact was modified. |
static int |
FIELD_COMPANY
|
static int |
FIELD_EMAIL_1
|
static int |
FIELD_EMAIL_2
|
static int |
FIELD_EMAIL_3
|
static int |
FIELD_EMAIL_4
|
static int |
FIELD_EMAIL_5
|
static int |
FIELD_EMAIL_ALL
|
static int |
FIELD_FIRSTNAME
For backwards compatibility. |
static int |
FIELD_LASTNAME
|
static int |
FIELD_NICKNAME
|
static int |
FIELD_PHONE_1
|
static int |
FIELD_PHONE_10
|
static int |
FIELD_PHONE_2
|
static int |
FIELD_PHONE_3
|
static int |
FIELD_PHONE_4
|
static int |
FIELD_PHONE_5
|
static int |
FIELD_PHONE_6
|
static int |
FIELD_PHONE_7
|
static int |
FIELD_PHONE_8
|
static int |
FIELD_PHONE_9
|
static int |
FIELD_PHONE_ALL
|
static int |
NAME_FORMAT_BOTH
Deprecated. |
static int |
NAME_FORMAT_FIRST
When asking for the formatted contact name and you want the First name to appear first. |
static int |
NAME_FORMAT_LAST
When asking for the formatted contact name and you want the Last name to appear first. |
static int |
NAME_FORMAT_USE_MIDDLENAME
When asking for the formatted contact name and you want to include the Middle name. |
static int |
NAME_FORMAT_USE_NICKNAME
When asking for the formatted contact name and you want the First name to be replaced by the Nickname. |
| Constructor Summary | |
|---|---|
Contact()
|
|
| Method Summary | |
|---|---|
abstract int |
convertMatchFieldToIndex(int fieldspec)
This is a convenience for getting at the data in the contact that was matched by one of the search methods. |
abstract boolean |
equals(Object o)
|
abstract String |
getAddress(int index)
|
abstract int |
getAddressCount()
|
abstract String |
getAddressLabel(int index)
|
abstract int |
getBirthDate()
|
abstract int |
getBirthMonth()
|
abstract int |
getBirthYear()
|
abstract String |
getCity(int index)
|
abstract String |
getCompany()
|
abstract String |
getCountry(int index)
|
abstract byte[] |
getCustomIconData()
|
abstract String |
getDisplayInfoString()
|
abstract String |
getEmailAddress(int index)
|
abstract int |
getEmailCount()
|
abstract String |
getEmailLabel(int index)
|
abstract String |
getFirstName()
|
abstract String |
getFormattedName(int format)
Get the Contact full name using the specified format. |
abstract Bitmap |
getIconAsBitmap(int size,
boolean circleCrop)
|
abstract Bitmap |
getIconForPhoneNumber(String number,
int size)
Return the icon associated with this phone number, if it's a favorite. |
abstract int |
getIconIndex()
|
abstract String |
getIMAccount(int i)
|
abstract int |
getIMCount()
|
abstract String |
getIMLabel(int i)
|
abstract String |
getLastName()
|
abstract String[] |
getMatchFieldAndLabel(int field)
This is a convenience for getting at the data in the contact that was matched by one of the search methods. |
abstract String |
getMiddleName()
|
abstract String |
getNickname()
|
abstract String |
getNote()
|
abstract String |
getPhoneLabel(int index)
|
abstract String |
getPhoneNumber(int index)
|
abstract PhoneNumber |
getPhoneNumberObject(int index)
|
abstract int |
getRingToneFlags(int index)
|
abstract int |
getRingToneID(int index)
|
abstract int |
getSMSRingToneFlags(int index)
|
abstract int |
getSMSRingToneID(int index)
|
abstract String |
getState(int index)
|
abstract String |
getTitle()
|
abstract int |
getUID()
Get the UID of this Contact object |
abstract String |
getURLAddress(int index)
|
abstract int |
getURLCount()
|
abstract String |
getURLLabel(int index)
|
abstract String |
getZipCode(int index)
|
abstract boolean |
hasCustomIcon()
|
abstract boolean |
hasCustomRingTone()
|
abstract boolean |
hasPhoneNumbers()
|
abstract boolean |
isInTrash()
|
abstract boolean |
isMe()
|
abstract boolean |
isOnSIM()
|
void |
registerForContactChangeEvents(Listener listener)
Use this method to register a Listener for Contact change events. |
abstract String |
toVCard()
|
void |
unregisterFromContactChangeEvents(Listener listener)
Use this method in conjunction with registerForContactChangeEvents(Listener listener) |
| Methods inherited from class danger.contacts.Dialable |
|---|
getDisplayNameFirst, getDisplayNameLast, getIconAsBitmap, getPhoneCount, getPhoneNumberAndLabel, isFavorite |
| Methods inherited from class danger.app.Listener |
|---|
cancelEvents, childEventPump, childEventPumpDone, eventProblem, isDispatchingThread, receiveEvent, receiveEventInternal, sendEvent, sendEvent, sendEvent, sendEvent, sendEvent, sendLowPriorityEvent |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface danger.util.ActiveObject |
|---|
addDelegate, removeDelegate, update |
| Field Detail |
|---|
public static final int CHANGETYPE_MODIFICATION
public static final int CHANGETYPE_DELETION
public static final int EVENT_CHANGETYPE_MODIFICATION
registerForContactChangeEvents(Listener listener) to register a Listener for Contact change events.
public static final int EVENT_CHANGETYPE_DELETION
registerForContactChangeEvents(Listener listener) to register a Listener for Contact change events.
public static final int NAME_FORMAT_FIRST
getFormattedName(int)
public static final int NAME_FORMAT_LAST
getFormattedName(int)
public static final int NAME_FORMAT_USE_NICKNAME
getFormattedName(int)
public static final int NAME_FORMAT_USE_MIDDLENAME
getFormattedName(int)
public static final int NAME_FORMAT_BOTH
public static final int FIELD_FIRSTNAME
Contact.IndexedField for enumeration definition.
public static final int FIELD_LASTNAME
public static final int FIELD_NICKNAME
public static final int FIELD_COMPANY
public static final int FIELD_EMAIL_1
public static final int FIELD_EMAIL_2
public static final int FIELD_EMAIL_3
public static final int FIELD_EMAIL_4
public static final int FIELD_EMAIL_5
public static final int FIELD_PHONE_1
public static final int FIELD_PHONE_2
public static final int FIELD_PHONE_3
public static final int FIELD_PHONE_4
public static final int FIELD_PHONE_5
public static final int FIELD_PHONE_6
public static final int FIELD_PHONE_7
public static final int FIELD_PHONE_8
public static final int FIELD_PHONE_9
public static final int FIELD_PHONE_10
public static final int FIELD_EMAIL_ALL
public static final int FIELD_PHONE_ALL
| Constructor Detail |
|---|
public Contact()
| Method Detail |
|---|
public abstract boolean equals(Object o)
equals in class Objecto - An object to compare with.
public abstract String[] getMatchFieldAndLabel(int field)
field - A field specification, such as is returned by a match method.
public abstract int convertMatchFieldToIndex(int fieldspec)
fieldspec - A bitfield specifying a contact field, such as the ones
returned by the match methods.
public abstract String toVCard()
public abstract String getDisplayInfoString()
public abstract String getFormattedName(int format)
NAME_FORMAT_FIRST - First name first.NAME_FORMAT_LAST - Last name first.NAME_FORMAT_USE_NICKNAME - Nickname is used in place of First name.NAME_FORMAT_USE_MIDDLENAME - Middle name is included in the returned name string.NAME_FORMAT_BOTH - deprecated : This is a redundant field, since both First and Last names are included in the formatted name if available.
format - A bitmap specifying the name format parameters
public abstract String getFirstName()
public abstract String getLastName()
public abstract String getMiddleName()
public abstract String getNickname()
public abstract String getCompany()
public abstract String getTitle()
public abstract boolean isInTrash()
public abstract boolean isMe()
public abstract boolean isOnSIM()
public abstract boolean hasPhoneNumbers()
public abstract boolean hasCustomRingTone()
public abstract int getBirthDate()
public abstract int getBirthMonth()
public abstract int getBirthYear()
public abstract String getNote()
public abstract int getIconIndex()
public abstract Bitmap getIconAsBitmap(int size,
boolean circleCrop)
size - One of the IconGallery size constants.circleCrop - True if this icon should be cropped to a circle.
public abstract Bitmap getIconForPhoneNumber(String number,
int size)
number - The phone number to look for custom icons for.size - One of the IconGallery size constants.
public abstract boolean hasCustomIcon()
public abstract byte[] getCustomIconData()
public abstract int getEmailCount()
public abstract String getEmailLabel(int index)
index - Zero-based index specifying which email address.
public abstract String getEmailAddress(int index)
index - Zero-based index specifying which email address.
public abstract int getIMCount()
public abstract String getIMAccount(int i)
i - Zero-based index specifying which IM account.
public abstract String getIMLabel(int i)
i - Zero-based index specifying which IM account.
public abstract String getPhoneLabel(int index)
index - Zero-based index specifying which phone number.
public abstract String getPhoneNumber(int index)
index - Zero-based index specifying which phone number.
public abstract PhoneNumber getPhoneNumberObject(int index)
index - Zero-based index specifying which phone number.
public abstract int getSMSRingToneFlags(int index)
index - Zero-based index specifying which phone number.
public abstract int getSMSRingToneID(int index)
index - Zero-based index specifying which phone number.
public abstract int getRingToneFlags(int index)
index - Zero-based index specifying which phone number.
public abstract int getRingToneID(int index)
index - Zero-based index specifying which phone number.
public abstract int getURLCount()
public abstract String getURLLabel(int index)
index - Zero-based index specifying which URL.
public abstract String getURLAddress(int index)
index - Zero-based index specifying which URL.
public abstract int getAddressCount()
public abstract String getAddressLabel(int index)
index - Zero-based index specifying which street address.
public abstract String getAddress(int index)
index - Zero-based index specifying which street address.
public abstract String getCity(int index)
index - Zero-based index specifying which street address.
public abstract String getState(int index)
index - Zero-based index specifying which street address.
public abstract String getZipCode(int index)
index - Zero-based index specifying which street address.
public abstract String getCountry(int index)
index - Zero-based index specifying which street address.
public abstract int getUID()
public final void registerForContactChangeEvents(Listener listener)
EVENT_CHANGETYPE_MODIFICATIONEVENT_CHANGETYPE_DELETION
listener - The Listener that will receive the event notificationspublic final void unregisterFromContactChangeEvents(Listener listener)
registerForContactChangeEvents(Listener listener)
listener - The Listener to unregister from Contact change events
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||