|=
I\'m curious to learn about this operator, I\'ve seen this notation used while setting flags in Java.
for example:
notification.flags |=
It is equivalent to
notification.flags = notification.flags | Notification.FLAG_AUTO_CANCEL;
where | is bitwise OR operator which OR the two variables bit-by-bit.
|
It is well known by itself. There are also +=, -=, *=, /=, %=, &=, ^=.
+=
-=
*=
/=
%=
&=
^=