public class TermStore
extends java.lang.Object
Constructor and Description |
---|
TermStore() |
Modifier and Type | Method and Description |
---|---|
static void |
delete(eu.etaxonomy.cdm.model.common.DefinedTermBase selected)
delete
|
static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> |
getTerms(java.lang.Class<TERM> clazz)
Returns an alphabetically sorted list of terms (anything that extends
DefinedTermBase ) of the given type currently available in the system. |
static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> |
getTerms(java.lang.Class<TERM> clazz,
java.util.Comparator<TERM> comparator,
boolean filtered)
Returns a list of terms of the given type currently available in the system.
|
static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> |
getTerms(eu.etaxonomy.cdm.model.common.TermType termType,
java.util.Comparator<TERM> comparator)
Returns an alphabetically sorted list of terms (anything that extends
DefinedTermBase ) of the given TermType )
currently available in the system. |
static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> |
getTerms(eu.etaxonomy.cdm.model.common.TermVocabulary<TERM> termVocabulary,
java.util.Comparator<eu.etaxonomy.cdm.model.common.DefinedTermBase<?>> comparator)
Returns an alphabetically sorted list of terms (anything that extends
DefinedTermBase ) of the given TermType )
currently available in the system. |
static void |
saveTerm(eu.etaxonomy.cdm.model.common.DefinedTermBase term) |
static void |
updateVocabulary(eu.etaxonomy.cdm.model.common.DefinedTermBase term)
Save a vacabulary to data store
|
public static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> java.util.List<TERM> getTerms(java.lang.Class<TERM> clazz)
DefinedTermBase
) of the given type currently available in the system.clazz
- a class that inherits from DefinedTermBase
public static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> java.util.List<TERM> getTerms(eu.etaxonomy.cdm.model.common.TermType termType, java.util.Comparator<TERM> comparator)
DefinedTermBase
) of the given TermType
)
currently available in the system.termType
- the term typepublic static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> java.util.Set<TERM> getTerms(eu.etaxonomy.cdm.model.common.TermVocabulary<TERM> termVocabulary, java.util.Comparator<eu.etaxonomy.cdm.model.common.DefinedTermBase<?>> comparator)
DefinedTermBase
) of the given TermType
)
currently available in the system.termType
- the term typepublic static <TERM extends eu.etaxonomy.cdm.model.common.DefinedTermBase> java.util.List<TERM> getTerms(java.lang.Class<TERM> clazz, java.util.Comparator<TERM> comparator, boolean filtered)
filtered
is set to true
, all terms for certain types will be
gathered from edge cases.clazz
- a class that inherits from DefinedTermBase
comparator
- a Comparator
that defines the sorting algorithm. If set to null, DefaultTermComparator
will be usedfiltered
- if set to true, some terms are filtered from the result (according to definition in ITermStoreEdgeCase
s)public static void saveTerm(eu.etaxonomy.cdm.model.common.DefinedTermBase term)
term
- a DefinedTermBase
object.public static void delete(eu.etaxonomy.cdm.model.common.DefinedTermBase selected) throws eu.etaxonomy.cdm.api.service.exception.ReferencedObjectUndeletableException
delete
selected
- a DefinedTermBase
object.eu.etaxonomy.cdm.api.service.exception.ReferencedObjectUndeletableException
public static void updateVocabulary(eu.etaxonomy.cdm.model.common.DefinedTermBase term)
term
- a DefinedTermBase
object.Copyright © 2007-2018. All Rights Reserved.