Home Reference Source
public class | source

NodeBlockchainPropagation

You can directly use an instance of this class. nodeBlockchainPropagation

Constructor Summary

Public Constructor
public

Member Summary

Private Members
private
private
private

Method Summary

Public Methods
public
public

propagateBlock(block: *, socketsAvoidBroadcast: *)

public

propagateLastBlockFast(suspendOtherBlocks: boolean)

Private Methods
private
private

_findSocket(socket: *): boolean

Public Constructors

public constructor() source

Private Members

private _blockPropagating: * source

private _socketsAlreadyBroadcast: *[] source

private _socketsPropagating: *[] source

Public Methods

public processPropagation(): boolean source

Return:

boolean

public propagateBlock(block: *, socketsAvoidBroadcast: *) source

Params:

NameTypeAttributeDescription
block *
socketsAvoidBroadcast *

public propagateLastBlockFast(suspendOtherBlocks: boolean) source

Params:

NameTypeAttributeDescription
suspendOtherBlocks boolean
  • optional
  • default: true

Private Methods

private _deleteDisconenctedSockets() source

private _findSocket(socket: *): boolean source

Params:

NameTypeAttributeDescription
socket *

Return:

boolean