Net-Async-Beanstalk
view release on metacpan or search on metacpan
lib/Net/Async/Beanstalk/Stack.pm view on Meta::CPAN
=item count_commands
How many commands are in the stack, including the one which the server
is currently processing.
=item current_command
Returns the command the server is currently processing, or has just
sent a response to, without removing it from the stack.
=item is_busy
A boolean indicating whether the client is busy, ie. has a command
currently being processed or has commands waiting to be sent. Actually
implemented by the same method as L</count_commands>.
=item _pending_commands
Returns the commands which have not yet completed, including the one
which the server is currently processing.
=item _push_command
lib/Net/Async/Beanstalk/Stack.pm view on Meta::CPAN
=cut
has _command_stack => (
is => 'ro',
init_arg => undef,
default => sub { [] },
handles_via => 'Array',
handles => {
count_commands => 'count',
is_busy => 'count',
_pending_commands => 'all',
_push_command => 'push',
_shift_command => 'shift',
},
);
sub current_command { $_[0]->_command_stack->[0] || croak "No active command" }
=back
( run in 0.347 second using v1.01-cache-2.11-cpan-87723dcf8b7 )