Exemplo n.º 1
0
        public User Login(string userName, string password, bool isPersistent, string customData)
        {
            // Check password and persist
            _currentUser = _session.Single<User>(u => u.Name == userName);

            _eventAggregator.GetEvent<LoginEvent>().Publish(_currentUser);

            return _currentUser;
        }
Exemplo n.º 2
0
        public void Logout()
        {
            _currentUser = null;

            _eventAggregator.GetEvent<LogoutEvent>().Publish(_currentUser);
        }