Example #1
0
        public string getFolder(EnvironmentVariable ev, string user)
        {
            LocationPath  parse_me = new LocationPath(ev, null);
            List <string> users    = this.getUsers(ev);

            if (user == null)
            {
                foreach (string usr in users)
                {
                    return(this.getAbsoluteRoot(parse_me, usr));
                }
                return(this.getAbsoluteRoot(parse_me, null));
            }
            if (users.Contains(user))
            {
                return(this.getAbsoluteRoot(parse_me, user));
            }
            throw new Exception("User " + user + " does not have a folder for EV " + ev.ToString());
        }
Example #2
0
 private static ObjectInfo EnvironmentVariableInfo(EnvironmentVariable envVar)
 {
     return(new ObjectInfo(envVar.ToString(), new[] { new Property("Name", envVar.Name), new Property("Value", envVar.Value) }));
 }
Example #3
0
 public string getFolder(EnvironmentVariable ev, string user)
 {
     LocationPath parse_me = new LocationPath(ev, null);
     List<string> users = this.getUsers(ev);
     if (user == null) {
         foreach (string usr in users) {
             return this.getAbsoluteRoot(parse_me, usr);
         }
         return this.getAbsoluteRoot(parse_me, null);
     }
     if (users.Contains(user)) {
         return this.getAbsoluteRoot(parse_me, user);
     }
     throw new Exception("User " + user + " does not have a folder for EV " + ev.ToString());
 }