|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.ros.internal.node.service.DefaultServiceServer<T,S>
public class DefaultServiceServer<T,S>
Default implementation of a ServiceServer
.
Constructor Summary | |
---|---|
DefaultServiceServer(ServiceDeclaration serviceDeclaration,
ServiceResponseBuilder<T,S> serviceResponseBuilder,
AdvertiseAddress advertiseAddress,
MessageDeserializer<T> messageDeserializer,
MessageSerializer<S> messageSerializer,
MessageFactory messageFactory,
java.util.concurrent.ScheduledExecutorService scheduledExecutorService)
|
Method Summary | |
---|---|
void |
addListener(ServiceServerListener<T,S> listener)
Add a ServiceServerListener . |
org.jboss.netty.buffer.ChannelBuffer |
finishHandshake(java.util.Map<java.lang.String,java.lang.String> incomingHeader)
|
GraphName |
getName()
|
java.net.URI |
getUri()
|
org.jboss.netty.channel.ChannelHandler |
newRequestHandler()
|
void |
removeListener(ServiceServerListener<T,S> listener)
Remove a ServiceServerListener . |
void |
shutdown()
Stops the service and unregisters it. |
void |
signalOnMasterRegistrationFailure()
Signal all ServiceServerListener s that the ServiceServer
has failed to register with the master. |
void |
signalOnMasterRegistrationSuccess()
Signal all ServiceServerListener s that the ServiceServer
has been successfully registered with the master. |
void |
signalOnMasterUnregistrationFailure()
Signal all ServiceServerListener s that the ServiceServer
has failed to unregister with the master. |
void |
signalOnMasterUnregistrationSuccess()
Signal all ServiceServerListener s that the ServiceServer
has been successfully unregistered with the master. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DefaultServiceServer(ServiceDeclaration serviceDeclaration, ServiceResponseBuilder<T,S> serviceResponseBuilder, AdvertiseAddress advertiseAddress, MessageDeserializer<T> messageDeserializer, MessageSerializer<S> messageSerializer, MessageFactory messageFactory, java.util.concurrent.ScheduledExecutorService scheduledExecutorService)
Method Detail |
---|
public org.jboss.netty.buffer.ChannelBuffer finishHandshake(java.util.Map<java.lang.String,java.lang.String> incomingHeader)
public java.net.URI getUri()
getUri
in interface ServiceServer<T,S>
URI
for this ServiceServer
public GraphName getName()
getName
in interface ServiceServer<T,S>
ServiceServer
public org.jboss.netty.channel.ChannelHandler newRequestHandler()
public void signalOnMasterRegistrationSuccess()
ServiceServerListener
s that the ServiceServer
has been successfully registered with the master.
Each listener is called in a separate thread.
public void signalOnMasterRegistrationFailure()
ServiceServerListener
s that the ServiceServer
has failed to register with the master.
Each listener is called in a separate thread.
public void signalOnMasterUnregistrationSuccess()
ServiceServerListener
s that the ServiceServer
has been successfully unregistered with the master.
Each listener is called in a separate thread.
public void signalOnMasterUnregistrationFailure()
ServiceServerListener
s that the ServiceServer
has failed to unregister with the master.
Each listener is called in a separate thread.
public void shutdown()
ServiceServer
shutdown
in interface ServiceServer<T,S>
public void addListener(ServiceServerListener<T,S> listener)
ServiceServer
ServiceServerListener
.
addListener
in interface ServiceServer<T,S>
listener
- the ServiceServerListener
to addpublic void removeListener(ServiceServerListener<T,S> listener)
ServiceServer
ServiceServerListener
.
This has no effect if the specified ServiceServerListener
was never
added.
removeListener
in interface ServiceServer<T,S>
listener
- the ServiceServerListener
to removepublic java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |