Class CharacteristicServiceImpl
- java.lang.Object
-
- ubic.gemma.persistence.service.AbstractService<O>
-
- 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:
CharacteristicService
-
-
Field Summary
-
Fields inherited from class ubic.gemma.persistence.service.AbstractService
log
-
-
Constructor Summary
Constructors Constructor Description CharacteristicServiceImpl(CharacteristicDao characteristicDao)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Characteristic>
browse(int start, int limit)
Browse through the characteristics, excluding GO annotations.List<Characteristic>
browse(int start, int limit, String sortField, boolean descending)
Browse through the characteristics, excluding GO annotations.Map<String,Long>
countCharacteristicsByValueUri(Collection<String> uris)
Characteristic
findBestByUri(String uri)
Find the best possible characteristic for a given URI.Collection<? extends Characteristic>
findByCategory(String query)
Collection<Characteristic>
findByUri(String searchString)
Looks for an exact match of the give string to a valueUri in the characteristic databaseCollection<Characteristic>
findByUri(Collection<String> uris)
given a collection of strings that represent URI's will find all the characteristics that are used in the system with URI's matching anyone in the given collectionCollection<Characteristic>
findByValue(String search)
Returns a collection of characteristics that have a Value that match the given search string.Map<String,Characteristic>
findCharacteristicsByValueUriOrValueLike(String search)
Map<Class<? extends Identifiable>,Map<String,Set<ExpressionExperiment>>>
findExperimentsByUris(Collection<String> uris, Taxon taxon, int limit, boolean loadEEs, boolean rankByLevel)
Map<Characteristic,Identifiable>
getParents(Collection<Characteristic> characteristics, Collection<Class<?>> parentClasses, int maxResults)
-
Methods inherited from class ubic.gemma.persistence.service.AbstractFilteringVoEnabledService
count, getFilter, getFilter, getFilter, getFilter, getFilterableProperties, getFilterablePropertyAllowedValues, getFilterablePropertyConfigAttributes, getFilterablePropertyDescription, getFilterablePropertyIsUsingSubquery, getFilterablePropertyResolvableAllowedValuesLabels, getFilterablePropertyType, getIdentifierPropertyName, getSort, load, load, loadAllValueObjects, loadIds, loadValueObject, loadValueObjectById, loadValueObjects, loadValueObjects, loadValueObjects, loadValueObjectsByIds
-
Methods inherited from class ubic.gemma.persistence.service.AbstractService
countAll, create, create, ensureInSession, ensureInSession, find, findOrCreate, findOrFail, getElementClass, load, load, loadAll, loadOrFail, loadOrFail, loadOrFail, remove, remove, remove, save, save, update, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface ubic.gemma.persistence.service.BaseImmutableService
create, findOrCreate, remove
-
Methods inherited from interface ubic.gemma.persistence.service.BaseReadOnlyService
countAll, find, findOrFail, getElementClass, load, load, loadAll, loadOrFail, loadOrFail, loadOrFail
-
Methods inherited from interface ubic.gemma.persistence.service.BaseService
save, save, update, update
-
Methods inherited from interface ubic.gemma.persistence.service.BaseVoEnabledService
loadAllValueObjects, loadValueObject, loadValueObjectById, loadValueObjects, loadValueObjectsByIds
-
Methods inherited from interface ubic.gemma.persistence.service.common.description.CharacteristicService
create, getFilter, getFilter, getFilterableProperties, getFilterablePropertyDescription, getFilterablePropertyType, getSort, remove, remove
-
-
-
-
Constructor Detail
-
CharacteristicServiceImpl
@Autowired public CharacteristicServiceImpl(CharacteristicDao characteristicDao)
-
-
Method Detail
-
browse
@Transactional(readOnly=true) public List<Characteristic> browse(int start, int limit)
Description copied from interface:CharacteristicService
Browse through the characteristics, excluding GO annotations.- Specified by:
browse
in interfaceCharacteristicService
- Parameters:
start
- How far into the list to startlimit
- Maximum records to retrieve- Returns:
- characteristics
-
browse
@Transactional(readOnly=true) public List<Characteristic> browse(int start, int limit, String sortField, boolean descending)
Description copied from interface:CharacteristicService
Browse through the characteristics, excluding GO annotations.- Specified by:
browse
in interfaceCharacteristicService
- Parameters:
start
- How far into the list to startlimit
- Maximum records to retrievesortField
- sort fielddescending
- sor order- Returns:
- characteristics
-
findExperimentsByUris
@Transactional(readOnly=true) public Map<Class<? extends Identifiable>,Map<String,Set<ExpressionExperiment>>> findExperimentsByUris(Collection<String> uris, @Nullable Taxon taxon, int limit, boolean loadEEs, boolean rankByLevel)
- Specified by:
findExperimentsByUris
in interfaceCharacteristicService
- See Also:
CharacteristicDao.findExperimentsByUris(Collection, Taxon, int, boolean)
-
findByUri
@Transactional(readOnly=true) public Collection<Characteristic> findByUri(Collection<String> uris)
Description copied from interface:CharacteristicService
given a collection of strings that represent URI's will find all the characteristics that are used in the system with URI's matching anyone in the given collection- Specified by:
findByUri
in interfaceCharacteristicService
- Parameters:
uris
- uris- Returns:
- characteristics
-
findByUri
@Transactional(readOnly=true) public Collection<Characteristic> findByUri(String searchString)
Description copied from interface:CharacteristicService
Looks for an exact match of the give string to a valueUri in the characteristic database- Specified by:
findByUri
in interfaceCharacteristicService
- Parameters:
searchString
- search string- Returns:
- characteristics
-
findBestByUri
@Nullable @Transactional(readOnly=true) public Characteristic findBestByUri(String uri)
Description copied from interface:CharacteristicService
Find the best possible characteristic for a given URI.- Specified by:
findBestByUri
in interfaceCharacteristicService
-
findByValue
@Transactional(readOnly=true) public Collection<Characteristic> findByValue(String search)
Description copied from interface:CharacteristicService
Returns a collection of characteristics that have a Value that match the given search string. The value is usually a human readable form of the termURI- Specified by:
findByValue
in interfaceCharacteristicService
- Parameters:
search
- search- Returns:
- characteristics
-
findCharacteristicsByValueUriOrValueLike
@Transactional(readOnly=true) public Map<String,Characteristic> findCharacteristicsByValueUriOrValueLike(String search)
- Specified by:
findCharacteristicsByValueUriOrValueLike
in interfaceCharacteristicService
- See Also:
CharacteristicDao.findCharacteristicsByValueUriOrValueLikeGroupedByNormalizedValue(String)
-
countCharacteristicsByValueUri
@Transactional(readOnly=true) public Map<String,Long> countCharacteristicsByValueUri(Collection<String> uris)
- Specified by:
countCharacteristicsByValueUri
in interfaceCharacteristicService
-
getParents
@Transactional(readOnly=true) public Map<Characteristic,Identifiable> getParents(Collection<Characteristic> characteristics, @Nullable Collection<Class<?>> parentClasses, int maxResults)
- Specified by:
getParents
in interfaceCharacteristicService
- Parameters:
characteristics
- characteristics- Returns:
- a map of the specified characteristics to their annotated objects.
-
findByCategory
@Transactional(readOnly=true) public Collection<? extends Characteristic> findByCategory(String query)
- Specified by:
findByCategory
in interfaceCharacteristicService
-
-