Example #1
0
        public HomeDirectory GetLecteurReseau(UserPrincipal user)
        {
            HomeDirectory home = new HomeDirectory()
            {
                LettreReseau = user.HomeDrive,
                Directory    = user.HomeDirectory
            };

            return(home);
        }
Example #2
0
        public HomeDirectory GetLecteurReseau(string userName)
        {
            var user = GetUser(userName);

            HomeDirectory home = null;

            if (user != null)
            {
                home = new HomeDirectory()
                {
                    LettreReseau = user.HomeDrive,
                    Directory    = user.HomeDirectory
                };
            }
            else
            {
                throw new UserNotExistException("Utilisateur " + userName + " n'existe pas");
            }

            return(home);
        }