Revision 202b97d1
Added by Andreas Kohlbecker almost 7 years ago
src/main/java/eu/etaxonomy/cdm/vaadin/view/registration/RegistrationDTO.java | ||
---|---|---|
32 | 32 |
import eu.etaxonomy.cdm.vaadin.model.EntityReference; |
33 | 33 |
import eu.etaxonomy.cdm.vaadin.model.TypedEntityReference; |
34 | 34 |
import eu.etaxonomy.cdm.vaadin.model.registration.SpecimenTypeDesignationWorkingSetDTO; |
35 |
import eu.etaxonomy.cdm.vaadin.util.converter.TypeDesignationConverter;
|
|
36 |
import eu.etaxonomy.cdm.vaadin.util.converter.TypeDesignationConverter.TypeDesignationWorkingSet;
|
|
35 |
import eu.etaxonomy.cdm.vaadin.util.converter.TypeDesignationSetManager;
|
|
36 |
import eu.etaxonomy.cdm.vaadin.util.converter.TypeDesignationSetManager.TypeDesignationWorkingSet;
|
|
37 | 37 |
|
38 | 38 |
public class RegistrationDTO{ |
39 | 39 |
|
... | ... | |
51 | 51 |
|
52 | 52 |
private EntityReference name = null; |
53 | 53 |
|
54 |
private TypeDesignationConverter typeDesignationConverter;
|
|
54 |
private TypeDesignationSetManager typeDesignationManager;
|
|
55 | 55 |
|
56 | 56 |
private Registration reg; |
57 | 57 |
|
... | ... | |
101 | 101 |
case TYPIFICATION: |
102 | 102 |
default: |
103 | 103 |
try { |
104 |
typeDesignationConverter = new TypeDesignationConverter(reg, reg.getTypeDesignations());
|
|
105 |
summary = typeDesignationConverter.buildString().print();
|
|
104 |
typeDesignationManager = new TypeDesignationSetManager(reg, reg.getTypeDesignations());
|
|
105 |
summary = typeDesignationManager.buildString().print();
|
|
106 | 106 |
} catch (RegistrationValidationException e) { |
107 | 107 |
messages.add("Validation errors: " + e.getMessage()); |
108 | 108 |
} |
... | ... | |
229 | 229 |
} |
230 | 230 |
|
231 | 231 |
public EntityReference getTypifiedName() { |
232 |
return typeDesignationConverter != null ? typeDesignationConverter.getTypifiedName() : null;
|
|
232 |
return typeDesignationManager != null ? typeDesignationManager.getTypifiedName() : null;
|
|
233 | 233 |
} |
234 | 234 |
|
235 | 235 |
public EntityReference getName() { |
... | ... | |
237 | 237 |
} |
238 | 238 |
|
239 | 239 |
public LinkedHashMap<TypedEntityReference, TypeDesignationWorkingSet> getOrderdTypeDesignationWorkingSets() { |
240 |
return typeDesignationConverter != null ? typeDesignationConverter.getOrderdTypeDesignationWorkingSets() : null;
|
|
240 |
return typeDesignationManager != null ? typeDesignationManager.getOrderdTypeDesignationWorkingSets() : null;
|
|
241 | 241 |
} |
242 | 242 |
|
243 | 243 |
/** |
244 | 244 |
* @param baseEntityReference |
245 | 245 |
*/ |
246 | 246 |
public TypeDesignationWorkingSet getTypeDesignationWorkingSet(TypedEntityReference baseEntityReference) { |
247 |
return typeDesignationConverter != null ? typeDesignationConverter.getOrderdTypeDesignationWorkingSets().get(baseEntityReference) : null;
|
|
247 |
return typeDesignationManager != null ? typeDesignationManager.getOrderdTypeDesignationWorkingSets().get(baseEntityReference) : null;
|
|
248 | 248 |
|
249 | 249 |
} |
250 | 250 |
|
... | ... | |
288 | 288 |
* @return |
289 | 289 |
*/ |
290 | 290 |
private TypeDesignationBase findTypeDesignation(EntityReference ref) { |
291 |
return typeDesignationConverter != null ? typeDesignationConverter.findTypeDesignation(ref) : null;
|
|
291 |
return typeDesignationManager != null ? typeDesignationManager.findTypeDesignation(ref) : null;
|
|
292 | 292 |
} |
293 | 293 |
|
294 | 294 |
public Collection<TypeDesignationBase> getTypeDesignations() { |
295 |
return typeDesignationConverter != null ? typeDesignationConverter.getTypeDesignations() : null;
|
|
295 |
return typeDesignationManager != null ? typeDesignationManager.getTypeDesignations() : null;
|
|
296 | 296 |
} |
297 | 297 |
|
298 | 298 |
/** |
Also available in: Unified diff
ref #6719 renaming the TypeDesignationConverter to TypeDesignationSetManager