What does the |= operator do in Java?

前端 未结 6 736
暗喜
暗喜 2020-12-06 10:15

While reading the Android guide to Notifications, I stumbled across this:

Adding vibration

You can alert the user with th

6条回答
  •  孤城傲影
    2020-12-06 10:50

    This is the bit wise OR operator. If notifications.default is 0b00000001 in binary form and Notification.DEFAULT_VIBRATE is 0b11000000, then the result will be 0b11000001.

提交回复
热议问题