dummyfossilizer

package
v0.0.3-dev Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2016 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package dummyfossilizer implements a fossilizer that can be used for testing.

It doesn't do much -- it just adds a timestamp.

Index

Constants

View Source
const (
	// Name is the name set in the fossilizer's information.
	Name = "dummy"

	// Description is the description set in the fossilizer's information.
	Description = "Stratumn Dummy Fossilizer"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// A version string that will be set in the store's information.
	Version string

	// A git commit hash that will be set in the store's information.
	Commit string
}

Config contains configuration options for the store.

type DummyFossilizer

type DummyFossilizer struct {
	// contains filtered or unexported fields
}

DummyFossilizer is the type that implements github.com/stratumn/go/fossilizer.Adapter.

func New

func New(config *Config) *DummyFossilizer

New creates an instance of a DummyFossilizer.

func (*DummyFossilizer) AddResultChan

func (a *DummyFossilizer) AddResultChan(resultChan chan *fossilizer.Result)

AddResultChan implements github.com/stratumn/go/fossilizer.Adapter.AddResultChan.

func (*DummyFossilizer) Fossilize

func (a *DummyFossilizer) Fossilize(data []byte, meta []byte) error

Fossilize implements github.com/stratumn/go/fossilizer.Adapter.Fossilize.

func (*DummyFossilizer) GetInfo

func (a *DummyFossilizer) GetInfo() (interface{}, error)

GetInfo implements github.com/stratumn/go/fossilizer.Adapter.GetInfo.

type Info

type Info struct {
	Name        string `json:"name"`
	Description string `json:"description"`
	Version     string `json:"version"`
	Commit      string `json:"commit"`
}

Info is the info returned by GetInfo.

Jump to

Keyboard shortcuts

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