OpenRA.FileFormats.Blowfish.RunCipher C# (CSharp) Méthode

RunCipher() static private méthode

static private RunCipher ( uint data, CipherFunc f ) : uint[]
data uint
f CipherFunc
Résultat uint[]
        static uint[] RunCipher(uint[] data, CipherFunc f)
        {
            var result = new uint[data.Length];

            var size = data.Length / 2;
            var i = 0;
            while (size-- > 0)
            {
                var a = SwapBytes(data[i]);
                var b = SwapBytes(data[i + 1]);

                f(ref a, ref b);

                result[i++] = SwapBytes(a);
                result[i++] = SwapBytes(b);
            }

            return result;
        }