Examples of DisconnectEvent


Examples of clueless.events.DisconnectEvent

      }
      public void windowClosing(WindowEvent arg0) {
        int choice = JOptionPane.showConfirmDialog(jfrm, "Are you sure you wish to quit?",
            "Quit Game", JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE);
        if (choice == JOptionPane.YES_OPTION) {
          controller.fireDisconnectEvent(new DisconnectEvent(this));
          jfrm.dispose();
        }
      }
      public void windowDeactivated(WindowEvent arg0) {}
      public void windowDeiconified(WindowEvent arg0) {}
View Full Code Here

Examples of clueless.events.DisconnectEvent

      }
      public void windowClosing(WindowEvent arg0) {
        int choice = JOptionPane.showConfirmDialog(jfrm, "Are you sure you wish to quit?",
            "Quit Game", JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE);
        if (choice == JOptionPane.YES_OPTION) {
          controller.fireDisconnectEvent(new DisconnectEvent(this));
          jfrm.dispose();
        }
      }
      public void windowDeactivated(WindowEvent arg0) {}
      public void windowDeiconified(WindowEvent arg0) {}
View Full Code Here

Examples of clueless.events.DisconnectEvent

  public void quitGame()
  {
    int choice = JOptionPane.showConfirmDialog(jfrm, "Are you sure you wish to quit?",
        "Quit Game", JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE);
    if (choice == JOptionPane.YES_OPTION) {
      controller.fireDisconnectEvent(new DisconnectEvent(this));
      jfrm.dispose();   
    }
  }
View Full Code Here

Examples of erki.talk.clients.erki.event.DisconnectEvent

                            "NO_HOST_AND_PORT"), Formatter.getErrorFormat()));
            return;
        }
       
        if (event.getText().toLowerCase().equals("/disconnect")) {
            Controller.getInstance().dispatchEvent(new DisconnectEvent());
            return;
        }
       
        if (event.getText().toLowerCase().startsWith("/quit ")) {
            Controller.getInstance()
View Full Code Here

Examples of jpower.socket.event.DisconnectEvent

            reader.close();
            handler.getSocket().close();
        } catch (IOException e) {
            eventBus.dispatchEvent(new ErrorEvent(6, e, handler.getPowerSocket()));
        }
        eventBus.dispatchEvent(new DisconnectEvent(handler.getPowerSocket()));
    }
View Full Code Here

Examples of org.asteriskjava.manager.event.DisconnectEvent

    }

    @Test
    public void testReconnect() throws Exception
    {
        DisconnectEvent disconnectEvent;

        replay(mockSocket);
        disconnectEvent = new DisconnectEvent(this);

        // fake successful login
        mc.setState(ManagerConnectionState.CONNECTED);

        mc.setUsername("username");
View Full Code Here

Examples of org.asteriskjava.manager.event.DisconnectEvent

    }

    @Test
    public void testReconnectWithIOException() throws Exception
    {
        DisconnectEvent disconnectEvent;

        replay(mockSocket);
        disconnectEvent = new DisconnectEvent(this);

        // fake successful login
        mc.setState(ManagerConnectionState.CONNECTED);

        mc.setThrowIOExceptionOnFirstSocketCreate(true);
View Full Code Here

Examples of org.asteriskjava.manager.event.DisconnectEvent

    }

    @Test
    public void testReconnectWithTimeoutException() throws Exception
    {
        DisconnectEvent disconnectEvent;

        mockSocket.close();
        replay(mockSocket);
        disconnectEvent = new DisconnectEvent(this);

        // fake successful login
        mc.setState(ManagerConnectionState.CONNECTED);

        mc.setThrowTimeoutExceptionOnFirstLogin(true);
View Full Code Here

Examples of org.asteriskjava.manager.event.DisconnectEvent

        }
        finally
        {
            this.dead = true;
            // cleans resources and reconnects if needed
            DisconnectEvent disconnectEvent = new DisconnectEvent(source);
            disconnectEvent.setDateReceived(DateUtil.getDate());
            dispatcher.dispatchEvent(disconnectEvent);
        }
    }
View Full Code Here

Examples of org.asteriskjava.manager.event.DisconnectEvent

        }
        finally
        {
            this.dead = true;
            // cleans resources and reconnects if needed
            DisconnectEvent disconnectEvent = new DisconnectEvent(source);
            disconnectEvent.setDateReceived(DateUtil.getDate());
            dispatcher.dispatchEvent(disconnectEvent);
        }
    }
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.