Package net.jini.discovery

Examples of net.jini.discovery.ConstrainableLookupLocator


  return new LookupSimulatorProxyVerifier(myRef);
    }

    public LookupLocator getConstrainedLocator(String host, int port)
    {
  return new ConstrainableLookupLocator(host, port, locatorConstraints);
    }
View Full Code Here


    }

    public LookupLocator getConstrainedLocator(String url)
  throws MalformedURLException
    {
  return new ConstrainableLookupLocator(url, locatorConstraints);
    }
View Full Code Here

      /* start the UnicastThread listening on the new port */
      unicaster = newUnicaster;
      unicaster.start();
      unicastPort = port;
      myLocator = (proxy instanceof RemoteMethodControl) ?
    new ConstrainableLookupLocator(
        myLocator.getHost(), unicaster.port, null) :
    new LookupLocator(myLocator.getHost(), unicaster.port);
      synchronized (announcer) {
    announcer.notify();
      }
View Full Code Here

      myServiceID = newServiceID();
  }
  myRef = (Registrar) serverExporter.export(this);
  proxy = RegistrarProxy.getInstance(myRef, myServiceID);
  myLocator = (proxy instanceof RemoteMethodControl) ?
      new ConstrainableLookupLocator(
    unicastDiscoveryHost, unicaster.port, null) :
      new LookupLocator(unicastDiscoveryHost, unicaster.port);
  /* register myself */
  Item item = new Item(new ServiceItem(myServiceID,
               proxy,
View Full Code Here

    public static LookupLocator getConstrainedLocator(String host, int port)
    {
  if (testLocatorConstraints == null) {
      initLocatorConstraints();
  }
  return new ConstrainableLookupLocator(getFQHostName(host),
                port,
                testLocatorConstraints);
    }
View Full Code Here

    return;
      String[] addrs = parseList(list, false);
      LookupLocator[] locs = new LookupLocator[addrs.length];
      for (int i = 0; i < addrs.length; i++) {
    try {
        locs[i] = new ConstrainableLookupLocator(
            "jini://" + addrs[i], locatorConstraints);
    } catch (MalformedURLException e) {
        JOptionPane.showMessageDialog(Browser.this,
              "\"" + addrs[i] + "\": " +
              e.getMessage(),
View Full Code Here

      /* start the UnicastThread listening on the new port */
      unicaster = newUnicaster;
      unicaster.start();
      unicastPort = port;
      myLocator = (proxy instanceof RemoteMethodControl) ?
    new ConstrainableLookupLocator(
        myLocator.getHost(), unicaster.port, null) :
    new LookupLocator(myLocator.getHost(), unicaster.port);
      synchronized (announcer) {
    announcer.notify();
      }
View Full Code Here

      myServiceID = newServiceID();
  }
  myRef = (Registrar) serverExporter.export(this);
  proxy = RegistrarProxy.getInstance(myRef, myServiceID);
  myLocator = (proxy instanceof RemoteMethodControl) ?
      new ConstrainableLookupLocator(
    unicastDiscoveryHost, unicaster.port, null) :
      new LookupLocator(unicastDiscoveryHost, unicaster.port);
  /* register myself */
  Item item = new Item(new ServiceItem(myServiceID,
               proxy,
View Full Code Here

            String host = (locsStarted[i].getHost()).toLowerCase();
            if( host.indexOf(domain) == -1 ) {//host does not contain domain
                host = new String(host+"."+domain);//add domain
            }//endif
      if (locsStarted[i] instanceof ConstrainableLookupLocator) {
                locsToAdd[i] = new ConstrainableLookupLocator(
        host, locsStarted[i].getPort(),
        ((ConstrainableLookupLocator)locsStarted[i]).getConstraints());
      } else {
                locsToAdd[i] = new LookupLocator(host,locsStarted[i].getPort());
      }
View Full Code Here

            String host = (unqualifiedLocs[i].getHost()).toLowerCase();
            if( host.indexOf(domain) == -1 ) {//host does not contain domain
                host = new String(host+"."+domain);//add domain
            }//endif
            if (unqualifiedLocs[i] instanceof ConstrainableLookupLocator) {
                qualifiedLocs[i] = new ConstrainableLookupLocator(
                    host,unqualifiedLocs[i].getPort(),
                    ((ConstrainableLookupLocator)unqualifiedLocs[i]).getConstraints());
            } else {
                qualifiedLocs[i] = new LookupLocator
                                           (host,unqualifiedLocs[i].getPort());
View Full Code Here

TOP

Related Classes of net.jini.discovery.ConstrainableLookupLocator

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.