Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Graph

Index

Constructors

Properties

Accessors

Methods

Constructors

constructor

  • new Graph(gridIn: number[][], options?: { diagonal?: boolean }): Graph
  • A graph memory structure

    Parameters

    • gridIn: number[][]

      2D array of input weights

    • options: { diagonal?: boolean } = {}

      diagonal - Specifies whether diagonal moves are allowed

      • Optional diagonal?: boolean

    Returns Graph

Properties

Protected dirtyNodes

dirtyNodes: GridNode[] = []

Private Readonly grid

grid: GridNode[][] = []

Private Readonly nodes

nodes: GridNode[] = []

Accessors

diagonal

  • get diagonal(): boolean

Methods

cleanDirty

  • cleanDirty(): void

get

Private init

  • init(): void

markDirty

neighbors

toString

  • toString(): string

Generated using TypeDoc