Skip to content

Commit 418e996

Browse files
committed
add tracker server jsdoc comment
1 parent dfd235d commit 418e996

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

index.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,6 +453,20 @@ Client.prototype.setInterval = function (intervalMs) {
453453

454454
inherits(Server, EventEmitter)
455455

456+
/**
457+
* A BitTorrent tracker server.
458+
*
459+
* A "BitTorrent tracker" is an HTTP service which responds to GET requests from
460+
* BitTorrent clients. The requests include metrics from clients that help the tracker
461+
* keep overall statistics about the torrent. The response includes a peer list that
462+
* helps the client participate in the torrent.
463+
*
464+
* @param {Object} opts options
465+
* @param {Number} opts.interval interval in ms that clients should announce on
466+
* @param {Number} opts.trustProxy Trust 'x-forwarded-for' header from reverse proxy
467+
* @param {boolean} opts.http Start an http server? (default: true)
468+
* @param {boolean} opts.udp Start a udp server? (default: true)
469+
*/
456470
function Server (opts) {
457471
var self = this
458472
if (!(self instanceof Server)) return new Server(opts)

0 commit comments

Comments
 (0)