[Schmitzm-commits] r665 - branches/2.0-RC2/src/schmitzm/jfree/feature/style

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Wed Feb 3 18:58:51 CET 2010


Author: mojays
Date: 2010-02-03 18:58:37 +0100 (Wed, 03 Feb 2010)
New Revision: 665

Modified:
   branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureBasicChartStyle.java
   branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureChartStyle.java
   branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureScatterChartStyle.java
Log:
New method in FeatureChartStyle to remove an attribute definition (not yet implemented!!).

Modified: branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureBasicChartStyle.java
===================================================================
--- branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureBasicChartStyle.java	2010-02-03 17:45:14 UTC (rev 664)
+++ branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureBasicChartStyle.java	2010-02-03 17:58:37 UTC (rev 665)
@@ -96,7 +96,18 @@
       return dest;
     }
 
-	/**
+    /**
+     * Removes all style informations about an attribute and
+     * reorganizes the attribute indexes so there is an continuous 
+     * order. 
+     * @param idx an attribute
+     */
+    @Override
+    public void removeAttribute(int idx) {
+      dummyFeatureChartStyle.removeAttribute(idx);
+    }
+
+    /**
 	 * Returns the maximum number of feature attributes that can be
 	 * specified by this style.
 	 * @return always -1 which indicates no limit

Modified: branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureChartStyle.java
===================================================================
--- branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureChartStyle.java	2010-02-03 17:45:14 UTC (rev 664)
+++ branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureChartStyle.java	2010-02-03 17:58:37 UTC (rev 665)
@@ -66,6 +66,14 @@
   public int getAttributeCount();
 
   /**
+   * Removes all style informations about an attribute and
+   * reorganizes the attribute indexes so there is an continuous 
+   * order. 
+   * @param idx an attribute index
+   */
+  public void removeAttribute(int idx);
+
+  /**
    * Returns the name of a feature attribute needed to create a
    * chart for this style.
    * @param idx attribute index (0=domain; 1=1st range series;
@@ -265,6 +273,17 @@
     }
     
     /**
+     * Removes all style informations about an attribute and
+     * reorganizes the attribute indexes so there is an continuous 
+     * order. 
+     * @param idx an attribute
+     */
+    @Override
+    public void removeAttribute(int idx) {
+      throw new UnsupportedOperationException("FeatureChartStyle.removeAttribute(..) not yet implemented!");
+    }
+    
+    /**
      * Creates a (deep) clone of this style. The properties
      * of the super class ({@link AbstractChartStyle}) are <b>ignored</b>
      * because they are unused for the dummy.
@@ -424,24 +443,6 @@
 	}
 
     /**
-     * Does nothing, but always throws a {@link UnsupportedOperationException},
-     * because the dummy can not provide this functionality.
-     */
-    @Override
-    public JFreeChart applyToDataset(Dataset dataset) {
-      throw new UnsupportedOperationException("FeatureChartStyle.Dummy does not implement applyToDataset(..)");
-    }
-
-    /**
-     * Does nothing, but always throws a {@link UnsupportedOperationException},
-     * because the dummy can not provide this functionality.
-     */
-    @Override
-    public JFreeChart applyToFeatureCollection(FeatureCollection<SimpleFeatureType, SimpleFeature> fc) {
-      throw new UnsupportedOperationException("FeatureChartStyle.Dummy does not implement applyToFeatureCollection(..)");
-    }
-
-    /**
      * Sets the values, which are interpreted as "No Data". 
      * @param idx attribute index the "No Data" values are set for
      * @param noDataValues the "No Data" values
@@ -511,6 +512,25 @@
         return null;
       return value;
     }
+
+    /**
+     * Does nothing, but always throws a {@link UnsupportedOperationException},
+     * because the dummy can not provide this functionality.
+     */
+    @Override
+    public JFreeChart applyToDataset(Dataset dataset) {
+      throw new UnsupportedOperationException("FeatureChartStyle.Dummy does not implement applyToDataset(..)");
+    }
+
+    /**
+     * Does nothing, but always throws a {@link UnsupportedOperationException},
+     * because the dummy can not provide this functionality.
+     */
+    @Override
+    public JFreeChart applyToFeatureCollection(FeatureCollection<SimpleFeatureType, SimpleFeature> fc) {
+      throw new UnsupportedOperationException("FeatureChartStyle.Dummy does not implement applyToFeatureCollection(..)");
+    }
+
   }
   
 }

Modified: branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureScatterChartStyle.java
===================================================================
--- branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureScatterChartStyle.java	2010-02-03 17:45:14 UTC (rev 664)
+++ branches/2.0-RC2/src/schmitzm/jfree/feature/style/FeatureScatterChartStyle.java	2010-02-03 17:58:37 UTC (rev 665)
@@ -113,6 +113,17 @@
   }
 
   /**
+   * Removes all style informations about an attribute and
+   * reorganizes the attribute indexes so there is an continuous 
+   * order. 
+   * @param idx an attribute
+   */
+  @Override
+  public void removeAttribute(int idx) {
+    dummyFeatureChartStyle.removeAttribute(idx);
+  }
+
+  /**
    * Returns the maximum number of feature attributes that can be
    * specified by this style.
    * @return always 2



More information about the Schmitzm-commits mailing list