Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoInputs = errors.New("transaction must have at least one input") ErrNoOutputs = errors.New("transaction must have at least one output") ErrNegativeOutput = errors.New("transaction output value cannot be negative") ErrInvalidSignature = errors.New("invalid transaction signature") )
Functions ¶
This section is empty.
Types ¶
type Transaction ¶
func NewTransaction ¶
func NewTransaction(inputs []Input, outputs []Output) *Transaction
func (*Transaction) Hash ¶
func (tx *Transaction) Hash() []byte
type Validator ¶
type Validator struct {
// contains filtered or unexported fields
}
func NewValidator ¶
func NewValidator() *Validator
func (*Validator) ValidateTransaction ¶
func (v *Validator) ValidateTransaction(tx *Transaction) error
Click to show internal directories.
Click to hide internal directories.