|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.glassfish.grizzly.AbstractTransport
org.glassfish.grizzly.nio.NIOTransport
public abstract class NIOTransport
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.glassfish.grizzly.Transport |
|---|
Transport.State |
| Field Summary | |
|---|---|
protected NIOChannelDistributor |
nioChannelDistributor
|
protected static java.util.Random |
RANDOM
|
protected SelectionKeyHandler |
selectionKeyHandler
|
protected SelectorHandler |
selectorHandler
|
protected java.nio.channels.spi.SelectorProvider |
selectorProvider
|
protected SelectorRunner[] |
selectorRunners
|
protected int |
selectorRunnersCount
|
| Fields inherited from class org.glassfish.grizzly.AbstractTransport |
|---|
attributeBuilder, connectionMonitoringConfig, isBlocking, isStandalone, kernelPool, kernelPoolConfig, managedWorkerPool, memoryManager, name, processor, processorSelector, readBufferSize, state, strategy, threadPoolMonitoringConfig, transportMonitoringConfig, workerPoolConfig, workerThreadPool, writeBufferSize |
| Constructor Summary | |
|---|---|
NIOTransport(java.lang.String name)
|
|
| Method Summary | |
|---|---|
protected abstract void |
closeConnection(Connection connection)
Close the connection, managed by Transport |
NIOChannelDistributor |
getNIOChannelDistributor()
|
SelectionKeyHandler |
getSelectionKeyHandler()
|
SelectorHandler |
getSelectorHandler()
|
java.nio.channels.spi.SelectorProvider |
getSelectorProvider()
Get the SelectorProvider to be used by this transport. |
protected SelectorRunner[] |
getSelectorRunners()
|
int |
getSelectorRunnersCount()
|
protected static void |
notifyProbesError(NIOTransport transport,
java.lang.Throwable error)
Notify registered TransportProbes about the error. |
protected static void |
notifyProbesPause(NIOTransport transport)
Notify registered TransportProbes about the pause event. |
protected static void |
notifyProbesResume(NIOTransport transport)
Notify registered TransportProbes about the resume event. |
protected static void |
notifyProbesStart(NIOTransport transport)
Notify registered TransportProbes about the start event. |
protected static void |
notifyProbesStop(NIOTransport transport)
Notify registered TransportProbes about the stop event. |
void |
notifyTransportError(java.lang.Throwable error)
Method gets invoked, when error occur during the Transport lifecycle. |
void |
setNIOChannelDistributor(NIOChannelDistributor nioChannelDistributor)
|
void |
setSelectionKeyHandler(SelectionKeyHandler selectionKeyHandler)
|
void |
setSelectorHandler(SelectorHandler selectorHandler)
|
void |
setSelectorProvider(java.nio.channels.spi.SelectorProvider selectorProvider)
Set the SelectorProvider to be used by this transport. |
void |
setSelectorRunnersCount(int selectorRunnersCount)
|
void |
start()
Starts the transport |
protected void |
startSelectorRunners()
|
protected void |
stopSelectorRunners()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.glassfish.grizzly.Transport |
|---|
configureStandalone, fireIOEvent, getReader, getReader, getWriter, getWriter |
| Field Detail |
|---|
protected static final java.util.Random RANDOM
protected SelectorHandler selectorHandler
protected SelectionKeyHandler selectionKeyHandler
protected int selectorRunnersCount
protected SelectorRunner[] selectorRunners
protected NIOChannelDistributor nioChannelDistributor
protected java.nio.channels.spi.SelectorProvider selectorProvider
| Constructor Detail |
|---|
public NIOTransport(java.lang.String name)
| Method Detail |
|---|
public SelectionKeyHandler getSelectionKeyHandler()
public void setSelectionKeyHandler(SelectionKeyHandler selectionKeyHandler)
public SelectorHandler getSelectorHandler()
public void setSelectorHandler(SelectorHandler selectorHandler)
public int getSelectorRunnersCount()
public void setSelectorRunnersCount(int selectorRunnersCount)
public java.nio.channels.spi.SelectorProvider getSelectorProvider()
SelectorProvider to be used by this transport.
SelectorProvider to be used by this transport.public void setSelectorProvider(java.nio.channels.spi.SelectorProvider selectorProvider)
SelectorProvider to be used by this transport.
selectorProvider - the SelectorProvider.
public void start()
throws java.io.IOException
AbstractTransport
start in interface Transportstart in class AbstractTransportjava.io.IOException
protected void startSelectorRunners()
throws java.io.IOException
java.io.IOException
protected void stopSelectorRunners()
throws java.io.IOException
java.io.IOExceptionpublic NIOChannelDistributor getNIOChannelDistributor()
public void setNIOChannelDistributor(NIOChannelDistributor nioChannelDistributor)
public void notifyTransportError(java.lang.Throwable error)
error - Throwable.protected SelectorRunner[] getSelectorRunners()
protected static void notifyProbesError(NIOTransport transport,
java.lang.Throwable error)
TransportProbes about the error.
transport - the Transport event occurred on.protected static void notifyProbesStart(NIOTransport transport)
TransportProbes about the start event.
transport - the Transport event occurred on.protected static void notifyProbesStop(NIOTransport transport)
TransportProbes about the stop event.
transport - the Transport event occurred on.protected static void notifyProbesPause(NIOTransport transport)
TransportProbes about the pause event.
transport - the Transport event occurred on.protected static void notifyProbesResume(NIOTransport transport)
TransportProbes about the resume event.
transport - the Transport event occurred on.
protected abstract void closeConnection(Connection connection)
throws java.io.IOException
AbstractTransport
closeConnection in class AbstractTransportjava.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||