Uses of Class
org.johnnei.javatorrent.torrent.files.Piece
-
-
Uses of Piece in org.johnnei.javatorrent.disk
Methods in org.johnnei.javatorrent.disk that return Piece Modifier and Type Method Description PieceDiskJobCheckHash. getPiece()Gets the piece for which the hash has been verified.PieceDiskJobReadBlock. getPiece()The piece from which data was read.PieceDiskJobWriteBlock. getPiece()Gets the piece for which this store task is being used.Constructors in org.johnnei.javatorrent.disk with parameters of type Piece Constructor Description DiskJobCheckHash(Piece piece, Consumer<DiskJobCheckHash> callback)DiskJobReadBlock(Piece piece, int offset, int length, Consumer<DiskJobReadBlock> callback)DiskJobWriteBlock(Piece piece, int blockIndex, byte[] data, Consumer<DiskJobWriteBlock> callback)Creates a new job to store a block of a piece. -
Uses of Piece in org.johnnei.javatorrent.torrent
Fields in org.johnnei.javatorrent.torrent with type parameters of type Piece Modifier and Type Field Description protected List<Piece>AbstractFileSet. piecesThe pieces which contain all the information to complete the downloading of the files.Methods in org.johnnei.javatorrent.torrent that return Piece Modifier and Type Method Description PieceAbstractFileSet. getPiece(int index)Gets the piece with the given indexMethods in org.johnnei.javatorrent.torrent that return types with arguments of type Piece Modifier and Type Method Description Stream<Piece>AbstractFileSet. getNeededPieces()Creates a stream with only the pieces which are not done -
Uses of Piece in org.johnnei.javatorrent.torrent.algos.pieceselector
Methods in org.johnnei.javatorrent.torrent.algos.pieceselector that return types with arguments of type Piece Modifier and Type Method Description Optional<Piece>FullPieceSelect. getPieceForPeer(Peer peer)Optional<Piece>IPieceSelector. getPieceForPeer(Peer p)Gets the next piece to download -
Uses of Piece in org.johnnei.javatorrent.torrent.files
Methods in org.johnnei.javatorrent.torrent.files with parameters of type Piece Modifier and Type Method Description IMessageIFileSetRequestFactory. createCancelRequestFor(Peer peer, Piece piece, int byteOffset, int length)Creates a cancelIMessagefor a earlier send out request.IMessageIFileSetRequestFactory. createRequestFor(Peer peer, Piece piece, int byteOffset, int length)Creates a request to download the given piece block. -
Uses of Piece in org.johnnei.javatorrent.torrent.peer
Methods in org.johnnei.javatorrent.torrent.peer with parameters of type Piece Modifier and Type Method Description booleanPeer. addBlockRequest(Piece piece, int byteOffset, int blockLength, PeerDirection type)Adds a download or upload job to the peer.voidPeer. cancelBlockRequest(Piece piece, int byteOffset, int blockLength, PeerDirection type)Removes the download or upload job from the peer.voidPeer. onReceivedBlock(Piece piece, int byteOffset)Indicates that we've received the requested block from the peer.
-