Exemplo n.º 1
0
 public UtlConnectionProxy(UtlConnectionOptions connectionOptions, UtlConnection owner)
 {
     this.ConnectionOptions = connectionOptions;
     this.Owner             = owner;
     this.Created           = DateTime.UtcNow.Ticks;
     this.IsPooled          = false;
 }
Exemplo n.º 2
0
 public UtlConnectionProxy(ISessionInterface sessionProxy, UtlConnectionOptions connectionOptions, UtlConnection owner)
 {
     this.SessionProxy      = sessionProxy;
     this.ConnectionOptions = connectionOptions;
     this.Owner             = owner;
     this.Created           = DateTime.UtcNow.Ticks;
     this.IsPooled          = false;
 }
Exemplo n.º 3
0
 public UtlConnection(ISessionInterface sessionProxy)
 {
     this._connectionState   = ConnectionState.Closed;
     this._connectionOptions = new UtlConnectionOptions();
     this._connectionString  = string.Empty;
     this.Version           += 1L;
     this.InnerConnection    = new UtlConnectionProxy(sessionProxy, this._connectionOptions, this);
     this._connectionState   = ConnectionState.Open;
 }
Exemplo n.º 4
0
 public UtlConnection(string connectionString)
 {
     this._connectionState   = ConnectionState.Closed;
     this._connectionOptions = new UtlConnectionOptions();
     this._connectionString  = string.Empty;
     if (!string.IsNullOrEmpty(connectionString))
     {
         this.ConnectionString = connectionString;
     }
 }
Exemplo n.º 5
0
 protected override void Dispose(bool disposing)
 {
     base.Dispose(disposing);
     if (disposing)
     {
         this.Close();
         this._connectionString  = string.Empty;
         this._connectionOptions = null;
     }
 }
Exemplo n.º 6
0
 public void Close()
 {
     if (!this._isClrSpConnection && (this.SessionProxy != null))
     {
         try
         {
             this.SessionProxy.Close();
         }
         catch (Exception)
         {
         }
         finally
         {
             this.SessionProxy      = null;
             this.Owner             = null;
             this.IsPooled          = false;
             this.Created           = 0L;
             this.ConnectionOptions = null;
         }
     }
 }
Exemplo n.º 7
0
 public UtlConnectionProxy(UtlConnectionOptions connectionOptions) : this(connectionOptions, null)
 {
 }