Project

General

Profile

Download (3.93 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2017 EDIT
3
* European Distributed Institute of Taxonomy
4
* http://www.e-taxonomy.eu
5
*
6
* The contents of this file are subject to the Mozilla Public License Version 1.1
7
* See LICENSE.TXT at the top of this package for the full license terms.
8
*/
9
package eu.etaxonomy.cdm.api.service.registration;
10

    
11
import java.io.IOException;
12
import java.util.Collection;
13
import java.util.List;
14
import java.util.Set;
15
import java.util.UUID;
16

    
17
import eu.etaxonomy.cdm.api.service.dto.RegistrationDTO;
18
import eu.etaxonomy.cdm.api.service.dto.RegistrationWorkingSet;
19
import eu.etaxonomy.cdm.api.service.exception.RegistrationValidationException;
20
import eu.etaxonomy.cdm.api.service.pager.Pager;
21
import eu.etaxonomy.cdm.database.PermissionDeniedException;
22
import eu.etaxonomy.cdm.model.common.User;
23
import eu.etaxonomy.cdm.model.name.Registration;
24
import eu.etaxonomy.cdm.model.name.RegistrationStatus;
25
import eu.etaxonomy.cdm.model.name.TypeDesignationStatusBase;
26
import eu.etaxonomy.cdm.persistence.query.MatchMode;
27
import eu.etaxonomy.cdm.persistence.query.OrderHint;
28

    
29
/**
30
 * @author a.kohlbecker
31
 * @since May 4, 2017
32
 *
33
 */
34
public interface IRegistrationWorkingSetService {
35

    
36
    /**
37
     * @param id the CDM Entity id
38
     * @return
39
     */
40
    public RegistrationDTO loadDtoById(Integer id);
41

    
42
    public RegistrationDTO loadDtoByUuid(UUID uuid);
43

    
44
    public Pager<RegistrationDTO> pageDTOs(Integer pageSize, Integer pageIndex);
45

    
46
    public Pager<RegistrationDTO> pageDTOs(User submitter, Collection<RegistrationStatus> includedStatus,
47
            String identifierFilterPattern, String taxonNameFilterPattern, Set<TypeDesignationStatusBase> typeStatusFilter,
48
            Integer pageSize, Integer pageIndex, List<OrderHint> orderHints);
49

    
50
    public Pager<RegistrationDTO> pageDTOs(String identifier, Integer pageIndex,  Integer pageSize) throws IOException;
51

    
52
    /**
53
     * @param referenceID
54
     * @param resolveSections resolve the higher publication unit and build the RegistrationWorkingSet for that reference. E.e. For journal sections the
55
     *  use the inReference which is the journal article.
56
     *
57
     * @return
58
     */
59
    @Deprecated
60
    public RegistrationWorkingSet loadWorkingSetByReferenceID(Integer referenceID, boolean resolveSections) throws RegistrationValidationException;
61

    
62
    /**
63
     * Loads the working set specified by the <code>referenceUuid</code> from the database. The list of {@link RegistrationDTO}s can be empty in case
64
     * there is no registration which is related to the reference.
65
     *
66
     * @param referenceUuid
67
     * @param resolveSections resolve the higher publication unit and build the RegistrationWorkingSet for that reference. E.e. For journal sections the
68
     *  use the inReference which is the journal article.
69
     * @return
70
     */
71
    public RegistrationWorkingSet loadWorkingSetByReferenceUuid(UUID referenceUuid, boolean resolveSections) throws RegistrationValidationException, PermissionDeniedException;
72

    
73
    public Set<RegistrationDTO> loadBlockingRegistrations(UUID blockedRegistrationUuid);
74

    
75
    public Pager<RegistrationDTO> convertToDTOPager(Pager<Registration> regPager);
76

    
77
    public List<RegistrationDTO> makeDTOs(Collection<Registration> regs);
78

    
79
    Pager<RegistrationDTO> pageDTOs(UUID submitterUuid, Collection<RegistrationStatus> includedStatus, String identifierFilterPattern, String taxonNameFilterPattern, Collection<UUID> typeDesignationStatusUuids, Integer pageSize, Integer pageIndex,
80
            List<OrderHint> orderHints);
81

    
82
    /**
83
     * @param submitterUuid
84
     * @param includedStatus
85
     * @param taxonNameFilterPattern
86
     * @param matchMode
87
     * @param pageSize
88
     * @param pageIndex
89
     * @param orderHints
90
     * @param propertyPaths
91
     * @return
92
     */
93
    public Pager<RegistrationDTO> findInTaxonGraph(UUID submitterUuid, Collection<RegistrationStatus> includedStatus,
94
            String taxonNameFilterPattern, MatchMode matchMode, Integer pageSize, Integer pageIndex,
95
            List<OrderHint> orderHints);
96

    
97

    
98

    
99
}
(1-1/2)