/// <summary>
		/// Initializes a new instance.
		/// </summary>
		/// <param name="link">The link this nestable transaction is associated with.</param>
		/// <param name="mode">The initial transactional mode.</param>
		protected NestableTransaction(
			IDataLink link,
			NestableTransactionMode mode = NestableTransactionMode.Database)
		{
			if (link == null) throw new ArgumentNullException("link", "Link cannot be null.");
			if (link.IsDisposed) throw new ObjectDisposedException(link.ToString());

			_Link = link;
			_Mode = mode;
		}
예제 #2
0
		/// <summary>
		/// Initializes a new instance.
		/// </summary>
		/// <param name="engine">The engine this instance will be associated with.</param>
		/// <param name="mode">The default initial mode to use when needed to create the nestable
		/// transtransaction object maintained by this instance.</param>
		protected DataLink(
			IDataEngine engine,
			NestableTransactionMode mode = NestableTransactionMode.Database)
		{
			if (engine == null) throw new ArgumentNullException("engine", "Engine cannot be null.");
			if (engine.IsDisposed) throw new ObjectDisposedException(engine.ToString());

			_Engine = engine;
			_SerialId = ++_LastSerialId;
			_DefaultTransactionMode = mode;
		}
예제 #3
0
        /// <summary>
        /// Initializes a new instance.
        /// </summary>
        /// <param name="link">The link this nestable transaction is associated with.</param>
        /// <param name="mode">The initial transactional mode.</param>
        protected NestableTransaction(
            IDataLink link,
            NestableTransactionMode mode = NestableTransactionMode.Database)
        {
            if (link == null)
            {
                throw new ArgumentNullException("link", "Link cannot be null.");
            }
            if (link.IsDisposed)
            {
                throw new ObjectDisposedException(link.ToString());
            }

            _Link = link;
            _Mode = mode;
        }
예제 #4
0
        /// <summary>
        /// Initializes a new instance.
        /// </summary>
        /// <param name="engine">The engine this instance will be associated with.</param>
        /// <param name="mode">The default initial mode to use when needed to create the nestable
        /// transtransaction object maintained by this instance.</param>
        protected DataLink(
            IDataEngine engine,
            NestableTransactionMode mode = NestableTransactionMode.Database)
        {
            if (engine == null)
            {
                throw new ArgumentNullException("engine", "Engine cannot be null.");
            }
            if (engine.IsDisposed)
            {
                throw new ObjectDisposedException(engine.ToString());
            }

            _Engine   = engine;
            _SerialId = ++_LastSerialId;
            _DefaultTransactionMode = mode;
        }
예제 #5
0
		public FakeLink(IDataEngine engine, NestableTransactionMode mode) : base(engine, mode) { }
예제 #6
0
		public FakeTransaction(IDataLink link, NestableTransactionMode mode) : base(link, mode) { }
예제 #7
0
 public FakeLink(IDataEngine engine, NestableTransactionMode mode) : base(engine, mode)
 {
 }
예제 #8
0
 public FakeTransaction(IDataLink link, NestableTransactionMode mode) : base(link, mode)
 {
 }