nbcontracthelper

package
v0.20240422.0-devinwon Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NBContractBuilder added in v0.20240415.0

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

NBContractBuilder is a helper struct to build the NBContract (Node Bootstrap Contract). It provides methods to apply configuration, get the NBContract object, and validate the contract, etc.

func NewNBContractBuilder added in v0.20240415.0

func NewNBContractBuilder() *NBContractBuilder

NewNBContractBuilder creates a new instance of NBContractBuilder and ensures all objects in nodeBootstrapConfig are non-nil.

func (*NBContractBuilder) ApplyConfiguration added in v0.20240415.0

func (nBCB *NBContractBuilder) ApplyConfiguration(config *nbcontractv1.Configuration)

ApplyConfiguration Applies the configuration to the nodeBootstrapConfig object.

func (*NBContractBuilder) GetNodeBootstrapConfig added in v0.20240415.0

func (nBCB *NBContractBuilder) GetNodeBootstrapConfig() *nbcontractv1.Configuration

GetNodeBootstrapConfig gets the nodeBootstrapConfig object.

func (*NBContractBuilder) ValidateNBContract

func (nBCB *NBContractBuilder) ValidateNBContract() error

ValidateNBContract validates the NBContract. It returns an error if the contract is invalid. This function should be called after applying the configuration.

Jump to

Keyboard shortcuts

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