#include <udp_tracker_connection.hpp>
Definition at line 63 of file udp_tracker_connection.hpp.
enum libtorrent::udp_tracker_connection::action_t [private] |
Definition at line 80 of file udp_tracker_connection.hpp.
| libtorrent::udp_tracker_connection::udp_tracker_connection | ( | asio::strand & | str, | |
| tracker_manager & | man, | |||
| tracker_request const & | req, | |||
| std::string const & | hostname, | |||
| unsigned short | port, | |||
| address | bind_infc, | |||
| boost::weak_ptr< request_callback > | c, | |||
| session_settings const & | stn | |||
| ) |
Definition at line 50 of file udp_tracker_connection.cpp.
References asio::ip::basic_resolver< InternetProtocol, ResolverService >::async_resolve(), asio::detail::socket_ops::bind(), m_name_lookup, m_settings, m_strand, name_lookup(), libtorrent::timeout_handler::set_timeout(), libtorrent::session_settings::tracker_completion_timeout, libtorrent::session_settings::tracker_receive_timeout, and asio::io_service::strand::wrap().
| boost::intrusive_ptr<udp_tracker_connection> libtorrent::udp_tracker_connection::self | ( | ) | [inline, private] |
Reimplemented from libtorrent::timeout_handler.
Definition at line 88 of file udp_tracker_connection.hpp.
| void libtorrent::udp_tracker_connection::name_lookup | ( | asio::error_code const & | error, | |
| udp::resolver::iterator | i | |||
| ) | [private] |
Definition at line 76 of file udp_tracker_connection.cpp.
References asio::ip::basic_endpoint< InternetProtocol >::address(), libtorrent::tracker_connection::bind_interface(), libtorrent::tracker_connection::fail(), libtorrent::tracker_connection::has_requester(), asio::basic_io_object< IoObjectService >::io_service(), asio::ip::address::is_v4(), m_name_lookup, m_socket, m_target, libtorrent::request_callback::m_tracker_address, asio::error_code::message(), asio::detail::error_base< T >::operation_aborted, asio::ip::basic_endpoint< InternetProtocol >::port(), asio::ip::basic_endpoint< InternetProtocol >::protocol(), libtorrent::tracker_connection::requester(), libtorrent::timeout_handler::restart_read_timeout(), send_udp_connect(), and libtorrent::request_callback::tracker_warning().
Referenced by udp_tracker_connection().
| void libtorrent::udp_tracker_connection::timeout | ( | asio::error_code const & | error | ) | [private] |
| void libtorrent::udp_tracker_connection::send_udp_connect | ( | ) | [private] |
Definition at line 137 of file udp_tracker_connection.cpp.
References action_connect, asio::detail::socket_ops::bind(), asio::buffer(), connect_response(), libtorrent::tracker_connection::has_requester(), m_attempts, m_buffer, m_sender, m_socket, m_transaction_id, libtorrent::tracker_connection::requester(), libtorrent::tracker_connection::tracker_req(), udp_buffer_size, libtorrent::detail::write_int32(), and libtorrent::detail::write_uint32().
Referenced by name_lookup().
| void libtorrent::udp_tracker_connection::connect_response | ( | asio::error_code const & | error, | |
| std::size_t | bytes_transferred | |||
| ) | [private] |
Definition at line 169 of file udp_tracker_connection.cpp.
References action_connect, action_error, libtorrent::tracker_request::announce_request, asio::detail::socket_ops::bind(), asio::buffer(), libtorrent::tracker_connection::fail(), libtorrent::tracker_connection::has_requester(), m_attempts, m_buffer, m_connection_id, m_sender, m_socket, m_target, m_transaction_id, asio::error_code::message(), asio::detail::error_base< T >::operation_aborted, libtorrent::detail::read_int32(), libtorrent::detail::read_int64(), libtorrent::tracker_connection::requester(), libtorrent::timeout_handler::restart_read_timeout(), libtorrent::tracker_request::scrape_request, send_udp_announce(), send_udp_scrape(), libtorrent::tracker_connection::tracker_req(), and udp_buffer_size.
Referenced by announce_response(), scrape_response(), and send_udp_connect().
| void libtorrent::udp_tracker_connection::send_udp_announce | ( | ) | [private] |
Definition at line 253 of file udp_tracker_connection.cpp.
References action_announce, announce_response(), libtorrent::big_number::begin(), asio::detail::socket_ops::bind(), asio::buffer(), libtorrent::tracker_request::downloaded, libtorrent::big_number::end(), libtorrent::tracker_request::event, libtorrent::tracker_connection::has_requester(), libtorrent::tracker_request::info_hash, libtorrent::tracker_request::key, libtorrent::tracker_request::left, libtorrent::tracker_request::listen_port, m_attempts, m_buffer, m_connection_id, m_sender, m_socket, m_transaction_id, libtorrent::tracker_request::num_want, libtorrent::tracker_request::pid, libtorrent::tracker_connection::requester(), libtorrent::tracker_connection::tracker_req(), libtorrent::tracker_request::uploaded, libtorrent::detail::write_int32(), libtorrent::detail::write_int64(), and libtorrent::detail::write_uint16().
Referenced by connect_response().
| void libtorrent::udp_tracker_connection::announce_response | ( | asio::error_code const & | error, | |
| std::size_t | bytes_transferred | |||
| ) | [private] |
Definition at line 335 of file udp_tracker_connection.cpp.
References action_announce, action_error, asio::detail::socket_ops::bind(), asio::buffer(), libtorrent::big_number::clear(), connect_response(), libtorrent::tracker_connection::fail(), libtorrent::tracker_connection::has_requester(), libtorrent::peer_entry::ip, m_buffer, m_man, m_sender, m_socket, m_target, m_transaction_id, asio::error_code::message(), asio::detail::error_base< T >::operation_aborted, libtorrent::peer_entry::pid, libtorrent::peer_entry::port, libtorrent::detail::read_int32(), libtorrent::detail::read_uint16(), libtorrent::detail::read_uint8(), libtorrent::tracker_manager::remove_request(), libtorrent::tracker_connection::requester(), libtorrent::timeout_handler::restart_read_timeout(), simple_client::s, libtorrent::tracker_connection::tracker_req(), libtorrent::request_callback::tracker_response(), and udp_buffer_size.
Referenced by send_udp_announce().
| void libtorrent::udp_tracker_connection::send_udp_scrape | ( | ) | [private] |
Definition at line 309 of file udp_tracker_connection.cpp.
References action_scrape, asio::detail::socket_ops::bind(), asio::buffer(), libtorrent::big_number::end(), libtorrent::tracker_request::info_hash, m_attempts, m_buffer, m_connection_id, m_sender, m_socket, m_transaction_id, scrape_response(), libtorrent::tracker_connection::tracker_req(), libtorrent::detail::write_int32(), and libtorrent::detail::write_int64().
Referenced by connect_response().
| void libtorrent::udp_tracker_connection::scrape_response | ( | asio::error_code const & | error, | |
| std::size_t | bytes_transferred | |||
| ) | [private] |
Definition at line 444 of file udp_tracker_connection.cpp.
References action_error, action_scrape, asio::detail::socket_ops::bind(), asio::buffer(), connect_response(), libtorrent::tracker_connection::fail(), libtorrent::tracker_connection::has_requester(), m_buffer, m_man, m_sender, m_socket, m_target, m_transaction_id, asio::error_code::message(), asio::detail::error_base< T >::operation_aborted, libtorrent::detail::read_int32(), libtorrent::tracker_manager::remove_request(), libtorrent::tracker_connection::requester(), libtorrent::timeout_handler::restart_read_timeout(), libtorrent::tracker_connection::tracker_req(), libtorrent::request_callback::tracker_response(), and udp_buffer_size.
Referenced by send_udp_scrape().
| void libtorrent::udp_tracker_connection::on_timeout | ( | ) | [private, virtual] |
Implements libtorrent::timeout_handler.
Definition at line 130 of file udp_tracker_connection.cpp.
References asio::ip::basic_resolver< InternetProtocol, ResolverService >::cancel(), libtorrent::tracker_connection::fail_timeout(), m_name_lookup, and m_socket.
friend class tracker_manager [friend] |
Definition at line 65 of file udp_tracker_connection.hpp.
Reimplemented from libtorrent::tracker_connection.
Definition at line 105 of file udp_tracker_connection.hpp.
Referenced by announce_response(), and scrape_response().
Reimplemented from libtorrent::timeout_handler.
Definition at line 107 of file udp_tracker_connection.hpp.
Referenced by udp_tracker_connection().
Definition at line 108 of file udp_tracker_connection.hpp.
Referenced by name_lookup(), on_timeout(), and udp_tracker_connection().
boost::shared_ptr<datagram_socket> libtorrent::udp_tracker_connection::m_socket [private] |
Definition at line 109 of file udp_tracker_connection.hpp.
Referenced by announce_response(), connect_response(), name_lookup(), on_timeout(), scrape_response(), send_udp_announce(), send_udp_connect(), and send_udp_scrape().
Definition at line 110 of file udp_tracker_connection.hpp.
Referenced by announce_response(), connect_response(), name_lookup(), and scrape_response().
Definition at line 111 of file udp_tracker_connection.hpp.
Referenced by announce_response(), connect_response(), scrape_response(), send_udp_announce(), send_udp_connect(), and send_udp_scrape().
int libtorrent::udp_tracker_connection::m_transaction_id [private] |
Definition at line 113 of file udp_tracker_connection.hpp.
Referenced by announce_response(), connect_response(), scrape_response(), send_udp_announce(), send_udp_connect(), and send_udp_scrape().
Definition at line 114 of file udp_tracker_connection.hpp.
Referenced by connect_response(), send_udp_announce(), and send_udp_scrape().
session_settings const& libtorrent::udp_tracker_connection::m_settings [private] |
int libtorrent::udp_tracker_connection::m_attempts [private] |
Definition at line 116 of file udp_tracker_connection.hpp.
Referenced by connect_response(), send_udp_announce(), send_udp_connect(), and send_udp_scrape().
std::vector<char> libtorrent::udp_tracker_connection::m_buffer [private] |
Definition at line 117 of file udp_tracker_connection.hpp.
Referenced by announce_response(), connect_response(), scrape_response(), send_udp_announce(), send_udp_connect(), and send_udp_scrape().
1.5.6