pulsar

package
v0.9.15 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2019 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPulse

func NewPulse(numberDelta uint32, previousPulseNumber insolar.PulseNumber, entropyGenerator entropygenerator.EntropyGenerator) *insolar.Pulse

NewPulse creates a new pulse with using of custom GeneratedEntropy Generator

Types

type Pulsar

type Pulsar struct {
	Config       configuration.Pulsar
	PublicKeyRaw string

	EntropyGenerator entropygenerator.EntropyGenerator

	Certificate                certificate.Certificate
	CryptographyService        insolar.CryptographyService
	PlatformCryptographyScheme insolar.PlatformCryptographyScheme
	KeyProcessor               insolar.KeyProcessor
	PulseDistributor           insolar.PulseDistributor
	// contains filtered or unexported fields
}

Pulsar is a base struct for pulsar's node It contains all the stuff, which is needed for working of a pulsar

func NewPulsar

func NewPulsar(
	configuration configuration.Pulsar,
	cryptographyService insolar.CryptographyService,
	scheme insolar.PlatformCryptographyScheme,
	keyProcessor insolar.KeyProcessor,
	pulseDistributor insolar.PulseDistributor,
	entropyGenerator entropygenerator.EntropyGenerator,
) *Pulsar

NewPulsar creates a new pulse with using of custom GeneratedEntropy Generator

func (*Pulsar) LastPN added in v0.9.0

func (p *Pulsar) LastPN() insolar.PulseNumber

func (*Pulsar) Send

func (p *Pulsar) Send(ctx context.Context, pulseNumber insolar.PulseNumber) error

type PulseSenderConfirmationPayload added in v0.7.5

type PulseSenderConfirmationPayload struct {
	insolar.PulseSenderConfirmation
}

PulseSenderConfirmationPayload is a struct with info about pulse's confirmations

func (*PulseSenderConfirmationPayload) Hash added in v0.7.5

func (ps *PulseSenderConfirmationPayload) Hash(hashProvider insolar.Hasher) ([]byte, error)

Hash calculates hash of payload

type TestPulsar added in v0.9.0

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

func NewTestPulsar added in v0.9.0

func NewTestPulsar(
	configuration configuration.Pulsar,
	distributor insolar.PulseDistributor,
	generator entropygenerator.EntropyGenerator,
) *TestPulsar

func (*TestPulsar) SendPulse added in v0.9.0

func (p *TestPulsar) SendPulse(ctx context.Context) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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