svn-gvsig-desktop / trunk / org.gvsig.desktop / org.gvsig.desktop.compat.cdc / org.gvsig.fmap.dal / org.gvsig.fmap.dal.api / src / main / java / org / gvsig / fmap / dal / DataManager.java @ 46875
History | View | Annotate | Download (23.7 KB)
1 |
/**
|
---|---|
2 |
* gvSIG. Desktop Geographic Information System.
|
3 |
*
|
4 |
* Copyright (C) 2007-2013 gvSIG Association.
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or modify it under
|
7 |
* the terms of the GNU General Public License as published by the Free Software
|
8 |
* Foundation; either version 3 of the License, or (at your option) any later
|
9 |
* version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful, but WITHOUT
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
13 |
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
14 |
* details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License along with
|
17 |
* this program; if not, write to the Free Software Foundation, Inc., 51
|
18 |
* Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
19 |
*
|
20 |
* For any additional information, do not hesitate to contact us at info AT
|
21 |
* gvsig.com, or visit our website www.gvsig.com.
|
22 |
*/
|
23 |
package org.gvsig.fmap.dal; |
24 |
|
25 |
import java.io.File; |
26 |
import java.util.List; |
27 |
import java.util.Map; |
28 |
import java.util.Set; |
29 |
import java.util.function.Predicate; |
30 |
import javax.json.JsonObject; |
31 |
import org.gvsig.expressionevaluator.Expression; |
32 |
import org.gvsig.expressionevaluator.ExpressionBuilder; |
33 |
|
34 |
import org.gvsig.fmap.dal.exception.DataException; |
35 |
import org.gvsig.fmap.dal.exception.InitializeException; |
36 |
import org.gvsig.fmap.dal.exception.ProviderNotRegisteredException; |
37 |
import org.gvsig.fmap.dal.exception.ValidateDataParametersException; |
38 |
import org.gvsig.fmap.dal.expressionevaluator.DALExpressionBuilder; |
39 |
import org.gvsig.fmap.dal.expressionevaluator.FeatureSymbolTable; |
40 |
import org.gvsig.fmap.dal.feature.EditableFeatureType; |
41 |
import org.gvsig.fmap.dal.feature.Feature; |
42 |
import org.gvsig.fmap.dal.feature.FeatureIndex; |
43 |
import org.gvsig.fmap.dal.feature.FeatureQuery; |
44 |
import org.gvsig.fmap.dal.feature.FeatureStore; |
45 |
import org.gvsig.fmap.dal.feature.FeatureType; |
46 |
import org.gvsig.fmap.dal.feature.paging.FeaturePagingHelper; |
47 |
import org.gvsig.fmap.dal.resource.ResourceManager; |
48 |
import org.gvsig.tools.dataTypes.DataType; |
49 |
import org.gvsig.tools.dynobject.DynObject; |
50 |
import org.gvsig.tools.dynobject.DynStruct; |
51 |
import org.gvsig.tools.dynobject.Tags; |
52 |
import org.gvsig.tools.evaluator.Evaluator; |
53 |
import org.gvsig.tools.exception.BaseException; |
54 |
import org.gvsig.tools.service.spi.Services; |
55 |
import org.gvsig.fmap.dal.expressionevaluator.FeatureAttributeEmulatorExpression; |
56 |
import org.gvsig.fmap.dal.feature.DataProfile; |
57 |
import org.gvsig.fmap.dal.feature.EditableFeature; |
58 |
import org.gvsig.fmap.dal.feature.EditableFeatureAttributeDescriptor; |
59 |
import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor; |
60 |
import org.gvsig.fmap.dal.feature.FeatureRuleExpression; |
61 |
import org.gvsig.fmap.dal.feature.FeatureSet; |
62 |
import org.gvsig.tools.observer.Observer; |
63 |
import org.gvsig.tools.resourcesstorage.ResourcesStorage; |
64 |
import org.gvsig.tools.util.Factory; |
65 |
|
66 |
/**
|
67 |
* There are two top level management roles within DAL: data access and resource
|
68 |
* management.
|
69 |
*
|
70 |
* This class is responsible of the data access management role. It provides
|
71 |
* ways for registering and instantiating {@link DataServerExplorer}(s),
|
72 |
* {@link DataStore}(s), {@link Evaluator}(s) and {@link FeatureIndex}(es).
|
73 |
*
|
74 |
* @see ResourceManager
|
75 |
*
|
76 |
*/
|
77 |
public interface DataManager extends Services { |
78 |
|
79 |
public static final int RECOMENDED_SIZE_FOR_CLOB = 4096; |
80 |
|
81 |
public static final String CREATE_STORE_AUTHORIZATION = "dal-create-store"; |
82 |
public static final String READ_STORE_AUTHORIZATION = "dal-read-store"; |
83 |
public static final String WRITE_STORE_AUTHORIZATION = "dal-write-store"; |
84 |
|
85 |
public static final String DAL_SYMBOL_TABLE = "DAL.SymbolTable.Global"; |
86 |
// public static final String DAL_SYMBOL_TABLE_FEATURE = "DAL.SymbolTable.Feature";
|
87 |
|
88 |
public static final String FUNCTION_FOREING_VALUE = "FOREING_VALUE"; |
89 |
public static final String FUNCTION_FOREIGN_VALUE = "FOREIGN_VALUE"; |
90 |
public static final String FUNCTION_SELECT = "SELECT"; |
91 |
public static final String FUNCTION_UPDATE = "UPDATE"; |
92 |
public static final String FUNCTION_SELECT_COUNT = "SELECT_COUNT"; |
93 |
public static final String FUNCTION_EXISTS = "EXISTS"; |
94 |
public static final String FUNCTION_EXISTS_TABLE = "EXISTS_TABLE"; |
95 |
public static final String FUNCTION_ROW_TAG = "ROW_TAG"; |
96 |
public static final String FUNCTION_SET_ROW_TAG = "SET_ROW_TAG"; |
97 |
public static final String FUNCTION_CURRENT_ROW = "CURRENT_ROW"; |
98 |
public static final String FUNCTION_CURRENT_STORE = "CURRENT_STORE"; |
99 |
public static final String FUNCTION_ISSELECTED_CURRENT_ROW = "ISSELECTED_CURRENT_ROW"; |
100 |
public static final String FUNCTION_GEOMETRY = "GEOMETRY"; |
101 |
public static final String FUNCTION_CREATE_IN_MEMORY_TABLE = "CREATE_IN_MEMORY_TABLE"; |
102 |
public static final String FUNCTION_INSERT_INTO_TABLE = "INSERT_INTO_TABLE"; |
103 |
public static final String FUNCTION_CREATE_TABLE = "CREATE_TABLE"; |
104 |
public static final String FUNCTION_CREATE_TABLE_STRUCTURE = "CREATE_TABLE_STRUCTURE"; |
105 |
public static final String FUNCTION_SELECT_FROM_SELECTION = "SELECTFROMSELECTION"; |
106 |
public static final String FUNCTION_SELECT_COUNT_FROM_SELECTION = "SELECTCOUNTFROMSELECTION"; |
107 |
|
108 |
public static final String DAL_PREFERRED_COLUMNS = "DAL.Preferred.Columns"; |
109 |
|
110 |
public static final String DAL_USE_LABELS = "DAL.useLabels"; |
111 |
|
112 |
public static final String DAL_USE_LARGE_SELECTION = "DAL.useLargeSelection"; |
113 |
public static final String DAL_STORE_ENVELOPE = "DAL.forcedEnvelope"; |
114 |
public static final String DAL_FEATURETYPE_MODE_EDIT = "DAL.featureTypeEditMode"; |
115 |
public static final String DAL_FEATURETYPE_MODE_EDIT_MSG = "DAL.featureTypeEditMode.msg"; |
116 |
|
117 |
public static final int USE_LABELS_YES = 0; |
118 |
public static final int USE_LABELS_NO = 1; |
119 |
public static final int USE_LABELS_BOTH = 2; |
120 |
|
121 |
/**
|
122 |
*
|
123 |
* Returns the default DAL's temporary directory
|
124 |
*
|
125 |
* @return Temporary directory name
|
126 |
* @deprecated use FoldersManager of org.gvsig.tools
|
127 |
*/
|
128 |
public String getTemporaryDirectory(); |
129 |
|
130 |
/*
|
131 |
* ====================================================================
|
132 |
*
|
133 |
* Store related services
|
134 |
*/
|
135 |
/**
|
136 |
* Creates, initializes and returns an instance of DataStoreParameters given
|
137 |
* the name with which their provider is registered.
|
138 |
*
|
139 |
* @param name provider name
|
140 |
* @param arguments
|
141 |
* @return the data store parameters
|
142 |
*
|
143 |
* @throws ProviderNotRegisteredException if the memory provider is not
|
144 |
* registered
|
145 |
* @throws InitializeException if there is an error initializing the
|
146 |
* parameters for the memory provider
|
147 |
*
|
148 |
*/
|
149 |
public DataStoreParameters createStoreParameters(String name, Object... arguments) |
150 |
throws InitializeException, ProviderNotRegisteredException;
|
151 |
|
152 |
public DataStoreParameters createStoreParameters(String name) |
153 |
throws InitializeException, ProviderNotRegisteredException;
|
154 |
|
155 |
public DataStoreParameters createStoreParameters(byte[] data); |
156 |
|
157 |
/**
|
158 |
* Creates, initializes and fill an instance of DataStoreParameters from the
|
159 |
* tags of the DynStruct passed as parameter.
|
160 |
*
|
161 |
* @param struct structure from which tags were created ths parameters.
|
162 |
* @return the data store parameters
|
163 |
*
|
164 |
* @throws ProviderNotRegisteredException if the memory provider is not
|
165 |
* registered
|
166 |
* @throws InitializeException if there is an error initializing the
|
167 |
* parameters for the memory provider
|
168 |
*
|
169 |
*/
|
170 |
public DataStoreParameters createStoreParameters(DynStruct struct)
|
171 |
throws InitializeException, ProviderNotRegisteredException;
|
172 |
|
173 |
public DataStoreParameters createStoreParameters(Tags tags) throws InitializeException, ProviderNotRegisteredException; |
174 |
|
175 |
/**
|
176 |
* Creates, initializes and returns an instance of NewDataStoreParameters
|
177 |
* given the name with which their provider is registered.
|
178 |
*
|
179 |
* @param explorer
|
180 |
* @param provider
|
181 |
* @return
|
182 |
*
|
183 |
* @throws InitializeException
|
184 |
* @throws ProviderNotRegisteredException
|
185 |
*/
|
186 |
public NewDataStoreParameters createNewStoreParameters(String explorer, String provider) |
187 |
throws InitializeException, ProviderNotRegisteredException;
|
188 |
|
189 |
public NewDataStoreParameters createNewStoreParameters(String provider) |
190 |
throws InitializeException, ProviderNotRegisteredException;
|
191 |
|
192 |
/**
|
193 |
*
|
194 |
* Creates, initializes and returns an instance of DataStore given the
|
195 |
* DataStoreParameters.
|
196 |
*
|
197 |
* @param provider
|
198 |
* @param parameters parameters used to instantiate and initialize the
|
199 |
* DataStore
|
200 |
* @return
|
201 |
*
|
202 |
* @throws ProviderNotRegisteredException if the memory provider is not
|
203 |
* registered
|
204 |
* @throws InitializeException if there is an error initializing the
|
205 |
* parameters for the memory provider
|
206 |
* @throws ValidateDataParametersException if the parameters to open the
|
207 |
* memory based store are not valid
|
208 |
*/
|
209 |
public DataStore openStore(String provider, DynObject parameters) |
210 |
throws InitializeException, ProviderNotRegisteredException,
|
211 |
ValidateDataParametersException; |
212 |
|
213 |
public DataStore openStore(String provider, DataStoreParameters parameters) |
214 |
throws InitializeException, ProviderNotRegisteredException,
|
215 |
ValidateDataParametersException; |
216 |
|
217 |
public DataStore openStore(String providerName, DataStoreParameters |
218 |
parameters, boolean ignoreDALResource)
|
219 |
throws InitializeException, ProviderNotRegisteredException,
|
220 |
ValidateDataParametersException; |
221 |
|
222 |
public DataStore openStore(
|
223 |
String providerName,
|
224 |
Object... arguments)
|
225 |
throws
|
226 |
InitializeException, |
227 |
ProviderNotRegisteredException, |
228 |
ValidateDataParametersException; |
229 |
|
230 |
public DataStore openStore(DynStruct struct)
|
231 |
throws InitializeException, ProviderNotRegisteredException, ValidateDataParametersException;
|
232 |
|
233 |
/**
|
234 |
* Create a new physical store
|
235 |
*
|
236 |
* @param explorer
|
237 |
* @param provider
|
238 |
* @param parameters
|
239 |
* @param overwrite
|
240 |
*
|
241 |
* @throws InitializeException
|
242 |
* @throws ProviderNotRegisteredException
|
243 |
* @throws ValidateDataParametersException
|
244 |
*/
|
245 |
public void newStore(String explorer, String provider, NewDataStoreParameters parameters, boolean overwrite) |
246 |
throws InitializeException, ProviderNotRegisteredException,
|
247 |
ValidateDataParametersException; |
248 |
|
249 |
public void newStore(String provider, NewDataStoreParameters parameters, boolean overwrite) |
250 |
throws InitializeException, ProviderNotRegisteredException,
|
251 |
ValidateDataParametersException; |
252 |
|
253 |
/**
|
254 |
* Returns a list of Strings containing the names of all available DataStore
|
255 |
* providers.
|
256 |
*
|
257 |
* @return list of String containing available DataStore provider names
|
258 |
*/
|
259 |
public List getStoreProviders(); |
260 |
|
261 |
/**
|
262 |
* Returns a list of Strings containing the names of all available DataStore
|
263 |
* providers for an explorer.
|
264 |
*
|
265 |
* @param name
|
266 |
* @return
|
267 |
*/
|
268 |
public List<String> getStoreProviders(String name); |
269 |
|
270 |
/*
|
271 |
* ====================================================================
|
272 |
*
|
273 |
* Explorer related services
|
274 |
*/
|
275 |
/**
|
276 |
* Returns an instance of {@link DataServerExplorerParameters} corresponding
|
277 |
* to the given name.
|
278 |
*
|
279 |
* @param name name of a registered server explorer provider
|
280 |
* @return
|
281 |
*
|
282 |
* @throws InitializeException if parameter initialization causes an error.
|
283 |
*
|
284 |
* @throws ProviderNotRegisteredException if could not find a provider by
|
285 |
* the given name.
|
286 |
*
|
287 |
*
|
288 |
*/
|
289 |
public DataServerExplorerParameters createServerExplorerParameters(
|
290 |
String name)
|
291 |
throws InitializeException, ProviderNotRegisteredException;
|
292 |
|
293 |
/**
|
294 |
* Returns an instance of {@link DataServerExplorer} given its parameters.
|
295 |
*
|
296 |
* @param name
|
297 |
* @param parameters parameters used to instantiate and initialize the
|
298 |
* {@link DataServerExplorer}.
|
299 |
*
|
300 |
* @return an instance of {@link DataServerExplorer}.
|
301 |
*
|
302 |
* @throws InitializeException
|
303 |
*
|
304 |
* @throws ProviderNotRegisteredException
|
305 |
* @throws ValidateDataParametersException
|
306 |
*/
|
307 |
public DataServerExplorer openServerExplorer(
|
308 |
String name,
|
309 |
DataServerExplorerParameters parameters) |
310 |
throws InitializeException, ProviderNotRegisteredException,
|
311 |
ValidateDataParametersException; |
312 |
|
313 |
public DataServerExplorer openServerExplorer(
|
314 |
String explorerName,
|
315 |
Object... arguments)
|
316 |
throws
|
317 |
InitializeException, |
318 |
ProviderNotRegisteredException, |
319 |
ValidateDataParametersException; |
320 |
/**
|
321 |
* @param parameters
|
322 |
* @return
|
323 |
* @throws org.gvsig.fmap.dal.exception.InitializeException
|
324 |
* @throws org.gvsig.fmap.dal.exception.ProviderNotRegisteredException
|
325 |
* @throws org.gvsig.fmap.dal.exception.ValidateDataParametersException
|
326 |
* @deprecated see openServerExplorer
|
327 |
*/
|
328 |
public DataServerExplorer createServerExplorer(
|
329 |
DataServerExplorerParameters parameters) |
330 |
throws InitializeException, ProviderNotRegisteredException,
|
331 |
ValidateDataParametersException; |
332 |
|
333 |
/**
|
334 |
* @param parameters
|
335 |
* @return
|
336 |
* @throws org.gvsig.fmap.dal.exception.InitializeException
|
337 |
* @throws org.gvsig.fmap.dal.exception.ProviderNotRegisteredException
|
338 |
* @throws org.gvsig.fmap.dal.exception.ValidateDataParametersException
|
339 |
* @deprecated see openStore
|
340 |
*/
|
341 |
public DataStore createStore(DataStoreParameters parameters)
|
342 |
throws InitializeException, ProviderNotRegisteredException,
|
343 |
ValidateDataParametersException; |
344 |
|
345 |
/**
|
346 |
* Returns a list of String containing the names of the available
|
347 |
* DataServerExplorer providers.
|
348 |
*
|
349 |
* @return list of String containing the names of the available
|
350 |
* DataServerExplorer providers.
|
351 |
*/
|
352 |
public List<String> getExplorerProviders(); |
353 |
|
354 |
/**
|
355 |
* Creates an instance of Evaluator that represents the given expression.
|
356 |
*
|
357 |
* @param expression String containing a CQL expression.
|
358 |
* @return instance of Evaluator representing the given expression.
|
359 |
* @throws InitializeException
|
360 |
* @deprecated use createFilter
|
361 |
*/
|
362 |
public Evaluator createExpresion(String expression) |
363 |
throws InitializeException;
|
364 |
|
365 |
/**
|
366 |
* Creates an instance of Evaluator that represents the given expression.
|
367 |
*
|
368 |
* @param expression a Expression with the filter
|
369 |
* @return instance of Evaluator representing the given expression.
|
370 |
* @throws InitializeException
|
371 |
* @deprecated use createFilter
|
372 |
*/
|
373 |
public Evaluator createExpresion(Expression expression) |
374 |
throws InitializeException;
|
375 |
|
376 |
/**
|
377 |
* Creates an instance of Evaluator that represents the given expression.
|
378 |
*
|
379 |
* @param expression String containing a CQL expression.
|
380 |
* @return instance of Evaluator representing the given expression.
|
381 |
* @throws InitializeException
|
382 |
*/
|
383 |
public Evaluator createFilter(String expression) |
384 |
throws InitializeException;
|
385 |
|
386 |
/**
|
387 |
* Creates an instance of Evaluator that represents the given expression.
|
388 |
*
|
389 |
* @param expression a Expression with the filter
|
390 |
* @return instance of Evaluator representing the given expression.
|
391 |
* @throws InitializeException
|
392 |
*/
|
393 |
public Evaluator createFilter(Expression expression) |
394 |
throws InitializeException;
|
395 |
|
396 |
/*
|
397 |
* ====================================================================
|
398 |
*
|
399 |
* Index related services
|
400 |
*/
|
401 |
/**
|
402 |
* Returns a list of String containing the names of the available index
|
403 |
* providers.
|
404 |
*
|
405 |
* @return list of strings with the names of the available index providers
|
406 |
*/
|
407 |
public List<String> getFeatureIndexProviders(); |
408 |
|
409 |
/**
|
410 |
* Sets the default DataIndexProvider for the given data type.
|
411 |
*
|
412 |
* @param dataType one of the data types defined in {@link DataTypes}.
|
413 |
* @param name Provider's name
|
414 |
*/
|
415 |
public void setDefaultFeatureIndexProviderName(int dataType, String name); |
416 |
|
417 |
/**
|
418 |
* Returns the default DataIndexProvider name, given a data type. Data types
|
419 |
* are defined in {@link DataTypes}.
|
420 |
*
|
421 |
* @param dataType one of the constants in {@link DataTypes}.
|
422 |
*
|
423 |
* @return the name of the default {@link FeatureIndexProvider} if there is
|
424 |
* anyone available for the given data type.
|
425 |
*/
|
426 |
public String getDefaultFeatureIndexProviderName(int dataType); |
427 |
|
428 |
/**
|
429 |
* Utility method to create the {@link DataStoreParameters} to create a
|
430 |
* {@link FeatureStore} based on the {@link MemoryStoreProvider}.
|
431 |
*
|
432 |
* @param autoOrderAttributeName the name of the {@link Feature} attribute
|
433 |
* to be used to order the store {@link Feature}s by default. Set to null if
|
434 |
* you don't want any order by default
|
435 |
* @return the parameters for the memory based store
|
436 |
* @throws InitializeException if there is an error initializing the
|
437 |
* parameters for the memory provider
|
438 |
*/
|
439 |
public DataStoreParameters createMemoryStoreParameters(
|
440 |
String autoOrderAttributeName) throws InitializeException; |
441 |
|
442 |
/**
|
443 |
* Utility method to create the a {@link FeatureStore} based on the
|
444 |
* {@link MemoryStoreProvider}.
|
445 |
*
|
446 |
* @param autoOrderAttributeName the name of the {@link Feature} attribute
|
447 |
* to be used to order the store {@link Feature}s by default. Set to null if
|
448 |
* you don't want any order by default
|
449 |
* @return the the memory based store
|
450 |
* @throws InitializeException if there is an error initializing the
|
451 |
* parameters for the memory provider
|
452 |
*/
|
453 |
public FeatureStore createMemoryStore(String autoOrderAttributeName) |
454 |
throws InitializeException;
|
455 |
|
456 |
/**
|
457 |
* Creates a {@link FeaturePagingHelper} to paginate data from a
|
458 |
* {@link FeatureStore}.
|
459 |
*
|
460 |
* @param featureStore to get the {@link Feature}s from
|
461 |
* @param pageSize the page size
|
462 |
* @return a {@link FeaturePagingHelper}
|
463 |
* @throws BaseException if there is an error creating the helper
|
464 |
*/
|
465 |
public FeaturePagingHelper createFeaturePagingHelper(
|
466 |
FeatureStore featureStore, int pageSize) throws BaseException; |
467 |
|
468 |
/**
|
469 |
* Creates a {@link FeaturePagingHelper} to paginate data from a
|
470 |
* {@link FeatureStore}.
|
471 |
*
|
472 |
* @param featureStore to get the {@link Feature}s from
|
473 |
* @param featureQuery to filter and/or order the data
|
474 |
* @param pageSize the page size
|
475 |
* @return a {@link FeaturePagingHelper}
|
476 |
* @throws BaseException if there is an error creating the helper
|
477 |
*/
|
478 |
public FeaturePagingHelper createFeaturePagingHelper(
|
479 |
FeatureStore featureStore, FeatureQuery featureQuery, int pageSize)
|
480 |
throws BaseException;
|
481 |
|
482 |
public void setOpenErrorHandler(OpenErrorHandler handler); |
483 |
|
484 |
public OpenErrorHandler getOpenErrorHandler();
|
485 |
|
486 |
public DataStoreProviderFactory getStoreProviderFactory(String name); |
487 |
|
488 |
public EditableFeatureType createFeatureType();
|
489 |
|
490 |
public EditableFeatureType createFeatureType(JsonObject json);
|
491 |
|
492 |
public DataServerExplorerPool getDataServerExplorerPool();
|
493 |
|
494 |
public void setDataServerExplorerPool(DataServerExplorerPool pool); |
495 |
|
496 |
public void setResourcesLoader(ClassLoader loader); |
497 |
|
498 |
public void setResourcesLoader(File folder); |
499 |
|
500 |
/**
|
501 |
* Return a list of the DataTypes supported for the type of the feature
|
502 |
* attributes. The list is only informative.
|
503 |
*
|
504 |
* @return
|
505 |
*/
|
506 |
public List<DataType> getDataTypes(); |
507 |
|
508 |
public Register getStoreRegister();
|
509 |
|
510 |
public Register getStoreProviderRegister();
|
511 |
|
512 |
public Register getServerExplorerRegister();
|
513 |
|
514 |
public Register getFeatureIndexRegister();
|
515 |
|
516 |
/**
|
517 |
* Creates a default ExpressionBuilder.
|
518 |
*
|
519 |
* This ExpressionBuilder is not dependent on a data source,
|
520 |
* and is not advisable to use it.
|
521 |
*
|
522 |
* @return the ExpressionBuilder
|
523 |
* @deprecated use ExpressionEvaluatorManager.createExpressionBuilder()
|
524 |
*/
|
525 |
public ExpressionBuilder createExpressionBuilder();
|
526 |
|
527 |
/**
|
528 |
* Returns a list of String containing the names of the available cache providers.
|
529 |
*
|
530 |
* @return
|
531 |
* list of strings with the names of the available cache providers
|
532 |
*/
|
533 |
public List getFeatureCacheProviders(); |
534 |
|
535 |
/**
|
536 |
* Returns an instance of {@link DataServerExplorerParameters} corresponding
|
537 |
* to the given name used by the cache to create a store to save the
|
538 |
* retrieved data.
|
539 |
*
|
540 |
* @param name
|
541 |
* name of a registered feature cache provider
|
542 |
* @return
|
543 |
*
|
544 |
* @throws InitializeException
|
545 |
* if parameter initialization causes an error.
|
546 |
*
|
547 |
* @throws ProviderNotRegisteredException
|
548 |
* if could not find a cache provider by the given name.
|
549 |
*
|
550 |
*/
|
551 |
public DynObject createCacheParameters(String name) |
552 |
throws InitializeException, ProviderNotRegisteredException;
|
553 |
|
554 |
/**
|
555 |
* @param providerName
|
556 |
* @param params
|
557 |
* @param overwrite
|
558 |
* @throws DataException
|
559 |
*/
|
560 |
public void createFileStore(String providerName, NewDataStoreParameters params, boolean overwrite) throws DataException; |
561 |
|
562 |
public FeatureSymbolTable createFeatureSymbolTable();
|
563 |
|
564 |
public FeatureSymbolTable createFeatureSymbolTable(String name); |
565 |
|
566 |
public EditableFeatureAttributeDescriptor createFeatureAttributeDescriptor(String name, int type); |
567 |
|
568 |
public FeatureAttributeEmulatorExpression createFeatureAttributeEmulatorExpression(FeatureType type, Expression expression); |
569 |
|
570 |
public void registerDataProfile(DataProfile profile); |
571 |
|
572 |
public List<DataProfile> getDataProfiles(); |
573 |
|
574 |
public DataProfile getDataProfile(String name); |
575 |
|
576 |
public StoresRepository getStoresRepository();
|
577 |
|
578 |
public DatabaseWorkspaceManager createDatabaseWorkspaceManager(DataServerExplorerParameters connection);
|
579 |
|
580 |
public void addDatabaseWorkspace(DatabaseWorkspaceManager DatabaseWorkspace); |
581 |
|
582 |
public void removeDatabaseWorkspace(DatabaseWorkspaceManager DatabaseWorkspace); |
583 |
|
584 |
public void addDatabaseWorkspaceListener(DatabaseWorkspaceManager.DatabaseWorkspaceListener listener); |
585 |
|
586 |
public DatabaseWorkspaceManager getDatabaseWorkspace(String name); |
587 |
|
588 |
public DatabaseWorkspaceManager getDatabaseWorkspace(DataStoreParameters params);
|
589 |
|
590 |
public DatabaseWorkspaceManager getDatabaseWorkspace(DataServerExplorerParameters params);
|
591 |
|
592 |
public void writeDALResource(ResourcesStorage resources, DataStore store); |
593 |
|
594 |
public void writeDALResource(ResourcesStorage resources, FeatureType featureType); |
595 |
|
596 |
/**
|
597 |
* Return a 35-40 characters unique identifier.
|
598 |
*
|
599 |
* @return the unique identifier
|
600 |
*/
|
601 |
public String createUniqueID(); |
602 |
|
603 |
public void clearAvailableValuesCache(); |
604 |
|
605 |
public DALExpressionBuilder createDALExpressionBuilder();
|
606 |
|
607 |
public boolean isTheOldRasterRegistered(); |
608 |
|
609 |
public void addStoreObserver(Observer observer); |
610 |
|
611 |
public void removeStoreObserver(Observer observer); |
612 |
|
613 |
public String getServerExplorerFromStore(String name); |
614 |
|
615 |
public void setMaxSizeForSmallFeatureSelection(long size); |
616 |
|
617 |
public long getMaxSizeForSmallFeatureSelection(); |
618 |
|
619 |
public void registerLargeMap(Factory factory); |
620 |
|
621 |
public void registerLargeSet(Factory factory); |
622 |
|
623 |
public Map createLargeMap(); |
624 |
|
625 |
public Set createLargeSet(); |
626 |
|
627 |
public DataTransaction createTransaction();
|
628 |
|
629 |
public void putFeaturesInClipboard(FeatureSet set); |
630 |
|
631 |
public List<EditableFeature> getFeaturesFromClipboard( |
632 |
FeatureStore store, |
633 |
Predicate<FeatureAttributeDescriptor> attrFilter
|
634 |
) throws DataException;
|
635 |
|
636 |
public FeatureRuleExpression createFeatureRuleExpression();
|
637 |
|
638 |
public DataFactory getStoreFactory(DataStoreParameters parameters);
|
639 |
|
640 |
public File getCacheResourcesFolder(); |
641 |
|
642 |
public void clearAllCachedResources(); |
643 |
} |