svn-gvsig-desktop / trunk / org.gvsig.desktop / org.gvsig.desktop.compat.cdc / org.gvsig.fmap.dal / org.gvsig.fmap.dal.impl / src / main / java / org / gvsig / fmap / dal / feature / impl / EditingManager.java @ 46078
History | View | Annotate | Download (2.5 KB)
1 | 43840 | jjdelcerro | |
---|---|---|---|
2 | package org.gvsig.fmap.dal.feature.impl; |
||
3 | |||
4 | import java.util.Iterator; |
||
5 | 43967 | jjdelcerro | import java.util.List; |
6 | 43840 | jjdelcerro | import org.gvsig.fmap.dal.exception.DataException; |
7 | 45739 | jjdelcerro | import org.gvsig.fmap.dal.feature.EditableFeature; |
8 | 43840 | jjdelcerro | import org.gvsig.fmap.dal.feature.Feature; |
9 | import org.gvsig.fmap.dal.feature.FeatureReference; |
||
10 | import org.gvsig.fmap.dal.feature.FeatureStore; |
||
11 | import org.gvsig.fmap.dal.feature.FeatureType; |
||
12 | 44871 | jjdelcerro | import org.gvsig.fmap.dal.feature.FeatureType.FeatureTypeChanged; |
13 | 43840 | jjdelcerro | import org.gvsig.fmap.dal.feature.spi.FeatureProvider; |
14 | |||
15 | |||
16 | public interface EditingManager { |
||
17 | 43841 | jjdelcerro | /*
|
18 | Este interface, con el tiempo deberia ir al SPI.
|
||
19 | |||
20 | Tendria que sustituir a:
|
||
21 | - FeatureManager
|
||
22 | - FeatureTypeManager
|
||
23 | - SpatialManager
|
||
24 | como mecanismos para guardar los datos mientras se esta en edicion.
|
||
25 | |||
26 | Habria que eliminar estos managers del DefaultFeatureStore y sustituirlos
|
||
27 | por este.
|
||
28 | |||
29 | En una primera implementacion, se mantendrian estos managers como parte interna
|
||
30 | de la implementacion del MemoryEditingManager.
|
||
31 | |||
32 | */
|
||
33 | 43840 | jjdelcerro | |
34 | public void dispose(); |
||
35 | |||
36 | public void delete(Feature feature); |
||
37 | |||
38 | 45521 | fdiaz | // public void delete(FeatureReference featureReference);
|
39 | 43840 | jjdelcerro | |
40 | 45739 | jjdelcerro | public void add(EditableFeature newFeature); |
41 | 43840 | jjdelcerro | |
42 | 45739 | jjdelcerro | public int update(EditableFeature newFeature, Feature oldFeature); |
43 | 43840 | jjdelcerro | |
44 | public int update(FeatureType type, FeatureType oldType); |
||
45 | |||
46 | public void restore(FeatureReference featureReference); |
||
47 | |||
48 | public void restore(FeatureReference featureReference, int code); |
||
49 | |||
50 | public void restore(String featureTypeId); |
||
51 | |||
52 | public void restore(String featureTypeId, int code); |
||
53 | |||
54 | public boolean isDeleted(Feature feature); |
||
55 | |||
56 | public boolean isDeleted(FeatureReference featureReference); |
||
57 | |||
58 | public boolean isDeleted(FeatureType type); |
||
59 | |||
60 | public boolean isDeleted(String featureTypeId); |
||
61 | |||
62 | public boolean isSelectionCompromised(); |
||
63 | |||
64 | 44871 | jjdelcerro | public Iterator<FeatureReference> getDeletedFeatures(); |
65 | 43840 | jjdelcerro | public Iterator<FeatureProvider> getInsertedFeatures(); |
66 | public Iterator<FeatureProvider> getUpdatedFeatures(); |
||
67 | |||
68 | 43967 | jjdelcerro | public List<FeatureTypeChanged> getFeatureTypesChanged() throws DataException; |
69 | 43840 | jjdelcerro | |
70 | public FeatureType getFeatureType(String id) throws DataException ; |
||
71 | |||
72 | public Feature getFeature(FeatureReference reference, FeatureStore store, FeatureType type) throws DataException; |
||
73 | |||
74 | |||
75 | /*
|
||
76 | it = featureTypeManager.newsIterator();
|
||
77 | |||
78 | position = expansionManager.update(type, oldType);
|
||
79 | |||
80 | expansionManager.restore(oldType.getId(),position);
|
||
81 | |||
82 | spatialManager.cancelModifies();
|
||
83 | */
|
||
84 | } |