Package org.gvsig.fmap.dal.store.db
Interface DBStoreParameters
- All Superinterfaces:
DataParameters,DataStoreParameters,DBConnectionParameter,DBParameters,org.gvsig.tools.dynobject.DynObject,OpenDataStoreParameters,OpenFeatureStoreParameters,org.gvsig.tools.persistence.Persistent,org.gvsig.json.SupportFromJson,org.gvsig.json.SupportToJson
- All Known Subinterfaces:
JDBCStoreParameters
- Author:
- fdiaz
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringParameter name forinitial filterstatic final StringParameter name forinitial orderstatic final StringParameter name fordefault geometrystatic final StringParameter name forfieldsstatic final StringParameter name forGeometrySubtypestatic final StringParameter name forGeometryTypestatic final Stringstatic final StringParameter name forpk fieldsstatic final StringParameter name forsqlstatic final StringParameter name for the name oftablestatic final StringParameter name forworking area
OFields inherited from interface org.gvsig.fmap.dal.DataParameters
CRS_PARAMTER_NAMEFields inherited from interface org.gvsig.fmap.dal.resource.db.DBParameters
DBNAME_PARAMTER_NAME, HOST_PARAMTER_NAME, PASSWORD_PARAMTER_NAME, PORT_PARAMTER_NAME, USER_PARAMTER_NAME -
Method Summary
Modifier and TypeMethodDescriptionGet initial filter to use.
This filter is passed to BD provider on each request as a base filter.Get initial order to use.
This order is used if no custom order is request in query.org.gvsig.crs.projection.lib.ProjectiongetCRS()Get the SRS id string set manually for thedefault geometryfield of this layer.
if is set tonullmeans that the library must detect it automatically.
Supported only for stores with geometric fields.Returns the DataStore's nameReturn the value ofdata base nameparameterReturn the geometry field to use like default geometry (seeFeature.getDefaultGeometry())
This option is supported only in geometry providers.
If this parameters is not set and store has only one field geometry then library uses that field as defaultReturns the DataStore's descriptionString[]Get an array of the field names that we want to use.
Anullmeans that we want all fields available.Get a comma separated list of the field names that we want to use.
Anullor empty string means that we want all fields available.intintgetHost()Return the value ofhostparameterReturn the value ofpasswordparameterString[]Get an array of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()Get a comma separated list of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note:If this parameters is undefined, the library can't do this detection, some services will don't be available for this store (like selection, editing orFeature.getReference())getPort()Return the value ofportparametergetSQL()Get the SQL to use as source of the store instead a table or a view.
If this property is set the store changes his work flow: store is in read only mode.tableproperty is ignored.pkFieldsis not identified automatically filter and order will be resolved locally (pour performance)getTable()Gettableparameter value
This parameters describes what table or view we want to connect.
Not used ifsqlparameter set.getUser()Return the value ofuserparameterorg.gvsig.fmap.geom.primitive.EnvelopeGet the filter by area ofgetDefaultGeometryField()used in this store.
Supported only for stores with geometric fieldsbooleanisValid()Indicates whether these parameters are valid.voidsetBaseFilter(String filter) Set initial filter to use.
This filter is passed to BD provider on each request as a base filter.voidsetBaseOrder(String order) Set initial order to use.
This order is used if no custom order is request in query.voidvoidsetCRS(org.gvsig.crs.projection.lib.Projection srs) Set manually the SRS for thedefault geometryfield of this layer.
if is set tonullor empty string means that the library must detect it automatically.
Supported only for stores with geometric fields.voidSetdata base name/code> parameter valuevoidsetDefaultGeometryField(String geomName) Set the geometry field to use like default geometry.
SeegetDefaultGeometryField()for description.voidSet a comma separated list of the field names that we want to use.
Anullmeans that we want all fields available.voidSet an array of the field names that we want to use.
Anullmeans that we want all fields available.voidsetGeometrySubtype(int geometrySubtype) voidsetGeometryType(int geometryType) voidvoidsetPassword(String password) Setpassword/code> parameter valuevoidsetPkFields(String fields) Set a comma separated list of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()voidsetPkFields(String[] fields) Set an array of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()voidsetPort(int port) voidSetport/code> parameter valuevoidSet the SQL to use as source of the store instead a table or a view.
Note:seegetSQL()for descriptionvoidSettableparameter value
This parameters describes what table or view we want to connect.
Not used ifsqlparameter set.voidSetuser/code> parameter valuevoidsetWorkingArea(org.gvsig.fmap.geom.primitive.Envelope workingArea) Set the filter by area ofgetDefaultGeometryField()used in this store.
Supported only for stores with geometric fieldsMethods inherited from interface org.gvsig.fmap.dal.DataParameters
clear, getCopy, toByteArray, toString, validateMethods inherited from interface org.gvsig.fmap.dal.DataStoreParameters
getProviderName, getSourceId, isTheSameExplorer, isTheSameStoreMethods inherited from interface org.gvsig.tools.dynobject.DynObject
delegate, getDynClass, getDynValue, hasDynValue, implement, invokeDynMethod, invokeDynMethod, setDynValueMethods inherited from interface org.gvsig.tools.persistence.Persistent
loadFromState, saveToStateMethods inherited from interface org.gvsig.json.SupportFromJson
fromJsonMethods inherited from interface org.gvsig.json.SupportToJson
toJson, toJson, toJsonBuilder, toJsonBuilder
-
Field Details
-
BASEFILTER_PARAMTER_NAME
Parameter name forinitial filter- See Also:
-
BASEORDER_PARAMTER_NAME
Parameter name forinitial order- See Also:
-
DEFAULTGEOMETRY_PARAMTER_NAME
Parameter name fordefault geometry- See Also:
-
FIELDS_PARAMTER_NAME
Parameter name forfields- See Also:
-
GEOMETRYSUBTYPE_PARAMTER_NAME
Parameter name forGeometrySubtype- See Also:
-
GEOMETRYTYPE_PARAMTER_NAME
Parameter name forGeometryType- See Also:
-
PARAMETERS_DEFINITION_NAME
- See Also:
-
PKFIELDS_PARAMTER_NAME
Parameter name forpk fields- See Also:
-
SQL_PARAMTER_NAME
Parameter name forsql- See Also:
-
TABLE_PARAMTER_NAME
Parameter name for the name oftable- See Also:
-
WORKINGAREA_PARAMTER_NAME
Parameter name forworking area
O- See Also:
-
-
Method Details
-
getBaseFilter
String getBaseFilter()Get initial filter to use.
This filter is passed to BD provider on each request as a base filter.- Returns:
- filter
- See Also:
-
getBaseOrder
String getBaseOrder()Get initial order to use.
This order is used if no custom order is request in query.- Returns:
- order
- See Also:
-
getCRS
org.gvsig.crs.projection.lib.Projection getCRS()Get the SRS id string set manually for thedefault geometryfield of this layer.
if is set tonullmeans that the library must detect it automatically.
Supported only for stores with geometric fields.- Returns:
- See Also:
-
getDBName
String getDBName()Description copied from interface:DBParametersReturn the value ofdata base nameparameter- Specified by:
getDBNamein interfaceDBParameters- Returns:
-
getDataStoreName
String getDataStoreName()Description copied from interface:DataStoreParametersReturns the DataStore's name- Specified by:
getDataStoreNamein interfaceDataStoreParameters- Returns:
- a String containing the DataStore's name
-
getDefaultGeometryField
String getDefaultGeometryField()Return the geometry field to use like default geometry (seeFeature.getDefaultGeometry())
This option is supported only in geometry providers.
If this parameters is not set and store has only one field geometry then library uses that field as default- Returns:
- See Also:
-
getDescription
String getDescription()Description copied from interface:DataStoreParametersReturns the DataStore's description- Specified by:
getDescriptionin interfaceDataStoreParameters- Returns:
- a String containing the DataStore's description
-
getFields
String[] getFields()Get an array of the field names that we want to use.
Anullmeans that we want all fields available.- Returns:
- See Also:
-
getFieldsString
String getFieldsString()Get a comma separated list of the field names that we want to use.
Anullor empty string means that we want all fields available.- Returns:
- See Also:
-
getGeometrySubtype
int getGeometrySubtype() -
getGeometryType
int getGeometryType() -
getHost
String getHost()Description copied from interface:DBParametersReturn the value ofhostparameter- Specified by:
getHostin interfaceDBParameters- Returns:
-
getPassword
String getPassword()Description copied from interface:DBParametersReturn the value ofpasswordparameter- Specified by:
getPasswordin interfaceDBParameters- Returns:
-
getPkFields
String[] getPkFields()Get an array of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()- Returns:
- See Also:
-
getPkFieldsString
String getPkFieldsString()Get a comma separated list of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note:If this parameters is undefined, the library can't do this detection, some services will don't be available for this store (like selection, editing orFeature.getReference())- Returns:
- See Also:
-
getPort
Integer getPort()Description copied from interface:DBParametersReturn the value ofportparameter- Specified by:
getPortin interfaceDBParameters- Returns:
-
getSQL
String getSQL()Get the SQL to use as source of the store instead a table or a view.
If this property is set the store changes his work flow:- store is in read only mode.
tableproperty is ignored.pkFieldsis not identified automatically- filter and order will be resolved locally (pour performance)
- Returns:
- sql to use
- See Also:
-
getTable
String getTable()Gettableparameter value
This parameters describes what table or view we want to connect.
Not used ifsqlparameter set.- Parameters:
password-- See Also:
-
getUser
String getUser()Description copied from interface:DBParametersReturn the value ofuserparameter- Specified by:
getUserin interfaceDBParameters- Returns:
-
getWorkingArea
org.gvsig.fmap.geom.primitive.Envelope getWorkingArea()Get the filter by area ofgetDefaultGeometryField()used in this store.
Supported only for stores with geometric fields- Returns:
-
isValid
boolean isValid()Description copied from interface:DataStoreParametersIndicates whether these parameters are valid.- Specified by:
isValidin interfaceDataStoreParameters- Returns:
- true if these parameters are valid, false if not.
-
setBaseFilter
Set initial filter to use.
This filter is passed to BD provider on each request as a base filter.- See Also:
-
setBaseOrder
Set initial order to use.
This order is used if no custom order is request in query.- See Also:
-
setCRS
void setCRS(org.gvsig.crs.projection.lib.Projection srs) Set manually the SRS for thedefault geometryfield of this layer.
if is set tonullor empty string means that the library must detect it automatically.
Supported only for stores with geometric fields.- See Also:
-
setCRS
-
setDBName
Setdata base name/code> parameter value- Specified by:
setDBNamein interfaceDBParameters- Parameters:
data- base name
-
setDefaultGeometryField
Set the geometry field to use like default geometry.
SeegetDefaultGeometryField()for description.- Parameters:
geomName-- See Also:
-
setFields
Set a comma separated list of the field names that we want to use.
Anullmeans that we want all fields available.- See Also:
-
setFields
Set an array of the field names that we want to use.
Anullmeans that we want all fields available.- See Also:
-
setGeometrySubtype
void setGeometrySubtype(int geometrySubtype) -
setGeometryType
void setGeometryType(int geometryType) -
setHost
- Specified by:
setHostin interfaceDBParameters
-
setPassword
Setpassword/code> parameter value- Specified by:
setPasswordin interfaceDBParameters- Parameters:
password-
-
setPkFields
Set a comma separated list of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()- See Also:
-
setPkFields
Set an array of the field names that compound the primary key.
Anullor empty string means that library must detect this information.
Note: seegetPkFieldsString()- See Also:
-
setPort
void setPort(int port) -
setPort
Setport/code> parameter value- Specified by:
setPortin interfaceDBParameters- Parameters:
port-
-
setSQL
Set the SQL to use as source of the store instead a table or a view.
Note:seegetSQL()for description- See Also:
-
setTable
Settableparameter value
This parameters describes what table or view we want to connect.
Not used ifsqlparameter set.- Parameters:
password-- See Also:
-
setUser
Setuser/code> parameter value- Specified by:
setUserin interfaceDBParameters- Parameters:
user-
-
setWorkingArea
void setWorkingArea(org.gvsig.fmap.geom.primitive.Envelope workingArea) Set the filter by area ofgetDefaultGeometryField()used in this store.
Supported only for stores with geometric fields
-