Exemple #1
0
 /// <summary>
 /// Process the input <see cref="char"/> table to the output <see cref="char"/> table.
 /// </summary>
 /// <param name="input"></param>
 /// <returns>return the processing <see cref="char"/> table. The <see cref="char"/> not contained in operating alphabet as not modified.</returns>
 public char[] Process(char[] input)
 {
     for (int i = 0; i < input.Length; i++)
     {
         if (OperatingAlphabet.Contains(input[i]))
         {
             input[i] = Process(input[i]);
         }
     }
     return(input);
 }
Exemple #2
0
        /// <summary>
        /// Process the input enumerable <see cref="char"/> to the output enumerable <see cref="char"/>.
        /// </summary>
        /// <param name="input"></param>
        /// <returns>return the processing <see cref="char"/> table. The <see cref="char"/> not contained in operating alphabet as not modified.</returns>
        public IEnumerable <char> Process(IEnumerable <char> input)
        {
            char[] rslt = input.ToArray();

            for (int i = 0; i < rslt.Length; i++)
            {
                if (OperatingAlphabet.Contains(rslt[i]))
                {
                    rslt[i] = Process(rslt[i]);
                }
            }

            return(rslt);
        }
Exemple #3
0
 /// <summary>
 /// Project a character onto the range use in access wire matrix indexes.
 /// </summary>
 /// <param name="input"></param>
 /// <returns></returns>
 public int ProjectCharacter(char input)
 {
     return(OperatingAlphabet.ToList().IndexOf(input));;
 }