value holds a 64 bit binary number. The & operator with the mask 0xFF sets the first 52 bits of value to 0.
1234567 (base 10) ==
0x000000000012d687 (base 16) ==
0000...000100101101011010000111 (base 2)
1 & 1 = 1
1 & 0 = 0
0 & 1 = 0
0 & 0 = 0
1234567 & 0xff ==
0000...000100101101011010000111 & 0000...000011111111 ==
0000...000000000000000010000111
10000111 (base 2) == 0x87 (base 16) == 135 (base 10)
The cast (byte) truncates (drops) the first 52 bits.
b holds the remaining 8 bits. b = 135