Examples of addEventListener()


Examples of ImplementacionTeclado.KeyboardHook.addEventListener()

  public static void main( String args[] )
  {
                System.out.println("entra");
    KeyboardHook kh = new KeyboardHook();
                System.out.println("despues");
    kh.addEventListener( new DriverTeclado() );
    BufferedReader br = new BufferedReader( new InputStreamReader( System.in ) );
               // System.out.println("hola");
    try{
      br.readLine();
                    //    System.out.println("try");
View Full Code Here

Examples of com.corundumstudio.socketio.SocketIOServer.addEventListener()

        config.setKeyStorePassword("test1234");
        InputStream stream = SslChatLauncher.class.getResourceAsStream("/keystore.jks");
        config.setKeyStore(stream);

        final SocketIOServer server = new SocketIOServer(config);
        server.addEventListener("chatevent", ChatObject.class, new DataListener<ChatObject>() {
            @Override
            public void onData(SocketIOClient client, ChatObject data, AckRequest ackRequest) {
                server.getBroadcastOperations().sendEvent("chatevent", data);
            }
        });
View Full Code Here

Examples of com.eclipsesource.tabris.app.App.addEventListener()

  @Test
  public void testAddListensTransportsListenOperation() {
    App app = new AppImpl();
    AppListener listener = mock( AppListener.class );

    app.addEventListener( PAUSE, listener );

    verify( environment.getServiceObject() ).listen( "Pause", true );
  }

  @Test
View Full Code Here

Examples of com.github.neuralnetworks.training.backpropagation.BackPropagationAutoencoder.addEventListener()

  // backpropagation for autoencoders
  BackPropagationAutoencoder t = TrainerFactory.backPropagationAutoencoder(ae, trainInputProvider, testInputProvider, error, new NNRandomInitializer(new MersenneTwisterRandomInitializer(-0.01f, 0.01f)), 0.1f, 0.5f, 0f, 0f, 0f);

  // log data
  t.addEventListener(new LogTrainingListener(Thread.currentThread().getStackTrace()[1].getMethodName(), true, false));

  // sequential execution for debugging
  Environment.getInstance().setExecutionMode(EXECUTION_MODE.SEQ);

  // training
View Full Code Here

Examples of com.github.neuralnetworks.training.rbm.AparapiCDTrainer.addEventListener()

  // Contrastive divergence training
  AparapiCDTrainer t = TrainerFactory.cdSigmoidTrainer(rbm, trainInputProvider, testInputProvider, error, new NNRandomInitializer(new MersenneTwisterRandomInitializer(-0.01f, 0.01f)), 0.02f, 0.5f, 0f, 0f, 1, false);
  t.setLayerCalculator(NNFactory.rbmSigmoidSigmoid(rbm));

  // log data
  t.addEventListener(new LogTrainingListener(Thread.currentThread().getStackTrace()[1].getMethodName(), true, false));

  // training
  t.train();

  // testing
View Full Code Here

Examples of com.hazelcast.map.MapService.addEventListener()

        if (getPredicate() == null) {
            eventFilter = new EntryEventFilter(includeValue, key);
        } else {
            eventFilter = new QueryEventFilter(includeValue, key, getPredicate());
        }
        String registrationId = mapService.addEventListener(listener, eventFilter, name);
        endpoint.setListenerRegistration(MapService.SERVICE_NAME, name, registrationId);
        return registrationId;
    }

    public String getServiceName() {
View Full Code Here

Examples of com.jitcaforwin.basic.api.IiTunes.addEventListener()

public class EventDemo {
  public static void main(String args[]) {
    IiTunes iTunes = new iTunesApp();

    IiTunesEventsListener demoListener = new DemoEventHandler();
    iTunes.addEventListener(demoListener);

    System.out.println("Enter for exit!");
    Scanner in = new Scanner(System.in);
    in.nextLine();
View Full Code Here

Examples of com.jitcaforwin.basic.iTunesApp.addEventListener()

public class EventDemo {
  public static void main(String args[]) {
    IiTunes iTunes = new iTunesApp();

    IiTunesEventsListener demoListener = new DemoEventHandler();
    iTunes.addEventListener(demoListener);

    System.out.println("Enter for exit!");
    Scanner in = new Scanner(System.in);
    in.nextLine();
View Full Code Here

Examples of com.sshtools.j2ssh.session.SessionChannelClient.addEventListener()

        if (authenticationState != AuthenticationProtocolState.COMPLETE) {
            throw new SshException("Authentication has not been completed!");
        }

        SessionChannelClient session = new SessionChannelClient();
        session.addEventListener(activeChannelListener);

        if (!connection.openChannel(session, eventListener)) {
            throw new SshException("The server refused to open a session");
        }
View Full Code Here

Examples of com.sun.grid.jgdi.EventClient.addEventListener()

                evc.subscribe(EventTypeEnum.CheckpointMod);
                evc.subscribe(EventTypeEnum.CheckpointDel);

                evc.commit();

                evc.addEventListener(new EventListener() {

                    public void eventOccured(Event evt) {
                        System.out.println("got event " + evt);
                    }
                });
View Full Code Here
TOP
Copyright © 2015 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.