Methods Summary |
---|
public byte[] | getAdditionalByteArrayProperty(java.lang.String name)
|
public java.util.List | getAdditionalListProperty(java.lang.String name)
|
public java.lang.Long | getAdditionalLongProperty(java.lang.String name)
|
public java.util.Map | getAdditionalMapProperty(java.lang.String name)
|
public java.lang.Object | getAdditionalProperty(java.lang.String name)
|
public java.lang.String | getAdditionalStringProperty(java.lang.String name)
|
public java.net.URL | getAnnounceURL()A torrent must have a URL that identifies the tracker. This method returns it. However
an extension to this exists to allow multiple trackers, and their backups, to be defined.
See below
|
public TOTorrentAnnounceURLGroup | getAnnounceURLGroup()When a group of sets of trackers is defined their URLs are accessed via this method
|
public byte[] | getComment()Comment is an optional torrent property
|
public byte[] | getCreatedBy()
|
public long | getCreationDate()Gets the creation date of the torrent. Optional property, 0 returned if not set
|
public TOTorrentFile[] | getFiles()A torrent consists of one or more files. These are accessed via this method.
|
public byte[] | getHash()A torrent has a unique SHA1 (20 byte) hash that is computed from some of its contents.
It is used, for example, when contacting a tracker to identify the torrent.
|
public HashWrapper | getHashWrapper()convenience method to get a wrapped hash for performance purposes
|
public AEMonitor | getMonitor()
|
public byte[] | getName()Get the name of the torrent
|
public int | getNumberOfPieces()
|
public long | getPieceLength()Returns the piece length used for the torrent
|
public byte[][] | getPieces()This method provides access to the SHA1 hash values (20 bytes each) that correspond
to the pieces of the torrent.
|
public boolean | getPrivate()
|
public long | getSize()
|
public boolean | hasSameHashAs(org.gudy.azureus2.core3.torrent.TOTorrent other)compares two torrents by hash
|
public boolean | isCreated()
|
public boolean | isSimpleTorrent()A "simple torrent" is one that consists of a single file on its own (i.e. not in a
nested directory).
|
public void | print()A diagnostic method for dumping the tracker contents to "stdout"
|
public void | removeAdditionalProperties()remove all additional properties to clear out the torrent
|
public void | removeAdditionalProperty(java.lang.String name)
|
public void | serialiseToBEncodedFile(java.io.File file)This method will serialise a torrent using the standard "b-encoding" mechanism into a file
|
public java.util.Map | serialiseToMap()This method will serialise a torrent into a Map consistent with that used by the
"b-encoding" routines defined elsewhere
|
public void | serialiseToXMLFile(java.io.File file)This method will serialise a torrent using an XML encoding to a file
|
public void | setAdditionalByteArrayProperty(java.lang.String name, byte[] value)
|
public void | setAdditionalListProperty(java.lang.String name, java.util.List value)
|
public void | setAdditionalLongProperty(java.lang.String name, java.lang.Long value)
|
public void | setAdditionalMapProperty(java.lang.String name, java.util.Map value)
|
public void | setAdditionalProperty(java.lang.String name, java.lang.Object value)set an arbitrary property. Make sure its compatible with bencoding!
|
public void | setAdditionalStringProperty(java.lang.String name, java.lang.String value)The additional properties are used for holding non-core data for Azureus' own user
|
public boolean | setAnnounceURL(java.net.URL url)
|
public void | setComment(java.lang.String comment)
|
public void | setCreationDate(long date)
|
public void | setPieces(byte[][] pieces)This method exists to support the temporary discarding of piece hashes to conserver
memory. It should only be used with care!
|
public void | setPrivate(boolean _private)Note - changing the private attribute CHANGES THE TORRENT HASH
|