130 likes | 228 Views
Chapter 6: In Depth Discovery. Chapter 7:. טלי ערבה גיא גילעד. Multicast request Communication flow. Multicast announcement Communication flow. Unicast discovery Communication flow. package net.jini.discovery; import java.util.EventListener; public interface DiscoveryListener
E N D
Chapter 6: In Depth Discovery. Chapter 7: טלי ערבה גיא גילעד
Multicast request Communication flow
Multicast announcement Communication flow
Unicast discovery Communication flow
package net.jini.discovery; import java.util.EventListener; public interface DiscoveryListener extends EventListener { public void discovered(DiscoveryEvent ev); public void discarded(DiscoveryEvent ev); }
package net.jini.discovery; import java.util.EventObject; public class DiscoveryEvent extends EventObject { // … some methods elided … public ServiceRegistrar[] getRegistrars(); }
package net.jini.discovery; public class LookupDiscovery { public static final String[] ALL_GROUPS = null; public static final String[] NO_GROUPS = new String[0]; public LookupDiscovery(String[] grps) throws IOException; public void addDiscoveryListener(DiscoveryListener l); public void removeDiscoveryListener(DiscoveryListener l);
public void discard(ServiceRegistrar reg); public String[] getGroups(); public void setGroups(String[] grps) throws IOException; public void addGroups(String[] grps) throws IOException; public void removeGroups(String[] grps); public void terminate(); }
package net.jini.discovery; public class LookupLocator implements Serializable { public LookupLocator(String host, int port); public LookupLocator(String url) throws MalformedURLException; public String getHost(); public int getPort(); public ServiceRegistrar getRegistrar() throws IOException, ClassNotFoundException; public ServiceRegistrar getRegistrar(int timeout) throws IOException, ClassNotFoundException; }
security permission net.jini.discovery.DiscoveryPermission “*” permission net.jini.discovery.DiscoveryPermission “unsafe” permission net.jini.discovery.DiscoveryPermission “”