Package com.sun.jini.discovery

Examples of com.sun.jini.discovery.DiscoveryConstraints$ConstraintReducer


    Socket sock = null;
    MulticastAnnouncement announcement = null;
    UnicastResponse response = null;
    if (req instanceof Socket) {
        // Perform unicast discovery on the connected socket.
        DiscoveryConstraints unicastDiscoveryConstraints =
      DiscoveryConstraints.process(
          rawUnicastDiscoveryConstraints);
        sock = (Socket)req;
        UnicastResponse resp;
        try {
View Full Code Here


  } catch (UnknownHostException uhe) {
      // Name resolution failed.
      // We'll just try to use the host name later anyway.
  }
 
  DiscoveryConstraints dc = DiscoveryConstraints.process(constraints);
  int pv = dc.chooseProtocolVersion();
  Discovery disco;
  switch (pv) {
      case Discovery.PROTOCOL_VERSION_1:
    disco = Discovery.getProtocol1();
    break;
      case Discovery.PROTOCOL_VERSION_2:
    disco = Discovery.getProtocol2(null);
    break;
      default:
    throw new AssertionError(pv);
  }

  long deadline = dc.getConnectionDeadline(Long.MAX_VALUE);
  long connectionTimeout = getTimeout(deadline);

  if (addrs == null) {
      return getSingleResponse(host, connectionTimeout, port, dc, disco);
  }
View Full Code Here

  } catch (UnknownHostException uhe) {
      // Name resolution failed.
      // We'll just try to use the host name later anyway.
  }
 
  DiscoveryConstraints dc = DiscoveryConstraints.process(constraints);
  int pv = dc.chooseProtocolVersion();
  Discovery disco;
  switch (pv) {
      case Discovery.PROTOCOL_VERSION_1:
    disco = Discovery.getProtocol1();
    break;
      case Discovery.PROTOCOL_VERSION_2:
    disco = Discovery.getProtocol2(null);
    break;
      default:
    throw new AssertionError(pv);
  }

  long deadline = dc.getConnectionDeadline(Long.MAX_VALUE);
  long connectionTimeout = getTimeout(deadline);

  if (addrs == null) {
      return getSingleResponse(host, connectionTimeout, port, dc, disco);
  }
View Full Code Here

    Socket sock = null;
    MulticastAnnouncement announcement = null;
    UnicastResponse response = null;
    if (req instanceof Socket) {
        // Perform unicast discovery on the connected socket.
        DiscoveryConstraints unicastDiscoveryConstraints =
      DiscoveryConstraints.process(
          rawUnicastDiscoveryConstraints);
        sock = (Socket)req;
        UnicastResponse resp;
        try {
View Full Code Here

  } catch (UnknownHostException uhe) {
      // Name resolution failed.
      // We'll just try to use the host name later anyway.
  }
 
  DiscoveryConstraints dc = DiscoveryConstraints.process(constraints);
  int pv = dc.chooseProtocolVersion();
  Discovery disco;
  switch (pv) {
      case Discovery.PROTOCOL_VERSION_1:
    disco = Discovery.getProtocol1();
    break;
      case Discovery.PROTOCOL_VERSION_2:
    disco = Discovery.getProtocol2(null);
    break;
      default:
    throw new AssertionError(pv);
  }

  long deadline = dc.getConnectionDeadline(Long.MAX_VALUE);
  long connectionTimeout = getTimeout(deadline);

  if (addrs == null) {
      return getSingleResponse(host, connectionTimeout, port, dc, disco);
  }
View Full Code Here

    Socket sock = null;
    MulticastAnnouncement announcement = null;
    UnicastResponse response = null;
    if (req instanceof Socket) {
        // Perform unicast discovery on the connected socket.
        DiscoveryConstraints unicastDiscoveryConstraints =
      DiscoveryConstraints.process(
          rawUnicastDiscoveryConstraints);
        sock = (Socket)req;
        UnicastResponse resp;
        try {
View Full Code Here

TOP

Related Classes of com.sun.jini.discovery.DiscoveryConstraints$ConstraintReducer

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.