Microsoft.Protocols.TestTools.StackSdk.BranchCache.Pchc.EncodeMessage.GetBytesFromUlong C# (CSharp) Method

GetBytesFromUlong() private static method

Convert the ulong type value to byte array.
private static GetBytesFromUlong ( ulong value, bool isBigEndian ) : byte[]
value ulong An ulong value
isBigEndian bool order of bytes. If it's big endian, set it to true, else set it to false.
return byte[]
        private static byte[] GetBytesFromUlong(ulong value, bool isBigEndian)
        {
            byte[] resultData = BitConverter.GetBytes(value);
            ReverseByFlag(resultData, isBigEndian);
            return resultData;
        }