# Person

Artifact: [androidx.appsearch:appsearch-builtin-types](https://developer.android.com/jetpack/androidx/releases/appsearch) [View Source](https://cs.android.com/search?q=file:androidx/appsearch/builtintypes/Person.java+class:androidx.appsearch.builtintypes.Person) Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

*** ** * ** ***


```
@Document(name = "builtin:Person")
class Person : Thing
```

<br />

|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html) |||
| ↳ | [androidx.appsearch.builtintypes.Thing](https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing) ||
|   | ↳ | [androidx.appsearch.builtintypes.Person](https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person) |

*** ** * ** ***

AppSearch document representing a Person entity modeled after [Person](http://schema.org/Person).

The `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` document includes commonly searchable properties such as name, organization, and notes, as well as contact information such as phone numbers, email addresses, etc, grouped by their label. The labeled contact information is present in a nested `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/ContactPoint` document.

## Summary

| ### Nested types |
|---|
| `class https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.AdditionalName` Holds type information for additional names for Person. |
| `@https://developer.android.com/reference/kotlin/androidx/appsearch/annotation/Document.BuilderProducer class https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.Builder : https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.BuilderBase<https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.Builder!>` Builder class for `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `@https://developer.android.com/reference/kotlin/androidx/appsearch/app/ExperimentalAppSearchApi class https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.BuilderBase<T : https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.BuilderBase<T!>?> : https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing.BuilderBase<T!>` |

| ### Public constructors |
|---|
| `@https://developer.android.com/reference/kotlin/androidx/appsearch/app/ExperimentalAppSearchApi https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#Person(androidx.appsearch.builtintypes.Person.BuilderBase<?>)(builder: https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.BuilderBase<*>)` Constructor for `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |

| ### Public functions |
|---|---|
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getAdditionalNames()()` Returns a list of additional names for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getAffiliations()()` Returns a list of affiliation for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/ContactPoint!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getContactPoints()()` Returns a list of `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/ContactPoint`. |
| `https://developer.android.com/reference/android/net/Uri.html?` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getExternalUri()()` Returns an external uri for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getFamilyName()()` Returns the family (or last) name for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getGivenName()()` Returns the given (or first) name for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `https://developer.android.com/reference/android/net/Uri.html?` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getImageUri()()` Returns `https://developer.android.com/reference/android/net/Uri.html` of the profile image for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getMiddleName()()` Returns the middle name(s) for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getNotes()()` Returns the notes about this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getRelations()()` Returns a list of relations for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`, like "Father" or "Mother". |
| `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.AdditionalName!>` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getTypedAdditionalNames()()` Returns a list of `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.AdditionalName` for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#isBot()()` Returns whether this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` is a machine rather than a human. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#isImportant()()` Returns whether this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` is important to the user of this device with regards to how frequently they interact. |

### Inherited functions

From [androidx.appsearch.builtintypes.Thing](https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing) `(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!>` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getAlternateNames()()`

Returns an unmodifiable list of aliases, if any, for this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getCreationTimestampMillis()()`

Returns the creation timestamp, in milliseconds since Unix epoch, of this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getDescription()()`

Returns a description of this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getDocumentScore()()`

Returns the intrinsic score (or importance) of this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getDocumentTtlMillis()()`

Returns the time-to-live timestamp, in milliseconds since `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getCreationTimestampMillis()`, for this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getId()()`

Returns the unique identifier for this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` `@https://developer.android.com/reference/kotlin/androidx/appsearch/app/ExperimentalAppSearchApi
https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getImage()()`

Returns the URL for an image of this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getName()()`

Returns the name of this item.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getNamespace()()`

Returns the namespace (or logical grouping) for this item.
`(https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/PotentialAction!>` `@https://developer.android.com/reference/kotlin/androidx/appsearch/app/ExperimentalAppSearchApi
https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getPotentialActions()()`

Returns the actions that can be taken on this object.
`https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html?` `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Thing#getUrl()()`

Returns the deeplink URL of this item.

## Public constructors

### Person

Added in [1.2.0-alpha02](https://developer.android.com/jetpack/androidx/releases/appsearch#1.2.0-alpha02)

```
@ExperimentalAppSearchApi
Person(builder: Person.BuilderBase<*>)
```

Constructor for `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

| Parameters |
|---|---|
| `builder: https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.BuilderBase<*>` | The builder to construct the `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` from. |

## Public functions

### getAdditionalNames

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getAdditionalNames(): (Mutable)List<String!>
```

Returns a list of additional names for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

Additional names can include something like phonetic names, or nicknames.

Different from `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person#getTypedAdditionalNames()`, the return value doesn't include type information for the additional names.

### getAffiliations

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getAffiliations(): (Mutable)List<String!>
```

Returns a list of affiliation for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. Like company, school, etc.

For a contact with the title "Software Engineer" in a department "Engineering" at a company "Cloud Company", this can include a flattened value of "Software Engineer, Engineering, Cloud Company".

### getContactPoints

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getContactPoints(): (Mutable)List<ContactPoint!>
```

Returns a list of `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/ContactPoint`.

More information can be found in `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/ContactPoint`.

### getExternalUri

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getExternalUri(): Uri?
```

Returns an external uri for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`. Or `null` if no `https://developer.android.com/reference/android/net/Uri.html` is provided. A `https://developer.android.com/reference/android/net/Uri.html` can be any of the following:

- A `https://developer.android.com/reference/android/provider/ContactsContract.Contacts.html#CONTENT_LOOKUP_URI`.
- A `mailto:` schema\*
- A `tel:` schema\*

For mailto: and tel: URI schemes, it is recommended that the path portion refers to a valid contact in the Contacts Provider.

### getFamilyName

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getFamilyName(): String?
```

Returns the family (or last) name for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

### getGivenName

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getGivenName(): String?
```

Returns the given (or first) name for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

### getImageUri

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getImageUri(): Uri?
```

Returns `https://developer.android.com/reference/android/net/Uri.html` of the profile image for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

### getMiddleName

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getMiddleName(): String?
```

Returns the middle name(s) for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

For a Person with multiple middle names, this method returns a flattened and whitespace separated list. For example, "middle1 middle2 ..."

### getNotes

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getNotes(): (Mutable)List<String!>
```

Returns the notes about this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

### getRelations

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getRelations(): (Mutable)List<String!>
```

Returns a list of relations for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`, like "Father" or "Mother".

### getTypedAdditionalNames

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun getTypedAdditionalNames(): (Mutable)List<Person.AdditionalName!>
```

Returns a list of `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.AdditionalName` for this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person`.

Additional names can include something like phonetic names, or nicknames.

Each `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person.AdditionalName` contains type information for the additional name.

### isBot

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun isBot(): Boolean
```

Returns whether this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` is a machine rather than a human.

### isImportant

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/appsearch#1.1.0)

```
fun isImportant(): Boolean
```

Returns whether this `https://developer.android.com/reference/kotlin/androidx/appsearch/builtintypes/Person` is important to the user of this device with regards to how frequently they interact.