Statistics
| Revision:

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 @ 46723

History | View | Annotate | Download (23.5 KB)

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