Queue::Q::ClaimFIFO::Item - An item in a 'ClaimFIFO' queue
use Queue::Q::ClaimFIFO::Redis; # or ::Perl or ... my $q = ... create object of chosen ClaimFIFO implementation... # consumer: my $item = $q->claim_item; # this is a Queue::Q::ClaimFIFO::Item! my $data = $item->data; # work with data... $q->mark_item_as_done($item);
Instances of this class represent a single item in a
ClaimFIFO type queue (or
DistFIFO if that is based on
Typically, you do not have to create
Queue::Q::ClaimFIFO::Item objects manually. They are implicitly created by the queue when you enqueue a new data structure.
Takes named parameters. Requires an
data parameter that is the item's content.
If the queue backend implementation requires serialization (which is bound to be the general case), the data must be a data structure that can be serialized in the
Sereal format using Sereal::Encoder.
Returns the item's content.
Steffen Mueller, <email@example.com>
Copyright (C) 2012 by Steffen Mueller
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.1 or, at your option, any later version of Perl 5 you may have available.