Contribute to pear/File_Bittorrent development by creating an account on GitHub. * Info on the.torrent file format * BEncoding is a simple, easy to implement method of associating * data types with information in a file. The values in a torrent. .NET library for encoding/decoding bencode and reading/writing torrent files - Krusen/BencodeNET.
// 1.x - Parsing strings directly BString bstring = Bencode. DecodeString( '12:Hello World! '); BNumber bnumber = Bencode. DecodeNumber( 'i42e '); BList blist = Bencode. DecodeList( 'l3:foo3:bari42ee '); BDictionary bdictionary = Bencode. DecodeDictionary( 'd3:fooi42e5:Hello6:World!e '); // 2.0 - Parsing strings directly var parser = new BencodeParser(); BString bstring = parser.
ParseString( '12:Hello World! '); BNumber bnumber = parser. ParseString( 'i42e '); BList blist = parser. ParseString( 'l3:foo3:bari42ee '); BDictionary bdictionary = parser. Shapochka salem lisichka s opisaniem. ParseString( 'd3:fooi42e5:Hello6:World!e '); // If you don't know the type you are parsing, you can use the non-generic method IBObject bobject = parser. ParseString( '12:Hellow World!