System.VarintBitConverter.DecodeZigZag C# (CSharp) Method

DecodeZigZag() private static method

private static DecodeZigZag ( ulong value ) : long
value ulong
return long
        private static long DecodeZigZag(ulong value)
        {
            if ((value & 0x1) == 0x1)
            {
                return (-1 * ((long)(value >> 1) + 1));
            }

            return (long)(value >> 1);
        }