Class DataStoreService
- Namespace
- DevExpress.Xpo.DB
- Assembly
- DevExpress.Xpo.v24.1.dll
The base class for WCF services providing access to data directly via data store providers (DevExpress.Xpo.DB.IDataStore implementors).
public class DataStoreService : ServiceBase, IDataStoreWarpService, IDataStoreService
- Inheritance
-
DataStoreService
- Implements
- Derived
- Inherited Members
Constructors
DataStoreService(IDataStore)
Initializes a new instance of the DataStoreService class with a data store provider, which supplies data for the service.
public DataStoreService(IDataStore provider)
Parameters
provider
IDataStoreAn object implementing the DevExpress.Xpo.DB.IDataStore interface, which supplies data for the service.
Fields
commandChannel
protected readonly ICommandChannel commandChannel
Field Value
- ICommandChannel
provider
protected readonly IDataStore provider
Field Value
- IDataStore
Methods
Do(string, object)
Executes a specified command with specific parameters and returns the operation result.
public virtual OperationResult<object> Do(string command, object args)
Parameters
command
stringA string specifying the command to execute.
args
objectAn object specifying the command‘s parameters.
Returns
- OperationResult<object>
An OperationResult<object> denoting the operation result.
GetAutoCreateOption()
Returns which operations are performed when a data store is accessed for the first time. This method delegates its call to get the corresponding option value of a data store passed as provider to the constructor.
public virtual OperationResult<AutoCreateOption> GetAutoCreateOption()
Returns
- OperationResult<AutoCreateOption>
An OperationResult<DevExpress.Xpo.DB.AutoCreateOption> denoting the operation result.
ModifyData(ModificationStatement[])
Updates data in a data store using specified modification statements and returns the operation result. This method delegates its call to the corresponding method of a data store passed as provider to the constructor.
public virtual OperationResult<ModificationResult> ModifyData(ModificationStatement[] dmlStatements)
Parameters
dmlStatements
ModificationStatement[]An array of data modification statements.
Returns
- OperationResult<ModificationResult>
An OperationResult<DevExpress.Xpo.DB.ModificationResult> denoting the result of the data modifications.
SelectData(SelectStatement[])
Fetches data from a data store using specified query statements and returns the operation result. This method delegates its call to the corresponding method of a data store passed as provider to the constructor.
public virtual OperationResult<SelectedData> SelectData(SelectStatement[] selects)
Parameters
selects
SelectStatement[]An array of query statements.
Returns
- OperationResult<SelectedData>
An OperationResult<DevExpress.Xpo.DB.SelectedData> denoting the result of the data fetch.
UpdateSchema(bool, DBTable[])
Updates a data store’s schema according to specified settings and returns the operation result. This method delegates its call to the corresponding method of a data store passed as provider to the constructor.
public virtual OperationResult<UpdateSchemaResult> UpdateSchema(bool doNotCreateIfFirstTableNotExist, DBTable[] tables)
Parameters
doNotCreateIfFirstTableNotExist
booltrue if the schema should not be created when the table that corresponds to the first item in the tables array doesn’t exist in the data store; otherwise, false.
tables
DBTable[]An array of tables whose structure should be saved in the data store.
Returns
- OperationResult<UpdateSchemaResult>
An OperationResult<DevExpress.Xpo.DB.UpdateSchemaResult> denoting the result of the update operation.
WarpSelectData(SelectStatement[])
Reserved for future use.
public virtual OperationResult<byte[]> WarpSelectData(SelectStatement[] selects)
Parameters
selects
SelectStatement[]