Class AbstractBinaryTreeNode<T, FAMILY>Abstract

Type Parameters

Hierarchy

Implements

Constructors

  • The constructor function initializes a BinaryTreeNode object with an id, value, and count.

    Type Parameters

    Parameters

    • id: number

      The id parameter is of type BinaryTreeNodeId and represents the unique identifier for the binary tree node.

    • Optional val: T

      The val parameter is an optional parameter of type T. It represents the value of the binary tree node. If no value is provided, it will be undefined.

    • Optional count: number

      The count parameter is an optional parameter that represents the number of times the value val appears in the binary tree node. If the count parameter is not provided, it defaults to 1.

    Returns AbstractBinaryTreeNode<T, FAMILY>

Properties

_count: number = 1
_familyPosition: FamilyPosition = FamilyPosition.ROOT
_height: number = 0
_id: number
_left?: null | FAMILY
_parent: undefined | null | FAMILY
_right?: null | FAMILY
_val: undefined | T

Accessors

Methods

Generated using TypeDoc