Revision 25252 branches/v2_0_0_prep/libraries/libFMap_dal/src/org/gvsig/fmap/dal/feature/FeatureAttributeDescriptor.java
FeatureAttributeDescriptor.java | ||
---|---|---|
2 | 2 |
|
3 | 3 |
import java.text.DateFormat; |
4 | 4 |
|
5 |
import org.gvsig.fmap.dal.DataTypes; |
|
5 | 6 |
import org.gvsig.fmap.geom.Geometry; |
6 | 7 |
import org.gvsig.tools.evaluator.Evaluator; |
7 | 8 |
|
... | ... | |
9 | 10 |
|
10 | 11 |
|
11 | 12 |
/** |
12 |
* Describes a Feature attribute. |
|
13 |
* A feature attribute descriptor contains information about |
|
14 |
* one of the attributes in a feature, such as its name, data type |
|
15 |
* or precision. |
|
13 | 16 |
* |
14 | 17 |
* |
15 | 18 |
*/ |
... | ... | |
37 | 40 |
* {@link #getPrecision}, and {@link #getObjectClass} should be interpreted. |
38 | 41 |
* For attributes whose maximum cardinality is greater than one, this should |
39 | 42 |
* return the data type of the individual elements of the collection. |
43 |
* |
|
44 |
* @return |
|
45 |
* an <code>int</code> indicating the data type as defined in {@link DataTypes}. |
|
40 | 46 |
*/ |
41 | 47 |
public int getDataType(); |
42 | 48 |
|
... | ... | |
49 | 55 |
public String getDataTypeName(); |
50 | 56 |
|
51 | 57 |
/** |
52 |
* Returns a number that indicates the size of a given attribute. See the |
|
53 |
* documentation for the various constants of |
|
54 |
* {@link FeatureAttributeDescriptor} for how to interpret this value. As an |
|
55 |
* example, when the data type is {@link FeatureAttributeDescriptor#STRING |
|
56 |
* STRING}, this value indicates the maximum length of the string. |
|
58 |
* Returns a number that indicates the size of this attribute. See the |
|
59 |
* documentation for the various constants of {@link DataTypes} |
|
60 |
* for how to interpret this value. As an example, when the data type is |
|
61 |
* {@link DataTypes#STRING}, this value indicates the maximum length of the string. |
|
62 |
* |
|
63 |
* @return |
|
64 |
* an <code>int</code> indicating the size of the attribute. |
|
57 | 65 |
*/ |
58 | 66 |
public int getSize(); |
59 | 67 |
|
60 | 68 |
/** |
61 |
* For attributes of type {@link FeatureAttributeDescriptor#DECIMAL DECIMAL}
|
|
69 |
* For attributes of type {@link DataTypes#DECIMAL}
|
|
62 | 70 |
* , this returns the maximum number of places after the decimal point. For |
63 | 71 |
* other types, this must always return zero. |
64 | 72 |
*/ |
65 | 73 |
public int getPrecision(); |
66 | 74 |
|
67 | 75 |
/** |
68 |
* For attributes of type {@link FeatureAttributeDescriptor#OBJECT OBJECT},
|
|
76 |
* For attributes of type {@link DataTypes#OBJECT},
|
|
69 | 77 |
* this returns the Java {@link Class} object that class or interface that |
70 | 78 |
* all values of this attribute can be cast to. |
71 | 79 |
*/ |
... | ... | |
92 | 100 |
* Returns {@code true} if this attribute forms all or part of the unique identifying |
93 | 101 |
* value for the feature it is contained by. The primary key attributes uniquely |
94 | 102 |
* identify this feature from other features of the same type. This is different |
95 |
* from the {@linkplain Feature#getID feature's ID}, which must uniquely identify
|
|
103 |
* from the {@linkplain Feature#getReference()}, which must uniquely identify
|
|
96 | 104 |
* the {@link Feature} among all feature types. |
97 | 105 |
*/ |
98 | 106 |
public boolean isPrimaryKey(); |
Also available in: Unified diff