Overview | Package | Class | Tree | Deprecated | Index | Help
| Apache Tomcat 7.0.29
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.tomcat.util.net
Class AprEndpoint.Poller

    java.lang.Object
      java.lang.Thread
          org.apache.tomcat.util.net.AprEndpoint.Poller

All Implemented Interfaces:
  Runnable

Enclosing class:
  AprEndpoint

    public class AprEndpoint.Poller

extends Thread

Poller class.

Nested Class Summary

Nested classes/interfaces inherited from class java.lang.Thread
`Thread.State, Thread.UncaughtExceptionHandler`

Field Summary
`protected int` | `keepAliveCount`

Fields inherited from class java.lang.Thread
`MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY`

Constructor Summary
`AprEndpoint.Poller(boolean comet)`

Method Summary
`void` | `add(long socket, int timeout)` Add specified socket and associated pool to the poller.
`void` | `destroy()` Destroy the poller.
`int` | `getKeepAliveCount()`
`protected void` | `init()` Create the poller.
`void` | `run()` The background thread that listens for incoming TCP/IP connections and hands them off to an appropriate processor.

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, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### keepAliveCount

    protected volatile int keepAliveCount

Constructor Detail

### AprEndpoint.Poller

    public AprEndpoint.Poller(boolean comet)

Method Detail

### getKeepAliveCount

    public int getKeepAliveCount()

### init

    protected void init()

  Create the poller. With some versions of APR, the maximum poller size will be 62 (recompiling APR is necessary to remove this limitation).

### destroy

    public void destroy()

  Destroy the poller.

  Overrides:
    `destroy` in class `Thread`

### add

    public void add(long socket,
                    int timeout)

  Add specified socket and associated pool to the poller. The socket will be added to a temporary array, and polled first after a maximum amount of time equal to pollTime (in most cases, latency will be much lower, however).

  Parameters:
    `socket` - to add to the poller
    `timeout` - read timeout (in milliseconds) to use with this socket. Use -1 for infinite timeout

### run

    public void run()

  The background thread that listens for incoming TCP/IP connections and hands them off to an appropriate processor.

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

Overview | Package | Class | Tree | Deprecated | Index | Help
| Apache Tomcat 7.0.29
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000-2012 Apache Software Foundation. All Rights Reserved.