com.sun.grizzly.async
Interface AsyncQueueDataProcessor

All Known Implementing Classes:
SSLPreProcessor

public interface AsyncQueueDataProcessor

Interface represents processor class, which could be used either by AsyncQueueWriter for pre processing data, which will be sent on a SelectableChannel; or by AsyncQueueReader for post processing data, which were read from a SelectableChannel.

Author:
Alexey Stashok

Method Summary
 ByteBuffer getInternalByteBuffer()
          Method returns the processor's internal ByteBuffer.
 void process(ByteBuffer buffer)
          Method is called to process data.
 

Method Detail

process

void process(ByteBuffer buffer)
             throws IOException
Method is called to process data. Processor could either use passed buffer as input data source and save operation result to the internal ByteBuffer; or passed buffer could be used to return process result to caller.

Parameters:
buffer - ByteBuffer, which, depending on implementation, will be either used as input data source, or contain process results.
Throws:
IOException

getInternalByteBuffer

ByteBuffer getInternalByteBuffer()
Method returns the processor's internal ByteBuffer.

Returns:
internal processor's ByteBuffer


Copyright © 2012 Oracle Corporation. All Rights Reserved.