blockchain

package
v0.2.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2017 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package blockchain defines primitives to work with blockchains.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HashTimestamper

type HashTimestamper interface {
	Networker

	// TimestampHash timestamps a hash on a blockchain.
	TimestampHash(hash *types.Bytes32) (types.TransactionID, error)
}

HashTimestamper must be able to timestamp a hash.

type Network

type Network interface {
	fmt.Stringer
}

Network represents a blockchain network.

type Networker

type Networker interface {
	// Network returns the network identifier of the blockchain.
	Network() Network
}

Networker must be able to return a network identifier.

type Timestamper

type Timestamper interface {
	Networker

	// Timestamp timestamps data on a blockchain.
	Timestamp(date interface{}) (types.TransactionID, error)
}

Timestamper must be able to timestamp data.

Directories

Path Synopsis
btc
Package btc defines primitives to work with Bitcoin.
Package btc defines primitives to work with Bitcoin.
blockcypher
Package blockcypher defines primitives to work with the BlockCypher API.
Package blockcypher defines primitives to work with the BlockCypher API.
btctesting
Package btctesting defines helpers to test Bitcoin.
Package btctesting defines helpers to test Bitcoin.
btctimestamper
Package btctimestamper implements a fake Bitcoin timestamper which can be used for testing.
Package btctimestamper implements a fake Bitcoin timestamper which can be used for testing.
Package dummytimestamper implements a fake blockchain timestamper which can be used for testing.
Package dummytimestamper implements a fake blockchain timestamper which can be used for testing.

Jump to

Keyboard shortcuts

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