IO::Async::Buffer - backward-compatibility wrapper around C<IO::Async::Stream>


NAME

IO::Async::Buffer - backward-compatibility wrapper around IO::Async::Stream

Back to Top


SYNOPSIS

This class should not be used in new code, and is provided for backward compatibility for older applications that still use it. It has been renamed to IO::Async::Stream. Any application using this class should simply change

 use IO::Async::Buffer;
 my $buffer = IO::Async::Buffer->new( .... );

into

 use IO::Async::Stream;
 my $stream = IO::Async::Stream->new( .... );

The behaviour has not otherwise changed.

Back to Top


CONSTRUCTOR

$buffer = IO::Async::Buffer->new( %params )

This function wraps a call to IO::Async::Stream->new(). It will translate the following deprecated options as well:

on_incoming_data => CODE

This option is deprecated and should not be used in new code. It is maintained as a backward-compatibility synonym for on_read.

Back to Top


DEPRECATED METHODS

This class also provides wrappers for methods that have been renamed between IO::Async::Buffer and IO::Async::Stream.

$buffer->send( $data )

A synonym for write().

Back to Top


SEE ALSO

Back to Top


AUTHOR

Paul Evans <leonerd@leonerd.org.uk>

Back to Top

 IO::Async::Buffer - backward-compatibility wrapper around C<IO::Async::Stream>