Revision 44938

View differences:

trunk/org.gvsig.desktop/org.gvsig.desktop.plugin/org.gvsig.daltransform.app/org.gvsig.daltransform.app.mainplugin/src/main/java/org/gvsig/daltransform/swing/impl/components/NumericFeatureTypeAttributesCombo.java
1 1
/**
2 2
 * gvSIG. Desktop Geographic Information System.
3 3
 *
4
 * Copyright (C) 2007-2013 gvSIG Association.
4
 * Copyright (C) 2007-2020 gvSIG Association.
5 5
 *
6 6
 * This program is free software; you can redistribute it and/or
7 7
 * modify it under the terms of the GNU General Public License
......
21 21
 * For any additional information, do not hesitate to contact us
22 22
 * at info AT gvsig.com, or visit our website www.gvsig.com.
23 23
 */
24
/*
25
 * AUTHORS (In addition to CIT):
26
 * 2009 {Iver T.I.}   {Task}
27
 */
28 24

  
29 25
package org.gvsig.daltransform.swing.impl.components;
30 26

  
31
import org.gvsig.fmap.dal.DataTypes;
32 27
import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
28
import org.gvsig.tools.dataTypes.DataType;
33 29

  
34 30
/**
35
 * @author <a href="mailto:jpiera@gvsig.org">Jorge Piera</a>
31
 * @author gvSIG Team
36 32
 */
37 33
public class NumericFeatureTypeAttributesCombo extends FeatureTypeAttributesCombo{
38 34

  
39
	/**
40
     * 
41
     */
42 35
    private static final long serialVersionUID = -1694488470656611290L;
43 36

  
44
    /* (non-Javadoc)
45
	 * @see org.gvsig.app.daltransform.gui.combos.FeatureTypeAttributesCombo#addFeatureAttributeDescriptor(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
46
	 */
37
    @Override
47 38
	public void addFeatureAttributeDescriptor(
48 39
			FeatureAttributeDescriptor featureAttributeDescriptor) {
49
		int type = featureAttributeDescriptor.getType();
50
		if ((type == DataTypes.DOUBLE) ||
51
				(type == DataTypes.FLOAT) ||
52
				(type == DataTypes.INT) ||
53
				(type == DataTypes.LONG)){
54
			super.addFeatureAttributeDescriptor(featureAttributeDescriptor);
40
                DataType type = featureAttributeDescriptor.getDataType();
41
		if ( type.isNumeric() ){
42
                    super.addFeatureAttributeDescriptor(featureAttributeDescriptor);
55 43
		}
56 44
	}	
57 45
}

Also available in: Unified diff