Statistics
| Revision:

svn-gvsig-desktop / branches / v2_0_0_prep / libraries / libFMap_dal / src / org / gvsig / fmap / dal / feature / EditableFeatureAttributeDescriptor.java @ 26911

History | View | Annotate | Download (3.58 KB)

1 24496 jmvivo
package org.gvsig.fmap.dal.feature;
2 23754 jjdelcerro
3 26717 jmvivo
import org.cresques.cts.IProjection;
4 24663 jiyarza
import org.gvsig.fmap.dal.DataTypes;
5 24505 jmvivo
import org.gvsig.fmap.dal.feature.exception.AttributeFeatureTypeIntegrityException;
6 23754 jjdelcerro
import org.gvsig.tools.evaluator.Evaluator;
7
8 24663 jiyarza
/**
9
 * This interface represents a FeatureAttributeDescriptor in editable state.
10
 * To edit a FeatureAttributeDescriptor you have to obtain its instance of
11
 * EditableFeatureAttributeDescriptor and then perform editing operations on it.
12
 *
13 25481 jiyarza
 * Once you have completed the editing you can save the changes to the original
14 24663 jiyarza
 * FeatureAttributeDescriptor. This is the only way to edit a FeatureAttributeDescriptor.
15
 */
16 23754 jjdelcerro
public interface EditableFeatureAttributeDescriptor extends
17
                FeatureAttributeDescriptor {
18
19
        /**
20
         * Checks attribute integrity
21
         */
22 23772 jjdelcerro
        void checkIntegrity() throws AttributeFeatureTypeIntegrityException;
23 23754 jjdelcerro
24 24663 jiyarza
        /**
25
         * Sets the name
26
         * @param
27
         *                 name to set
28
         * @return this
29
         */
30 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setName(String name);
31
32 24663 jiyarza
        /**
33
         * Sets the data type
34
         * @param
35
         *                 type one of the constants defined in {@link DataTypes}
36
         * @return this
37
         */
38 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setDataType(int type);
39
40 24663 jiyarza
        /**
41
         * Sets the size
42
         * @param size
43
         *                         a size of type int
44
         * @return this
45
         *
46
         */
47 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setSize(int size);
48
49 24663 jiyarza
        /**
50
         * Sets the precision
51
         *
52
         * @param
53
         *                 precision of type int
54
         *
55
         * @return this
56
         */
57 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setPrecision(int precision);
58
59 24663 jiyarza
        /**
60
         * Sets the Class to which the related FeatureAttribute can be cast
61
         *
62
         * @param theClass
63
         *                                 Class to which the related FeatureAttribute can be cast
64
         * @return this
65
         */
66 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setObjectClass(Class theClass);
67
68 24663 jiyarza
        /**
69
         * Sets the number of minimum occurrences
70
         *
71
         * @param minimumOccurrences
72
         *
73
         * @return this
74
         */
75 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setMinimumOccurrences(
76
                        int minimumOccurrences);
77
78 24663 jiyarza
        /**
79
         * Sets the maximum number of occurrences
80
         *
81
         * @param maximumOccurrences
82
         *
83
         * @return
84
         */
85 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setMaximumOccurrences(
86
                        int maximumOccurrences);
87
88 24663 jiyarza
        /**
89
         * Sets whether the related FeatureAttribute is part of the FeatureType's primary key
90
         *
91
         * @param isPrimaryKey
92
         *                                 true if is part of the primary key
93
         * @return this
94
         */
95 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setIsPrimaryKey(
96
                        boolean isPrimaryKey);
97
98 24663 jiyarza
        /**
99
         * Sets the expression evaluator that the FeatureAttribute will use
100
         * @param evaluator
101
         *                                 an implementation of DAL's Evaluator interface
102
         * @return this
103
         */
104 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setEvaluator(Evaluator evaluator);
105
106 24663 jiyarza
        /**
107
         * Sets whether the related FeatureAttribute is read only
108
         *
109
         * @param isReadOnly
110
         *
111
         * @return this
112
         */
113 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setIsReadOnly(boolean isReadOnly);
114
115 24663 jiyarza
        /**
116
         * Sets whether the related FeatureAttribute can have a null value
117
         *
118
         * @param allowNull
119
         *                                 a boolean value determining whether the FeatureAttribute can be null
120
         *
121
         * @return this
122
         */
123 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setAllowNull(boolean allowNull);
124
125 24663 jiyarza
        /**
126
         * Sets the SRS.
127
         *
128
         * @param SRS
129
         *
130
         * @return
131
         */
132 26717 jmvivo
        public EditableFeatureAttributeDescriptor setSRS(IProjection SRS);
133 23754 jjdelcerro
134 24663 jiyarza
        /**
135
         * Sets the geometry type
136
         *
137
         * @param geometryType
138
         *
139
         * @return this
140
         */
141 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setGeometryType(int geometryType);
142
143 24663 jiyarza
        /**
144
         * Sets the default value
145
         *
146
         * @param defaultValue
147
         *
148
         * @return this
149
         */
150 23754 jjdelcerro
        public EditableFeatureAttributeDescriptor setDefaultValue(
151
                        Object defaultValue);
152
153
}