# Class MinilinkCollection<MGO, L>

#### Type Parameters

- #### MGO extends MinilinksGeneratorOptions = typeof MinilinksGeneratorOptionsDefault

- #### L extends Link<Id> = Link<Id>

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:205

#####
Index

### Constructors

constructor

### Properties

_updating
byFrom
byId
byTo
byType
emitter
links
options
types
useMinilinksApply
useMinilinksFilter
useMinilinksHandle
useMinilinksQuery
useMinilinksSubscription

### Methods

add
apply
query
remove
select
subscribe

## Constructors

### constructor

- new MinilinkCollection<MGO, L>(options?, memory?): MinilinkCollection<MGO, L>

- #### Type Parameters

  - #### MGO extends MinilinksGeneratorOptions = MinilinksGeneratorOptions

  - #### L extends Link<Id> = Link<Id>

  #### Parameters

  - ##### `Optional` options: MGO

  - ##### `Optional` memory: any

  #### Returns MinilinkCollection<MGO, L>

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:510

## Properties

### _updating

_updating: boolean = false

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:449

### byFrom

byFrom: {
[id: Id]: L[];
} = {}

#### Type declaration

- ##### [id: Id]: L[]

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:214

### byId

byId: {
[id: Id]: L;
} = {}

#### Type declaration

- ##### [id: Id]: L

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:213

### byTo

byTo: {
[id: Id]: L[];
} = {}

#### Type declaration

- ##### [id: Id]: L[]

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:215

### byType

byType: {
[id: Id]: L[];
} = {}

#### Type declaration

- ##### [id: Id]: L[]

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:216

### emitter

emitter: EventEmitter

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:219

### links

links: L[] = []

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:217

### options

options: MGO

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:218

### types

types: {
[id: Id]: L[];
} = {}

#### Type declaration

- ##### [id: Id]: L[]

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:212

### useMinilinksApply

useMinilinksApply: (<L>(ml, name, data?) => any) = useMinilinksApply

#### Type declaration

- - <L>(ml, name, data?): any

  - #### Type Parameters

    - #### L extends Link<Id>

    #### Parameters

    - ##### ml: any

    - ##### name: string

    - ##### `Optional` data: L[]

    #### Returns any

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:208

### useMinilinksFilter

useMinilinksFilter: (<L, R>(ml, filter, results, interval?) => R) = useMinilinksFilter

#### Type declaration

- - <L, R>(ml, filter, results, interval?): R

  - #### Type Parameters

    - #### L extends Link<Id>

    - #### R = any

    #### Parameters

    - ##### ml: any

    - ##### filter: ((currentLink, oldLink, newLink) => boolean)

      - - (currentLink, oldLink, newLink): boolean

        - #### Parameters

          - ##### currentLink: L

          - ##### oldLink: L

          - ##### newLink: L

          #### Returns boolean

    - ##### results: ((l?, ml?, oldLink?, newLink?) => R)

      - - (l?, ml?, oldLink?, newLink?): R

        - #### Parameters

          - ##### `Optional` l: L

          - ##### `Optional` ml: any

          - ##### `Optional` oldLink: L

          - ##### `Optional` newLink: L

          #### Returns R

    - ##### `Optional` interval: number

    #### Returns R

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:207

### useMinilinksHandle

useMinilinksHandle: (<L>(ml, handler) => void) = useMinilinksHandle

#### Type declaration

- - <L>(ml, handler): void

  - #### Type Parameters

    - #### L extends Link<Id>

    #### Parameters

    - ##### ml: any

    - ##### handler: ((event, oldLink, newLink) => any)

      - - (event, oldLink, newLink): any

        - #### Parameters

          - ##### event: any

          - ##### oldLink: any

          - ##### newLink: any

          #### Returns any

    #### Returns void

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:210

### useMinilinksQuery

useMinilinksQuery: (<L>(ml, query) => any) = useMinilinksQuery

#### Type declaration

- - <L>(ml, query): any

  - React hook. Returns reactiviely links from minilinks, by query in deeplinks dialect. Recalculates when query changes. (Take query into useMemo!).

    #### Type Parameters

    - #### L extends Link<Id>

    #### Parameters

    - ##### ml: any

    - ##### query: QueryLink | Id

    #### Returns any

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:206

### useMinilinksSubscription

useMinilinksSubscription: (<L>(ml, query) => any) = useMinilinksSubscription

#### Type declaration

- - <L>(ml, query): any

  - React hook. Returns reactiviely links from minilinks, by query in deeplinks dialect. Recalculates when data in minilinks changes. (Take query into useMemo!).

    #### Type Parameters

    - #### L extends Link<Id>

    #### Parameters

    - ##### ml: any

    - ##### query: QueryLink | Id

    #### Returns any

- Defined in work/deeplinks/deeplinks/imports/minilinks.ts:209

## Methods

### add

- add(linksArray): {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

- #### Parameters

  - ##### linksArray: any[]

  #### Returns {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

  - ##### `Optional` anomalies?: MinilinkError[]

  - ##### `Optional` errors?: MinilinkError[]

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:261

### apply

- apply(linksArray, applyName?): {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

- #### Parameters

  - ##### linksArray: any[]

  - ##### applyName: string = ''

  #### Returns {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

  - ##### `Optional` anomalies?: MinilinkError[]

  - ##### `Optional` errors?: MinilinkError[]

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:450

### query

- query<A>(query, options?): A extends string
  ? any
  : L[]

- #### Type Parameters

  - #### A

  #### Parameters

  - ##### query: QueryLink | Id

  - ##### `Optional` options: MinilinksQueryOptions<A>

  #### Returns A extends string
  ? any
  : L[]

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:221

### remove

- remove(idsArray): {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

- #### Parameters

  - ##### idsArray: any[]

  #### Returns {
  anomalies?: MinilinkError[];
  errors?: MinilinkError[];
  }

  - ##### `Optional` anomalies?: MinilinkError[]

  - ##### `Optional` errors?: MinilinkError[]

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:374

### select

- select(query, options?): any

- #### Parameters

  - ##### query: QueryLink | Id

  - ##### `Optional` options: MinilinksQueryOptions<MinilinksQueryOptionAggregate>

  #### Returns any

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:230

### subscribe

- subscribe(query): Observable<any>

- minilinks.subscribe

  #### Parameters

  - ##### query: QueryLink | Id

  #### Returns Observable<any>

  #### Example

      minilinks.subscribe({ type_id: 2 }).subscribe({ next: (links) => {}, error: (err) => {} });

  - Defined in work/deeplinks/deeplinks/imports/minilinks.ts:239

Generated using TypeDoc