org.mbari.siam.dataTurbine
Class DNSAdvertiser

java.lang.Object
  extended by org.mbari.siam.dataTurbine.DNSAdvertiser
All Implemented Interfaces:
com.apple.dnssd.BaseListener, com.apple.dnssd.RegisterListener

public class DNSAdvertiser
extends java.lang.Object
implements com.apple.dnssd.RegisterListener

DNSAdvertiser advertises the DataTurbine Service to DNSSD


Field Summary
protected  java.lang.String _instrumentMnemonic
           
protected  java.lang.String _instrumentName
          Unique instrument instance name
protected  java.lang.String _sourceLocationName
           
protected  com.apple.dnssd.DNSSDRegistration _zeroConfService
          ZeroConf registration for OSDT source
 
Constructor Summary
DNSAdvertiser(java.lang.String instrumentName, java.lang.String sourceLocationName, java.lang.String instrumentMnemonic)
          Create the DNSAdvertiser
 
Method Summary
protected  void advertiseService(java.lang.String dtHostName, int dtHostPort, long rcdType, java.util.HashMap channels)
          Advertise OSDT source with ZeroConf
 void close()
          Close the ZeroConf service
 void operationFailed(com.apple.dnssd.DNSSDService service, int errorCode)
          RegisterListener method
 void serviceRegistered(com.apple.dnssd.DNSSDRegistration registration, int flags, java.lang.String serviceName, java.lang.String regType, java.lang.String domain)
          RegisterListener method
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_sourceLocationName

protected java.lang.String _sourceLocationName

_instrumentName

protected java.lang.String _instrumentName
Unique instrument instance name


_instrumentMnemonic

protected java.lang.String _instrumentMnemonic

_zeroConfService

protected com.apple.dnssd.DNSSDRegistration _zeroConfService
ZeroConf registration for OSDT source

Constructor Detail

DNSAdvertiser

public DNSAdvertiser(java.lang.String instrumentName,
                     java.lang.String sourceLocationName,
                     java.lang.String instrumentMnemonic)
Create the DNSAdvertiser

Method Detail

close

public void close()
Close the ZeroConf service


advertiseService

protected void advertiseService(java.lang.String dtHostName,
                                int dtHostPort,
                                long rcdType,
                                java.util.HashMap channels)
Advertise OSDT source with ZeroConf


serviceRegistered

public void serviceRegistered(com.apple.dnssd.DNSSDRegistration registration,
                              int flags,
                              java.lang.String serviceName,
                              java.lang.String regType,
                              java.lang.String domain)
RegisterListener method

Specified by:
serviceRegistered in interface com.apple.dnssd.RegisterListener

operationFailed

public void operationFailed(com.apple.dnssd.DNSSDService service,
                            int errorCode)
RegisterListener method

Specified by:
operationFailed in interface com.apple.dnssd.BaseListener


Copyright © 2003 MBARI.

The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.