Merge branch 'develop' into remoting-4.0
[taxeditor.git] / eu.etaxonomy.taxeditor.bulkeditor / src / main / java / eu / etaxonomy / taxeditor / bulkeditor / input / AgentEditorInput.java
index 83795a4aa5485383159f8584b6bb5f5af63f4ba6..1ed2910f4c7e595805a3127b7b2e39357a406f96 100644 (file)
@@ -32,64 +32,34 @@ import eu.etaxonomy.taxeditor.store.CdmStore;
 
 
 /**
- * <p>AgentEditorInput class.</p>
- *
  * @author p.ciardelli
  * @created 25.06.2009
  * @version 1.0
  */
 public class AgentEditorInput extends AbstractBulkEditorInput<TeamOrPersonBase> {
 
-       /**
-        *
-        */
        private static final long serialVersionUID = 3387950621617078479L;
 
-       /** Constant <code>ID="bulkeditor.input.author"</code> */
        public static final String ID = "bulkeditor.input.author";
 
        private static AgentEditorInput instance;
 
-       /**
-        * <p>getID</p>
-        *
-        * @return the iD
-        */
        public static String getID() {
                return ID;
        }
 
-       /* (non-Javadoc)
-        * @see org.eclipse.ui.IEditorInput#getName()
-        */
-       /**
-        * <p>getName</p>
-        *
-        * @return a {@link java.lang.String} object.
-        */
+
        @Override
     public String getName() {
                return BulkEditorInputType.AGENT.label;
        }
 
-       /* (non-Javadoc)
-        * @see org.eclipse.ui.IEditorInput#getToolTipText()
-        */
-       /**
-        * <p>getToolTipText</p>
-        *
-        * @return a {@link java.lang.String} object.
-        */
+
        @Override
     public String getToolTipText() {
                return getName();
        }
 
-       /**
-        * <p>Getter for the field <code>instance</code>.</p>
-        *
-        * @return a {@link eu.etaxonomy.taxeditor.bulkeditor.input.AbstractBulkEditorInput} object.
-        */
        public static AbstractBulkEditorInput getInstance() {
                if (instance == null) {
                        instance = new AgentEditorInput();
@@ -97,18 +67,13 @@ public class AgentEditorInput extends AbstractBulkEditorInput<TeamOrPersonBase>
                return instance;
        }
 
-       /* (non-Javadoc)
-        * @see eu.etaxonomy.taxeditor.bulkeditor.input.BulkEditorInput#isMergingEnabled()
-        */
        /** {@inheritDoc} */
        @Override
        public boolean isMergingEnabled() {
                return true;
        }
 
-       /* (non-Javadoc)
-        * @see eu.etaxonomy.taxeditor.bulkeditor.input.BulkEditorInput#isMergingEnabled()
-        */
+
        /** {@inheritDoc} */
        @Override
        public boolean isConvertingEnabled() {
@@ -128,7 +93,6 @@ public class AgentEditorInput extends AbstractBulkEditorInput<TeamOrPersonBase>
                                    IMergeStrategy strategy = DefaultMergeStrategy.NewInstance(TeamOrPersonBase.class);
                                    CdmStore.getCommonService().merge(mergeTarget.getId(), entity.getId(), TeamOrPersonBase.class);
                                }
-
                        } catch (MergeException e) {
                                MessagingUtils.errorDialog("Bulk Editor Merge Error",
                                                this,
@@ -156,20 +120,16 @@ public class AgentEditorInput extends AbstractBulkEditorInput<TeamOrPersonBase>
 
 
        public boolean delete(AgentBase entity) throws ReferencedObjectUndeletableException  {
-
                        return CdmStore.getService(IAgentService.class).delete(entity) != null;
 
        }
 
-//     /** {@inheritDoc} */
-//     public boolean save(AgentBase entity) {
-//
-//             return CdmStore.getService(IAgentService.class).saveOrUpdate(entity) != null;
-//     }
+       /** {@inheritDoc} */
+       public boolean save(AgentBase entity) {
+
+               return CdmStore.getService(IAgentService.class).saveOrUpdate(entity) != null;
+       }
 
-       /* (non-Javadoc)
-        * @see eu.etaxonomy.taxeditor.bulkeditor.input.AbstractBulkEditorInput#getSortProviders()
-        */
        @Override
        public List<IBulkEditorSortProvider<TeamOrPersonBase>> getSortProviders() {
                List<IBulkEditorSortProvider<TeamOrPersonBase>> sortProviders = super.getSortProviders();
@@ -179,9 +139,7 @@ public class AgentEditorInput extends AbstractBulkEditorInput<TeamOrPersonBase>
                return sortProviders;
        }
 
-       /* (non-Javadoc)
-        * @see eu.etaxonomy.taxeditor.bulkeditor.input.AbstractBulkEditorInput#createEntityCreator()
-        */
+
        @Override
        protected IEntityCreator<TeamOrPersonBase> createEntityCreator() {
                return new AgentCreator();