org.glassfish.grizzly
Class AbstractWriter<L>

java.lang.Object
  extended by org.glassfish.grizzly.AbstractWriter<L>
All Implemented Interfaces:
Writer<L>
Direct Known Subclasses:
AbstractNIOAsyncQueueWriter, TemporarySelectorWriter

public abstract class AbstractWriter<L>
extends Object
implements Writer<L>

Abstract class, which provides transitive dependencies for overloaded Writer methods.

Author:
Alexey Stashok

Constructor Summary
AbstractWriter()
           
 
Method Summary
 GrizzlyFuture<WriteResult<WritableMessage,L>> write(Connection connection, L dstAddress, WritableMessage message)
          Method writes the WritableMessage to the specific address.
 void write(Connection connection, L dstAddress, WritableMessage message, CompletionHandler<WriteResult<WritableMessage,L>> completionHandler)
          Method writes the WritableMessage to the specific address.
 GrizzlyFuture<WriteResult<WritableMessage,L>> write(Connection connection, WritableMessage message)
          Method writes the WritableMessage.
 void write(Connection connection, WritableMessage message, CompletionHandler<WriteResult<WritableMessage,L>> completionHandler)
          Method writes the WritableMessage.
 
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.Writer
write
 

Constructor Detail

AbstractWriter

public AbstractWriter()
Method Detail

write

public final GrizzlyFuture<WriteResult<WritableMessage,L>> write(Connection connection,
                                                                 WritableMessage message)
Method writes the WritableMessage.

Specified by:
write in interface Writer<L>
Parameters:
connection - the Connection to write to
message - the WritableMessage, from which the data will be written
Returns:
Future, using which it's possible to check the result

write

public final void write(Connection connection,
                        WritableMessage message,
                        CompletionHandler<WriteResult<WritableMessage,L>> completionHandler)
Method writes the WritableMessage.

Specified by:
write in interface Writer<L>
Parameters:
connection - the Connection to write to
message - the WritableMessage, from which the data will be written
completionHandler - CompletionHandler, which will get notified, when write will be completed

write

public final GrizzlyFuture<WriteResult<WritableMessage,L>> write(Connection connection,
                                                                 L dstAddress,
                                                                 WritableMessage message)
Method writes the WritableMessage to the specific address.

Specified by:
write in interface Writer<L>
Parameters:
connection - the Connection to write to
dstAddress - the destination address the WritableMessage will be sent to
message - the WritableMessage, from which the data will be written
Returns:
Future, using which it's possible to check the result

write

public final void write(Connection connection,
                        L dstAddress,
                        WritableMessage message,
                        CompletionHandler<WriteResult<WritableMessage,L>> completionHandler)
Method writes the WritableMessage to the specific address.

Specified by:
write in interface Writer<L>
Parameters:
connection - the Connection to write to
dstAddress - the destination address the WritableMessage will be sent to
message - the WritableMessage, from which the data will be written
completionHandler - CompletionHandler, which will get notified, when write will be completed


Copyright © 2013 Oracle Corporation. All Rights Reserved.