public abstract class AbstractClassificationServiceImpl extends Object implements ClassificationService
| Modifier and Type | Field and Description |
|---|---|
protected ScheduledExecutorService |
executorService |
protected Instant |
lastModified |
protected SortedMap<TermId,Term> |
terms |
| Constructor and Description |
|---|
AbstractClassificationServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanUp() |
ClassificationScheme |
getClassificationScheme() |
Instant |
getLastModified() |
protected abstract @Nullable List<InputSource> |
getSources(boolean init) |
Term |
getTerm(String termId)
Returns the Term with the given id.
|
@NonNull Term |
getTermByReference(String code,
Predicate<String> predicate) |
List<Term> |
getTermsByReference(String reference) |
protected SortedMap<TermId,Term> |
getTermsMap() |
boolean |
hasTerm(String termId) |
protected SortedMap<TermId,Term> |
readTerms(Iterable<InputSource> streams) |
String |
toString() |
protected String |
toString(Map<TermId,Term> map) |
Collection<Term> |
values() |
Collection<Term> |
valuesOf(String termId) |
protected final ScheduledExecutorService executorService
protected Instant lastModified
public Term getTerm(String termId) throws TermNotFoundException
ClassificationServicegetTerm in interface ClassificationServiceTermNotFoundException - if no such termpublic List<Term> getTermsByReference(String reference)
getTermsByReference in interface ClassificationServicepublic @NonNull Term getTermByReference(String code, Predicate<String> predicate)
public boolean hasTerm(String termId)
hasTerm in interface ClassificationServicepublic Collection<Term> values()
values in interface ClassificationServicepublic Collection<Term> valuesOf(String termId)
valuesOf in interface ClassificationServicepublic ClassificationScheme getClassificationScheme()
getClassificationScheme in interface ClassificationServicepublic Instant getLastModified()
getLastModified in interface ClassificationService@PreDestroy public void cleanUp()
protected SortedMap<TermId,Term> readTerms(Iterable<InputSource> streams) throws ParserConfigurationException
ParserConfigurationExceptionprotected abstract @Nullable List<InputSource> getSources(boolean init)
Copyright © 2022 NPO. All rights reserved.