Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CachedPiece ¶
type CachedPiece struct {
// contains filtered or unexported fields
}
CachedPiece is a wrapper around a piece.Piece object that is capable of reading the data from a picecache.Cache.
func New ¶
func New(pi *piece.Piece, cache *piececache.Cache, readSize int64, peerID [20]byte) *CachedPiece
New returns a new CachedPiece object. Reads are done with blocks of `readSize`.
Click to show internal directories.
Click to hide internal directories.