Esempio n. 1
0
        /// <summary>
        /// Closes connection with server instance and resets session ID, user name and user password assigned to this object. This method is also called when ODatabase instance is being disposed.
        /// </summary>
        public void Close()
        {
            DbClose operation = new DbClose();

            WorkerConnection.ExecuteOperation<DbClose>(operation);
            WorkerConnection.SessionID = -1;
            WorkerConnection.Close();

            UserName = "";
            UserPassword = "";
        }
Esempio n. 2
0
        internal void Close()
        {
            SessionId = -1;

            DbClose operation = new DbClose();

            ExecuteOperation(operation);

            if ((_networkStream != null) && (_socket != null))
            {
                _networkStream.Close();
                _socket.Close();
            }

            _networkStream = null;
            _socket        = null;
        }
Esempio n. 3
0
 internal void Close()
 {
     if (!IsActive)
     {
         return;
     }
     try
     {
         DbClose operation = new DbClose(this.Database);
         ExecuteOperation(operation);
     }
     catch { }
     finally
     {
         Destroy();
     }
 }