# FontsContractCompat.FontFamilyResult

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  
belongs to Maven artifact com.android.support:support-compat:28.0.0-alpha1  
Summary:[Constants](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#constants)\|[Methods](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#pubmethods)\|[Inherited Methods](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#inhmethods)\|[\[Expand All\]](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#)  

# FontsContractCompat.FontFamilyResult

| This package is part of the Android[support library](https://developer.android.com/topic/libraries/support-library)which is no longer maintained. The support library has been superseded by[AndroidX](https://developer.android.com/jetpack/androidx)which is part of[Jetpack](https://developer.android.com/jetpack). We recommend using the AndroidX libraries in all new projects. You should also consider[migrating](https://developer.android.com/jetpack/androidx/migrate)existing projects to AndroidX. To find the AndroidX class that maps to this deprecated class, see the AndroidX support library[class mappings](https://developer.android.com/jetpack/androidx/migrate/class-mappings).

`
public
static


class
FontsContractCompat.FontFamilyResult
`  
`

extends Object


``


`

|---|------------------------------------------------------------------|
| java.lang.Object                                                    ||
| ↳ | android.support.v4.provider.FontsContractCompat.FontFamilyResult |

<br />

*** ** * ** ***

Object returned from[fetchFonts(Context, CancellationSignal, FontRequest)](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat#fetchFonts(android.content.Context, android.os.CancellationSignal, android.support.v4.provider.FontRequest)).

## Summary

|                                                                                                                            ### Constants                                                                                                                             ||
|-------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `int` | [STATUS_OK](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#STATUS_OK) Constant represents that the font was successfully retrieved.                                                                 |
| `int` | [STATUS_UNEXPECTED_DATA_PROVIDED](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#STATUS_UNEXPECTED_DATA_PROVIDED) Constant represents that the provider returns unexpected data.                    |
| `int` | [STATUS_WRONG_CERTIFICATES](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#STATUS_WRONG_CERTIFICATES) Constant represents that the given certificate was not matched with the provider's signature. |

|                                                                                                                          ### Public methods                                                                                                                          ||
|-------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------|
| ` `[FontInfo[]](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontInfo) | ` `[getFonts](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#getFonts())`() `           |
| ` int`                                                                                                            | ` `[getStatusCode](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#getStatusCode())`() ` |

| ### Inherited methods |
|-----------------------|---|
| [![](https://developer.android.com/static/assets/images/styles/disclosure_down.png)](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#)From class` java.lang.Object ` |-------------------|-------------------------------| | ` Object`         | ` clone() `                   | | ` boolean`        | ` equals(Object arg0) `       | | ` void`           | ` finalize() `                | | ` final Class<?>` | ` getClass() `                | | ` int`            | ` hashCode() `                | | ` final void`     | ` notify() `                  | | ` final void`     | ` notifyAll() `               | | ` String`         | ` toString() `                | | ` final void`     | ` wait(long arg0, int arg1) ` | | ` final void`     | ` wait(long arg0) `           | | ` final void`     | ` wait() `                    | ||

## Constants

### STATUS_OK

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int STATUS_OK
```

Constant represents that the font was successfully retrieved. Note that when this value is set and[getFonts()](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#getFonts())returns an empty array, it means there were no fonts matching the given query.

<br />

Constant Value: 0 (0x00000000)  

### STATUS_UNEXPECTED_DATA_PROVIDED

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int STATUS_UNEXPECTED_DATA_PROVIDED
```

Constant represents that the provider returns unexpected data.[getFonts()](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#getFonts())returns null if this status was set. For example, this value is set when the font provider gives invalid format of variation settings.

<br />

Constant Value: 2 (0x00000002)  

### STATUS_WRONG_CERTIFICATES

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int STATUS_WRONG_CERTIFICATES
```

Constant represents that the given certificate was not matched with the provider's signature.[getFonts()](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult#getFonts())returns null if this status was set.

<br />

Constant Value: 1 (0x00000001)

## Public methods

### getFonts

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
FontInfo[] getFonts ()
```

<br />

<br />

|                                                        Returns                                                         ||
|----------------------------------------------------------------------------------------------------------------|--------|
| [FontInfo[]](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontInfo) | <br /> |

### getStatusCode

added in[version 26.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getStatusCode ()
```

<br />

<br />

|    Returns    ||
|-------|--------|
| `int` | <br /> |

-

  ## Classes

  - [DocumentFile](https://developer.android.com/reference/android/support/v4/provider/DocumentFile)
  - [FontRequest](https://developer.android.com/reference/android/support/v4/provider/FontRequest)
  - [FontsContractCompat](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat)
  - [FontsContractCompat.Columns](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.Columns)
  - [FontsContractCompat.FontFamilyResult](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontFamilyResult)
  - [FontsContractCompat.FontInfo](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontInfo)
  - [FontsContractCompat.FontRequestCallback](https://developer.android.com/reference/android/support/v4/provider/FontsContractCompat.FontRequestCallback)