WriteUInt32() public static méthode

public static WriteUInt32 ( uint value, byte buffer, int offset ) : int
value uint
buffer byte
offset int
Résultat int
Exemple #1
0
        public static void CreateRandomData(byte[] buffer, int offset)
        {
            uint unixTime = (uint)((DateTime.UtcNow.Ticks - UnixTimeStart) / TimeSpan.TicksPerSecond);

            BitConverterBE.WriteUInt32(unixTime, buffer, offset);
            lock (_randBuffer) {
                RNG.GetBytes(_randBuffer);
                Buffer.BlockCopy(_randBuffer, 0, buffer, offset + 4, _randBuffer.Length);
            }
        }