Merge branch 'release/5.0.0'
[cdmlib.git] / cdmlib-services / src / main / java / eu / etaxonomy / cdm / api / service / dto / EntityDTO.java
1 /**
2 * Copyright (C) 2014 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.dto;
10
11 import java.util.UUID;
12
13 import eu.etaxonomy.cdm.model.common.IdentifiableEntity;
14
15 /**
16 * DTO for any CdmBase.
17 *
18 * @author a.mueller
19 * @since 2016-09-21
20 *
21 */
22 //might extend CdmBase in future, when a default formatter is available for all CdmBase classes
23 public class EntityDTO<T extends IdentifiableEntity> extends EntityDTOBase<T> {
24
25 public EntityDTO(T entity){
26 super(entity);
27 }
28
29 public EntityDTO(UUID entityUuid, String titleCache){
30 super(entityUuid, titleCache);
31 }
32
33 /**
34 * {@inheritDoc}
35 */
36 @Override
37 public String toString() {
38 return "(" + cdmEntity.getTitleCache() + "; " + cdmEntity.getUuid() + ")";
39 }
40
41
42 }