Package com.goodow.realtime.channel

Examples of com.goodow.realtime.channel.Bus


  DocumentImpl(final DocumentBridge internalApi, final Handler<Error> errorHandler) {
    model = new ModelImpl(internalApi, this);
    handlerRegs = new Registrations();
    collaborators = Json.createObject();

    Bus bus = internalApi.store.getBus();
    if (errorHandler != null) {
      handlerRegs.wrap(bus.subscribeLocal(
          Constants.Topic.STORE + "/" + internalApi.id + "/" + Constants.Topic.DOCUMENT_ERROR,
          new Handler<Message<Error>>() {
            @Override
            public void handle(Message<Error> message) {
              Platform.scheduler().handle(errorHandler, message.body());
            }
          }));
    }

    handlerRegs.wrap(bus.subscribe(
        Constants.Topic.STORE + "/" + internalApi.id + Constants.Topic.PRESENCE
        + Constants.Topic.WATCH, new Handler<Message<JsonObject>>() {
          @Override
          public void handle(Message<JsonObject> message) {
            JsonObject body = message.body().set(Key.IS_ME, false);
View Full Code Here

TOP

Related Classes of com.goodow.realtime.channel.Bus

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.