All Downloads are FREE. Search and download functionalities are using the official Maven repository.

angry1980.audio.dao.FingerprintDAO Maven / Gradle / Ivy

There is a newer version: 0.0.10
Show newest version
package angry1980.audio.dao;

import angry1980.audio.model.Fingerprint;

import java.util.Collection;
import java.util.Optional;

public interface FingerprintDAO {

    Collection getAll();

    Collection findByTrackIds(long[] trackIds);

    default Optional findByTrackId(long trackId){
        return Optional.ofNullable(tryToFindByTrackId(trackId));
    }

    F tryToFindByTrackId(long trackId);

    default Optional create(F fingerprint){
        return Optional.of(tryToCreate(fingerprint));
    }

    F tryToCreate(F fingerprint);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy