Class DirectoryFaceStorageBackend


  • public class DirectoryFaceStorageBackend
    extends FaceStorageBackend
    FaceStorageBackend to store data in a directory. Directory must not contain files other than these created by this class!
    • Constructor Detail

      • DirectoryFaceStorageBackend

        public DirectoryFaceStorageBackend​(File dir)
    • Method Detail

      • registerInternal

        protected boolean registerInternal​(String name,
                                           String data,
                                           boolean duplicate)
        Description copied from class: FaceStorageBackend
        Register/store new face.
        Specified by:
        registerInternal in class FaceStorageBackend
        Parameters:
        name - Name of the face, needs to be unique.
        data - Face detection model data to store.
        duplicate - Only true if we are adding a duplicate and want to replace the saved one.
        Returns:
        If registering was successful.
      • deleteInternal

        protected boolean deleteInternal​(String name)
        Description copied from class: FaceStorageBackend
        Delete all references to a face.
        Specified by:
        deleteInternal in class FaceStorageBackend
        Parameters:
        name - The face to delete.
        Returns:
        If deletion was successful.