DeveelDB  20151217
complete SQL database system, primarly developed for .NET/Mono frameworks
DeveelDbProvider.cs
Go to the documentation of this file.
1 using System;
2 using System.Data.Common;
3 
5 
6 using IQToolkit.Data;
7 using IQToolkit.Data.Common;
8 
9 namespace Deveel.Data.Linq {
10  class DeveelDbProvider : EntityProvider {
11  private readonly IQuery context;
12 
13  public DeveelDbProvider(IQuery context, QueryMapping mapping, QueryPolicy policy)
14  : base(new DeveelDbLanguage(), mapping, policy) {
15  this.context = context;
16  }
17 
18  protected override QueryExecutor CreateExecutor() {
19  return new DeveelDbExecutor(context);
20  }
21 
22  public override void DoTransacted(Action action) {
23  throw new NotImplementedException();
24  }
25 
26  public override void DoConnected(Action action) {
27  action();
28  }
29 
30  public override int ExecuteCommand(string commandText) {
31  // TODO: what to return here?
32  context.ExecuteQuery(commandText);
33  return -1;
34  }
35  }
36 }
override QueryExecutor CreateExecutor()
override void DoConnected(Action action)
DeveelDbProvider(IQuery context, QueryMapping mapping, QueryPolicy policy)
override void DoTransacted(Action action)
override int ExecuteCommand(string commandText)