4 package eu
.etaxonomy
.taxeditor
.ui
.section
.key
;
6 import java
.util
.Collection
;
8 import eu
.etaxonomy
.cdm
.api
.conversation
.ConversationHolder
;
9 import eu
.etaxonomy
.cdm
.model
.description
.IIdentificationKey
;
10 import eu
.etaxonomy
.cdm
.model
.location
.NamedArea
;
11 import eu
.etaxonomy
.taxeditor
.ui
.campanula
.compatibility
.ICdmFormElement
;
12 import eu
.etaxonomy
.taxeditor
.ui
.element
.CdmFormFactory
;
13 import eu
.etaxonomy
.taxeditor
.ui
.section
.AbstractEntityCollectionSection
;
19 public class GeographicalScopeDetailSection
extends
20 AbstractEntityCollectionSection
<IIdentificationKey
, NamedArea
> {
22 public GeographicalScopeDetailSection(CdmFormFactory formFactory
,
23 ConversationHolder conversation
, ICdmFormElement parentElement
, int style
) {
24 super(formFactory
, conversation
, parentElement
, "Geographical Scope", style
);
28 public Collection
<NamedArea
> getCollection(IIdentificationKey entity
) {
29 return entity
.getGeographicalScope();
33 public NamedArea
createNewElement() {
34 return NamedArea
.NewInstance();
38 public void addElement(NamedArea element
) {
39 getEntity().addGeographicalScope(element
);
43 public void removeElement(NamedArea element
) {
44 getEntity().removeGeographicalScope(element
);
48 public String
getEmptyString() {
49 return "No geographical scopes yet.";
53 protected String
getTooltipString() {
54 return "Add a geographical scope";