Package org.gvsig.fmap.dal
Interface DatabaseWorkspaceManager
- All Superinterfaces:
Cloneable,org.gvsig.tools.lang.Cloneable,Iterable<org.gvsig.expressionevaluator.Function>,org.gvsig.tools.util.LabeledValue<DatabaseWorkspaceManager>,SupportTransactions,org.gvsig.expressionevaluator.SymbolTable
public interface DatabaseWorkspaceManager
extends org.gvsig.tools.util.LabeledValue<DatabaseWorkspaceManager>, org.gvsig.expressionevaluator.SymbolTable, SupportTransactions
- Author:
- jjdelcerro
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interface -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final intstatic final Stringstatic final intstatic final Stringstatic final intstatic final String -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidconnect()voidCreate and initialize the tables associated with a gvSIG workspace.voidcreateTable(int tableid) Create the configuration table indicated in the workspace.voidcreateTableRepository(String tableName) voidcreateTableResources(String tableName) voidvoiddrop()voiddropTable(int tableid) Remove the indicated configuration table from the workspace.booleanexistsTable(int tableid) Check if the indicated configuration table exists in the workspace.Gets the value of a configuration variable associated with this work space.org.gvsig.tools.resourcesstorage.ResourcesStoragegetAlternativeResourcesStorage(String tableName) If the workspace has an alternate resource storage defined, return it.getId()Returns the identifier of this workspace.getLabel()Returns the label of this workspace.org.gvsig.tools.resourcesstorage.ResourcesStorageGets the repository of data stores associated with this workspace.getTable(int tableid) Gets the data store associated with the indicated configuration table.booleanbooleanstatic booleanisInternalTable(String name) Check if the indicated name corresponds to one of the configuration tables of the workspace.booleanisValid()Returns true if the connection associated with this object refers to a valid workspace.booleanReturns true if the connection associated with this object refers to a valid workspace with a stores-repository.booleanAssigns the indicated value to the configuration variable.voidsetAlternativeResourcesStorage(String resourcesPath) voidsetBaseFolder(File baseFolder) booleanwriteStoresRepositoryEntry(String name, DataStoreParameters parameters) Add a new data store to the workspace.booleanwriteStoresRepositoryEntry(String name, DataStoreParameters parameters, org.gvsig.tools.util.Bitmask mask) Methods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface org.gvsig.tools.util.LabeledValue
getValue, toStringMethods inherited from interface org.gvsig.fmap.dal.SupportTransactions
getTransaction, setTransactionMethods inherited from interface org.gvsig.expressionevaluator.SymbolTable
addSymbolTable, clone, containsSymbolTable, exists, function, functions, getName, isSQLCompatible, localfunctions, localvariables, removeSymbolTable, value, variables
-
Field Details
-
CONFIG_CAN_ANONYMOUS_USER_WRITE_IN_THE_TABLES
- See Also:
-
TABLE_REPOSITORY_NAME
- See Also:
-
TABLE_RESOURCES_NAME
- See Also:
-
TABLE_CONFIGURATION_NAME
- See Also:
-
FIELD_RESOURCES_NAME
- See Also:
-
FIELD_RESOURCES_RESOURCE
- See Also:
-
FIELD_REPOSITORY_NAME
- See Also:
-
FIELD_REPOSITORY_PARAMETERS
- See Also:
-
FIELD_REPOSITORY_FLAGS
- See Also:
-
FIELD_REPOSITORY_EXTRA
- See Also:
-
FIELD_CONFIGURATION_NAME
- See Also:
-
FIELD_CONFIGURATION_VALUE
- See Also:
-
TABLE_RESOURCES
static final int TABLE_RESOURCES- See Also:
-
TABLE_REPOSITORY
static final int TABLE_REPOSITORY- See Also:
-
TABLE_CONFIGURATION
static final int TABLE_CONFIGURATION- See Also:
-
CONFIG_NAME_STORESREPOSITORYID
- See Also:
-
CONFIG_NAME_STORESREPOSITORYLABEL
- See Also:
-
-
Method Details
-
isInternalTable
Check if the indicated name corresponds to one of the configuration tables of the workspace.- Parameters:
name- to check.- Returns:
- true if the name is that of a configuration table.
-
getId
String getId()Returns the identifier of this workspace.- Returns:
- the id.
-
getServerExplorer
DataServerExplorer getServerExplorer() -
getServerExplorerParameters
DataServerExplorerParameters getServerExplorerParameters() -
getLabel
String getLabel()Returns the label of this workspace.- Specified by:
getLabelin interfaceorg.gvsig.tools.util.LabeledValue<DatabaseWorkspaceManager>- Returns:
- the label value.
-
get
Gets the value of a configuration variable associated with this work space.- Parameters:
name- of the variable to consult- Returns:
- the value of the variable
-
set
Assigns the indicated value to the configuration variable.- Parameters:
name- of the variable.value- value to set.- Returns:
- true if can assign the value.
-
getStoresRepository
StoresRepository getStoresRepository()Gets the repository of data stores associated with this workspace.- Returns:
- the data stores repository.
-
writeStoresRepositoryEntry
Add a new data store to the workspace.- Parameters:
name- of the data store.parameters- to open the data store.- Returns:
- true if ok.
-
writeStoresRepositoryEntry
boolean writeStoresRepositoryEntry(String name, DataStoreParameters parameters, org.gvsig.tools.util.Bitmask mask) -
canAnonymousUserWriteInTheTables
boolean canAnonymousUserWriteInTheTables() -
existsTable
boolean existsTable(int tableid) Check if the indicated configuration table exists in the workspace.- Parameters:
tableid-- Returns:
- true if the table exists.
-
createTable
void createTable(int tableid) Create the configuration table indicated in the workspace.- Parameters:
tableid- identifier of the configuration table to create.
-
dropTable
void dropTable(int tableid) Remove the indicated configuration table from the workspace.- Parameters:
tableid- identifier of the configuration table to remove.
-
getTable
Gets the data store associated with the indicated configuration table.- Parameters:
tableid- identifier of the configuration table to get.- Returns:
- the FeatureStore of the configuration table.
-
isValid
boolean isValid()Returns true if the connection associated with this object refers to a valid workspace. At least the variable "StoresRepository.id" must be defined.- Returns:
-
isValidStoresRepository
boolean isValidStoresRepository()Returns true if the connection associated with this object refers to a valid workspace with a stores-repository. At least the repositories table must exist and the variable "StoresRepository.id" must be defined.- Returns:
-
getAlternativeResourcesStorage
If the workspace has an alternate resource storage defined, return it. If don't have it, return null.- Parameters:
tableName-- Returns:
- the alternate resource storage.
-
hasAlternativeResourcesStorage
boolean hasAlternativeResourcesStorage() -
setAlternativeResourcesStorage
-
create
Create and initialize the tables associated with a gvSIG workspace.- Parameters:
id- of the workspacedescription- of the workspace
-
drop
void drop() -
getBaseFolder
File getBaseFolder() -
setBaseFolder
-
getResourcesStorage
org.gvsig.tools.resourcesstorage.ResourcesStorage getResourcesStorage() -
connect
void connect() -
disconnect
void disconnect() -
createTableRepository
-
createTableResources
-
isConnected
boolean isConnected() -
getLabelOrId
String getLabelOrId()
-