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

# Interface IAbstractGraph<V, E>

#### Type Parameters

- #### V

- #### E

#### Hierarchy

- IAbstractGraph
  - IDirectedGraph
  - IUNDirectedGraph

#### Implemented by

- AbstractGraph

- Defined in src/interfaces/abstract-graph.ts:3

#####
Index

### Methods

addEdge
addVertex
degreeOf
edgeSet
edgesOf
getEdge
getMinPathBetween
getNeighbors
hasEdge
hasVertex
removeAllVertices
removeEdge
removeVertex
setEdgeWeight

## Methods

### addEdge

- addEdge(src, dest, weight, val): boolean

- #### Parameters

  - ##### src: V | VertexId

  - ##### dest: V | VertexId

  - ##### weight: number

  - ##### val: E

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:22

### addVertex

- addVertex(id, val?): boolean

- #### Parameters

  - ##### id: VertexId

  - ##### `Optional` val: V

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:6

### degreeOf

- degreeOf(vertexOrId): number

- #### Parameters

  - ##### vertexOrId: V | VertexId

  #### Returns number

  - Defined in src/interfaces/abstract-graph.ts:12

### edgeSet

- edgeSet(): E[]

- #### Returns E[]

  - Defined in src/interfaces/abstract-graph.ts:20

### edgesOf

- edgesOf(vertexOrId): E[]

- #### Parameters

  - ##### vertexOrId: V | VertexId

  #### Returns E[]

  - Defined in src/interfaces/abstract-graph.ts:14

### getEdge

- getEdge(srcOrId, destOrId): null | E

- #### Parameters

  - ##### srcOrId: V | VertexId

  - ##### destOrId: V | VertexId

  #### Returns null | E

  - Defined in src/interfaces/abstract-graph.ts:18

### getMinPathBetween

- getMinPathBetween(v1, v2, isWeight?): null | V[]

- #### Parameters

  - ##### v1: V | VertexId

  - ##### v2: V | VertexId

  - ##### `Optional` isWeight: boolean

  #### Returns null | V[]

  - Defined in src/interfaces/abstract-graph.ts:28

### getNeighbors

- getNeighbors(vertexOrId): V[]

- #### Parameters

  - ##### vertexOrId: V | VertexId

  #### Returns V[]

  - Defined in src/interfaces/abstract-graph.ts:30

### hasEdge

- hasEdge(src, dest): boolean

- #### Parameters

  - ##### src: V | VertexId

  - ##### dest: V | VertexId

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:16

### hasVertex

- hasVertex(vertexOrId): boolean

- #### Parameters

  - ##### vertexOrId: V | VertexId

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:4

### removeAllVertices

- removeAllVertices(vertices): boolean

- #### Parameters

  - ##### vertices: V[] | VertexId []

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:10

### removeEdge

- removeEdge(edge): null | E

- #### Parameters

  - ##### edge: E

  #### Returns null | E

  - Defined in src/interfaces/abstract-graph.ts:24

### removeVertex

- removeVertex(vertexOrId): boolean

- #### Parameters

  - ##### vertexOrId: V | VertexId

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:8

### setEdgeWeight

- setEdgeWeight(srcOrId, destOrId, weight): boolean

- #### Parameters

  - ##### srcOrId: V | VertexId

  - ##### destOrId: V | VertexId

  - ##### weight: number

  #### Returns boolean

  - Defined in src/interfaces/abstract-graph.ts:26

Generated using TypeDoc