code: @Override
      public void onReceive(Object message) {
          if (message instanceof OnAppVisible) {
              onAppVisible();
          } else if (message instanceof OnAppHidden) {
              onAppHidden();
          } else if (message instanceof PerformOnline) {
              performOnline();
          } else {
              super.onReceive(message);
          }
      }
docs: Messages