[Schmitzm-commits] r466 - in branches/1.0-gt2-2.6/src/schmitzm/geotools: feature gui

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Wed Oct 14 08:22:48 CEST 2009


Author: alfonx
Date: 2009-10-14 08:22:46 +0200 (Wed, 14 Oct 2009)
New Revision: 466

Modified:
   branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/AttributeTypeFilter.java
   branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/FeatureTypeTableModel.java
   branches/1.0-gt2-2.6/src/schmitzm/geotools/gui/FeatureCollectionTableModel.java
Log:
* Removed the "int idx" parameter in accept method of the AttributeTypeFilter, because the AttributeMetadataMap is not based on the column-index any more.

Modified: branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/AttributeTypeFilter.java
===================================================================
--- branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/AttributeTypeFilter.java	2009-10-13 16:20:37 UTC (rev 465)
+++ branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/AttributeTypeFilter.java	2009-10-14 06:22:46 UTC (rev 466)
@@ -54,7 +54,7 @@
    * Standard-Filter, der alle Attribute akzeptiert.
    */
   public static final AttributeTypeFilter ALL = new AttributeTypeFilter() {
-    public boolean accept(AttributeDescriptor type, int idx) {
+    public boolean accept(AttributeDescriptor type) {
       return true;
     }
   };
@@ -64,7 +64,7 @@
 	 * Geometrie-Attribute} ausblendet.
 	 */
 	public static final AttributeTypeFilter NO_GEOMETRY = new AttributeTypeFilter() {
-		public boolean accept(AttributeDescriptor desciptor, int idx) {
+		public boolean accept(AttributeDescriptor desciptor) {
 			return !(desciptor instanceof GeometryDescriptor);
 		}
 	};
@@ -74,5 +74,5 @@
    * @param type ein Attribut-Typ
    * @param idx  der Index des Attributs
    */
-  public boolean accept(AttributeDescriptor type, int idx);
+  public boolean accept(AttributeDescriptor type);
 }

Modified: branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/FeatureTypeTableModel.java
===================================================================
--- branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/FeatureTypeTableModel.java	2009-10-13 16:20:37 UTC (rev 465)
+++ branches/1.0-gt2-2.6/src/schmitzm/geotools/feature/FeatureTypeTableModel.java	2009-10-14 06:22:46 UTC (rev 466)
@@ -83,7 +83,7 @@
     if ( featureType != null )
       for (int i=0; i<featureType.getAttributeCount(); i++) {
         AttributeDescriptor type = featureType.getAttributeDescriptors().get(i);
-        if ( attrFilter == null || attrFilter.accept( type, i ) )
+        if ( attrFilter == null || attrFilter.accept( type ) )
           attrTypes.add( type );
       }
     this.fireTableDataChanged();

Modified: branches/1.0-gt2-2.6/src/schmitzm/geotools/gui/FeatureCollectionTableModel.java
===================================================================
--- branches/1.0-gt2-2.6/src/schmitzm/geotools/gui/FeatureCollectionTableModel.java	2009-10-13 16:20:37 UTC (rev 465)
+++ branches/1.0-gt2-2.6/src/schmitzm/geotools/gui/FeatureCollectionTableModel.java	2009-10-14 06:22:46 UTC (rev 466)
@@ -131,7 +131,7 @@
       attrTypes.clear();
       for (int i=0; i<ft.getAttributeCount(); i++) {
         AttributeDescriptor type = ft.getAttributeDescriptors().get(i);
-        if ( attrFilter == null || attrFilter.accept( type, i ) )
+        if ( attrFilter == null || attrFilter.accept( type ) )
           attrTypes.add( type );
       }
       // Namen und Attribut-Indizes der angezeigten Spalten ermitteln



More information about the Schmitzm-commits mailing list