Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrMaxSize = errors.New("MaxSize is required and must be 64B <= MaxSize <= 1GB && MaxSize > NormalSize")
View Source
var ErrMinSize = errors.New("MinSize is required and must be 64B <= MinSize <= 1GB && MinSize < NormalSize")
View Source
var ErrNormalSize = errors.New("NormalSize is required and must be 64B <= NormalSize <= 1GB")
Functions ¶
This section is empty.
Types ¶
type UltraCDC ¶
type UltraCDC struct { }
func (*UltraCDC) Algorithm ¶
Algorithm's return value, cutpoint, might typically be used next in segment := data[:cutpoint], so we expect to exclude the cutpoint index value itself. Also commonly when n == len(data) and data is short, then the returned cutpoint will be n; n is the default to return when we did not find a shorter cutpoint. The segment := data[:len(data)] will then take all of data as the segment to hash.
PRE condition: n must be <= len(data). We will panic if this does not hold. It is always safe to pass n = len(data).
POST INVARIANT: cutpoint <= n. We never return a cutpoint > n.
func (*UltraCDC) DefaultOptions ¶
func (c *UltraCDC) DefaultOptions() *chunkers.ChunkerOpts
Click to show internal directories.
Click to hide internal directories.