Documentation ¶
Index ¶
- type Index
- func (index *Index) AddChunk(chunk *objects.Chunk)
- func (index *Index) AddObject(object *objects.Object)
- func (index *Index) ChecksumToId(checksum [32]byte) (uint32, bool)
- func (index *Index) GetObject(checksum [32]byte) *objects.Object
- func (index *Index) IdToChecksum(checksumID uint32) ([32]byte, bool)
- func (index *Index) LinkPathnameToObject(pathnameID uint64, object *objects.Object)
- func (index *Index) ListChunks() [][32]byte
- func (index *Index) ListContentTypes() []string
- func (index *Index) ListObjects() [][32]byte
- func (index *Index) LookupChunk(checksum [32]byte) *objects.Chunk
- func (index *Index) LookupObject(checksum [32]byte) *objects.Object
- func (index *Index) LookupObjectForPathname(pathnameID uint64) *objects.Object
- func (index *Index) LookupObjectForPathnameHash(pathnameHash [32]byte) *objects.Object
- func (index *Index) LookupObjectsForContentType(contentType string) [][32]byte
- func (index *Index) RecordPathnameChecksum(pathnameChecksum [32]byte, pathnameID uint64)
- func (index *Index) Serialize() ([]byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Index ¶
type Index struct { Checksums map[[32]byte]uint32 Pathnames map[uint32]uint64 ContentTypes map[string]uint32 PathnameToObject map[uint64]uint32 ObjectToPathnames map[uint32][]uint64 Objects map[uint32][]uint32 ObjectToContentType map[uint32]uint32 Chunks map[uint32]uint32 ChunkToObjects map[uint32][]uint32 ContentTypeToObjects map[uint32][]uint32 // contains filtered or unexported fields }
func NewIndexFromBytes ¶
func (*Index) LinkPathnameToObject ¶
func (*Index) ListChunks ¶
func (*Index) ListContentTypes ¶
func (*Index) ListObjects ¶
func (*Index) LookupObjectForPathname ¶
func (*Index) LookupObjectForPathnameHash ¶
func (*Index) LookupObjectsForContentType ¶
func (*Index) RecordPathnameChecksum ¶
Click to show internal directories.
Click to hide internal directories.