Пример #1
0
        protected override void Dispose(bool disposing)
        {
            if (!this.IsDisposed)
            {
                try
                {
                    // release any unmanaged resources
                    this.Release();

                    // release any managed resources
                    if (disposing)
                    {
                        this.Clear();

                        this.db              = null;
                        this.fields          = null;
                        this.parameters      = null;
                        this.transaction     = null;
                        this.outputParams    = null;
                        this.allRowsFetched  = false;
                        this.recordsAffected = 0;
                        this.state           = StatementState.Deallocated;
                        this.handle          = 0;
                    }
                }
                finally
                {
                    base.Dispose(disposing);
                }
            }
        }
Пример #2
0
        private void Dispose(bool disposing)
        {
            lock (this)
            {
                if (!this.disposed)
                {
                    try
                    {
                        // release any unmanaged resources
                        this.Rollback();

                        // release any managed resources
                        if (disposing)
                        {
                            this.db     = null;
                            this.handle = 0;
                            this.state  = TransactionState.NoTransaction;
                        }
                    }
                    finally
                    {
                        this.disposed = true;
                    }
                }
            }
        }
		public FesTransaction(IDatabase db)
		{
			if (!(db is FesDatabase))
			{
				throw new ArgumentException("Specified argument is not of FesDatabase type.");
			}

			this.db		= (FesDatabase)db;
			this.state	= TransactionState.NoTransaction;

			GC.SuppressFinalize(this);
		}
Пример #4
0
        public FesTransaction(IDatabase db)
        {
            if (!(db is FesDatabase))
            {
                throw new ArgumentException("Specified argument is not of FesDatabase type.");
            }

            this.db    = (FesDatabase)db;
            this.state = TransactionState.NoTransaction;

            GC.SuppressFinalize(this);
        }
Пример #5
0
        public FesBlob(IDatabase db, ITransaction transaction, long blobId) : base(db)
        {
            if (!(db is FesDatabase))
            {
                throw new ArgumentException("Specified argument is not of FesDatabase type.");
            }
            if (!(transaction is FesTransaction))
            {
                throw new ArgumentException("Specified argument is not of FesTransaction type.");
            }

            this.db          = (FesDatabase)db;
            this.transaction = (FesTransaction)transaction;
            this.position    = 0;
            this.blobHandle  = 0;
            this.blobId      = blobId;
        }
Пример #6
0
		public FesBlob(IDatabase db, ITransaction transaction, long blobId) : base(db)
		{
			if (!(db is FesDatabase))
			{
				throw new ArgumentException("Specified argument is not of FesDatabase type.");
			}
			if (!(transaction is FesTransaction))
			{
				throw new ArgumentException("Specified argument is not of FesTransaction type.");
			}

			this.db				= (FesDatabase)db;
			this.transaction	= (FesTransaction)transaction;
			this.position		= 0;
			this.blobHandle		= 0;
			this.blobId			= blobId;
		}
Пример #7
0
        public FesStatement(IDatabase db, ITransaction transaction)
        {
            if (!(db is FesDatabase))
            {
                throw new ArgumentException("Specified argument is not of FesDatabase type.");
            }

            this.recordsAffected = -1;
            this.db           = (FesDatabase)db;
            this.outputParams = new Queue();

            if (transaction != null)
            {
                this.Transaction = transaction;
            }

            GC.SuppressFinalize(this);
        }
Пример #8
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.");
            }
            this.db          = (FesDatabase)db;
            this.transaction = (FesTransaction)transaction;
            this.handle      = handle;

            this.LookupBounds();
        }
		private void Dispose(bool disposing)
		{
			lock (this)
			{
				if (!this.disposed)
				{
					try
					{
						// release any unmanaged resources
						this.Rollback();

						// release any managed resources
						if (disposing)
						{
							this.db = null;
							this.handle = 0;
							this.state = TransactionState.NoTransaction;
						}
					}
					finally
					{
						this.disposed = true;
					}
				}
			}
		}
Пример #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.");
			}
			this.db			 = (FesDatabase)db;
			this.transaction = (FesTransaction)transaction;
			this.handle		 = handle;

			this.LookupBounds();
		}
Пример #11
0
		protected override void Dispose(bool disposing)
		{
			if (!this.IsDisposed)
			{
				try
				{
					// release any unmanaged resources
					this.Release();

					// release any managed resources
					if (disposing)
					{
						this.Clear();

						this.db				= null;
						this.fields			= null;
						this.parameters		= null;
						this.transaction	= null;
						this.outputParams	= null;
						this.allRowsFetched	= false;
						this.recordsAffected = 0;
						this.state	= StatementState.Deallocated;
						this.handle = 0;
					}
				}
				finally
				{
					base.Dispose(disposing);
				}
			}
		}
Пример #12
0
		public FesStatement(IDatabase db, ITransaction transaction)
		{
			if (!(db is FesDatabase))
			{
				throw new ArgumentException("Specified argument is not of FesDatabase type.");
			}

			this.recordsAffected = -1;
			this.db = (FesDatabase)db;
			this.outputParams = new Queue();

			if (transaction != null)
			{
				this.Transaction = transaction;
			}

			GC.SuppressFinalize(this);
		}