Is there a way we can find the number of available fingerprints in device

跟風遠走 提交于 2019-12-23 05:29:21

问题


Is it possible to retrieve the number of available fingerprints in an Android device.

I want to do some functionality when number of fingerprints changes in the device.

For that I have to retrieve the number of fingerprints in the device first.

Can anyone suggest how to do that.


回答1:


On devices with a fingerprint sensor, users can enroll one or more fingerprints and use those fingerprints to unlock the device and perform other tasks. Android uses the Fingerprint Hardware Abstraction Layer (HAL) to connect to a vendor-specific library and fingerprint hardware, e.g. a fingerprint sensor. There is a method enumerate(Synchronous call for enumerating all known fingerprint templates) There is also Android's FingerprintManager. But it has a method hasEnrolledFingerprints which returns true if there is more than one fingerprint enrolled.So you won't know how many or if there was any added.

Useful links to the docs HAL

FingerprintManager



来源:https://stackoverflow.com/questions/47193924/is-there-a-way-we-can-find-the-number-of-available-fingerprints-in-device

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!