Exemplo n.º 1
0
 internal PropertyHandler(string username, IPropertyCollection properties, IPredefinedNames propertyNames)
 {
     this.username        = username;
     this.propertyNames   = propertyNames;
     propertiesPerContext = new Dictionary <IContext, IPropertyCollection>();
     AttachProperties(properties);
     if (CreationDate == DateTime.MinValue)
     {
         CreationDate = DateTime.UtcNow;
     }
 }
Exemplo n.º 2
0
		protected UserRepositoryBase(string name, IConfig config, IPredefinedNames predefinedNames, IUserCache cache) {
			if(name == null) {
				throw new ArgumentNullException("name");
			}
			if(config == null) {
				throw new ArgumentNullException("config");
			}
			this.name = name;
			this.config = config;
			this.predefinedNames = predefinedNames;
			this.cache = cache;
		}
Exemplo n.º 3
0
 protected UserRepositoryBase(string name, IConfig config, IPredefinedNames predefinedNames, IUserCache cache)
 {
     if (name == null)
     {
         throw new ArgumentNullException("name");
     }
     if (config == null)
     {
         throw new ArgumentNullException("config");
     }
     this.name            = name;
     this.config          = config;
     this.predefinedNames = predefinedNames;
     this.cache           = cache;
 }
Exemplo n.º 4
0
		public User(string userId,
		            string userName,
		            string domain,
		            IPropertyCollection properties,
		            IPredefinedNames propertyNames) {
			if(userId == null) {
				throw new ArgumentNullException("userId");
			}
			if(string.IsNullOrEmpty(userName)) {
				throw new ArgumentException("User name can not be empty.");
			}
			id = userId;
			this.domain = (domain ?? string.Empty);
			this.userName = userName;
			this.properties = new PropertyHandler(userName, properties, propertyNames);
		}
Exemplo n.º 5
0
 public User(string userId,
             string userName,
             string domain,
             IPropertyCollection properties,
             IPredefinedNames propertyNames)
 {
     if (userId == null)
     {
         throw new ArgumentNullException("userId");
     }
     if (string.IsNullOrEmpty(userName))
     {
         throw new ArgumentException("User name can not be empty.");
     }
     id              = userId;
     this.domain     = (domain ?? string.Empty);
     this.userName   = userName;
     this.properties = new PropertyHandler(userName, properties, propertyNames);
 }
Exemplo n.º 6
0
 private static IPredefinedNames CreatePredefinedNames(IConfig config,
                                                       GetValueDelegate getValue,
                                                       IPredefinedNames context)
 {
     return(new PredefinedNames(getValue("userName", config),
                                getValue("fullName", config),
                                getValue("firstName", config),
                                getValue("lastName", config),
                                getValue("description", config),
                                getValue("email", config),
                                getValue("homePage", config),
                                getValue("streetAddress", config),
                                getValue("company", config),
                                getValue("department", config),
                                getValue("city", config),
                                getValue("telephone", config),
                                getValue("fax", config),
                                getValue("homeTelephone", config),
                                getValue("mobileTelephone", config),
                                getValue("postOfficeBox", config),
                                getValue("postalCode", config),
                                getValue("country", config),
                                getValue("title", config),
                                getValue("active", config),
                                getValue("passwordQuestion", config),
                                getValue("passwordAnswer", config),
                                getValue("lastActivityDate", config),
                                getValue("creationDate", config),
                                getValue("lastLockoutDate", config),
                                getValue("lastLoginDate", config),
                                getValue("lastPasswordChangedDate", config),
                                getValue("locked", config),
                                getValue("lastUpdatedDate", config),
                                getValue("isAnonymous", config),
                                getValue("password", config),
                                getValue("passwordSalt", config),
                                context));
 }
Exemplo n.º 7
0
		private static IPredefinedNames CreatePredefinedNames(IConfig config,
		                                                      GetValueDelegate getValue,
		                                                      IPredefinedNames context) {
			return new PredefinedNames(getValue("userName", config),
			                           getValue("fullName", config),
			                           getValue("firstName", config),
			                           getValue("lastName", config),
			                           getValue("description", config),
			                           getValue("email", config),
			                           getValue("homePage", config),
			                           getValue("streetAddress", config),
			                           getValue("company", config),
			                           getValue("department", config),
			                           getValue("city", config),
			                           getValue("telephone", config),
			                           getValue("fax", config),
			                           getValue("homeTelephone", config),
			                           getValue("mobileTelephone", config),
			                           getValue("postOfficeBox", config),
			                           getValue("postalCode", config),
			                           getValue("country", config),
			                           getValue("title", config),
			                           getValue("active", config),
			                           getValue("passwordQuestion", config),
			                           getValue("passwordAnswer", config),
			                           getValue("lastActivityDate", config),
			                           getValue("creationDate", config),
			                           getValue("lastLockoutDate", config),
			                           getValue("lastLoginDate", config),
			                           getValue("lastPasswordChangedDate", config),
			                           getValue("locked", config),
			                           getValue("lastUpdatedDate", config),
			                           getValue("isAnonymous", config),
			                           getValue("password", config),
			                           getValue("passwordSalt", config),
			                           context);
		}
Exemplo n.º 8
0
		public UserRepositoryAdapter(string name, IConfig config, IPredefinedNames predefinedNames, IUserCache cache) : base(name, config, predefinedNames, cache){
		}
Exemplo n.º 9
0
 public UserRepositoryAdapter(string name, IConfig config, IPredefinedNames predefinedNames, IUserCache cache) : base(name, config, predefinedNames, cache)
 {
 }
Exemplo n.º 10
0
 private static IPredefinedNames CreatePredefinedPropertyNames(IConfig config, IPredefinedNames context)
 {
     return(CreatePredefinedNames(config, GetPredefinedPropertyKey, context));
 }
Exemplo n.º 11
0
 public PredefinedNames(
     string username,
     string fullname,
     string firstname,
     string lastname,
     string description,
     string email,
     string homepage,
     string streetaddress,
     string company,
     string department,
     string city,
     string telephone,
     string fax,
     string hometelephone,
     string mobiletelephone,
     string postofficebox,
     string postalcode,
     string country,
     string title,
     string active,
     string passwordQuestion,
     string passwordAnswer,
     string lastActivityDate,
     string creationDate,
     string lastLockoutDate,
     string lastLoginDate,
     string lastPasswordChangedDate,
     string locked,
     string lastUpdatedDate,
     string isAnonymous,
     string password,
     string passwordSalt,
     IPredefinedNames contextNames)
 {
     userName                     = username;
     fullName                     = fullname;
     firstName                    = firstname;
     lastName                     = lastname;
     this.description             = description;
     this.email                   = email;
     homePage                     = homepage;
     streetAddress                = streetaddress;
     this.company                 = company;
     this.department              = department;
     this.city                    = city;
     this.telephone               = telephone;
     this.fax                     = fax;
     homeTelephone                = hometelephone;
     mobileTelephone              = mobiletelephone;
     postOfficeBox                = postofficebox;
     postalCode                   = postalcode;
     this.country                 = country;
     this.title                   = title;
     this.active                  = active;
     this.passwordQuestion        = passwordQuestion;
     this.passwordAnswer          = passwordAnswer;
     this.lastActivityDate        = lastActivityDate;
     this.creationDate            = creationDate;
     this.lastLockoutDate         = lastLockoutDate;
     this.lastLoginDate           = lastLoginDate;
     this.lastPasswordChangedDate = lastPasswordChangedDate;
     this.locked                  = locked;
     this.lastUpdatedDate         = lastUpdatedDate;
     this.isAnonymous             = isAnonymous;
     this.password                = password;
     this.passwordSalt            = passwordSalt;
     this.contextNames            = contextNames;
 }
Exemplo n.º 12
0
		private static IPredefinedNames CreatePredefinedPropertyNames(IConfig config, IPredefinedNames context) {
			return CreatePredefinedNames(config, GetPredefinedPropertyKey, context);
		}
Exemplo n.º 13
0
		public PredefinedNames(
			string username,
			string fullname,
			string firstname,
			string lastname,
			string description,
			string email,
			string homepage,
			string streetaddress,
			string company,
			string department,
			string city,
			string telephone,
			string fax,
			string hometelephone,
			string mobiletelephone,
			string postofficebox,
			string postalcode,
			string country,
			string title,
			string active,
			string passwordQuestion,
			string passwordAnswer,
			string lastActivityDate,
			string creationDate,
			string lastLockoutDate,
			string lastLoginDate,
			string lastPasswordChangedDate,
			string locked,
			string lastUpdatedDate,
			string isAnonymous,
			string password,
			string passwordSalt,
			IPredefinedNames contextNames) {
			userName = username;
			fullName = fullname;
			firstName = firstname;
			lastName = lastname;
			this.description = description;
			this.email = email;
			homePage = homepage;
			streetAddress = streetaddress;
			this.company = company;
			this.department = department;
			this.city = city;
			this.telephone = telephone;
			this.fax = fax;
			homeTelephone = hometelephone;
			mobileTelephone = mobiletelephone;
			postOfficeBox = postofficebox;
			postalCode = postalcode;
			this.country = country;
			this.title = title;
			this.active = active;
			this.passwordQuestion = passwordQuestion;
			this.passwordAnswer = passwordAnswer;
			this.lastActivityDate = lastActivityDate;
			this.creationDate = creationDate;
			this.lastLockoutDate = lastLockoutDate;
			this.lastLoginDate = lastLoginDate;
			this.lastPasswordChangedDate = lastPasswordChangedDate;
			this.locked = locked;
			this.lastUpdatedDate = lastUpdatedDate;
			this.isAnonymous = isAnonymous;
			this.password = password;
			this.passwordSalt = passwordSalt;
			this.contextNames = contextNames;
		}