public final class

ShowOrCreateActivity

extends Activity
java.lang.Object
   ↳ android.content.Context
     ↳ android.content.ContextWrapper
       ↳ android.view.ContextThemeWrapper
         ↳ android.app.Activity
           ↳ com.android.contacts.ui.ShowOrCreateActivity

Class Overview

Handle several edge cases around showing or possibly creating contacts in connected with a specific E-mail address or phone number. Will search based on incoming getData() as described by SHOW_OR_CREATE_CONTACT.

  • If no matching contacts found, will prompt user with dialog to add to a contact, then will use ACTION_INSERT_OR_EDIT to let create new contact or edit new data into an existing one.
  • If one matching contact found, directly show ACTION_VIEW that specific contact.
  • If more than one matching found, show list of matching contacts using ACTION_SEARCH.

Summary

[Expand]
Inherited Constants
From class android.app.Activity
From class android.content.Context
From interface android.content.ComponentCallbacks2
[Expand]
Inherited Fields
From class android.app.Activity
Public Constructors
ShowOrCreateActivity()
Public Methods
void onQueryComplete(int token, Object cookie, Cursor cursor)
void startSearch(String initialQuery, boolean selectInitialQuery, Bundle appSearchData, boolean globalSearch)
Protected Methods
void onCreate(Bundle icicle)
Dialog onCreateDialog(int id)
void onStop()
[Expand]
Inherited Methods
From class android.app.Activity
From class android.view.ContextThemeWrapper
From class android.content.ContextWrapper
From class android.content.Context
From class java.lang.Object
From interface android.content.ComponentCallbacks
From interface android.content.ComponentCallbacks2
From interface android.view.KeyEvent.Callback
From interface android.view.LayoutInflater.Factory
From interface android.view.LayoutInflater.Factory2
From interface android.view.View.OnCreateContextMenuListener
From interface android.view.Window.Callback

Public Constructors

public ShowOrCreateActivity ()

Public Methods

public void onQueryComplete (int token, Object cookie, Cursor cursor)

public void startSearch (String initialQuery, boolean selectInitialQuery, Bundle appSearchData, boolean globalSearch)

Protected Methods

protected void onCreate (Bundle icicle)

protected Dialog onCreateDialog (int id)

protected void onStop ()