public class FaceDao extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
closeAll()
关闭所有实例
|
long |
deleteAll()
删除全部
|
boolean |
deleteFace(String... ids)
删除人脸
|
FaceVector |
findById(String id)
使用index查询key
|
List<FaceVector> |
findByIds(String... ids)
使用id数组查询
|
List<FaceVector> |
findFace(int pageNo,
int pageSize)
分页查询人脸
|
static FaceDao |
getInstance(String dbFilePath)
获取FaceDao实例(单例模式)
|
void |
insertOrUpdate(FaceVector faceVector)
插入或更新人脸向量
|
public static FaceDao getInstance(String dbFilePath)
dbFilePath - 数据库文件路径public void insertOrUpdate(FaceVector faceVector) throws SQLException, ClassNotFoundException
faceVector - 人脸向量SQLException - SQL异常ClassNotFoundException - 类未找到异常public FaceVector findById(String id) throws SQLException, ClassNotFoundException
id - 人脸IDSQLException - SQL异常ClassNotFoundException - 类未找到异常public long deleteAll()
throws SQLException,
ClassNotFoundException
SQLException - SQL异常ClassNotFoundException - 类未找到异常public List<FaceVector> findByIds(String... ids) throws SQLException, ClassNotFoundException
ids - ID数组SQLException - SQL异常ClassNotFoundException - 类未找到异常public boolean deleteFace(String... ids) throws SQLException, ClassNotFoundException
ids - ID数组SQLException - SQL异常ClassNotFoundException - 类未找到异常public List<FaceVector> findFace(int pageNo, int pageSize) throws SQLException, ClassNotFoundException
pageNo - 页码pageSize - 每页大小SQLException - SQL异常ClassNotFoundException - 类未找到异常public static void closeAll()
Copyright © 2025. All rights reserved.