source: trunk/libtransmission/torrent-magnet.h

Last change on this file was 14724, checked in by jordan, 5 years ago

use '#pragma once' instead of #ifndef..#define..#endif guards

  • Property svn:keywords set to Date Rev Author Id
File size: 797 bytes
Line 
1/*
2 * This file Copyright (C) 2012-2014 Mnemosyne LLC
3 *
4 * It may be used under the GNU GPL versions 2 or 3
5 * or any future license endorsed by Mnemosyne LLC.
6 *
7 * $Id: torrent-magnet.h 14724 2016-03-29 16:37:21Z mikedld $
8 */
9
10#ifndef __TRANSMISSION__
11 #error only libtransmission should #include this header.
12#endif
13
14#pragma once
15
16#include <inttypes.h>
17#include <time.h>
18
19enum
20{
21    /* defined by BEP #9 */
22    METADATA_PIECE_SIZE = (1024 * 16)
23};
24
25void* tr_torrentGetMetadataPiece (tr_torrent * tor, int piece, size_t * len);
26
27void tr_torrentSetMetadataPiece (tr_torrent * tor, int piece, const void * data, int len);
28
29bool tr_torrentGetNextMetadataRequest (tr_torrent * tor, time_t now, int * setme);
30
31bool tr_torrentSetMetadataSizeHint (tr_torrent * tor, int64_t metadata_size);
32
33double tr_torrentGetMetadataPercent (const tr_torrent * tor);
34
Note: See TracBrowser for help on using the repository browser.