Documentation
¶
Overview ¶
Package blob is content-addressed attachment storage under blobs/sha256/ab/cd<rest> (RFC 8.1).
Index ¶
- type Store
- func (s *Store) CopyReadOnly(atts []envelope.Attachment, dir string) (map[string]string, error)
- func (s *Store) Get(sha string) ([]byte, error)
- func (s *Store) Path(sha string) string
- func (s *Store) Put(data []byte, mime string) (sha string, outMime string, err error)
- func (s *Store) PutFile(path string) (sha string, size int64, mime string, err error)
- func (s *Store) Remove(sha string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store is the blob directory.
func (*Store) CopyReadOnly ¶
CopyReadOnly materialises attachments into dir as read-only files with sanitised names and returns their paths keyed by name.