svn-gvsig-desktop / branches / v2_0_0_prep / libraries / libFMap_dal / src / org / gvsig / fmap / dal / feature / EditableFeatureAttributeDescriptor.java @ 28782
History | View | Annotate | Download (4.18 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 | 27439 | jmvivo | * This interface represents a FeatureAttributeDescriptor in editable state.
|
10 | * To edit a FeatureAttributeDescriptor you have to obtain its instance of
|
||
11 | 24663 | jiyarza | * EditableFeatureAttributeDescriptor and then perform editing operations on it.
|
12 | 27439 | jmvivo | *
|
13 | * 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 | 27439 | jmvivo | * @param
|
27 | 24663 | jiyarza | * 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 | 27439 | jmvivo | * @param
|
35 | 24663 | jiyarza | * 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 | 27439 | jmvivo | * @param size
|
43 | 24663 | jiyarza | * a size of type int
|
44 | * @return this
|
||
45 | 27439 | jmvivo | *
|
46 | 24663 | jiyarza | */
|
47 | 23754 | jjdelcerro | public EditableFeatureAttributeDescriptor setSize(int size); |
48 | |||
49 | 24663 | jiyarza | /**
|
50 | * Sets the precision
|
||
51 | 27439 | jmvivo | *
|
52 | * @param
|
||
53 | 24663 | jiyarza | * precision of type int
|
54 | 27439 | jmvivo | *
|
55 | 24663 | jiyarza | * @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 | 27439 | jmvivo | *
|
62 | * @param theClass
|
||
63 | 24663 | jiyarza | * 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 | 27439 | jmvivo | *
|
71 | 24663 | jiyarza | * @param minimumOccurrences
|
72 | 27439 | jmvivo | *
|
73 | 24663 | jiyarza | * @return this
|
74 | */
|
||
75 | 23754 | jjdelcerro | public EditableFeatureAttributeDescriptor setMinimumOccurrences(
|
76 | int minimumOccurrences);
|
||
77 | |||
78 | 24663 | jiyarza | /**
|
79 | * Sets the maximum number of occurrences
|
||
80 | 27439 | jmvivo | *
|
81 | 24663 | jiyarza | * @param maximumOccurrences
|
82 | 27439 | jmvivo | *
|
83 | 24663 | jiyarza | * @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 | 27439 | jmvivo | *
|
91 | 24663 | jiyarza | * @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 | 27439 | jmvivo | * @param evaluator
|
101 | 24663 | jiyarza | * 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 | 27439 | jmvivo | *
|
109 | 24663 | jiyarza | * @param isReadOnly
|
110 | 27439 | jmvivo | *
|
111 | 24663 | jiyarza | * @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 | 27439 | jmvivo | *
|
118 | 24663 | jiyarza | * @param allowNull
|
119 | * a boolean value determining whether the FeatureAttribute can be null
|
||
120 | 27439 | jmvivo | *
|
121 | 24663 | jiyarza | * @return this
|
122 | */
|
||
123 | 23754 | jjdelcerro | public EditableFeatureAttributeDescriptor setAllowNull(boolean allowNull); |
124 | |||
125 | 24663 | jiyarza | /**
|
126 | * Sets the SRS.
|
||
127 | 27439 | jmvivo | *
|
128 | 24663 | jiyarza | * @param SRS
|
129 | 27439 | jmvivo | *
|
130 | 24663 | jiyarza | * @return
|
131 | */
|
||
132 | 26717 | jmvivo | public EditableFeatureAttributeDescriptor setSRS(IProjection SRS);
|
133 | 23754 | jjdelcerro | |
134 | 24663 | jiyarza | /**
|
135 | * Sets the geometry type
|
||
136 | 27439 | jmvivo | *
|
137 | 24663 | jiyarza | * @param geometryType
|
138 | 27439 | jmvivo | *
|
139 | 24663 | jiyarza | * @return this
|
140 | */
|
||
141 | 23754 | jjdelcerro | public EditableFeatureAttributeDescriptor setGeometryType(int geometryType); |
142 | |||
143 | 27981 | jmvivo | |
144 | 24663 | jiyarza | /**
|
145 | 27981 | jmvivo | * Sets the geometry subtype
|
146 | *
|
||
147 | * @param geometrySubType
|
||
148 | *
|
||
149 | * @return this
|
||
150 | */
|
||
151 | public EditableFeatureAttributeDescriptor setGeometrySubType(
|
||
152 | int geometrySubType);
|
||
153 | |||
154 | /**
|
||
155 | 24663 | jiyarza | * Sets the default value
|
156 | 27439 | jmvivo | *
|
157 | 24663 | jiyarza | * @param defaultValue
|
158 | 27439 | jmvivo | *
|
159 | 24663 | jiyarza | * @return this
|
160 | */
|
||
161 | 23754 | jjdelcerro | public EditableFeatureAttributeDescriptor setDefaultValue(
|
162 | Object defaultValue);
|
||
163 | |||
164 | 27439 | jmvivo | /**
|
165 | * Sets additional information of the attribute
|
||
166 | 27550 | jmvivo | * @return TODO
|
167 | 27439 | jmvivo | *
|
168 | 27550 | jmvivo | *
|
169 | 27439 | jmvivo | */
|
170 | 27550 | jmvivo | public EditableFeatureAttributeDescriptor setAdditionalInfo(String infoName, Object value); |
171 | 27439 | jmvivo | |
172 | 27550 | jmvivo | /**
|
173 | * Sets whether the related FeatureAttribute is part of the FeatureType's
|
||
174 | * primary key
|
||
175 | *
|
||
176 | * @param isPrimaryKey
|
||
177 | * true if is part of the primary key
|
||
178 | * @return this
|
||
179 | */
|
||
180 | public EditableFeatureAttributeDescriptor setIsAutomatic(
|
||
181 | boolean isAutomatic);
|
||
182 | |||
183 | 23754 | jjdelcerro | } |