# FingerprintManagerCompat

added in[version 24.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:[Nested Classes](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#nestedclasses)\|[Methods](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#pubmethods)\|[Inherited Methods](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#inhmethods)\|[\[Expand All\]](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#)  

# FingerprintManagerCompat

| 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

final

class
FingerprintManagerCompat
`  
`

extends Object


``


`

|---|------------------------------------------------------------------|
| java.lang.Object                                                    ||
| ↳ | android.support.v4.hardware.fingerprint.FingerprintManagerCompat |

<br />

*** ** * ** ***

A class that coordinates access to the fingerprint hardware.

On platforms before[M](https://developer.android.com/reference/android/os/Build.VERSION_CODES.html#M), this class behaves as there would be no fingerprint hardware available.

## Summary

|                                                                                                                                                                                                                                                                                                                                  ### Nested classes                                                                                                                                                                                                                                                                                                                                  ||
|----------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` class` | [FingerprintManagerCompat.AuthenticationCallback](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationCallback) Callback structure provided to[authenticate(CryptoObject, int, CancellationSignal, AuthenticationCallback, Handler)](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#authenticate(android.support.v4.hardware.fingerprint.FingerprintManagerCompat.CryptoObject, int, android.support.v4.os.CancellationSignal, android.support.v4.hardware.fingerprint.FingerprintManagerCompat.AuthenticationCallback, android.os.Handler)). |
| ` class` | [FingerprintManagerCompat.AuthenticationResult](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationResult) Container for callback data from[authenticate(CryptoObject, int, CancellationSignal, AuthenticationCallback, Handler)](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#authenticate(android.support.v4.hardware.fingerprint.FingerprintManagerCompat.CryptoObject, int, android.support.v4.os.CancellationSignal, android.support.v4.hardware.fingerprint.FingerprintManagerCompat.AuthenticationCallback, android.os.Handler)).   |
| ` class` | [FingerprintManagerCompat.CryptoObject](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.CryptoObject) A wrapper class for the crypto objects supported by FingerprintManager.                                                                                                                                                                                                                                                                                                                                                                                                                                     |

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             ### Public methods                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ||
|------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` void`                                                                                                                                        | ` `[authenticate](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#authenticate(android.support.v4.hardware.fingerprint.FingerprintManagerCompat.CryptoObject, int, android.support.v4.os.CancellationSignal, android.support.v4.hardware.fingerprint.FingerprintManagerCompat.AuthenticationCallback, android.os.Handler))`(`[FingerprintManagerCompat.CryptoObject](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.CryptoObject)` crypto, int flags, `[CancellationSignal](https://developer.android.com/reference/android/support/v4/os/CancellationSignal)` cancel, `[FingerprintManagerCompat.AuthenticationCallback](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationCallback)` callback, `[Handler](https://developer.android.com/reference/android/os/Handler.html)` handler) ` Request authentication of a crypto object. |
| ` static `[FingerprintManagerCompat](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat) | ` `[from](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#from(android.content.Context))`(`[Context](https://developer.android.com/reference/android/content/Context.html)` context) ` Get a[FingerprintManagerCompat](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat)instance for a provided context.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| ` boolean`                                                                                                                                     | ` `[hasEnrolledFingerprints](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#hasEnrolledFingerprints())`() ` Determine if there is at least one fingerprint enrolled.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| ` boolean`                                                                                                                                     | ` `[isHardwareDetected](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#isHardwareDetected())`() ` Determine if fingerprint hardware is present and functional.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |

| ### Inherited methods |
|-----------------------|---|
| [![](https://developer.android.com/static/assets/images/styles/disclosure_down.png)](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat#)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() `                    | ||

## Public methods

### authenticate

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

```
void authenticate (FingerprintManagerCompat.CryptoObject crypto, 
                int flags, 
                CancellationSignal cancel, 
                FingerprintManagerCompat.AuthenticationCallback callback, 
                Handler handler)
```

Request authentication of a crypto object. This call warms up the fingerprint hardware and starts scanning for a fingerprint. It terminates when[onAuthenticationError(int, CharSequence)](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationCallback#onAuthenticationError(int, java.lang.CharSequence))or[onAuthenticationSucceeded(AuthenticationResult)](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationCallback#onAuthenticationSucceeded(android.support.v4.hardware.fingerprint.FingerprintManagerCompat.AuthenticationResult))is called, at which point the object is no longer valid. The operation can be canceled by using the provided cancel object.

Requires the[USE_FINGERPRINT](https://developer.android.com/reference/android/Manifest.permission#USE_FINGERPRINT)permission.

|                                                      Parameters                                                       ||
|------------|-----------------------------------------------------------------------------------------------------------|
| `crypto`   | `FingerprintManagerCompat.CryptoObject`: object associated with the call or null if none required. <br /> |
| `flags`    | `int`: optional flags; should be 0 <br />                                                                 |
| `cancel`   | `CancellationSignal`: an object that can be used to cancel authentication <br />                          |
| `callback` | `FingerprintManagerCompat.AuthenticationCallback`: an object to receive authentication events <br />      |
| `handler`  | `Handler`: an optional handler for events <br />                                                          |

### from

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

```
FingerprintManagerCompat from (Context context)
```

Get a[FingerprintManagerCompat](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat)instance for a provided context.

<br />

|         Parameters          ||
|-----------|------------------|
| `context` | `Context` <br /> |

|                                                                   Returns                                                                    ||
|--------------------------------------------------------------------------------------------------------------------------------------|--------|
| [FingerprintManagerCompat](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat) | <br /> |

### hasEnrolledFingerprints

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

```
boolean hasEnrolledFingerprints ()
```

Determine if there is at least one fingerprint enrolled.

Requires the[USE_FINGERPRINT](https://developer.android.com/reference/android/Manifest.permission#USE_FINGERPRINT)permission.

|                                     Returns                                     ||
|-----------|----------------------------------------------------------------------|
| `boolean` | true if at least one fingerprint is enrolled, false otherwise <br /> |

### isHardwareDetected

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

```
boolean isHardwareDetected ()
```

Determine if fingerprint hardware is present and functional.

Requires the[USE_FINGERPRINT](https://developer.android.com/reference/android/Manifest.permission#USE_FINGERPRINT)permission.

|                                    Returns                                     ||
|-----------|---------------------------------------------------------------------|
| `boolean` | true if hardware is present and functional, false otherwise. <br /> |

-

  ## Classes

  - [FingerprintManagerCompat](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat)
  - [FingerprintManagerCompat.AuthenticationCallback](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationCallback)
  - [FingerprintManagerCompat.AuthenticationResult](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.AuthenticationResult)
  - [FingerprintManagerCompat.CryptoObject](https://developer.android.com/reference/android/support/v4/hardware/fingerprint/FingerprintManagerCompat.CryptoObject)