root / branches / v2_0_0_prep / libraries / libFMap_data / src / org / gvsig / fmap / data / DataStore.java @ 23178
History | View | Annotate | Download (3.13 KB)
1 |
package org.gvsig.fmap.data; |
---|---|
2 |
|
3 |
import java.util.Iterator; |
4 |
|
5 |
import org.gvsig.fmap.data.commands.CommandsRecord; |
6 |
import org.gvsig.fmap.data.feature.IsNotFeatureSettingException; |
7 |
import org.gvsig.fmap.data.operation.DataStoreOperationContext; |
8 |
import org.gvsig.fmap.data.operation.DataStoreOperationException; |
9 |
import org.gvsig.fmap.data.operation.DataStoreOperationNotSupportedException; |
10 |
import org.gvsig.metadata.IMetadatable; |
11 |
import org.gvsig.tools.observer.Observable; |
12 |
|
13 |
import com.iver.utiles.IPersistence; |
14 |
import com.iver.utiles.XMLEntity; |
15 |
import com.iver.utiles.XMLException; |
16 |
|
17 |
public interface DataStore extends Observable, IMetadatable, IPersistence{ |
18 |
|
19 |
public String getName(); |
20 |
|
21 |
public void init(DataStoreParameters parameters) throws InitializeException; |
22 |
public void setXMLEntity(XMLEntity xmlEntity) throws XMLException; |
23 |
|
24 |
/*
|
25 |
* FIXME: Comprobar el valor de retorno de las funciones ?Deber?an de ser booleanas?
|
26 |
*/
|
27 |
/**
|
28 |
* Indica que se va a comenzar a hacer una serie de operaciones sobre el
|
29 |
* origen de datos con la finalidad de que dicho origen de datos se
|
30 |
* prepare (abra el fichero, comience una transacci?n, conecte al
|
31 |
* servidor, ...). Abre el fichero de ?ndices en caso de que exista.
|
32 |
* @throws OpenException
|
33 |
* @throws IsNotFeatureSettingException
|
34 |
*
|
35 |
*/
|
36 |
// public void open() throws OpenException;
|
37 |
public void refresh() throws OpenException,InitializeException; |
38 |
|
39 |
/**
|
40 |
* Hace que se cierre el soporte f?sico de la capa. Cierra el fichero de
|
41 |
* ?ndices en caso de que exista.
|
42 |
*
|
43 |
*/
|
44 |
// public void close() throws CloseException;
|
45 |
public void dispose() throws CloseException; |
46 |
|
47 |
|
48 |
public DataCollection getDataCollection() throws ReadException; |
49 |
|
50 |
public DataCollection getSelection();
|
51 |
public void setSelection(DataCollection selection) throws DataException; |
52 |
public DataCollection createSelection();
|
53 |
|
54 |
public Iterator getChilds(); // Iterator of DataStore |
55 |
|
56 |
/*
|
57 |
* TODO: Falta comprobar si el tema de edici?n lo dejamos aqui o
|
58 |
* volvemos a bajarlo al FeatureStore
|
59 |
*
|
60 |
* FIXME: Comprobar el valor de retorno de las funciones ?Deber?an de ser booleanas?
|
61 |
*/
|
62 |
public boolean isEditable(); |
63 |
public void startEditing() throws ReadException; |
64 |
public void cancelEditing(); |
65 |
public void finishEditing() throws WriteException, ReadException; |
66 |
public boolean isEditing(); |
67 |
|
68 |
public void undo(); |
69 |
public void redo(); |
70 |
public CommandsRecord getCommandsRecord();
|
71 |
|
72 |
public void beginComplexNotification(); |
73 |
public void endComplexNotification(); |
74 |
|
75 |
//Bloqueo en edici?n similar a la selecci?n
|
76 |
|
77 |
public DataCollection getLocked();
|
78 |
public void setLocked(DataCollection locked); |
79 |
public DataCollection createLocked();
|
80 |
public DataExplorer getExplorer() throws ReadException; |
81 |
|
82 |
|
83 |
public Object invokeOperation(int code,DataStoreOperationContext context) throws DataStoreOperationException, DataStoreOperationNotSupportedException; |
84 |
public Object invokeOperation(String name,DataStoreOperationContext context) throws DataStoreOperationException, DataStoreOperationNotSupportedException; |
85 |
|
86 |
public boolean implementsOperation(int code); |
87 |
public boolean implementsOperation(String name); |
88 |
|
89 |
|
90 |
} |
91 |
|