Home Reference Source Test
public class | source

AccountsTreeNode

Static Method Summary

Static Public Methods
public static

branchNode(prefix: string, childrenSuffixes: Array<string>, childrenHashes: Array<Hash>): AccountsTreeNode

public static

isBranchType(type: *): boolean

public static

isTerminalType(type: *): boolean

public static

terminalNode(prefix: string, account: Account): AccountsTreeNode

public static

Constructor Summary

Public Constructor
public

constructor(type: *, prefix: string, arg: Account | Array<string>, arg2: Array<Hash>)

Member Summary

Public Members
public get
public get

prefix: string

public set

prefix: string

public get

serializedSize: number

Method Summary

Public Methods
public

equals(o: AccountsTreeNode): boolean

public

getChild(prefix: string): string

public

getChildHash(prefix: string): Hash

public

getChildren(): Array<string>

public

getFirstChild(): string

public

getLastChild(): string

public

hasChildren(): boolean

public

hasSingleChild(): boolean

public

hash(): Hash

public

isBranch(): boolean

public

isChildOf(parent: AccountsTreeNode): boolean

Tests if this node is a child of some other node.

public

isTerminal(): boolean

public

serialize(buf: *): *

public
public

withChild(prefix: string, childHash: Hash): AccountsTreeNode

public

withoutChild(prefix: string): AccountsTreeNode

Static Public Methods

public static branchNode(prefix: string, childrenSuffixes: Array<string>, childrenHashes: Array<Hash>): AccountsTreeNode source

Params:

NameTypeAttributeDescription
prefix string
childrenSuffixes Array<string>
childrenHashes Array<Hash>

public static isBranchType(type: *): boolean source

Params:

NameTypeAttributeDescription
type *

Return:

boolean

public static isTerminalType(type: *): boolean source

Params:

NameTypeAttributeDescription
type *

Return:

boolean

public static terminalNode(prefix: string, account: Account): AccountsTreeNode source

Params:

NameTypeAttributeDescription
prefix string
account Account

public static unserialize(buf: SerialBuffer): AccountsTreeNode source

Params:

NameTypeAttributeDescription
buf SerialBuffer

Public Constructors

public constructor(type: *, prefix: string, arg: Account | Array<string>, arg2: Array<Hash>) source

Params:

NameTypeAttributeDescription
type *
prefix string
arg Account | Array<string>
arg2 Array<Hash>
  • optional

Public Members

public get account: Account source

public get prefix: string source

public set prefix: string source

public get serializedSize: number source

Public Methods

public equals(o: AccountsTreeNode): boolean source

Params:

NameTypeAttributeDescription
o AccountsTreeNode

Return:

boolean

public getChild(prefix: string): string source

Params:

NameTypeAttributeDescription
prefix string

Return:

string (nullable: true)

public getChildHash(prefix: string): Hash source

Params:

NameTypeAttributeDescription
prefix string

Return:

Hash (nullable: true)

public getChildren(): Array<string> source

Return:

Array<string> (nullable: true)

public getFirstChild(): string source

Return:

string (nullable: true)

public getLastChild(): string source

Return:

string (nullable: true)

public hasChildren(): boolean source

Return:

boolean

public hasSingleChild(): boolean source

Return:

boolean

public hash(): Hash source

Return:

Hash

public isBranch(): boolean source

Return:

boolean

public isChildOf(parent: AccountsTreeNode): boolean source

Tests if this node is a child of some other node.

Params:

NameTypeAttributeDescription
parent AccountsTreeNode

Return:

boolean

public isTerminal(): boolean source

Return:

boolean

public serialize(buf: *): * source

Params:

NameTypeAttributeDescription
buf *

Return:

*

public withAccount(account: Account): AccountsTreeNode source

Params:

NameTypeAttributeDescription
account Account

public withChild(prefix: string, childHash: Hash): AccountsTreeNode source

Params:

NameTypeAttributeDescription
prefix string
childHash Hash

public withoutChild(prefix: string): AccountsTreeNode source

Params:

NameTypeAttributeDescription
prefix string