public abstract class

NameLookupBuilder

extends Object
java.lang.Object
   ↳ com.android.providers.contacts.NameLookupBuilder

Class Overview

Given a full name, constructs all possible variants of the name.

Summary

Public Constructors
NameLookupBuilder(NameSplitter splitter)
Public Methods
void insertNameLookup(long rawContactId, long dataId, String name, int fullNameStyle)
Inserts name lookup records for the given structured name.
Protected Methods
abstract String[] getCommonNicknameClusters(String normalizedName)
Returns common nickname cluster IDs for a given name.
abstract void insertNameLookup(long rawContactId, long dataId, int lookupType, String string)
Inserts a name lookup record with the supplied column values.
String normalizeName(String name)
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public NameLookupBuilder (NameSplitter splitter)

Public Methods

public void insertNameLookup (long rawContactId, long dataId, String name, int fullNameStyle)

Inserts name lookup records for the given structured name.

Protected Methods

protected abstract String[] getCommonNicknameClusters (String normalizedName)

Returns common nickname cluster IDs for a given name. For example, it will return the same value for "Robert", "Bob" and "Rob". Some names belong to multiple clusters, e.g. Leo could be Leonard or Leopold. May return null.

Parameters
normalizedName A normalized first name, see normalize(String).

protected abstract void insertNameLookup (long rawContactId, long dataId, int lookupType, String string)

Inserts a name lookup record with the supplied column values.

protected String normalizeName (String name)