Copyright (C) 2024 The Open Library Foundation
This software is distributed under the terms of the Apache License, Version 2.0. See the file "LICENSE" for more information.
Fingerprint hash is the unique identifier for a resource in Linked Data Graph. This library provides a function for a fingerprint hash generation.
mvn clean install
The library can be used as a source of Linked Data resource hash:
import org.folio.ld.dictionary.model.Resource;
import org.folio.ld.fingerprint.service.FingerprintHashService;
import org.springframework.stereotype.Service;
@Service
public class YourService {
private final FingerprintHashService fingerprintHashService;
public YourService(FingerprintHashService fingerprintHashService) {
this.fingerprintHashService = fingerprintHashService;
}
public void yourMethod(Resource resource) {
Long hash = fingerprintHashService.hash(resource);
// ...
// ...
}
}
The built artifacts for this module are available. See configuration for repository access.