Documentation ¶
Index ¶
Constants ¶
View Source
const ManifestPathDelimiter = "/"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileBuilder ¶
type FileBuilder struct { Path string Blocks map[uint64]ManifestBlock // contains filtered or unexported fields }
func (*FileBuilder) AddBlock ¶
func (b *FileBuilder) AddBlock(blockId uint64, block *ManifestBlock) error
func (*FileBuilder) Build ¶
func (b *FileBuilder) Build() (*ManifestFile, error)
type Manifest ¶
type Manifest struct {
Files map[string]ManifestFile
}
type ManifestBlock ¶
func (*ManifestBlock) ToProto ¶
func (b *ManifestBlock) ToProto() *proto.ManifestBlockProto
type ManifestBuilder ¶
type ManifestBuilder struct { Files map[string]*FileBuilder // contains filtered or unexported fields }
func ManifestBuilderSink ¶
func ManifestBuilderSink() (blocks.BlockProcessor, *ManifestBuilder)
func (*ManifestBuilder) AddFile ¶
func (b *ManifestBuilder) AddFile(file string) *FileBuilder
func (*ManifestBuilder) Build ¶
func (b *ManifestBuilder) Build() (*Manifest, error)
func (*ManifestBuilder) BuildProto ¶
func (b *ManifestBuilder) BuildProto() (*proto.ManifestProto, error)
func (*ManifestBuilder) FromProto ¶
func (b *ManifestBuilder) FromProto(p *proto.ManifestProto) error
Adds the information from a protobuffer into the builder.
type ManifestFile ¶
type ManifestFile struct { Path string Blocks []ManifestBlock }
func (*ManifestFile) Hash ¶
func (f *ManifestFile) Hash() uint64
Click to show internal directories.
Click to hide internal directories.