Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LightClientsManager ¶
type LightClientsManager struct {
// contains filtered or unexported fields
}
LightClientsManager manages light clients of other shards and provides services for debt validation.
func NewLightClientManager ¶
func NewLightClientManager(targetShard uint, context context.Context, config *node.Config, engine consensus.Engine) (*LightClientsManager, error)
NewLightClientManager create a new LightClientManager instance.
func NewLightClientManagerSubChain ¶
func NewLightClientManagerSubChain(targetShard uint, context context.Context, config *node.Config, engine consensus.Engine) (*LightClientsManager, error)
NewLightClientManagerSubChain create a new LightClientManager instance.
func (*LightClientsManager) GetServices ¶
func (manager *LightClientsManager) GetServices() []node.Service
GetServices get node service
func (*LightClientsManager) IfDebtPacked ¶
func (manager *LightClientsManager) IfDebtPacked(debt *types.Debt) (packed bool, confirmed bool, retErr error)
IfDebtPacked indicates whether the specified debt is packed. returns packed whether debt is packed returns confirmed whether debt is confirmed returns retErr this error is return when debt is found invalid. which means we need remove this debt.
func (*LightClientsManager) ValidateDebt ¶
func (manager *LightClientsManager) ValidateDebt(debt *types.Debt) (packed bool, confirmed bool, retErr error)
ValidateDebt validate debt returns packed whether debt is packed returns confirmed whether debt is confirmed returns retErr error info