[@rxap/tree](../wiki/globals) / TreeDataSource

# Class: TreeDataSource\<Data, RootParameters, NodeParameters\>

Defined in: [tree/src/lib/tree.data-source.ts:238](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L238)

## Extends

- `BaseDataSource`\<`Node`\<`Data`\>[], [`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)\>

## Type Parameters

• **Data** *extends* `WithIdentifier` & `WithChildren` = `any`

• **RootParameters** = `any`

• **NodeParameters** = `any`

## Implements

- `OnInit`

## Constructors

### new TreeDataSource()

> **new TreeDataSource**\<`Data`, `RootParameters`, `NodeParameters`\>(`rootRemoteMethod`, `childrenRemoteMethod`, `applyFilterMethod`, `metadata`): [`TreeDataSource`](../wiki/Class.TreeDataSource)\<`Data`, `RootParameters`, `NodeParameters`\>

Defined in: [tree/src/lib/tree.data-source.ts:258](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L258)

#### Parameters

##### rootRemoteMethod

`Method`\<`Data` \| `Data`[], `RootParameters`\>

##### childrenRemoteMethod

`null` | `Method`\<`Data`[], `Node`\<`Data`, `any`\>\>

##### applyFilterMethod

`null` | `Method`\<`Node`\<`Data`, `any`\>[], [`TreeApplyFilterParameter`](../wiki/Interface.TreeApplyFilterParameter)\<[`ISearchForm`](../wiki/Interface.ISearchForm)\<`unknown`\>, `any`\>\>

##### metadata

`null` | [`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)

#### Returns

[`TreeDataSource`](../wiki/Class.TreeDataSource)\<`Data`, `RootParameters`, `NodeParameters`\>

#### Overrides

`BaseDataSource<Array<Node<Data>>, TreeDataSourceMetadata>.constructor`

## Properties

### \_\_id

> **\_\_id**: `string`

Defined in: [definition/src/lib/definition.ts:61](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L61)

**`Internal`**

unique internal id

#### Inherited from

`BaseDataSource.__id`

***

### \_connectedViewer

> `protected` **\_connectedViewer**: `Map`\<`string`, `Observable`\<`Node`\<`Data`, `any`\>[]\>\>

Defined in: [data-source/src/lib/base.data-source.ts:78](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L78)

#### Inherited from

`BaseDataSource._connectedViewer`

***

### \_connectedViewerTeardown

> `protected` **\_connectedViewerTeardown**: `Map`\<`string`, `TeardownLogic`\>

Defined in: [data-source/src/lib/base.data-source.ts:79](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L79)

#### Inherited from

`BaseDataSource._connectedViewerTeardown`

***

### \_data?

> `protected` `optional` **\_data**: `Node`\<`Data`, `any`\>[]

Defined in: [data-source/src/lib/base.data-source.ts:104](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L104)

#### Inherited from

`BaseDataSource._data`

***

### \_data$

> `protected` **\_data$**: `BehaviorSubject`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [tree/src/lib/tree.data-source.ts:250](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L250)

#### Overrides

`BaseDataSource._data$`

***

### \_initialised

> `protected` **\_initialised**: `boolean` = `false`

Defined in: [definition/src/lib/definition.ts:62](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L62)

#### Inherited from

`BaseDataSource._initialised`

***

### \_lastRefreshed

> `protected` **\_lastRefreshed**: `null` \| `Date` = `null`

Defined in: [data-source/src/lib/base.data-source.ts:77](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L77)

#### Inherited from

`BaseDataSource._lastRefreshed`

***

### \_retry$

> `protected` **\_retry$**: `Subject`\<`void`\>

Defined in: [data-source/src/lib/base.data-source.ts:90](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L90)

#### Inherited from

`BaseDataSource._retry$`

***

### \_viewerIds

> `protected` **\_viewerIds**: `Map`\<`BaseDataSourceViewer`\<`any`\>, `string`\>

Defined in: [data-source/src/lib/base.data-source.ts:89](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L89)

a map of viewer to view id.
Allows to create a view id from the viewer object reference

#### Inherited from

`BaseDataSource._viewerIds`

***

### change$

> `readonly` **change$**: `Subject`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [data-source/src/lib/base.data-source.ts:67](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L67)

#### Inherited from

`BaseDataSource.change$`

***

### childrenRemoteMethod

> `readonly` **childrenRemoteMethod**: `null` \| `Method`\<`Data`[], `Node`\<`Data`, `any`\>\> = `null`

Defined in: [tree/src/lib/tree.data-source.ts:263](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L263)

***

### destroyed$

> `readonly` **destroyed$**: `undefined` \| `Subject`\<`void`\>

Defined in: [definition/src/lib/definition.ts:48](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L48)

Emits if the data source is destroyed

#### Inherited from

`BaseDataSource.destroyed$`

***

### error$

> `readonly` **error$**: `ReplaySubject`\<`Error`\>

Defined in: [data-source/src/lib/base.data-source.ts:73](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L73)

#### Inherited from

`BaseDataSource.error$`

***

### expanded

> **expanded**: `SelectionModel`\<`string`\>

Defined in: [tree/src/lib/tree.data-source.ts:246](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L246)

***

### getIcon

> **getIcon**: `NodeGetIconFunction`\<`Data`\>

Defined in: [tree/src/lib/tree.data-source.ts:314](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L314)

***

### getStyle

> **getStyle**: `NodeGetStyleFunction`\<`Data`\>

Defined in: [tree/src/lib/tree.data-source.ts:318](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L318)

***

### getType

> **getType**: `NodeGetTypeFunction`\<`Data`\>

Defined in: [tree/src/lib/tree.data-source.ts:316](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L316)

***

### hasDetails

> **hasDetails**: `NodeHasDetailsFunction`\<`Data`\>

Defined in: [tree/src/lib/tree.data-source.ts:322](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L322)

***

### hasError?

> `optional` **hasError**: `Signal`\<`boolean`\>

Defined in: [data-source/src/lib/base.data-source.ts:94](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L94)

#### Inherited from

`BaseDataSource.hasError`

***

### hasError$

> `readonly` **hasError$**: `ToggleSubject`

Defined in: [data-source/src/lib/base.data-source.ts:72](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L72)

#### Inherited from

`BaseDataSource.hasError$`

***

### initialised$

> `readonly` **initialised$**: `undefined` \| `Subject`\<`void`\>

Defined in: [definition/src/lib/definition.ts:52](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L52)

Emits if the data source is initialised

#### Inherited from

`BaseDataSource.initialised$`

***

### interceptors

> `readonly` **interceptors**: `undefined` \| `Set`\<`Subject`\<`any`\>\>

Defined in: [definition/src/lib/definition.ts:53](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L53)

#### Inherited from

`BaseDataSource.interceptors`

***

### loading?

> `optional` **loading**: `Signal`\<`boolean`\>

Defined in: [data-source/src/lib/base.data-source.ts:92](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L92)

#### Inherited from

`BaseDataSource.loading`

***

### loading$

> **loading$**: `ToggleSubject`

Defined in: [tree/src/lib/tree.data-source.ts:248](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L248)

Indicates weather the data source is currently loading new data

#### Overrides

`BaseDataSource.loading$`

***

### matchFilter()

> **matchFilter**: (`node`) => `boolean`

Defined in: [tree/src/lib/tree.data-source.ts:324](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L324)

#### Parameters

##### node

`Node`\<`Data`\>

#### Returns

`boolean`

***

### metadata

> **metadata**: [`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)

Defined in: [definition/src/lib/definition.ts:44](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L44)

#### Inherited from

`BaseDataSource.metadata`

***

### rootRemoteMethod

> `readonly` **rootRemoteMethod**: `Method`\<`Data` \| `Data`[], `RootParameters`\>

Defined in: [tree/src/lib/tree.data-source.ts:260](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L260)

***

### searchForm

> **searchForm**: `null` \| [`SearchForm`](../wiki/Class.SearchForm)\<`unknown`\> = `null`

Defined in: [tree/src/lib/tree.data-source.ts:249](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L249)

***

### selected

> **selected**: `SelectionModel`\<`Node`\<`Data`, `any`\>\>

Defined in: [tree/src/lib/tree.data-source.ts:245](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L245)

***

### toDisplay

> **toDisplay**: `NodeToDisplayFunction`\<`Data`\>

Defined in: [tree/src/lib/tree.data-source.ts:311](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L311)

***

### tree$

> **tree$**: `BehaviorSubject`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [tree/src/lib/tree.data-source.ts:243](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L243)

***

### treeControl

> **treeControl**: `FlatTreeControl`\<`Node`\<`Data`, `any`\>\>

Defined in: [tree/src/lib/tree.data-source.ts:244](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L244)

***

### destroyed$

> `readonly` `static` **destroyed$**: `Subject`\<`BaseDefinition`\<`BaseDefinitionMetadata`\>\>

Defined in: [definition/src/lib/definition.ts:41](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L41)

Emits when a new Definition instance is initialised

#### Inherited from

`BaseDataSource.destroyed$`

***

### initialised$

> `readonly` `static` **initialised$**: `Subject`\<`BaseDefinition`\<`BaseDefinitionMetadata`\>\>

Defined in: [definition/src/lib/definition.ts:35](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L35)

Emits when a new Definition instance is initialised

#### Inherited from

`BaseDataSource.initialised$`

***

### instances

> `readonly` `static` **instances**: `Map`\<`string`, `BaseDefinition`\<`BaseDefinitionMetadata`\>\>

Defined in: [definition/src/lib/definition.ts:27](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L27)

A map of active Definition instances

#### Inherited from

`BaseDataSource.instances`

## Accessors

### data

#### Get Signature

> **get** **data**(): `undefined` \| `Data`

Defined in: [data-source/src/lib/base.data-source.ts:106](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L106)

##### Returns

`undefined` \| `Data`

#### Inherited from

`BaseDataSource.data`

***

### hasConnections

#### Get Signature

> **get** **hasConnections**(): `boolean`

Defined in: [data-source/src/lib/base.data-source.ts:110](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L110)

##### Returns

`boolean`

#### Inherited from

`BaseDataSource.hasConnections`

***

### id

#### Get Signature

> **get** **id**(): `string`

Defined in: [definition/src/lib/definition.ts:87](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L87)

##### Returns

`string`

#### Inherited from

`BaseDataSource.id`

***

### lastRefreshed

#### Get Signature

> **get** **lastRefreshed**(): `null` \| `Date`

Defined in: [data-source/src/lib/base.data-source.ts:74](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L74)

##### Returns

`null` \| `Date`

#### Inherited from

`BaseDataSource.lastRefreshed`

***

### nodeParameters

#### Get Signature

> **get** **nodeParameters**(): `null` \| `NodeParameters`

Defined in: [tree/src/lib/tree.data-source.ts:280](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L280)

##### Returns

`null` \| `NodeParameters`

#### Set Signature

> **set** **nodeParameters**(`nodeParameters`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:284](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L284)

##### Parameters

###### nodeParameters

`null` | `NodeParameters`

##### Returns

`void`

## Methods

### \_connect()

> `protected` **\_connect**(`collectionViewer`): `Observable`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [tree/src/lib/tree.data-source.ts:622](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L622)

#### Parameters

##### collectionViewer

`Required`\<`BaseDataSourceViewer`\<`any`\>\>

#### Returns

`Observable`\<`Node`\<`Data`, `any`\>[]\>

#### Overrides

`BaseDataSource._connect`

***

### \_disconnect()

> `protected` **\_disconnect**(`viewerId`): `void`

Defined in: [data-source/src/lib/base.data-source.ts:308](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L308)

#### Parameters

##### viewerId

`string`

#### Returns

`void`

#### Inherited from

`BaseDataSource._disconnect`

***

### applyMetadata()

> **applyMetadata**(`partialMetadata`): `void`

Defined in: [definition/src/lib/definition.ts:111](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L111)

#### Parameters

##### partialMetadata

`Partial`\<[`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)\>

#### Returns

`void`

#### Inherited from

`BaseDataSource.applyMetadata`

***

### attach()

> **attach**(`viewerId`): `Observable`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [data-source/src/lib/base.data-source.ts:210](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L210)

#### Parameters

##### viewerId

`string`

#### Returns

`Observable`\<`Node`\<`Data`, `any`\>[]\>

#### Inherited from

`BaseDataSource.attach`

***

### collapseNode()

> **collapseNode**(`node`, `options`?): `Promise`\<`void`\>

Defined in: [tree/src/lib/tree.data-source.ts:510](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L510)

#### Parameters

##### node

`Node`\<`Data`\>

##### options?

`EventOptions`

#### Returns

`Promise`\<`void`\>

***

### connect()

> **connect**(`viewerOrString`): `Observable`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [data-source/src/lib/base.data-source.ts:124](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L124)

#### Parameters

##### viewerOrString

`string` | `BaseDataSourceViewer`\<`any`\>

#### Returns

`Observable`\<`Node`\<`Data`, `any`\>[]\>

#### Inherited from

`BaseDataSource.connect`

***

### derive()

> **derive**(`id`, `metadata`): `BaseDataSource`\<`any`\>

Defined in: [data-source/src/lib/base.data-source.ts:270](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L270)

#### Parameters

##### id

`string`

##### metadata

`Partial`\<`BaseDataSourceMetadata`\> = `...`

#### Returns

`BaseDataSource`\<`any`\>

#### Inherited from

`BaseDataSource.derive`

***

### deselectNode()

> **deselectNode**(`node`): `Promise`\<`void`\>

Defined in: [tree/src/lib/tree.data-source.ts:400](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L400)

#### Parameters

##### node

`Node`\<`Data`\>

#### Returns

`Promise`\<`void`\>

***

### ~~destroy()~~

> **destroy**(): `void`

Defined in: [tree/src/lib/tree.data-source.ts:538](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L538)

#### Returns

`void`

#### Deprecated

use ngOnDestroy instead

#### Overrides

`BaseDataSource.destroy`

***

### disconnect()

> **disconnect**(`viewerOrId`): `void`

Defined in: [data-source/src/lib/base.data-source.ts:225](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L225)

#### Parameters

##### viewerOrId

`string` | `BaseDataSourceViewer`\<`any`\>

#### Returns

`void`

#### Inherited from

`BaseDataSource.disconnect`

***

### expandNode()

> **expandNode**(`node`, `options`?): `Promise`\<`void`\>

Defined in: [tree/src/lib/tree.data-source.ts:405](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L405)

#### Parameters

##### node

`Node`\<`Data`\>

##### options?

`EventOptions`

#### Returns

`Promise`\<`void`\>

***

### flatTree()

> **flatTree**(`tree`, `all`): `Node`\<`Data`, `any`\>[]

Defined in: [tree/src/lib/tree.data-source.ts:534](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L534)

Converts the tree structure into a list.

#### Parameters

##### tree

`Node`\<`Data`\>

##### all

`boolean` = `false`

true - include nodes children that are not expanded

#### Returns

`Node`\<`Data`, `any`\>[]

***

### genericRetryFunction()

> `protected` **genericRetryFunction**(`error`, `retryCount`): `Observable`\<`any`\>

Defined in: [data-source/src/lib/base.data-source.ts:311](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L311)

#### Parameters

##### error

`any`

##### retryCount

`number`

#### Returns

`Observable`\<`any`\>

#### Inherited from

`BaseDataSource.genericRetryFunction`

***

### getChildren()

> **getChildren**(`node`): `Promise`\<`Data`[]\>

Defined in: [tree/src/lib/tree.data-source.ts:445](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L445)

#### Parameters

##### node

`Node`\<`Data`\>

#### Returns

`Promise`\<`Data`[]\>

***

### getMetadata()

> **getMetadata**(): `null` \| [`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)

Defined in: [definition/src/lib/definition.ts:107](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L107)

#### Returns

`null` \| [`TreeDataSourceMetadata`](../wiki/Interface.TreeDataSourceMetadata)

#### Inherited from

`BaseDataSource.getMetadata`

***

### getNodeById()

> **getNodeById**(`id`): `null` \| `Node`\<`Data`, `any`\>

Defined in: [tree/src/lib/tree.data-source.ts:465](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L465)

#### Parameters

##### id

`string`

#### Returns

`null` \| `Node`\<`Data`, `any`\>

***

### getRoot()

> **getRoot**(`options`): `Promise`\<`Data` \| `Data`[]\>

Defined in: [tree/src/lib/tree.data-source.ts:453](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L453)

#### Parameters

##### options

###### cache?

`boolean`

#### Returns

`Promise`\<`Data` \| `Data`[]\>

***

### getRootParameters()

> **getRootParameters**(`options`): `Promise`\<`RootParameters`\>

Defined in: [tree/src/lib/tree.data-source.ts:458](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L458)

#### Parameters

##### options

###### cache?

`boolean`

#### Returns

`Promise`\<`RootParameters`\>

***

### getTreeRoot()

> **getTreeRoot**(`options`): `Promise`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [tree/src/lib/tree.data-source.ts:326](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L326)

#### Parameters

##### options

###### cache?

`boolean`

#### Returns

`Promise`\<`Node`\<`Data`, `any`\>[]\>

***

### getViewerId()

> **getViewerId**(`viewer`): `string`

Defined in: [data-source/src/lib/base.data-source.ts:114](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L114)

#### Parameters

##### viewer

`BaseDataSourceViewer`

#### Returns

`string`

#### Inherited from

`BaseDataSource.getViewerId`

***

### handelError()

> `protected` **handelError**(`error`): `void`

Defined in: [data-source/src/lib/base.data-source.ts:317](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L317)

#### Parameters

##### error

`any`

#### Returns

`void`

#### Inherited from

`BaseDataSource.handelError`

***

### init()

> **init**(): `void`

Defined in: [definition/src/lib/definition.ts:127](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L127)

#### Returns

`void`

#### Inherited from

`BaseDataSource.init`

***

### isConnected()

> **isConnected**(`viewerOrId`): `boolean`

Defined in: [data-source/src/lib/base.data-source.ts:217](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L217)

#### Parameters

##### viewerOrId

`string` | `BaseDataSourceViewer`\<`any`\>

#### Returns

`boolean`

#### Inherited from

`BaseDataSource.isConnected`

***

### ngOnDestroy()

> **ngOnDestroy**(): `void`

Defined in: [definition/src/lib/definition.ts:122](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L122)

A callback method that performs custom clean-up, invoked immediately
before a directive, pipe, or service instance is destroyed.

#### Returns

`void`

#### Inherited from

`BaseDataSource.ngOnDestroy`

***

### ngOnInit()

> **ngOnInit**(): `void`

Defined in: [tree/src/lib/tree.data-source.ts:289](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L289)

A callback method that is invoked immediately after the
default change detector has checked the directive's
data-bound properties for the first time,
and before any of the view or content children have been checked.
It is invoked only once when the directive is instantiated.

#### Returns

`void`

#### Implementation of

`OnInit.ngOnInit`

***

### refresh()

> **refresh**(): `Promise`\<`any`\>

Defined in: [tree/src/lib/tree.data-source.ts:553](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L553)

#### Returns

`Promise`\<`any`\>

#### Overrides

`BaseDataSource.refresh`

***

### refreshMatchFilter()

> **refreshMatchFilter**(): `void`

Defined in: [tree/src/lib/tree.data-source.ts:549](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L549)

#### Returns

`void`

***

### reset()

> **reset**(): `any`

Defined in: [tree/src/lib/tree.data-source.ts:595](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L595)

#### Returns

`any`

#### Overrides

`BaseDataSource.reset`

***

### retry()

> **retry**(): `any`

Defined in: [data-source/src/lib/base.data-source.ts:293](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L293)

#### Returns

`any`

#### Inherited from

`BaseDataSource.retry`

***

### selectNode()

> **selectNode**(`node`): `Promise`\<`void`\>

Defined in: [tree/src/lib/tree.data-source.ts:364](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L364)

#### Parameters

##### node

`Node`\<`Data`\>

#### Returns

`Promise`\<`void`\>

***

### setGetIcon()

> **setGetIcon**(`getIcon`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:390](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L390)

#### Parameters

##### getIcon

`NodeGetIconFunction`\<`Data`\> = `...`

#### Returns

`void`

***

### setGetStyle()

> **setGetStyle**(`getStyle`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:601](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L601)

#### Parameters

##### getStyle

`NodeGetStyleFunction`\<`any`\> = `...`

#### Returns

`void`

***

### setGetType()

> **setGetType**(`getType`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:605](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L605)

#### Parameters

##### getType

`NodeGetTypeFunction`\<`any`\> = `...`

#### Returns

`void`

***

### setHasDetails()

> **setHasDetails**(`hasDetails`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:394](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L394)

#### Parameters

##### hasDetails

`NodeHasDetailsFunction`\<`Data`\> = `...`

#### Returns

`void`

***

### setMatchFilter()

> **setMatchFilter**(`matchFilter`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:380](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L380)

#### Parameters

##### matchFilter

(`node`) => `boolean`

#### Returns

`void`

***

### setToDisplay()

> **setToDisplay**(`toDisplay`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:384](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L384)

#### Parameters

##### toDisplay

`NodeToDisplayFunction`\<`Data`\> = `...`

#### Returns

`void`

***

### setTreeControl()

> **setTreeControl**(`treeControl`): `void`

Defined in: [tree/src/lib/tree.data-source.ts:376](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L376)

#### Parameters

##### treeControl

`FlatTreeControl`\<`Node`\<`Data`, `any`\>\>

#### Returns

`void`

***

### toJSON()

> **toJSON**(): `object`

Defined in: [data-source/src/lib/base.data-source.ts:280](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L280)

#### Returns

`object`

#### Inherited from

`BaseDataSource.toJSON`

***

### toNode()

> **toNode**(`parent`, `item`, `depth`, `onExpand`, `onCollapse`, `onSelect`, `onDeselect`): `Promise`\<`Node`\<`Data`, `any`\>\>

Defined in: [tree/src/lib/tree.data-source.ts:484](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L484)

#### Parameters

##### parent

`null` | `Node`\<`Data`, `any`\>

##### item

`Data`

##### depth

`number` = `0`

##### onExpand

`ExpandNodeFunction`\<`Data`\> = `...`

##### onCollapse

`ExpandNodeFunction`\<`Data`\> = `...`

##### onSelect

`ExpandNodeFunction`\<`Data`\> = `...`

##### onDeselect

`ExpandNodeFunction`\<`Data`\> = `...`

#### Returns

`Promise`\<`Node`\<`Data`, `any`\>\>

***

### toPromise()

> **toPromise**(`viewer`): `Promise`\<`Node`\<`Data`, `any`\>[]\>

Defined in: [data-source/src/lib/base.data-source.ts:264](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/data-source/src/lib/base.data-source.ts#L264)

Creates a connection to tha data source and converts the Observable into a
promise and then disconnects the viewer

#### Parameters

##### viewer

`BaseDataSourceViewer`

#### Returns

`Promise`\<`Node`\<`Data`, `any`\>[]\>

#### Inherited from

`BaseDataSource.toPromise`

***

### updateNodes()

> **updateNodes**(): `void`

Defined in: [tree/src/lib/tree.data-source.ts:613](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/tree/src/lib/tree.data-source.ts#L613)

recall the getStyle, getIcon and toDisplay methods
and update the node objects

#### Returns

`void`

***

### add()

> `static` **add**(`definition`): `void`

Defined in: [definition/src/lib/definition.ts:94](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L94)

#### Parameters

##### definition

`BaseDefinition`

#### Returns

`void`

#### Inherited from

`BaseDataSource.add`

***

### remove()

> `static` **remove**(`definition`): `void`

Defined in: [definition/src/lib/definition.ts:102](https://gitlab.com/rxap/packages/-/blob/d77504e6fd71447b1032f897cabb2aefac17c260/packages/angular/definition/src/lib/definition.ts#L102)

#### Parameters

##### definition

`BaseDefinition`

#### Returns

`void`

#### Inherited from

`BaseDataSource.remove`
