Project

General

Profile

Download (2.14 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.service;
10

    
11
import java.util.UUID;
12

    
13
import eu.etaxonomy.cdm.api.service.dto.TypedEntityReference;
14
import eu.etaxonomy.cdm.model.common.IdentifiableEntity;
15
import eu.etaxonomy.cdm.model.common.VersionableEntity;
16
import eu.etaxonomy.cdm.model.name.Registration;
17
import eu.etaxonomy.cdm.vaadin.model.registration.SpecimenTypeDesignationWorkingSetDTO;
18

    
19
/**
20
 * @author a.kohlbecker
21
 * @since May 4, 2017
22
 *
23
 */
24
public interface ISpecimenTypeDesignationWorkingSetService {
25

    
26
    public SpecimenTypeDesignationWorkingSetDTO<Registration> create(UUID registrationUuid, UUID publicationUuid, UUID typifiedNameUuid);
27

    
28
    /**
29
     * @param id the CDM Entity id
30
     * @return
31
     */
32
    public SpecimenTypeDesignationWorkingSetDTO<Registration> load(UUID registrationUuid,
33
            TypedEntityReference<? extends IdentifiableEntity<?>> baseEntityRef);
34

    
35
    SpecimenTypeDesignationWorkingSetDTO<Registration> fixMissingFieldUnit(SpecimenTypeDesignationWorkingSetDTO<Registration> bean);
36

    
37

    
38
    /**
39
     * Saves the SpecimenTypeDesignationWorkingSetDTO and takes care for consistency in the working set:
40
     * <ul>
41
     *  <li>New TypeDesignations are associated with the OWNER.</li>
42
     *  <li>The citation and typified name of newly created TypeDesignations are set.</li>
43
     *  <li>All type specimens are assured to be derivatives of the FieldUnit which is the base entity of the set.</li>
44
     * </ul>
45
     *
46
     * @param dto the DTO to be persisted
47
     */
48
    void save(SpecimenTypeDesignationWorkingSetDTO<? extends VersionableEntity> dto);
49

    
50
    /**
51
     * @param bean The SpecimenTypeDesignationWorkingSetDTO  to be deleted
52
     * @param deleteFieldUnit The fieldunit and all derivatives which is the base entity of the workingset will
53
     * also be deleted once this is set to <code>true</code>.
54
     */
55
    public void delete(SpecimenTypeDesignationWorkingSetDTO bean, boolean deleteFieldUnit);
56

    
57
}
(6-6/8)