Project

General

Profile

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

    
11
import eu.etaxonomy.cdm.model.common.VersionableEntity;
12
import eu.etaxonomy.cdm.model.name.Registration;
13
import eu.etaxonomy.cdm.vaadin.model.registration.SpecimenTypeDesignationWorkingSetDTO;
14

    
15
/**
16
 * @author a.kohlbecker
17
 * @since May 4, 2017
18
 *
19
 */
20
public interface ISpecimenTypeDesignationWorkingSetService {
21

    
22
    public SpecimenTypeDesignationWorkingSetDTO<Registration> create(int registrationId, int publicationId, int typifiedNameId);
23

    
24
    /**
25
     * @param id the CDM Entity id
26
     * @return
27
     */
28
    public SpecimenTypeDesignationWorkingSetDTO<Registration> loadDtoByIds(int registrationId, int workingsetId);
29

    
30
    SpecimenTypeDesignationWorkingSetDTO<Registration> fixMissingFieldUnit(SpecimenTypeDesignationWorkingSetDTO<Registration> bean);
31

    
32

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

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

    
52
}
(5-5/7)