[@rxap/material-table-system](../wiki/globals) / SelectedRowsDirective

# Class: SelectedRowsDirective\<Data\>

Defined in: [packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts:25](https://gitlab.com/rxap/packages/-/blob/8058138ff98d9e37b711846892c79ebc45ed17d4/packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts#L25)

## Type Parameters

• **Data** *extends* `Record`\<`string`, `any`\>

## Implements

- `OnInit`
- `OnDestroy`

## Constructors

### new SelectedRowsDirective()

> **new SelectedRowsDirective**\<`Data`\>(`template`, `viewContainerRef`, `cdr`, `selectRowService`): [`SelectedRowsDirective`](../wiki/Class.SelectedRowsDirective)\<`Data`\>

Defined in: [packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts:29](https://gitlab.com/rxap/packages/-/blob/8058138ff98d9e37b711846892c79ebc45ed17d4/packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts#L29)

#### Parameters

##### template

`TemplateRef`\<[`SelectedRowsDirectiveContext`](../wiki/Interface.SelectedRowsDirectiveContext)\<`Data`\>\>

##### viewContainerRef

`ViewContainerRef`

##### cdr

`ChangeDetectorRef`

##### selectRowService

[`SelectRowService`](../wiki/Class.SelectRowService)\<`Data`\>

#### Returns

[`SelectedRowsDirective`](../wiki/Class.SelectedRowsDirective)\<`Data`\>

## Methods

### ngOnDestroy()

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

Defined in: [packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts:41](https://gitlab.com/rxap/packages/-/blob/8058138ff98d9e37b711846892c79ebc45ed17d4/packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts#L41)

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

#### Returns

`void`

#### Implementation of

`OnDestroy.ngOnDestroy`

***

### ngOnInit()

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

Defined in: [packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts:45](https://gitlab.com/rxap/packages/-/blob/8058138ff98d9e37b711846892c79ebc45ed17d4/packages/angular/material/table-system/src/lib/select-row/selected-rows.directive.ts#L45)

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`
