|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.ecf.core.AbstractContainer org.eclipse.ecf.discovery.AbstractDiscoveryContainerAdapter org.eclipse.ecf.provider.jmdns.container.JMDNSDiscoveryContainer
public class JMDNSDiscoveryContainer
Field Summary | |
---|---|
static int |
DEFAULT_REQUEST_TIMEOUT
|
Fields inherited from class org.eclipse.ecf.discovery.AbstractDiscoveryContainerAdapter |
---|
allServiceListeners, serviceListeners, servicesNamespaceName, serviceTypeListeners |
Fields inherited from interface org.eclipse.ecf.discovery.service.IDiscoveryService |
---|
CONTAINER_ID, CONTAINER_NAME |
Constructor Summary | |
---|---|
JMDNSDiscoveryContainer()
|
Method Summary | |
---|---|
void |
connect(ID targetID1,
IConnectContext joinContext)
Connect to a target remote process or process group. |
void |
disconnect()
Disconnect. |
void |
dispose()
Dispose this IContainer instance. |
ID |
getConnectedID()
IContainer methods |
java.lang.String |
getContainerName()
|
IServiceInfo |
getServiceInfo(IServiceID service)
IDiscoveryContainerAdapter methods |
IServiceInfo[] |
getServices()
Synchronously get service info about all known services |
IServiceInfo[] |
getServices(IServiceTypeID type)
Synchronously get service info about all known services of given service type |
IServiceTypeID[] |
getServiceTypes()
Synchronously get service info about all known services of given service type |
IServiceInfo[] |
purgeCache()
Purges the underlying IServiceInfo cache if available in the current provider |
void |
registerService(IServiceInfo serviceInfo)
Register the given service. |
void |
serviceAdded(javax.jmdns.ServiceEvent arg0)
A service has been added. |
void |
serviceRemoved(javax.jmdns.ServiceEvent arg0)
A service has been removed. |
void |
serviceResolved(javax.jmdns.ServiceEvent arg0)
A service has been resolved. |
void |
serviceTypeAdded(javax.jmdns.ServiceEvent arg0)
A new service type was discovered. |
void |
unregisterAllServices()
Unregister all previously registered service. |
void |
unregisterService(IServiceInfo serviceInfo)
Unregister a previously registered service defined by serviceInfo. |
Methods inherited from class org.eclipse.ecf.core.AbstractContainer |
---|
addListener, fireContainerEvent, getAdapter, getPasswordFromConnectContext, removeListener |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.ecf.discovery.IDiscoveryLocator |
---|
addServiceListener, addServiceListener, addServiceTypeListener, getAsyncServiceInfo, getAsyncServices, getAsyncServices, getAsyncServiceTypes, getServicesNamespace, removeServiceListener, removeServiceListener, removeServiceTypeListener |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
---|
getAdapter |
Methods inherited from interface org.eclipse.ecf.discovery.IDiscoveryAdvertiser |
---|
getServicesNamespace |
Methods inherited from interface org.eclipse.core.runtime.IAdaptable |
---|
getAdapter |
Field Detail |
---|
public static final int DEFAULT_REQUEST_TIMEOUT
Constructor Detail |
---|
public JMDNSDiscoveryContainer()
Method Detail |
---|
public ID getConnectedID()
getConnectedID
in interface IContainer
null
if container not connected.public void dispose()
IContainer
dispose
in interface IContainer
dispose
in class AbstractDiscoveryContainerAdapter
public void connect(ID targetID1, IConnectContext joinContext) throws ContainerConnectException
IContainer
connect
in interface IContainer
targetID1
- the ID of the remote server or group to connect to. See
IContainer.getConnectNamespace()
for a explanation of the
constraints upon this parameter.joinContext
- any required context to allow this container to authenticate.
May be null
if underlying provider does not
have any authentication requirements for connection.
ContainerConnectException
- thrown if communication cannot be established with remote
service. Causes can include network connection failure,
authentication failure, server error, or if container is
already connected.public void disconnect()
IContainer
null
.
disconnect
in interface IContainer
public IServiceInfo getServiceInfo(IServiceID service)
getServiceInfo
in interface IDiscoveryLocator
null
if no
information retrievable.public IServiceInfo[] getServices()
IDiscoveryLocator
getServices
in interface IDiscoveryLocator
null
. May be of length 0.public IServiceInfo[] getServices(IServiceTypeID type)
IDiscoveryLocator
getServices
in interface IDiscoveryLocator
null
. May be of length 0.public IServiceTypeID[] getServiceTypes()
IDiscoveryLocator
getServiceTypes
in interface IDiscoveryLocator
null
. May be of length 0.public void registerService(IServiceInfo serviceInfo)
IDiscoveryAdvertiser
registerService
in interface IDiscoveryAdvertiser
serviceInfo
- IServiceInfo of the service to be published. Must not be
null
.public void unregisterService(IServiceInfo serviceInfo)
IDiscoveryAdvertiser
unregisterService
in interface IDiscoveryAdvertiser
serviceInfo
- IServiceInfo defining the service to unregister. Must not be
null
.public void unregisterAllServices()
IDiscoveryAdvertiser
unregisterAllServices
in interface IDiscoveryAdvertiser
unregisterAllServices
in class AbstractDiscoveryContainerAdapter
IDiscoveryAdvertiser.unregisterAllServices()
public IServiceInfo[] purgeCache()
IDiscoveryLocator
purgeCache
in interface IDiscoveryLocator
purgeCache
in class AbstractDiscoveryContainerAdapter
IDiscoveryLocator.purgeCache()
public void serviceTypeAdded(javax.jmdns.ServiceEvent arg0)
javax.jmdns.ServiceTypeListener
serviceTypeAdded
in interface javax.jmdns.ServiceTypeListener
arg0
- The service event providing the fully qualified type of
the service.public void serviceAdded(javax.jmdns.ServiceEvent arg0)
javax.jmdns.ServiceListener
serviceAdded
in interface javax.jmdns.ServiceListener
arg0
- The ServiceEvent providing the name and fully qualified type
of the service.public void serviceRemoved(javax.jmdns.ServiceEvent arg0)
javax.jmdns.ServiceListener
serviceRemoved
in interface javax.jmdns.ServiceListener
arg0
- The ServiceEvent providing the name and fully qualified type
of the service.public void serviceResolved(javax.jmdns.ServiceEvent arg0)
javax.jmdns.ServiceListener
serviceResolved
in interface javax.jmdns.ServiceListener
arg0
- The ServiceEvent providing the name, the fully qualified
type of the service, and the service info record, or null if the service
could not be resolved.public java.lang.String getContainerName()
getContainerName
in class AbstractDiscoveryContainerAdapter
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |