coreapi: dag review

License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>


This commit was moved from ipfs/interface-go-ipfs-core@20fa7a599e

This commit was moved from ipfs/boxo@bae5f5303e
This commit is contained in:
Łukasz Magiera 2017-12-21 01:56:41 +01:00
parent e6a16b57e6
commit e68b73b54e

View File

@ -61,8 +61,9 @@ type UnixfsAPI interface {
// DagAPI specifies the interface to IPLD
type DagAPI interface {
// Put inserts data using specified format and input encoding.
// If format is not specified (nil), default dag-cbor/sha256 is used
Put(ctx context.Context, src io.Reader, opts ...options.DagPutOption) ([]Node, error)
// Unless used with WithCodec or WithHash, the defaults "dag-cbor" and
// "sha256" are used.
Put(ctx context.Context, src io.Reader, opts ...options.DagPutOption) (Path, error)
// WithInputEnc is an option for Put which specifies the input encoding of the
// data. Default is "json", most formats/codecs support "raw"