Examples of AddObserver()


Examples of org.contikios.cooja.interfaces.Position.addObserver()

    simulation.getEventCentral().addMoteCountListener(newMotesListener = new MoteCountListener() {
      @Override
      public void moteWasAdded(Mote mote) {
        Position pos = mote.getInterfaces().getPosition();
        if (pos != null) {
          pos.addObserver(posObserver);
          SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
              resetViewport = 1;
              repaint();
View Full Code Here

Examples of org.contikios.cooja.interfaces.Radio.addObserver()

          }

        }
      };

      moteRadio.addObserver(observer);
      activeMoteObservers.add(new MoteObservation(mote, moteRadio, observer));
    }

    /* Watchpoints */
    if (mote instanceof WatchpointMote) {
View Full Code Here

Examples of org.dmlite.model.DomainModel.addObserver()

      String reusableModelConfigFilePath,
      String specificModelConfigFilePath) {
    domainModel = new DomainModel(modelCode, dmLiteModelConfigFilePath,
        reusableModelConfigFilePath, specificModelConfigFilePath);
    DomainModel dm = (DomainModel) domainModel;
    dm.addObserver(this);
    ModelConfig modelConfig = domainModel.getModelConfig();
    if (modelConfig.isPersistent()) {
      createPersistentEntries();
    }
  }
View Full Code Here

Examples of org.easetech.easytest.interceptor.InternalInterceptor.addObserver()

        enhancer.setSuperclass(fieldType);
        InternalInterceptor cglibInterceptor = new InternalInterceptor();
        cglibInterceptor.setTargetInstance(fieldInstance);
        cglibInterceptor.setUserIntercepter(interceptorClass.newInstance());
        cglibInterceptor.setExpectedRunTime(timeInMillis);
        cglibInterceptor.addObserver(durationObserver);
        enhancer.setCallback(cglibInterceptor);
        return enhancer.create();
    }

    /**
 
View Full Code Here

Examples of org.easetech.easytest.interceptor.InternalInvocationhandler.addObserver()

        // use JDK dynamic proxy
        InternalInvocationhandler handler = new InternalInvocationhandler();
        handler.setUserIntercepter(interceptorClass.newInstance());
        handler.setTargetInstance(fieldInstance);
        handler.setExpectedRunTime(timeInMillis);
        handler.addObserver(durationObserver);
        return Proxy.newProxyInstance(classLoader, interfaces, handler);
    }

    private Object getCGLIBProxy(Class<? extends MethodIntercepter> interceptorClass, Long timeInMillis,
        Class<?> fieldType, Object fieldInstance) throws InstantiationException, IllegalAccessException {
View Full Code Here

Examples of org.enhydra.jawe.XPDLListenerAndObservable.addObserver()

            boolean receiveEvents,
            boolean modified) {
        XPDLListenerAndObservable xpdl = new XPDLListenerAndObservable(pkg, receiveEvents);
        xpdl.setModified(modified);
        xpdlListenerObservables.add(xpdl);
        xpdl.addObserver(this);
        return xpdl;
    }

    protected XPDLListenerAndObservable getXPDLListenerObservable(Package pkg) {
        Iterator it = xpdlListenerObservables.iterator();
View Full Code Here

Examples of org.eurekastreams.web.client.events.EventBus.addObserver()

    public void show()
    {
        final EventBus eventBus = Session.getInstance().getEventBus();
        if (groups == null)
        {
            eventBus.addObserver(GotPersonJoinedGroupsResponseEvent.class,
                    new Observer<GotPersonJoinedGroupsResponseEvent>()
                    {
                        public void update(final GotPersonJoinedGroupsResponseEvent event)
                        {
                            eventBus.removeObserver(event, this);
View Full Code Here

Examples of org.exist.collections.Collection.addObserver()

                if(collection == null) {
                    transact.abort(txn);
                    throw new XMLDBException(ErrorCodes.INVALID_COLLECTION, "Collection " + path + " not found");
                }
                for(final Observer observer : observers) {
                    collection.addObserver(observer);
                }
                if (uri != null || res.inputSource!=null) {
                    setupParser(collection, res);
                    info = collection.validateXMLResource(txn, broker, resURI, (uri != null) ? new InputSource(uri) : res.inputSource);
                } else if (res.root != null) {
View Full Code Here

Examples of org.ggp.base.player.GamePlayer.addObserver()

          gamer.addObserver(matchPanel);
          gamer.addObserver(detailPanel);

          GamePlayer player = new GamePlayer(port, gamer);
          player.addObserver(networkPanel);
          player.start();

          JTabbedPane tab = new JTabbedPane();
          tab.addTab("Match", matchPanel);
          tab.addTab("Network", networkPanel);
View Full Code Here

Examples of org.ggp.base.player.gamer.Gamer.addObserver()

            gamer = (Gamer) gamerClass.newInstance();
          } catch(Exception ex) { throw new RuntimeException(ex); }
          detailPanel = gamer.getDetailPanel();
          configPanel = gamer.getConfigPanel();

          gamer.addObserver(matchPanel);
          gamer.addObserver(detailPanel);

          GamePlayer player = new GamePlayer(port, gamer);
          player.addObserver(networkPanel);
          player.start();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.