turn on VIVO push.
547934
public static void turnOnVIVOPush(final AVCallback<Boolean> callback) {
    com.vivo.push.PushClient.getInstance(AVOSCloud.getContext()).turnOnPush(new com.vivo.push.IPushActionListener() {
      public void onStateChanged(int state) {
        if (null == callback) {
          AVException exception = null;
          if (0 != state) {
            exception = new AVException(AVException.UNKNOWN, "VIVO server internal error, state=" + state);
          }
          callback.internalDone(null == exception, exception);
        }
      }
    });
  }
898576
@SuppressWarnings("unused")
    private void opSetOptionPush() {
        // option = code[ip++]; // final for now
        pushAlt(ip, s, sprev, pkeep);
        ip += OPSize.SET_OPTION + OPSize.FAIL;
    }
1112148
function push() {
  window._gs = window._gs || function() {
    window._gs.q.push(arguments);
  };
  window._gs.q = window._gs.q || [];
  window._gs.apply(null, arguments);
}
1355078
final void push(UniCompletion<?,?> c) {
        if (c != null) {
            while (result == null && !tryPushStack(c))
                lazySetNext(c, null); // clear on failure
        }
    }
1172843
public function push(): void
    {
        $this->stack[$this->current + 1] = $this->stack[$this->current];

        ++$this->current;
    }
896081
public void push(Value value) {
		for (MeasureListener<Value> listener : listeners) {
			listener.measureGenerated(value);
		}
	}
350547
def run(self):
        """"""
        self.socket = self.bluez.hci_open_dev(self.bt_device_id)

        filtr = self.bluez.hci_filter_new()
        self.bluez.hci_filter_all_events(filtr)
        self.bluez.hci_filter_set_ptype(filtr, self.bluez.HCI_EVENT_PKT)
        self.socket.setsockopt(self.bluez.SOL_HCI, self.bluez.HCI_FILTER, filtr)

        self.set_scan_parameters()
        self.toggle_scan(True)

        while self.keep_going:
            pkt = self.socket.recv(255)
            event = to_int(pkt[1])
            subevent = to_int(pkt[3])
            if event == LE_META_EVENT and subevent == EVT_LE_ADVERTISING_REPORT:
                # we have an BLE advertisement
                self.process_packet(pkt)
        self.socket.close()
255321
public static boolean registerVIVOPush(Application application, String profile) {
    vivoDeviceProfile = profile;
    com.vivo.push.PushClient client = com.vivo.push.PushClient.getInstance(application.getApplicationContext());
    try {
      client.checkManifest();
      client.initialize();
      return true;
    } catch (com.vivo.push.util.VivoPushException ex) {
      printErrorLog("register error, mainifest is incomplete! details=" + ex.getMessage());
      return false;
    }
  }
1021580
def OnActivateCard(self, card):
        """"""
        SimpleSCardAppEventObserver.OnActivateCard(self, card)
        self.feedbacktext.SetLabel('Activated card: ' + repr(card))
        self.transmitbutton.Enable()
29919
public void onActivate() {
		menu = getContextMenu();
		mapWidget.setContextMenu(menu);

		if (maxBoundsDisplayed) {
			VectorLayer layer = getFeatureTransaction().getLayer();
			GeometryFactory factory = mapWidget.getMapModel().getGeometryFactory();
			LinearRing hole = factory.createLinearRing(new Bbox(layer.getLayerInfo().getMaxExtent()));
			LinearRing shell = factory.createLinearRing(mapWidget.getMapModel().getMapView().getMaxBounds());
			Polygon polygon = factory.createPolygon(shell, new LinearRing[] { hole });

			maxExtent = new GfxGeometry("maxExtent");
			maxExtent.setGeometry(polygon);
			maxExtent.setStyle(new ShapeStyle("#000000", .6f, "#990000", 1, 2));
			mapWidget.registerWorldPaintable(maxExtent);
		}
	}
240156
def push_intent(self, intent):
        """"""
        if intent.id:
            print('Updating {} intent'.format(intent.name))
            self.update(intent)
        else:
            print('Registering {} intent'.format(intent.name))
            intent = self.register(intent)
        return intent
615632
protected function broadcast()
    {
        if (function_exists('broadcast')) {
            broadcast(new NotificationPushed($this->push));
        } elseif (function_exists('event')) {
            event(new NotificationPushed($this->push));
        }
    }
89206
public void push(T token) {
        if (token == lastPushed) return;
        lastPushed = token;
        if (token.getChannel() == TokenChannel.Default) {
            main.add(token);
        }
        all.add(token);
    }
944709
def push(self, item, priority):
        '''
        
        '''
        data = self._encode_item(item)
        pairs = {data: -priority}
        self.server.zadd(self.key, **pairs)
1346910
def activate(self, timeout=None, **options):
        """"""

        if timeout is None:
            timeout = 1.0
        gbt = options.get('gbt', '')[0:47]
        lrt = min(max(0, options.get('lrt', 3)), 3)
        rwt = min(max(0, options.get('rwt', 8)), 14)

        pp = (lrt << 4) | (bool(gbt) << 1) | int(bool(self.nad))
        nfcid3t = bytearray.fromhex("01FE") + os.urandom(6) + "ST"
        atr_res = ATR_RES(nfcid3t, 0, 0, 0, rwt, pp, gbt)
        atr_res = atr_res.encode()

        target = nfc.clf.LocalTarget(atr_res=atr_res)
        target.sens_res = bytearray.fromhex("0101")
        target.sdd_res = bytearray.fromhex("08") + os.urandom(3)
        target.sel_res = bytearray.fromhex("40")
        target.sensf_res = bytearray.fromhex("01") + nfcid3t[0:8]
        target.sensf_res += bytearray.fromhex("00000000 00000000 FFFF")

        target = self.clf.listen(target, timeout)

        if target and target.atr_req and target.dep_req:
            log.debug("activated as " + str(target))

            atr_req = ATR_REQ.decode(target.atr_req)
            self.lrt = lrt
            self.gbt = gbt
            self.gbi = atr_req.gb
            self.miu = atr_req.lr - 3
            self.rwt = 4096/13.56E6 * pow(2, rwt)
            self.did = atr_req.did if atr_req.did > 0 else None
            self.acm = not (target.sens_res or target.sensf_res)
            self.cmd = chr(len(target.dep_req)+1) + target.dep_req
            if target.brty == "106A":
                self.cmd = b"\xF0" + self.cmd
            self.target = target

            self.pcnt.rcvd["ATR"] += 1
            self.pcnt.sent["ATR"] += 1
            log.info("running as " + str(self))

            return self.gbi
438494
def on(self):
        
        for device in self:
            if isinstance(device, (OutputDevice, CompositeOutputDevice)):
                device.on()
595858
final void orpush(CompletableFuture<?> b, BiCompletion<?, ?, ?> c) {
    if (c != null) {
      while (!tryPushStack(c)) {
        if (result != null) {
          lazySetNext(c, null);
          break;
        }
      }
      if (result != null)
        c.tryFire(SYNC);
      else
        b.unipush(new CoCompletion(c));
    }
  }