Esempio n. 1
0
        private static Password ParsePassword <TPassword>(string line) where TPassword : Password
        {
            string[] parts = line.Split(' ');

            string occurrences        = parts[0];
            string characterWithColon = parts[1];
            string password           = parts[2];

            PasswordPolicySchema policySchema = ParsePasswordPolicy(occurrences, characterWithColon);

            return((Password)Activator.CreateInstance(typeof(TPassword), password, policySchema));
        }
Esempio n. 2
0
 public PasswordPart2(string value, PasswordPolicySchema policySchema) : base(value, policySchema)
 {
 }
Esempio n. 3
0
 protected Password(string value, PasswordPolicySchema policySchema)
 {
     Value        = value;
     PolicySchema = policySchema;
 }