Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)   
Deprecated in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Ctors](https://developer.android.com/reference/android/provider/FontRequest#pubctors) \| [Methods](https://developer.android.com/reference/android/provider/FontRequest#pubmethods) \| [Inherited Methods](https://developer.android.com/reference/android/provider/FontRequest#inhmethods)

# FontRequest

*** ** * ** ***

` public final class FontRequest `   
` extends https://developer.android.com/reference/java/lang/Object ` ` `

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | android.provider.FontRequest |

<br />

*** ** * ** ***

<br />

**This class was deprecated in API level 31.**   

Use the `https://developer.android.com/reference/androidx/core/provider/FontRequest.html`

Information about a font request that may be sent to a Font Provider.

## Summary

| ### Public constructors ||
|---|---|
| ` https://developer.android.com/reference/android/provider/FontRequest#FontRequest(java.lang.String,%20java.lang.String,%20java.lang.String)(https://developer.android.com/reference/java/lang/String providerAuthority, https://developer.android.com/reference/java/lang/String providerPackage, https://developer.android.com/reference/java/lang/String query) ` |
| ` https://developer.android.com/reference/android/provider/FontRequest#FontRequest(java.lang.String,%20java.lang.String,%20java.lang.String,%20java.util.List<java.util.List<byte[]>>)(https://developer.android.com/reference/java/lang/String providerAuthority, https://developer.android.com/reference/java/lang/String providerPackage, https://developer.android.com/reference/java/lang/String query, https://developer.android.com/reference/java/util/List<https://developer.android.com/reference/java/util/List<byte[]>> certificates) ` |

| ### Public methods ||
|---|---|
| ` https://developer.android.com/reference/java/util/List<https://developer.android.com/reference/java/util/List<byte[]>>` | ` https://developer.android.com/reference/android/provider/FontRequest#getCertificates()() ` Returns the list of certificate sets given for this provider. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/android/provider/FontRequest#getProviderAuthority()() ` Returns the selected font provider's authority. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/android/provider/FontRequest#getProviderPackage()() ` Returns the selected font provider's package. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/android/provider/FontRequest#getQuery()() ` Returns the query string. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/android/provider/FontRequest#toString()() ` Returns a string representation of the object. |

### Inherited methods

From class ` https://developer.android.com/reference/java/lang/Object ` ` https://developer.android.com/reference/java/lang/Object` ` https://developer.android.com/reference/java/lang/Object#clone()() `

Creates and returns a copy of this object.
` boolean` ` https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object obj) `

Indicates whether some other object is "equal to" this one.
` void` ` https://developer.android.com/reference/java/lang/Object#finalize()() `

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
` final https://developer.android.com/reference/java/lang/Class<?>` ` https://developer.android.com/reference/java/lang/Object#getClass()() `

Returns the runtime class of this `Object`.
` int` ` https://developer.android.com/reference/java/lang/Object#hashCode()() `

Returns a hash code value for the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#notify()() `

Wakes up a single thread that is waiting on this object's monitor.
` final void` ` https://developer.android.com/reference/java/lang/Object#notifyAll()() `

Wakes up all threads that are waiting on this object's monitor.
` https://developer.android.com/reference/java/lang/String` ` https://developer.android.com/reference/java/lang/Object#toString()() `

Returns a string representation of the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long,%20int)(long timeoutMillis, int nanos) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long)(long timeoutMillis) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait()() `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*.

## Public constructors

### FontRequest

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public FontRequest (String providerAuthority, 
                String providerPackage, 
                String query)
```

<br />

<br />

| Parameters ||
|---|---|
| `providerAuthority` | `String`: The authority of the Font Provider to be used for the request. This should be a system installed app. This value cannot be `null`. <br /> |
| `providerPackage` | `String`: The package for the Font Provider to be used for the request. This is used to verify the identity of the provider. This value cannot be `null`. <br /> |
| `query` | `String`: The query to be sent over to the provider. Refer to your font provider's documentation on the format of this string. This value cannot be `null`. <br /> |

### FontRequest

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public FontRequest (String providerAuthority, 
                String providerPackage, 
                String query, 
                List<List<byte[]>> certificates)
```

<br />

<br />

| Parameters ||
|---|---|
| `providerAuthority` | `String`: The authority of the Font Provider to be used for the request. This value cannot be `null`. <br /> |
| `providerPackage` | `String`: The package for the Font Provider to be used for the request. This is used to verify the identity of the provider. This value cannot be `null`. <br /> |
| `query` | `String`: The query to be sent over to the provider. Refer to your font provider's documentation on the format of this string. This value cannot be `null`. <br /> |
| `certificates` | `List`: The list of sets of hashes for the certificates the provider should be signed with. This is used to verify the identity of the provider. Each set in the list represents one collection of signature hashes. Refer to your font provider's documentation for these values. This value cannot be `null`. <br /> |

## Public methods

### getCertificates

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public List<List<byte[]>> getCertificates ()
```

Returns the list of certificate sets given for this provider. This helps the system verify that the provider identified by the given authority is the one requested.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/util/List<https://developer.android.com/reference/java/util/List<byte[]>>` | <br /> |

### getProviderAuthority

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String getProviderAuthority ()
```

Returns the selected font provider's authority. This tells the system what font provider it should request the font from.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | <br /> |

### getProviderPackage

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String getProviderPackage ()
```

Returns the selected font provider's package. This helps the system verify that the provider identified by the given authority is the one requested.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | <br /> |

### getQuery

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String getQuery ()
```

Returns the query string. Refer to your font provider's documentation on the format of this string.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | <br /> |

### toString

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String toString ()
```

Returns a string representation of the object.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | a string representation of the object. <br /> |