Package fr.dyade.aaa.common.net

Examples of fr.dyade.aaa.common.net.SocketAddress


  final Socket createSocket(ServerDesc server) throws IOException {
    if (server == null)
      throw new ConnectException("Cannot connect to null server");
   
    for (Enumeration e = server.getSockAddrs(); e.hasMoreElements();) {
      SocketAddress sa = (SocketAddress) e.nextElement();

      if (this.logmon.isLoggable(BasicLevel.DEBUG))
        this.logmon.log(BasicLevel.DEBUG,
                        this.getName() + ", try to connect server#" +
                        server.getServerId() +
                        ", addr=" + sa.getHostname() +
                        ", port=" + sa.getPort());
                 
      try {
        Socket socket = createSocket(sa);

        if (this.logmon.isLoggable(BasicLevel.DEBUG))
View Full Code Here


        String hostname,
                    int port) {
    this.sid = sid;
    this.name = name;
    sockAddrs = new Vector();
    sockAddrs.addElement(new SocketAddress(hostname,port));
  }
View Full Code Here

    ((SocketAddress) sockAddrs.firstElement()).resetAddr();
    return getAddr();
  }

  void addSockAddr(String hostname, int port) {
    sockAddrs.addElement(new SocketAddress(hostname, port));
  }
View Full Code Here

    sockAddrs.addElement(new SocketAddress(hostname, port));
  }

  public void updateSockAddr(String hostname, int port) {
    sockAddrs.remove(0);
    sockAddrs.insertElementAt(new SocketAddress(hostname,port), 0);
  }
View Full Code Here

TOP

Related Classes of fr.dyade.aaa.common.net.SocketAddress

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.