# AbstractBinaryTreeNode | data-structure-typed
Documentation for data-structure-typed

# Class AbstractBinaryTreeNode<T, NEIGHBOR>`Abstract`

#### Type Parameters

- #### T = any

- #### NEIGHBOR extends AbstractBinaryTreeNode <T, NEIGHBOR> = AbstractBinaryTreeNodeNested <T>

#### Hierarchy

- AbstractBinaryTreeNode
  - BinaryTreeNode

#### Implements

- IAbstractBinaryTreeNode <T, NEIGHBOR>

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:23

#####
Index

### Constructors

constructor

### Properties

_height
_id
_left
_parent
_right
_val

### Accessors

familyPosition
height
id
left
parent
right
val

## Constructors

### `Protected` constructor

- new AbstractBinaryTreeNode<T, NEIGHBOR>(id, val?): AbstractBinaryTreeNode <T, NEIGHBOR>

- The constructor function initializes a BinaryTreeNode object with an id and an optional value.

  #### Type Parameters

  - #### T = any

  - #### NEIGHBOR extends AbstractBinaryTreeNode <T, NEIGHBOR, NEIGHBOR> = AbstractBinaryTreeNodeNested <T>

  #### Parameters

  - ##### id: number

    The `id` parameter is of type `BinaryTreeNodeId` and represents the unique identifier of the binary tree node. It is used to distinguish one node from another in the binary tree.

  - ##### `Optional` val: T

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

  #### Returns AbstractBinaryTreeNode <T, NEIGHBOR>

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:35

## Properties

### `Private` _height

_height: number = 0

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:96

### `Private` _id

_id: number

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:40

### `Private` _left

_left: undefined | null | NEIGHBOR

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:60

### `Private` _parent

_parent: undefined | null | NEIGHBOR

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:86

### `Private` _right

_right: undefined | null | NEIGHBOR

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:73

### `Private` _val

_val: undefined | T

- Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:50

## Accessors

### familyPosition

- get familyPosition(): FamilyPosition

- The function determines the position of a node in a family tree structure.

  #### Returns FamilyPosition

  a value of type `FamilyPosition`.

  Implementation of IAbstractBinaryTreeNode.familyPosition

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:110

### height

- get height(): number

- #### Returns number

  Implementation of IAbstractBinaryTreeNode.height

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:98
- set height(v): void

- #### Parameters

  - ##### v: number

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.height

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:102

### id

- get id(): number

- #### Returns number

  Implementation of IAbstractBinaryTreeNode.id

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:42
- set id(v): void

- #### Parameters

  - ##### v: number

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.id

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:46

### left

- get left(): undefined | null | NEIGHBOR

- #### Returns undefined | null | NEIGHBOR

  Implementation of IAbstractBinaryTreeNode.left

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:62
- set left(v): void

- #### Parameters

  - ##### v: undefined | null | NEIGHBOR

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.left

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:66

### parent

- get parent(): undefined | null | NEIGHBOR

- #### Returns undefined | null | NEIGHBOR

  Implementation of IAbstractBinaryTreeNode.parent

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:88
- set parent(v): void

- #### Parameters

  - ##### v: undefined | null | NEIGHBOR

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.parent

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:92

### right

- get right(): undefined | null | NEIGHBOR

- #### Returns undefined | null | NEIGHBOR

  Implementation of IAbstractBinaryTreeNode.right

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:75
- set right(v): void

- #### Parameters

  - ##### v: undefined | null | NEIGHBOR

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.right

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:79

### val

- get val(): undefined | T

- #### Returns undefined | T

  Implementation of IAbstractBinaryTreeNode.val

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:52
- set val(value): void

- #### Parameters

  - ##### value: undefined | T

  #### Returns void

  Implementation of IAbstractBinaryTreeNode.val

  - Defined in src/data-structures/binary-tree/abstract-binary-tree.ts:56

Generated using TypeDoc