public static string GenerateCode(int length, char[] allowedCharacters)
 {
     return(GenerateStringCode(length, CharacterSet.FromChars(allowedCharacters)));
 }
        public static string GenerateCode(int length, params ICharacterSet[] characterSets)
        {
            var characters = CharacterSet.CombineSets(characterSets);

            return(GenerateStringCode(length, characters));
        }