Jala 1.3

Class jala.BitTorrent

Object
   |
   +--jala.BitTorrent

class jala.BitTorrent


This class provides methods to create a BitTorrent metadata file from any desired file.
Defined in BitTorrent.js


Constructor Summary
jala.BitTorrent (<String> filePath, <String> trackerUrl)
            Constructs a new BitTorrent file.
 
Method Summary
 Object get(<String> name)
           Get a torrent property.
 Date getCreationDate()
           Get the creation date of the torrent.
 Number getPieceLength()
           Get the piece length of the torrent.
 helma.File getSourceFile()
           Returns the underlying source file.
 helma.File getTorrentFile()
           Returns the underlying torrent file.
 Array keys()
           Get all available property names.
 void save(<String> filename)
           Saves the torrent as file.
 void set(<String> name, <Object> value)
           Set a torrent property.
 void setCreationDate(<Date> date)
           Set the creation date of the torrent.
 void setPieceLength(<Number> length)
           Set the piece length of the torrent.
 String toString()
           Get a string representation of the torrent.
<static> Object bdecode(<String> code)
           The bdecode method.
<static> String bencode(<Object> obj)
           The bencode method.

Constructor Detail

jala.BitTorrent

jala.BitTorrent(<String> filePath, <String> trackerUrl)

Method Detail

get

Object get(<String> name)

getCreationDate

Date getCreationDate()

getPieceLength

Number getPieceLength()

getSourceFile

helma.File getSourceFile()

getTorrentFile

helma.File getTorrentFile()

keys

Array keys()

save

void save(<String> filename)

set

void set(<String> name, <Object> value)

setCreationDate

void setCreationDate(<Date> date)

setPieceLength

void setPieceLength(<Number> length)

toString

String toString()

bdecode

<static> Object bdecode(<String> code)

bencode

<static> String bencode(<Object> obj)

Jala 1.3

Documentation generated by JSDoc on Tue Jan 8 15:45:31 2008