fcjson

package
v0.8.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 2, 2021 License: Apache-2.0, MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Encoder

func Encoder(n ipld.Node, w io.Writer) error

func Marshal

func Marshal(n ipld.Node, sink shared.TokenSink) error

Marshal is a non-link-aware marshaler

Types

type DagMarshaler

type DagMarshaler struct {
	Loader
	Path ipld.Path
}

DagMarshaler acts like traversal.Progress, but with emission of a token stream over the depth-first-search traversal.

func (*DagMarshaler) Encoder

func (d *DagMarshaler) Encoder(n ipld.Node, w io.Writer) error

func (*DagMarshaler) MarshalRecursive

func (d *DagMarshaler) MarshalRecursive(n ipld.Node, sink shared.TokenSink) error

MarshalRecursive is a combination traversal + codec

type Loader

type Loader func(cid.Cid, ipld.Path) ipld.Node

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL