### File

`projects/commons/src/lib/shared/portal/portal-injector.ts`

### Implements

`Injector`

### Index

###### Methods
get

### Constructor

`constructor(parentInjector: Injector, customTokens: WeakMap)`
Defined in projects/commons/src/lib/shared/portal/portal-injector.ts:3
Parameters :
Name | Type | Optional
parentInjector | `Injector` | No
customTokens | `WeakMap<any | any>` | No

### Methods

get
`get(token: any, notFoundValue?: any)`
Defined in projects/commons/src/lib/shared/portal/portal-injector.ts:9
Parameters :
Name | Type | Optional
token | `any` | No
notFoundValue | `any` | Yes
Returns : `any`

    import { Injector } from '@angular/core';

    export class PortalInjector implements Injector {
      constructor(
          private readonly parentInjector: Injector,
          private readonly customTokens: WeakMap<any, any>
      ) {}

      get(token: any, notFoundValue?: any): any {
        return this.customTokens.get(token) || this.parentInjector.get<any>(token, notFoundValue);
      }
    }

# result-matching ""

# No results matching ""