NAME
Net::BitTorrent::Session::Piece::Block - Outgoing request
Constructor
new ( { [ARGS] } )
-
Creates a
Net::BitTorrent::Session::Piece::Block
object. This constructor should not be used directly.
Methods
as_string ( [ VERBOSE ] )
-
Returns a 'ready to print' dump of the
Net::BitTorrent::Session::Piece::Block
object's data structure. If called in void context, the structure is printed toSTDERR
.See also: Net::BitTorrent
get_client ( )
-
Returns the Net::BitTorrent object related to this block.
get_index ( )
-
Returns the zero based index of the related Net::BitTorrent::Session::Piece object.
get_length ( )
-
Returns the amount of data covered by the block.
get_offset ( )
-
Returns the offset of the block in reference to the beginning of the piece.
get_peers ( )
-
Returns a list of all related Net::BitTorrent::Session::Peer objects. Unless the session is in endgame mode, the list will contain a single peer.
get_piece ( )
-
Returns the Net::BitTorrent::Session::Piece object related to this piece.
get_session ( )
-
Returns the Net::BitTorrent::Session object related to this block.
Author
Sanko Robinson <sanko@cpan.org> - http://sankorobinson.com/
CPAN ID: SANKO
License and Legal
Copyright 2008 by Sanko Robinson <sanko@cpan.org>
This program is free software; you can redistribute it and/or modify it under the same terms as Perl 5.10 (or higher). See http://www.perl.com/perl/misc/Artistic.html or the LICENSE file included with this distribution.
All POD documentation is covered by the Creative Commons Attribution- Noncommercial-Share Alike 3.0 License (http://creativecommons.org/licenses/by-nc-sa/3.0/us/).
Neither this module nor the Author is affiliated with BitTorrent, Inc.