示例#1
0
        internal void Activate()
        {
            int wasInUse = System.Threading.Interlocked.Exchange(ref _isInUse, 1);

            if (0 != wasInUse)
            {
                throw SQL.ContextConnectionIsInUse();
            }

            CurrentDatabase = _smiConnection.GetCurrentDatabase(_smiEventSink);

            _smiEventSink.ProcessMessagesAndThrow();
        }