org.apache.mina.transport.udp

## Class AbstractUdpClient

- java.lang.Object
- - org.apache.mina.service.AbstractIoService
  - - org.apache.mina.service.client.AbstractIoClient
    - - org.apache.mina.transport.udp.AbstractUdpClient

All Implemented Interfaces:
  IoClient, IoService

Direct Known Subclasses:
  NioUdpClient

    public abstract class AbstractUdpClient
    extends AbstractIoClient

Base class for UDP based Clients

Author:
  Apache MINA Project

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.mina.service.AbstractIoService

`AbstractIoService.ServiceState`

### Field Summary

### Fields inherited from class org.apache.mina.service.AbstractIoService

`config, ioHandlerExecutor`

### Constructor Summary

Constructors
`protected` `AbstractUdpClient(IoHandlerExecutor ioHandlerExecutor)` Create an new AbsractUdpClient instance

### Method Summary

Methods
`abstract IoFuture<IoSession>` `connect(SocketAddress remoteAddress, SocketAddress localAddress)` Connects to the specified remote address binding to the specified local address.
`UdpSessionConfig` `getSessionConfig()` Returns the default configuration of the new `IoSession`s created by this service.

### Methods inherited from class org.apache.mina.service.AbstractIoService

`fireServiceActivated, fireServiceInactivated, getFilters, getIoHandler, getIoHandlerExecutor, getManagedSessions, initState, isActive, isCreated, isDisposed, isDisposing, isSuspended, setActive, setCreated, setDisposed, setDisposing, setFilters, setIoHandler, setSuspended`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.apache.mina.api.IoClient

`connect`

### Constructor Detail

#### AbstractUdpClient

    protected AbstractUdpClient(IoHandlerExecutor ioHandlerExecutor)

Create an new AbsractUdpClient instance

### Method Detail

#### connect

    public abstract IoFuture<IoSession> connect(SocketAddress remoteAddress,
                              SocketAddress localAddress)

Connects to the specified remote address binding to the specified local address.

Parameters:
  `remoteAddress` - Remote `SocketAddress` to connect
  `localAddress` - Local `SocketAddress` to use while initiating connection to remote `SocketAddress`
Returns:
  the `IoFuture` instance which is completed when the connection attempt initiated by this call succeeds or fails.

#### getSessionConfig

    public UdpSessionConfig getSessionConfig()

Returns the default configuration of the new `IoSession`s created by this service.

Returns:
  The default configuration for this `IoService`