1
|
package eu.etaxonomy.cdm.api.service;
|
2
|
|
3
|
import java.util.Collection;
|
4
|
import java.util.List;
|
5
|
import java.util.Map;
|
6
|
import java.util.Set;
|
7
|
import java.util.UUID;
|
8
|
|
9
|
import eu.etaxonomy.cdm.api.service.dto.RowWrapperDTO;
|
10
|
import eu.etaxonomy.cdm.common.monitor.IProgressMonitor;
|
11
|
import eu.etaxonomy.cdm.model.description.DescriptionBase;
|
12
|
import eu.etaxonomy.cdm.model.description.DescriptionElementBase;
|
13
|
import eu.etaxonomy.cdm.model.description.DescriptiveSystemRole;
|
14
|
import eu.etaxonomy.cdm.model.description.Feature;
|
15
|
import eu.etaxonomy.cdm.model.description.WorkingSet;
|
16
|
import eu.etaxonomy.cdm.persistence.dto.UuidAndTitleCache;
|
17
|
|
18
|
|
19
|
public interface IWorkingSetService extends IAnnotatableService<WorkingSet> {
|
20
|
/**
|
21
|
* Returns a Map of descriptions each with the descriptionelements that match the supplied features (or all description elements if no features are supplied)
|
22
|
*
|
23
|
* @param workingSet the working set which the descriptions belong to
|
24
|
* @param features restrict the returned description elements to those which have features in this set
|
25
|
* @param pageSize The maximum number of descriptions returned (can be null for all descriptions that belong to the working set)
|
26
|
* @param pageNumber The offset (in pageSize chunks) from the start of the result set (0 - based,
|
27
|
* can be null, equivalent of starting at the beginning of the recordset). Descriptions are sorted by titleCache
|
28
|
* @param propertyPaths properties to be initialized (applied to the descriptionElements)
|
29
|
* @return
|
30
|
*/
|
31
|
public Map<DescriptionBase, Set<DescriptionElementBase>> getDescriptionElements(WorkingSet workingSet, Set<Feature> features, Integer pageSize, Integer pageNumber, List<String> propertyPaths);
|
32
|
|
33
|
public <T extends DescriptionElementBase> Map<UuidAndTitleCache, Map<UUID, Set<T>>> getTaxonFeatureDescriptionElementMap(Class<T> clazz, UUID workingSetUuid, DescriptiveSystemRole role);
|
34
|
|
35
|
/**
|
36
|
* @param limitOfInitialElements
|
37
|
* @param pattern
|
38
|
* @return
|
39
|
*/
|
40
|
public List<UuidAndTitleCache<WorkingSet>> getWorkingSetUuidAndTitleCache(Integer limitOfInitialElements, String pattern);
|
41
|
|
42
|
/**
|
43
|
* Returns a collection of {@link RowWrapperDTO} objects for the given {@link WorkingSet}.<br>
|
44
|
* A RowWrapper represents on row in the character matrix.
|
45
|
* @param workingSet the working set for which the row wrapper objects should be fetched
|
46
|
* @param the progress monitor
|
47
|
* @return a list of row wrapper objects
|
48
|
*/
|
49
|
public Collection<RowWrapperDTO> getRowWrapper(WorkingSet workingSet, IProgressMonitor monitor);
|
50
|
|
51
|
/**
|
52
|
* Monitored invocation of {@link IWorkingSetService#getRowWrapper(WorkingSet, IProgressMonitor)}
|
53
|
* @param workingSet the working set for which getRowWrapper() is invoked
|
54
|
* @return the uuid of the monitor
|
55
|
*/
|
56
|
public UUID monitGetRowWrapper(WorkingSet workingSet);
|
57
|
|
58
|
/**
|
59
|
* Loads all avaliable specimens wrapped in a {@link RowWrapperDTO} object for
|
60
|
* a given {@link WorkingSet} according to the filters set in the working set
|
61
|
* @param workingSet the working set for which the specimens should be fetched
|
62
|
* @return a collection of wrapper objects containing the specimen
|
63
|
*/
|
64
|
public Collection<RowWrapperDTO> loadSpecimens(WorkingSet workingSet);
|
65
|
|
66
|
|
67
|
}
|