Package org.apache.avro.ipc

# Class DatagramServer

java.lang.Object
java.lang.Thread
org.apache.avro.ipc.DatagramServer

All Implemented Interfaces:
  `Runnable`, `Server`

public class DatagramServer extends Thread implements Server
A datagram-based server implementation. This uses a simple, non-standard wire protocol and is not intended for production services.

## Nested Class Summary

## Nested classes/interfaces inherited from class java.lang.Thread

`Thread.State, Thread.UncaughtExceptionHandler`

## Field Summary

### Fields inherited from class java.lang.Thread

`MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY`

## Constructor Summary

Constructors
Constructor
Description
`DatagramServer(Responder responder, SocketAddress addr)`

## Method Summary

Modifier and Type
Method
Description
`void`
`close()`
Stop this server.
`int`
`getPort()`
The port this server runs on.
`static void`
`main(String[] arg)`
`void`
`run()`

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

`activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield`

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

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

### Methods inherited from interface org.apache.avro.ipc.Server

`join, start`

## Constructor Details

### DatagramServer

public DatagramServer(Responder responder, SocketAddress addr) throws IOException

Throws:
  `IOException`

## Method Details

### getPort

public int getPort()
Description copied from interface: `Server`
The port this server runs on.

Specified by:
  `getPort` in interface `Server`

### run

public void run()

Specified by:
  `run` in interface `Runnable`
Overrides:
  `run` in class `Thread`

### close

public void close()
Description copied from interface: `Server`
Stop this server.

Specified by:
  `close` in interface `Server`

### main

public static void main(String[] arg) throws Exception

Throws:
  `Exception`