org.apache.activemq.transport.multicast
Class MulticastTransport

java.lang.Object
  extended by org.apache.activemq.util.ServiceSupport
      extended by org.apache.activemq.transport.TransportSupport
          extended by org.apache.activemq.transport.TransportThreadSupport
              extended by org.apache.activemq.transport.udp.UdpTransport
                  extended by org.apache.activemq.transport.multicast.MulticastTransport
All Implemented Interfaces:
Runnable, Service, Transport

public class MulticastTransport
extends UdpTransport

A multicast based transport.


Constructor Summary
MulticastTransport(OpenWireFormat wireFormat, URI remoteLocation)
           
 
Method Summary
protected  void bind(DatagramSocket socket, SocketAddress localAddress)
           
protected  InetSocketAddress createAddress(URI remoteLocation)
          Creates an address from the given URI
protected  CommandChannel createCommandChannel()
           
protected  DatagramHeaderMarshaller createDatagramHeaderMarshaller()
           
protected  void doStop(ServiceStopper stopper)
           
 long getKeepAliveInterval()
           
protected  InetAddress getMulticastAddress()
           
protected  String getProtocolName()
           
protected  String getProtocolUriScheme()
           
protected  MulticastSocket getSocket()
           
 int getTimeToLive()
           
 boolean isLoopBackMode()
           
 void setKeepAliveInterval(long keepAliveInterval)
           
 void setLoopBackMode(boolean loopBackMode)
           
protected  void setSocket(MulticastSocket socket)
           
 void setTimeToLive(int timeToLive)
           
 
Methods inherited from class org.apache.activemq.transport.udp.UdpTransport
connect, createCommandDatagramChannel, createLocalAddress, createReplayer, doStart, getBufferPool, getChannel, getCommandChannel, getDatagramSize, getLocalSocketAddress, getMinmumWireFormatVersion, getPort, getReceiveCounter, getRemoteAddress, getReplayBuffer, getReplayStrategy, getSequenceGenerator, getTargetAddress, getWireFormat, isReplayEnabled, isTrace, isUseLocalHost, oneway, oneway, resolveHostName, run, setBufferPool, setChannel, setCommandChannel, setDatagramSize, setMinmumWireFormatVersion, setPort, setReplayBuffer, setReplayEnabled, setReplayStrategy, setSequenceGenerator, setTargetEndpoint, setTrace, setUseLocalHost, toString
 
Methods inherited from class org.apache.activemq.transport.TransportThreadSupport
getStackSize, isDaemon, setDaemon, setStackSize
 
Methods inherited from class org.apache.activemq.transport.TransportSupport
asyncRequest, checkStarted, doConsume, getTransportListener, isConnected, isDisposed, isFaultTolerant, isReconnectSupported, isUpdateURIsSupported, narrow, onException, reconnect, request, request, setTransportListener, updateURIs
 
Methods inherited from class org.apache.activemq.util.ServiceSupport
addServiceListener, dispose, isStarted, isStopped, isStopping, postStop, preStart, removeServiceListener, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.apache.activemq.transport.Transport
asyncRequest, getTransportListener, isConnected, isDisposed, isFaultTolerant, isReconnectSupported, isUpdateURIsSupported, narrow, reconnect, request, request, setTransportListener, updateURIs
 
Methods inherited from interface org.apache.activemq.Service
start, stop
 

Constructor Detail

MulticastTransport

public MulticastTransport(OpenWireFormat wireFormat,
                          URI remoteLocation)
                   throws UnknownHostException,
                          IOException
Throws:
UnknownHostException
IOException
Method Detail

getKeepAliveInterval

public long getKeepAliveInterval()

setKeepAliveInterval

public void setKeepAliveInterval(long keepAliveInterval)

isLoopBackMode

public boolean isLoopBackMode()

setLoopBackMode

public void setLoopBackMode(boolean loopBackMode)

getTimeToLive

public int getTimeToLive()

setTimeToLive

public void setTimeToLive(int timeToLive)

getProtocolName

protected String getProtocolName()
Overrides:
getProtocolName in class UdpTransport

getProtocolUriScheme

protected String getProtocolUriScheme()
Overrides:
getProtocolUriScheme in class UdpTransport

bind

protected void bind(DatagramSocket socket,
                    SocketAddress localAddress)
             throws SocketException
Overrides:
bind in class UdpTransport
Throws:
SocketException

doStop

protected void doStop(ServiceStopper stopper)
               throws Exception
Overrides:
doStop in class UdpTransport
Throws:
Exception

createCommandChannel

protected CommandChannel createCommandChannel()
                                       throws IOException
Overrides:
createCommandChannel in class UdpTransport
Throws:
IOException

getMulticastAddress

protected InetAddress getMulticastAddress()

getSocket

protected MulticastSocket getSocket()

setSocket

protected void setSocket(MulticastSocket socket)

createAddress

protected InetSocketAddress createAddress(URI remoteLocation)
                                   throws UnknownHostException,
                                          IOException
Description copied from class: UdpTransport
Creates an address from the given URI

Overrides:
createAddress in class UdpTransport
Throws:
UnknownHostException
IOException

createDatagramHeaderMarshaller

protected DatagramHeaderMarshaller createDatagramHeaderMarshaller()
Overrides:
createDatagramHeaderMarshaller in class UdpTransport


Copyright © 2005-2013 The Apache Software Foundation. All Rights Reserved.