org.restlet.engine.io
Class TraceChannel<T extends SelectionChannel>

java.lang.Object
  extended by org.restlet.engine.io.WrapperChannel<T>
      extended by org.restlet.engine.io.WrapperSelectionChannel<T>
          extended by org.restlet.engine.io.TraceChannel<T>
All Implemented Interfaces:
Closeable, Channel, BlockableChannel, SelectionChannel
Direct Known Subclasses:
ReadableTraceChannel, WritableTraceChannel

public class TraceChannel<T extends SelectionChannel>
extends WrapperSelectionChannel<T>

Filter byte channel that sends a copy of all data on the trace output stream. It is important to inherit from SelectableChannel as some framework classes rely on this down the processing chain.

Author:
Jerome Louvel

Constructor Summary
TraceChannel(T wrappedChannel)
          Constructor.
TraceChannel(T wrappedChannel, OutputStream traceStream)
          Constructor.
 
Method Summary
 OutputStream getTraceStream()
          Returns the trace output stream to use if tracing is enabled.
 
Methods inherited from class org.restlet.engine.io.WrapperSelectionChannel
getRegistration, isBlocking, setRegistration, toString
 
Methods inherited from class org.restlet.engine.io.WrapperChannel
close, getWrappedChannel, isOpen
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.nio.channels.Channel
close, isOpen
 

Constructor Detail

TraceChannel

public TraceChannel(T wrappedChannel)
Constructor.

Parameters:
wrappedChannel - The wrapped channel.

TraceChannel

public TraceChannel(T wrappedChannel,
                    OutputStream traceStream)
Constructor.

Parameters:
wrappedChannel - The wrapped channel.
traceStream - The trace stream.
Method Detail

getTraceStream

public OutputStream getTraceStream()
Returns the trace output stream to use if tracing is enabled.

Returns:
The trace output stream to use if tracing is enabled.


Copyright © 2005-2013 Restlet.