blockproposal

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2022 License: AGPL-3.0, ISC Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrBlockProposalIsNil      = errors.New("block proposal is nil")
	ErrTrustBaseIsNil          = errors.New("trust base is nil")
	ErrSignerIsNil             = errors.New("signer is nil")
	ErrNodeVerifierIsNil       = errors.New("node signature verifier is nil")
	ErrInvalidSystemIdentifier = errors.New("invalid system identifier")
)
View Source
var File_block_proposal_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type BlockProposal

type BlockProposal struct {
	SystemIdentifier   []byte                           `protobuf:"bytes,1,opt,name=system_identifier,json=systemIdentifier,proto3" json:"system_identifier,omitempty"`
	NodeIdentifier     string                           `protobuf:"bytes,2,opt,name=node_identifier,json=nodeIdentifier,proto3" json:"node_identifier,omitempty"`
	UnicityCertificate *certificates.UnicityCertificate `protobuf:"bytes,3,opt,name=unicity_certificate,json=unicityCertificate,proto3" json:"unicity_certificate,omitempty"`
	Transactions       []*txsystem.Transaction          `protobuf:"bytes,4,rep,name=transactions,proto3" json:"transactions,omitempty"`
	Signature          []byte                           `protobuf:"bytes,5,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

func (*BlockProposal) Descriptor deprecated

func (*BlockProposal) Descriptor() ([]byte, []int)

Deprecated: Use BlockProposal.ProtoReflect.Descriptor instead.

func (*BlockProposal) GetNodeIdentifier

func (x *BlockProposal) GetNodeIdentifier() string

func (*BlockProposal) GetSignature

func (x *BlockProposal) GetSignature() []byte

func (*BlockProposal) GetSystemIdentifier

func (x *BlockProposal) GetSystemIdentifier() []byte

func (*BlockProposal) GetTransactions

func (x *BlockProposal) GetTransactions() []*txsystem.Transaction

func (*BlockProposal) GetUnicityCertificate

func (x *BlockProposal) GetUnicityCertificate() *certificates.UnicityCertificate

func (*BlockProposal) Hash

func (x *BlockProposal) Hash(algorithm gocrypto.Hash) ([]byte, error)

func (*BlockProposal) IsValid

func (x *BlockProposal) IsValid(nodeSignatureVerifier crypto.Verifier, ucTrustBase crypto.Verifier, algorithm gocrypto.Hash, systemIdentifier []byte, systemDescriptionHash []byte) error

func (*BlockProposal) ProtoMessage

func (*BlockProposal) ProtoMessage()

func (*BlockProposal) ProtoReflect

func (x *BlockProposal) ProtoReflect() protoreflect.Message

func (*BlockProposal) Reset

func (x *BlockProposal) Reset()

func (*BlockProposal) Sign

func (x *BlockProposal) Sign(algorithm gocrypto.Hash, signer crypto.Signer) error

func (*BlockProposal) String

func (x *BlockProposal) String() string

func (*BlockProposal) Verify

func (x *BlockProposal) Verify(algorithm gocrypto.Hash, nodeSignatureVerifier crypto.Verifier) error

Jump to

Keyboard shortcuts

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