performed javacscript:fix and worked on documentation
[taxeditor.git] / taxeditor-editor / src / main / java / eu / etaxonomy / taxeditor / section / AbstractCdmDetailSection.java
index 0494a3159288e021f4ab488bb01f194d7b737fe6..72964c0acdf5b43ab09f1eb5e98c321a2f3583ce 100644 (file)
@@ -30,6 +30,8 @@ import eu.etaxonomy.taxeditor.forms.ISelectableElement;
 import eu.etaxonomy.taxeditor.forms.SelectionArbitrator;
 
 /**
+ * <p>Abstract AbstractCdmDetailSection class.</p>
+ *
  * @author n.hoffmann
  * @created Feb 26, 2010
  * @version 1.0
@@ -40,6 +42,16 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
        
        protected SelectionArbitrator selectionArbitrator;
        
+       /**
+        * <p>Constructor for AbstractCdmDetailSection.</p>
+        *
+        * @param formFactory a {@link eu.etaxonomy.taxeditor.forms.CdmFormFactory} object.
+        * @param conversation a {@link eu.etaxonomy.cdm.api.conversation.ConversationHolder} object.
+        * @param parentElement a {@link eu.etaxonomy.taxeditor.forms.ICdmFormElement} object.
+        * @param selectionProvider a {@link org.eclipse.jface.viewers.ISelectionProvider} object.
+        * @param style a int.
+        * @param <ENTITY> a ENTITY object.
+        */
        public AbstractCdmDetailSection(CdmFormFactory formFactory,
                        ConversationHolder conversation, ICdmFormElement parentElement, ISelectionProvider selectionProvider, int style) {
                super(formFactory, conversation, parentElement, selectionProvider, Section.CLIENT_INDENT | style);
@@ -51,6 +63,12 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
        }
        
        
+       /**
+        * <p>createControls</p>
+        *
+        * @param formElement a {@link eu.etaxonomy.taxeditor.section.AbstractCdmDetailSection} object.
+        * @param style a int.
+        */
        protected void createControls(AbstractCdmDetailSection<ENTITY> formElement, int style) {
                TableWrapLayout layout = (TableWrapLayout) getLayoutComposite().getLayout();
                layout.topMargin = 10;
@@ -60,13 +78,21 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
                detailElement = formFactory.createCdmDetailElement(getDetailType(), formElement, style);
        }
        
+       /**
+        * <p>getDetailType</p>
+        *
+        * @return a {@link eu.etaxonomy.taxeditor.forms.CdmFormFactory.DetailType} object.
+        */
        protected abstract DetailType getDetailType();
 
        /**
+        * <p>getHeading</p>
+        *
         * @return the heading for this section
         */
        public abstract String getHeading();
        
+       /** {@inheritDoc} */
        @Override
        public void dispose() {
                if(detailElement instanceof ISelectableElement){
@@ -78,6 +104,7 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
        /* (non-Javadoc)
         * @see eu.etaxonomy.taxeditor.forms.section.AbstractEditorFormSection#setBackground(org.eclipse.swt.graphics.Color)
         */
+       /** {@inheritDoc} */
        @Override
        public void setBackground(Color color) {
                if(detailElement != null){
@@ -86,6 +113,11 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
                super.setBackground(color);
        }
        
+       /**
+        * <p>setEntity</p>
+        *
+        * @param entity a ENTITY object.
+        */
        public void setEntity(ENTITY entity) {
                if(detailElement != null){
                        detailElement.setEntity(entity);
@@ -95,6 +127,9 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
                layout();
        }
        
+       /**
+        * <p>setSectionTitle</p>
+        */
        protected void setSectionTitle(){
                String title = "";
                if(getEntity() != null && (getEntity() instanceof IdentifiableEntity)){
@@ -103,6 +138,9 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
                this.setText(getHeading() + title);
        }
        
+       /**
+        * <p>updateTitle</p>
+        */
        public void updateTitle(){
                if(!isDisposed()){
                        setSectionTitle();
@@ -110,16 +148,19 @@ public abstract class AbstractCdmDetailSection<ENTITY extends IAnnotatableEntity
                }
        }
        
+       /** {@inheritDoc} */
        public void setIrrelevant(boolean irrelevant) {
                if(detailElement != null){
                        detailElement.setIrrelevant(irrelevant);
                }
        }
        
+       /** {@inheritDoc} */
        public void expansionStateChanging(ExpansionEvent e) {
 //             logger.warn("Expansion State Changing");
        }
        
+       /** {@inheritDoc} */
        public void expansionStateChanged(ExpansionEvent e) {
 //             logger.warn("Expansion State Changed");
        }