コード例 #1
0
        public override async Task <TransactionBase> BeginTransaction(TransactionParameterBuffer tpb, AsyncWrappingCommonArgs async)
        {
            var transaction = new FesTransaction(this);
            await transaction.BeginTransaction(tpb, async).ConfigureAwait(false);

            return(transaction);
        }
コード例 #2
0
 protected override void Dispose(bool disposing)
 {
     if (!_disposed)
     {
         try
         {
             if (disposing)
             {
                 Release();
                 Clear();
                 _db              = null;
                 _fields          = null;
                 _parameters      = null;
                 _transaction     = null;
                 _outputParams    = null;
                 _statusVector    = null;
                 _allRowsFetched  = false;
                 _state           = StatementState.Deallocated;
                 _statementType   = DbStatementType.None;
                 _recordsAffected = 0;
                 _handle.Dispose();
                 FetchSize = 0;
             }
         }
         finally
         {
             _disposed = true;
             base.Dispose(disposing);
         }
     }
 }
コード例 #3
0
ファイル: FesDatabase.cs プロジェクト: dant02/NETProvider
        public override async ValueTask <TransactionBase> BeginTransactionAsync(TransactionParameterBuffer tpb, CancellationToken cancellationToken = default)
        {
            var transaction = new FesTransaction(this);
            await transaction.BeginTransactionAsync(tpb, cancellationToken).ConfigureAwait(false);

            return(transaction);
        }
コード例 #4
0
ファイル: FesDatabase.cs プロジェクト: dant02/NETProvider
        public override TransactionBase BeginTransaction(TransactionParameterBuffer tpb)
        {
            var transaction = new FesTransaction(this);

            transaction.BeginTransaction(tpb);
            return(transaction);
        }
コード例 #5
0
        public TransactionBase BeginTransaction(TransactionParameterBuffer tpb)
        {
            FesTransaction transaction = new FesTransaction(this);

            transaction.BeginTransaction(tpb);

            return(transaction);
        }
コード例 #6
0
 public FesArray(DatabaseBase db, TransactionBase transaction, long handle, string tableName, string fieldName)
     : base(tableName, fieldName)
 {
     if (!(db is FesDatabase))
     {
         throw new ArgumentException($"Specified argument is not of {nameof(FesDatabase)} type.");
     }
     if (!(transaction is FesTransaction))
     {
         throw new ArgumentException($"Specified argument is not of {nameof(FesTransaction)} type.");
     }
     _db           = (FesDatabase)db;
     _transaction  = (FesTransaction)transaction;
     _handle       = handle;
     _statusVector = new IntPtr[IscCodes.ISC_STATUS_LENGTH];
 }
コード例 #7
0
 public override void Dispose2()
 {
     if (!_disposed)
     {
         _disposed = true;
         Release();
         Clear();
         _db              = null;
         _fields          = null;
         _parameters      = null;
         _transaction     = null;
         OutputParameters = null;
         _statusVector    = null;
         _allRowsFetched  = false;
         _handle.Dispose();
         FetchSize = 0;
         base.Dispose2();
     }
 }
コード例 #8
0
        public override async ValueTask Dispose2Async(CancellationToken cancellationToken = default)
        {
            if (!_disposed)
            {
                _disposed = true;
                await ReleaseAsync(cancellationToken).ConfigureAwait(false);

                Clear();
                _db              = null;
                _fields          = null;
                _parameters      = null;
                _transaction     = null;
                OutputParameters = null;
                _statusVector    = null;
                _allRowsFetched  = false;
                _handle.Dispose();
                FetchSize = 0;
                await base.Dispose2Async(cancellationToken).ConfigureAwait(false);
            }
        }
コード例 #9
0
        public override async Task Dispose2(AsyncWrappingCommonArgs async)
        {
            if (!_disposed)
            {
                _disposed = true;
                await Release(async).ConfigureAwait(false);

                Clear();
                _db              = null;
                _fields          = null;
                _parameters      = null;
                _transaction     = null;
                OutputParameters = null;
                _statusVector    = null;
                _allRowsFetched  = false;
                _handle.Dispose();
                FetchSize = 0;
                await base.Dispose2(async).ConfigureAwait(false);
            }
        }
コード例 #10
0
        public FesArray(
            IDatabase db,
            ITransaction transaction,
            long handle,
            string tableName,
            string fieldName)
            : base(tableName, fieldName)
        {
            if (!(db is FesDatabase))
            {
                throw new ArgumentException("Specified argument is not of GdsDatabase type.");
            }
            if (!(transaction is FesTransaction))
            {
                throw new ArgumentException("Specified argument is not of GdsTransaction type.");
            }
            _db           = (FesDatabase)db;
            _transaction  = (FesTransaction)transaction;
            _handle       = handle;
            _statusVector = new IntPtr[IscCodes.ISC_STATUS_LENGTH];

            LookupBounds();
        }
コード例 #11
0
ファイル: FesArray.cs プロジェクト: kingpong/NETProvider
        public FesArray(
            IDatabase db,
            ITransaction transaction,
            long handle,
            string tableName,
            string fieldName)
            : base(tableName, fieldName)
        {
            if (!(db is FesDatabase))
            {
                throw new ArgumentException("Specified argument is not of GdsDatabase type.");
            }
            if (!(transaction is FesTransaction))
            {
                throw new ArgumentException("Specified argument is not of GdsTransaction type.");
            }
            this.db = (FesDatabase)db;
            this.transaction = (FesTransaction)transaction;
            this.handle = handle;
            this.statusVector = new IntPtr[IscCodes.ISC_STATUS_LENGTH];

            this.LookupBounds();
        }
コード例 #12
0
        protected override void Dispose(bool disposing)
        {
            if (!this.IsDisposed)
            {
                try
                {
                    // release any unmanaged resources
                    this.Release();
                }
                catch
                {
                }
                finally
                {
                    // release any managed resources
                    if (disposing)
                    {
                        this.Clear();

                        this.db              = null;
                        this.fields          = null;
                        this.parameters      = null;
                        this.transaction     = null;
                        this.outputParams    = null;
                        this.statusVector    = null;
                        this.allRowsFetched  = false;
                        this.state           = StatementState.Deallocated;
                        this.statementType   = DbStatementType.None;
                        this.recordsAffected = 0;
                        this.handle          = 0;
                        this.FetchSize       = 0;
                    }

                    base.Dispose(disposing);
                }
            }
        }
コード例 #13
0
        protected override void Dispose(bool disposing)
        {
            if (!IsDisposed)
            {
                try
                {
                    // release any unmanaged resources
                    Release();
                }
                catch
                {
                }
                finally
                {
                    // release any managed resources
                    if (disposing)
                    {
                        Clear();

                        _db              = null;
                        _fields          = null;
                        _parameters      = null;
                        _transaction     = null;
                        _outputParams    = null;
                        _statusVector    = null;
                        _allRowsFetched  = false;
                        _state           = StatementState.Deallocated;
                        _statementType   = DbStatementType.None;
                        _recordsAffected = 0;
                        _handle          = 0;
                        FetchSize        = 0;
                    }

                    base.Dispose(disposing);
                }
            }
        }
コード例 #14
0
		public ITransaction BeginTransaction(TransactionParameterBuffer tpb)
		{
			FesTransaction transaction = new FesTransaction(this);
			transaction.BeginTransaction(tpb);

			return transaction;
		}
コード例 #15
0
        protected override void Dispose(bool disposing)
        {
            if (!this.IsDisposed)
            {
                try
                {
                    // release any unmanaged resources
                    this.Release();
                }
                catch
                {
                }
                finally
                {
                    // release any managed resources
                    if (disposing)
                    {
                        this.Clear();

                        this.db = null;
                        this.fields = null;
                        this.parameters = null;
                        this.transaction = null;
                        this.outputParams = null;
                        this.statusVector = null;
                        this.allRowsFetched = false;
                        this.state = StatementState.Deallocated;
                        this.statementType = DbStatementType.None;
                        this.recordsAffected = 0;
                        this.handle = 0;
                        this.FetchSize = 0;
                    }

                    base.Dispose(disposing);
                }
            }
        }
コード例 #16
0
		protected override void Dispose(bool disposing)
		{
			if (!IsDisposed)
			{
				try
				{
					Release();
				}
				catch
				{ }
				finally
				{
					if (disposing)
					{
						Clear();

						_db = null;
						_fields = null;
						_parameters = null;
						_transaction = null;
						_outputParams = null;
						_statusVector = null;
						_allRowsFetched = false;
						_state = StatementState.Deallocated;
						_statementType = DbStatementType.None;
						_recordsAffected = 0;
						_handle = 0;
						FetchSize = 0;
					}

					base.Dispose(disposing);
				}
			}
		}