Revision 27723 branches/v2_0_0_prep/libraries/libFMap_dal/src/org/gvsig/fmap/dal/DataManager.java

View differences:

DataManager.java
4 4

  
5 5
import org.gvsig.fmap.dal.exception.InitializeException;
6 6
import org.gvsig.fmap.dal.exception.ProviderNotRegisteredException;
7
import org.gvsig.fmap.dal.exception.ValidateDataParametersException;
7 8
import org.gvsig.fmap.dal.feature.FeatureIndex;
8 9
import org.gvsig.fmap.dal.feature.spi.index.FeatureIndexProvider;
9 10
import org.gvsig.fmap.dal.resource.ResourceManager;
......
11 12

  
12 13
/**
13 14
 * There are two top level management roles within DAL: data access and resource management.
14
 * 
15
 *
15 16
 * This class is responsible of the data access management role. It provides ways
16
 * for registering and instantiating {@link DataServerExplorer}(s), {@link DataStore}(s), 
17
 * for registering and instantiating {@link DataServerExplorer}(s), {@link DataStore}(s),
17 18
 * {@link Evaluator}(s) and {@link FeatureIndex}(es).
18
 * 
19
 * @see ResourceManager 
20
 * 
19
 *
20
 * @see ResourceManager
21
 *
21 22
 */
22 23

  
23 24
public interface DataManager {
24 25

  
25 26
	/**
26 27
	 * Returns the default DAL's temporary directory
27
	 * 
28
	 *
28 29
	 * @return Temporary directory name
29 30
	 */
30 31
	public String getTemporaryDirectory();
......
38 39
	/**
39 40
	 * Creates, initializes and returns an instance of DataStoreParameters given
40 41
	 * the name with which their provider is registered.
41
	 * 
42
	 *
42 43
	 * @param name
43 44
	 *            provider name
44
	 *            
45
	 *
45 46
	 * @throws InitializeException
46
	 * 
47
	 *
47 48
	 * @throws ProviderNotRegisteredException
48 49
	 **/
49 50
	public DataStoreParameters createStoreParameters(String name)
50 51
			throws InitializeException, ProviderNotRegisteredException;
51 52

  
52 53
	/**
53
	 * 
54
	 *
54 55
	 * Creates, initializes and returns an instance of DataStore given the
55 56
	 * DataStoreParameters.
56
	 * 
57
	 *
57 58
	 * @param parameters
58 59
	 *            parameters used to instantiate and initialize the DataStore
59
	 *            
60
	 * 
60 61
	 * @throws InitializeException
61
	 * 
62
	 *
62 63
	 * @throws ProviderNotRegisteredException
64
	 * @throws ValidateDataParametersException
63 65
	 **/
64 66
	public DataStore createStore(DataStoreParameters parameters)
65
			throws InitializeException, ProviderNotRegisteredException;
67
			throws InitializeException, ProviderNotRegisteredException,
68
			ValidateDataParametersException;
66 69

  
67 70
	/**
68 71
	 * Returns a list of Strings containing the names of all available DataStore
69 72
	 * providers.
70
	 * 
73
	 *
71 74
	 * @return list of String containing available DataStore provider names
72 75
	 */
73 76
	public List getStoreProviders();
......
78 81
	 * Explorer related services
79 82
	 */
80 83
	/**
81
	 * Returns an instance of {@link DataServerExplorerParameters} corresponding to 
84
	 * Returns an instance of {@link DataServerExplorerParameters} corresponding to
82 85
	 * the given name.
83 86
	 *
84 87
	 * @param name
85 88
	 *            name of a registered server explorer provider
86
	 *            
89
	 *
87 90
	 * @throws InitializeException
88 91
	 * 			if parameter initialization causes an error.
89
	 * 
92
	 *
90 93
	 * @throws ProviderNotRegisteredException
91 94
	 * 			if could not find a provider by the given name.
92
	 * 
95
	 *
93 96
	 **/
94 97
	public DataServerExplorerParameters createServerExplorerParameters(
95 98
			String name)
......
97 100

  
98 101
	/**
99 102
	 * Returns an instance of {@link DataServerExplorer} given its parameters.
100
	 * 
103
	 *
101 104
	 * @param parameters
102
	 * 			parameters used to instantiate and initialize the {@link DataServerExplorer}.
105
	 *            parameters used to instantiate and initialize the
106
	 *            {@link DataServerExplorer}.
107
	 *
108
	 * @return an instance of {@link DataServerExplorer}.
109
	 *
110
	 * @throws InitializeException
103 111
	 * 
104
	 * @return
105
	 * 		an instance of {@link DataServerExplorer}.
106
	 * 
107
	 * @throws InitializeException
108
	 *
109 112
	 * @throws ProviderNotRegisteredException
113
	 * @throws ValidateDataParametersException
110 114
	 */
111 115
	public DataServerExplorer createServerExplorer(
112 116
			DataServerExplorerParameters parameters)
113
			throws InitializeException, ProviderNotRegisteredException;
117
			throws InitializeException, ProviderNotRegisteredException,
118
			ValidateDataParametersException;
114 119

  
115 120
	/**
116 121
	 * Returns a list of String containing the names of the available
117 122
	 * DataServerExplorer providers.
118
	 * 
123
	 *
119 124
	 * @return list of String containing the names of the available
120 125
	 *         DataServerExplorer providers.
121 126
	 */
......
123 128

  
124 129
	/*
125 130
	 * ====================================================================
126
	 * 
131
	 *
127 132
	 * Expression evaluation related services
128 133
	 */
129 134

  
130 135
	/**
131 136
	 * Registers the default expression evaluator. It is used by DAL to evaluate
132 137
	 * and resolve query filters and expressions.
133
	 * 
138
	 *
134 139
	 * @param evaluator
135 140
	 *            Class that will be called to evaluate the expression. It must
136 141
	 *            implement {@link Evaluator}.
......
139 144

  
140 145
	/**
141 146
	 * Creates an instance of Evaluator that represents the given expression.
142
	 * 
147
	 *
143 148
	 * @param expression
144 149
	 *            String containing a CQL expression.
145 150
	 * @return instance of Evaluator representing the given expression.
......
150 155

  
151 156
	/*
152 157
	 * ====================================================================
153
	 * 
158
	 *
154 159
	 * Index related services
155 160
	 */
156 161

  
......
158 163
	/**
159 164
	 * Returns a list of String containing the names of the available index providers.
160 165
	 *
161
	 * @return 
166
	 * @return
162 167
	 * 		list of strings with the names of the available index providers
163 168
	 */
164 169
	public List getFeatureIndexProviders();
165 170

  
166 171
	/**
167 172
	 * Sets the default DataIndexProvider for the given data type.
168
	 * 
169
	 * @param dataType 
173
	 *
174
	 * @param dataType
170 175
	 * 				one of the data types defined in {@link DataTypes}.
171
	 * @param name 
176
	 * @param name
172 177
	 * 			Provider's name
173 178
	 */
174 179
    public void setDefaultFeatureIndexProviderName(int dataType, String name);
......
176 181
	/**
177 182
	 * Returns the default DataIndexProvider name, given a data type. Data types
178 183
	 * are defined in {@link DataTypes}.
179
	 * 
184
	 *
180 185
	 * @param dataType
181 186
	 *            one of the constants in {@link DataTypes}.
182
	 *            
187
	 *
183 188
	 * @return
184
	 * 		the name of the default {@link FeatureIndexProvider} if there is 
189
	 * 		the name of the default {@link FeatureIndexProvider} if there is
185 190
	 * 		anyone available for the given data type.
186 191
	 */
187 192
    public String getDefaultFeatureIndexProviderName(int dataType);

Also available in: Unified diff