# Class CoordinateMap<V>

data-structure-typed

#### Author

Tyler Zeng

#### Copyright

Copyright (c) 2022 Tyler Zeng zrwusa@gmail.com

#### License

MIT License

#### Type Parameters

- #### V

#### Hierarchy

- Map<any, V>
  - CoordinateMap

- Defined in src/data-structures/hash/coordinate-map.ts:8

#####
Index

### Constructors

constructor

### Properties

[toStringTag]
_joint
size
[species]

### Accessors

joint

### Methods

[iterator]
_setJoint
clear
delete
entries
forEach
get
has
keys
set
values

## Constructors

### constructor

- new CoordinateMap<V>(joint?): CoordinateMap<V>

- #### Type Parameters

  - #### V

  #### Parameters

  - ##### `Optional` joint: string

  #### Returns CoordinateMap<V>

  Overrides Map<any, V>.constructor

  - Defined in src/data-structures/hash/coordinate-map.ts:9

## Properties

### `Readonly` [toStringTag]

[toStringTag]: string

Inherited from Map.[toStringTag]

- Defined in node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts:135

### `Protected` _joint

_joint: string = '_'

- Defined in src/data-structures/hash/coordinate-map.ts:14

### `Readonly` size

size: number

#### Returns

the number of elements in the Map.

Inherited from Map.size

- Defined in node_modules/typescript/lib/lib.es2015.collection.d.ts:48

### `Static` `Readonly` [species]

[species]: MapConstructor

Inherited from Map.[species]

- Defined in node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts:317

## Accessors

### joint

- get joint(): string

- #### Returns string

  - Defined in src/data-structures/hash/coordinate-map.ts:16

## Methods

### [iterator]

- [iterator](): IterableIterator<[any, V]>

- Returns an iterable of entries in the map.

  #### Returns IterableIterator<[any, V]>

  Inherited from Map.[iterator]

  - Defined in node_modules/typescript/lib/lib.es2015.iterable.d.ts:121

### `Protected` _setJoint

- _setJoint(v): void

- #### Parameters

  - ##### v: string

  #### Returns void

  - Defined in src/data-structures/hash/coordinate-map.ts:64

### clear

- clear(): void

- #### Returns void

  Inherited from Map.clear

  - Defined in node_modules/typescript/lib/lib.es2015.collection.d.ts:23

### delete

- delete(key): boolean

- The function overrides the delete method and joins the key array using a specified joint character before calling the super delete method.

  #### Parameters

  - ##### key: number[]

    An array of numbers that represents the key to be deleted.

  #### Returns boolean

  The `delete` method is returning the result of calling the `delete` method on the superclass, with the `key` array joined together using the `_joint` property.

  Overrides Map.delete

  - Defined in src/data-structures/hash/coordinate-map.ts:60

### entries

- entries(): IterableIterator<[any, V]>

- Returns an iterable of key, value pairs for every entry in the map.

  #### Returns IterableIterator<[any, V]>

  Inherited from Map.entries

  - Defined in node_modules/typescript/lib/lib.es2015.iterable.d.ts:126

### forEach

- forEach(callbackfn, thisArg?): void

- Executes a provided function once per each key/value pair in the Map, in insertion order.

  #### Parameters

  - ##### callbackfn: ((value, key, map) => void)

    - - (value, key, map): void

      - #### Parameters

        - ##### value: V

        - ##### key: any

        - ##### map: Map<any, V>

        #### Returns void

  - ##### `Optional` thisArg: any

  #### Returns void

  Inherited from Map.forEach

  - Defined in node_modules/typescript/lib/lib.es2015.collection.d.ts:31

### get

- get(key): undefined | V

- The function overrides the get method to join the key array with a specified joint and then calls the super get method.

  #### Parameters

  - ##### key: number[]

    An array of numbers

  #### Returns undefined | V

  The code is returning the value associated with the specified key in the map.

  Overrides Map.get

  - Defined in src/data-structures/hash/coordinate-map.ts:49

### has

- has(key): boolean

- The "has" function overrides the base class's "has" function and checks if a key exists in the map by joining the key array with a specified delimiter.

  #### Parameters

  - ##### key: number[]

    The parameter "key" is an array of numbers.

  #### Returns boolean

  The `has` method is being overridden to return the result of calling the `has` method of the superclass (`super.has`) with the `key` array joined together using the `_joint` property.

  Overrides Map.has

  - Defined in src/data-structures/hash/coordinate-map.ts:27

### keys

- keys(): IterableIterator<any>

- Returns an iterable of keys in the map

  #### Returns IterableIterator<any>

  Inherited from Map.keys

  - Defined in node_modules/typescript/lib/lib.es2015.iterable.d.ts:131

### set

- set(key, value): CoordinateMap<V>

- The function overrides the set method of a Map object to convert the key from an array to a string using a specified delimiter before calling the original set method.

  #### Parameters

  - ##### key: number[]

    The key parameter is an array of numbers.

  - ##### value: V

    The value parameter is the value that you want to associate with the specified key.

  #### Returns CoordinateMap<V>

  The `set` method is returning the result of calling the `set` method of the superclass (`super.set(key.join(this._joint), value)`).

  Overrides Map.set

  - Defined in src/data-structures/hash/coordinate-map.ts:39

### values

- values(): IterableIterator<V>

- Returns an iterable of values in the map

  #### Returns IterableIterator<V>

  Inherited from Map.values

  - Defined in node_modules/typescript/lib/lib.es2015.iterable.d.ts:136

Generated using TypeDoc