AlertCategory

Alert category bitmask, ported from libtorrent::alert_category together with the alert::*_notification static constants (include/libtorrent/alert.hpp).

Each alert belongs to one or more categories. libtorrent's settings_pack::alert_mask is a combination of these flags; only alerts whose category intersects the mask are posted (except non-discardable response alerts such as SaveResumeDataAlert and SessionStatsAlert).

In libtorrent the type is flags::bitfield_flag<std::uint32_t> where each constant is a single set bit (0_bit, 1_bit, ...). Here the same bit layout is carried in a plain Int used as a 32-bit mask. The bit positions are part of libtorrent's ABI (they map onto the alert mask the user configures), so they are reproduced exactly.

The *_notification spellings are kept as aliases because that is how the alert:: base class exposes them and how most client code refers to them.

Properties

Link copied to clipboard
val all: Int

The full bitmask, representing every available category. alert_category::all.

Link copied to clipboard

Individual blocks requested/downloading/finished/rejected/timed-out/cancelled. alert_category::block_progress (bit 24).

Link copied to clipboard

Low-level peer connect/disconnect events. alert_category::connect (bit 5).

Link copied to clipboard
Link copied to clipboard
val dht: Int

DHT node events: incoming searches, bootstrapping, etc. alert_category::dht (bit 10).

Link copied to clipboard
val dhtLog: Int

DHT debug logging. alert_category::dht_log (bit 17).

Link copied to clipboard

Alias for dht.

Link copied to clipboard

Events from pure DHT operations not tied to a torrent. alert_category::dht_operation (bit 18).

Link copied to clipboard
val error: Int

Reports an error: tracker errors/warnings, file errors, resume-data failures, web-seed errors, .torrent file errors, listen-socket errors, port-mapping errors. alert_category::error (bit 0).

Link copied to clipboard

Alias for error.

Link copied to clipboard

Files completing download. alert_category::file_progress (bit 21).

Link copied to clipboard

Enables the incoming-request alert. alert_category::incoming_request (bit 16).

Link copied to clipboard

A peer was blocked by the IP/port blocker. alert_category::ip_block (bit 8).

Link copied to clipboard
Link copied to clipboard
val peer: Int

Peers sending invalid requests, getting banned or snubbed. alert_category::peer (bit 1).

Link copied to clipboard

Per-peer debug logging alerts. alert_category::peer_log (bit 15).

Link copied to clipboard

Alias for peer.

Link copied to clipboard

A limit was reached that might cap the download or upload rate. alert_category::performance_warning (bit 9).

Link copied to clipboard

Verbose piece-picker logging. alert_category::picker_log (bit 20).

Link copied to clipboard

Pieces completing download or failing the hash check. alert_category::piece_progress (bit 22).

Link copied to clipboard

Port-mapping events for NAT-PMP and UPnP. alert_category::port_mapping (bit 2).

Link copied to clipboard

Port-mapping log events (UPnP / NAT-PMP debugging). alert_category::port_mapping_log (bit 19).

Link copied to clipboard
Link copied to clipboard

Session-wide debug logging alerts. alert_category::session_log (bit 13).

Link copied to clipboard
val stats: Int

Per-torrent statistics alerts, posted ~once per second. alert_category::stats (bit 11).

Link copied to clipboard

Alias for stats.

Link copied to clipboard
val status: Int

Torrent or session state changes. alert_category::status (bit 6).

Link copied to clipboard
Link copied to clipboard

Storage events: file errors and move/rename synchronization. alert_category::storage (bit 3).

Link copied to clipboard
Link copied to clipboard

Per-torrent debug logging alerts. alert_category::torrent_log (bit 14).

Link copied to clipboard

All tracker events: announces, responses, warnings and errors. alert_category::tracker (bit 4).

Link copied to clipboard
Link copied to clipboard
val upload: Int

Blocks uploaded to other peers. alert_category::upload (bit 23).