Class CharacteristicServiceImpl
java.lang.Object
ubic.gemma.persistence.service.AbstractService<Characteristic>
ubic.gemma.persistence.service.AbstractFilteringVoEnabledService<Characteristic, CharacteristicValueObject>
ubic.gemma.persistence.service.common.description.CharacteristicServiceImpl
- All Implemented Interfaces:
BaseImmutableService<Characteristic>, BaseReadOnlyService<Characteristic>, BaseService<Characteristic>, BaseVoEnabledService<Characteristic, CharacteristicValueObject>, CharacteristicService, FilteringService<Characteristic>, FilteringVoEnabledService<Characteristic, CharacteristicValueObject>
@Service
public class CharacteristicServiceImpl
extends AbstractFilteringVoEnabledService<Characteristic, CharacteristicValueObject>
implements CharacteristicService
- Author:
- Luke
- See Also:
-
Field Summary
Fields inherited from class AbstractService
log -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbrowse(int start, int limit) Browse through the characteristics, excluding GO annotations.Browse through the characteristics, excluding GO annotations.countByValueUri(Collection<String> uris, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents) countExperimentsByUris(Collection<String> uris, boolean includeSubjects, boolean includePredicates, boolean includeObjects, Taxon taxon, Collection<Long> excludedExperimentIds) findBestByUri(String uri) Find the best possible characteristic for a given URI.Collection<? extends Characteristic> findByAnyUri(String uri) Find a characteristic or statement by any URI it contains including its category, value, predicates and objects.Collection<? extends Characteristic> findByAnyValue(String value) Find a characteristic by any value it contains including its category, value, predicates and objects.Collection<? extends Characteristic> findByAnyValueStartingWith(String value) Find a characteristic by any value it contains including its category, value, predicates and objects that starts with the given query.findByCategoryStartingWith(String query, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) findByCategoryUri(String query, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) findByObject(String value) findByObjectUri(String uri) findByParentClasses(Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, String category, int maxResults) Find characteristics that have a particular parent class or lack thereof.findByPredicate(String value) findByPredicateUri(String uri) findByUri(String uri, String category, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Looks for an exact match of the give string to a valueUri in the characteristic databasefindByValueLike(String search, String category, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Returns a collection of characteristics that have a value matching the given SQLLIKEpattern.findByValueStartingWith(String search, String category, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Returns a collection of characteristics that have a value starting with the given string.findByValueUriOrValueStartingWith(String search, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents) Find characteristics that have a value (prefix) or value URI (exact match) matching the given string.findEeCountsByUriForOriginalValue(Collection<String> uris, String originalValue) findEeCountsByUriForOriginalValue(Collection<String> uris, String originalValue, Collection<Long> excludedExperimentIds) Map<Class<? extends Identifiable>, Map<String, Set<ExpressionExperiment>>> findExperimentsByUris(Collection<String> uris, boolean includeSubjects, boolean includePredicates, boolean includeObjects, Taxon taxon, int limit, boolean loadEEs, boolean rankByLevel) findPriorCurationByOriginalValue(String originalValue, int maxResults, Collection<Long> excludedExperimentIds) findRepresentativeUsageByValueUris(Collection<String> valueUris) For each value URI, return one representative ACL-visible usage (or omit it when none is accessible), so a search hit can be shown in the context it has actually been applied.findValueGroupedByValueUri(Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, boolean includePredicates, boolean includeObjects, int maxResults) getParents(Collection<Characteristic> characteristics, Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, boolean thawParents) Methods inherited from class AbstractFilteringVoEnabledService
count, getFilter, getFilter, getFilter, getFilter, getFilter, getFilter, getFilter, getFilterableProperties, getFilterablePropertyAllowedValues, getFilterablePropertyConfigAttributes, getFilterablePropertyDescription, getFilterablePropertyResolvableAllowedValuesLabels, getFilterablePropertyType, getSort, isFilterablePropertyDeprecated, isFilterablePropertyUsingSubquery, load, load, loadAllValueObjects, loadIds, loadValueObject, loadValueObjectById, loadValueObjects, loadValueObjects, loadValueObjects, loadValueObjectsByCursor, loadValueObjectsByIdsMethods inherited from class AbstractService
countAll, create, create, ensureInSession, ensureInSession, find, findOrCreate, findOrFail, getElementClass, load, load, loadAll, loadOrFail, loadOrFail, loadOrFail, loadOrFail, loadOrFail, loadOrFail, remove, remove, save, save, streamAll, streamAll, update, updateMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BaseImmutableService
findOrCreateMethods inherited from interface BaseReadOnlyService
countAll, find, findOrFail, getElementClass, load, load, loadAll, loadOrFail, loadOrFail, loadOrFail, loadOrFail, loadOrFail, loadOrFail, streamAll, streamAllMethods inherited from interface BaseVoEnabledService
loadAllValueObjects, loadValueObject, loadValueObjectById, loadValueObjects, loadValueObjectsByIdsMethods inherited from interface CharacteristicService
create, create, remove, remove, save, save, update, updateMethods inherited from interface FilteringService
count, getFilter, getFilter, getFilter, getFilter, getFilter, getFilter, getFilter, getFilterableProperties, getFilterablePropertyAllowedValues, getFilterablePropertyConfigAttributes, getFilterablePropertyDescription, getFilterablePropertyResolvableAllowedValuesLabels, getFilterablePropertyType, getSort, isFilterablePropertyDeprecated, isFilterablePropertyUsingSubquery, load, load, loadIdsMethods inherited from interface FilteringVoEnabledService
loadValueObjects, loadValueObjects, loadValueObjectsByCursor
-
Constructor Details
-
CharacteristicServiceImpl
-
-
Method Details
-
browse
Description copied from interface:CharacteristicServiceBrowse through the characteristics, excluding GO annotations.- Specified by:
browsein interfaceCharacteristicService- Parameters:
start- How far into the list to startlimit- Maximum records to retrieve- Returns:
- characteristics
-
browse
Description copied from interface:CharacteristicServiceBrowse through the characteristics, excluding GO annotations.- Specified by:
browsein interfaceCharacteristicService- Parameters:
start- How far into the list to startlimit- Maximum records to retrievesortField- sort fielddescending- sor order- Returns:
- characteristics
-
findExperimentsByUris
public Map<Class<? extends Identifiable>, Map<String, Set<ExpressionExperiment>>> findExperimentsByUris(Collection<String> uris, boolean includeSubjects, boolean includePredicates, boolean includeObjects, @Nullable Taxon taxon, int limit, boolean loadEEs, boolean rankByLevel) - Specified by:
findExperimentsByUrisin interfaceCharacteristicService- See Also:
-
countExperimentsByUris
public Map<String,Long> countExperimentsByUris(Collection<String> uris, boolean includeSubjects, boolean includePredicates, boolean includeObjects, @Nullable Taxon taxon, Collection<Long> excludedExperimentIds) - Specified by:
countExperimentsByUrisin interfaceCharacteristicService- See Also:
-
findByParentClasses
public Collection<Characteristic> findByParentClasses(@Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, @Nullable String category, int maxResults) Description copied from interface:CharacteristicServiceFind characteristics that have a particular parent class or lack thereof.- Specified by:
findByParentClassesin interfaceCharacteristicService
-
findByUri
public Collection<Characteristic> findByUri(String uri, @Nullable String category, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Description copied from interface:CharacteristicServiceLooks for an exact match of the give string to a valueUri in the characteristic database- Specified by:
findByUriin interfaceCharacteristicService
-
findBestByUri
Description copied from interface:CharacteristicServiceFind the best possible characteristic for a given URI.- Specified by:
findBestByUriin interfaceCharacteristicService
-
findRepresentativeUsageByValueUris
public Map<String, CharacteristicDao.UsageExample> findRepresentativeUsageByValueUris(Collection<String> valueUris) Description copied from interface:CharacteristicServiceFor each value URI, return one representative ACL-visible usage (or omit it when none is accessible), so a search hit can be shown in the context it has actually been applied.- Specified by:
findRepresentativeUsageByValueUrisin interfaceCharacteristicService- See Also:
-
findByValueStartingWith
public Collection<Characteristic> findByValueStartingWith(String search, @Nullable String category, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Description copied from interface:CharacteristicServiceReturns a collection of characteristics that have a value starting with the given string.The value is usually a human-readable form of the termURI. SQL
LIKEpatterns are escaped. UseCharacteristicService.findByValueLike(String, String, Collection, boolean, int)to do wildcard searches instead.- Specified by:
findByValueStartingWithin interfaceCharacteristicService
-
findByValueLike
public Collection<Characteristic> findByValueLike(String search, @Nullable String category, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) Description copied from interface:CharacteristicServiceReturns a collection of characteristics that have a value matching the given SQLLIKEpattern.- Specified by:
findByValueLikein interfaceCharacteristicService
-
findByValueUriOrValueStartingWith
public Map<String, Characteristic> findByValueUriOrValueStartingWith(String search, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents) Description copied from interface:CharacteristicServiceFind characteristics that have a value (prefix) or value URI (exact match) matching the given string.- Specified by:
findByValueUriOrValueStartingWithin interfaceCharacteristicService- Parameters:
parentClasses- if not null, restrict to characteristics that have parents of the given classes.includeNoParents- if true, include characteristics that have no parents.- See Also:
-
countByValueUri
public Map<String,Long> countByValueUri(Collection<String> uris, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents) - Specified by:
countByValueUriin interfaceCharacteristicService
-
findEeCountsByUriGroupedByCategory
- Specified by:
findEeCountsByUriGroupedByCategoryin interfaceCharacteristicService- See Also:
-
findEeCountsByUriForOriginalValue
public Map<String,Long> findEeCountsByUriForOriginalValue(Collection<String> uris, String originalValue) - Specified by:
findEeCountsByUriForOriginalValuein interfaceCharacteristicService- See Also:
-
findEeCountsByUriForOriginalValue
public Map<String,Long> findEeCountsByUriForOriginalValue(Collection<String> uris, String originalValue, Collection<Long> excludedExperimentIds) - Specified by:
findEeCountsByUriForOriginalValuein interfaceCharacteristicService- See Also:
-
findPriorCurationByOriginalValue
public List<CharacteristicDao.PriorCurationUsage> findPriorCurationByOriginalValue(String originalValue, int maxResults, Collection<Long> excludedExperimentIds) - Specified by:
findPriorCurationByOriginalValuein interfaceCharacteristicService- See Also:
-
findValueGroupedByValueUri
public Map<String,String> findValueGroupedByValueUri(@Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, boolean includePredicates, boolean includeObjects, int maxResults) - Specified by:
findValueGroupedByValueUriin interfaceCharacteristicService- See Also:
-
getParents
public Map<Characteristic, Identifiable> getParents(Collection<Characteristic> characteristics, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, boolean thawParents) - Specified by:
getParentsin interfaceCharacteristicService- Parameters:
thawParents- if true, the parents will be initialized if they are proxies- See Also:
-
findByCategoryStartingWith
public Collection<Characteristic> findByCategoryStartingWith(String query, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) - Specified by:
findByCategoryStartingWithin interfaceCharacteristicService
-
findByCategoryUri
public Collection<Characteristic> findByCategoryUri(String query, @Nullable Collection<Class<? extends Identifiable>> parentClasses, boolean includeNoParents, int maxResults) - Specified by:
findByCategoryUriin interfaceCharacteristicService
-
findByAnyValue
Description copied from interface:CharacteristicServiceFind a characteristic by any value it contains including its category, value, predicates and objects.- Specified by:
findByAnyValuein interfaceCharacteristicService
-
findByAnyValueStartingWith
Description copied from interface:CharacteristicServiceFind a characteristic by any value it contains including its category, value, predicates and objects that starts with the given query.- Specified by:
findByAnyValueStartingWithin interfaceCharacteristicService
-
findByAnyUri
Description copied from interface:CharacteristicServiceFind a characteristic or statement by any URI it contains including its category, value, predicates and objects.- Specified by:
findByAnyUriin interfaceCharacteristicService
-
findByPredicate
- Specified by:
findByPredicatein interfaceCharacteristicService
-
findByPredicateUri
- Specified by:
findByPredicateUriin interfaceCharacteristicService
-
findByObject
- Specified by:
findByObjectin interfaceCharacteristicService
-
findByObjectUri
- Specified by:
findByObjectUriin interfaceCharacteristicService
-