# Class OptionsFromMethodDirective<Value, Parameters>

#### Type Parameters

- Value = any
- Parameters = any

#### Hierarchy (View Summary)

- AfterViewInit
- OnChanges
- ExtractOptionsMethodMixin
  - OptionsFromMethodDirective
    - AutocompleteOptionsFromMethodDirective

#### Implements

- AfterViewInit
- OnChanges

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:39
- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:49

#####
Index

### Constructors

constructor

### Properties

cdr
control?
injector
matFormField
method
ngControl
options
parameters?
resetOnChange?
settings
viewContainerRef

### Methods

extractControl
extractFormDefinition
extractMethod
extractMethods
extractOptionsMethod
loadOptions
ngAfterViewInit
ngOnChanges
renderTemplate
setOptions
ngTemplateContextGuard

##
Constructors

### constructor

- new OptionsFromMethodDirective<Value = any, Parameters = any>(): OptionsFromMethodDirective<
  Value,
  Parameters,
  >

  #### Type Parameters

  - Value = any
  - Parameters = any

  #### Returns OptionsFromMethodDirective<Value, Parameters>

  Inherited from ExtractOptionsMethodMixin.constructor

##
Properties

### `Protected` `Readonly` cdr

cdr: ChangeDetectorRef = ...

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:73

### `Protected` `Optional` control

control?: RxapFormControl<any, any, any>

Inherited from ExtractOptionsMethodMixin.control

- Defined in packages/angular/form-system/src/lib/mixins/extract-control.mixin.ts:14

### `Protected` `Readonly` injector

injector: Injector = ...

Inherited from ExtractOptionsMethodMixin.injector

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:72

### `Protected` matFormField

matFormField: null | MatFormField = null

Inherited from ExtractOptionsMethodMixin.matFormField

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:69

### method

method: Method<ControlOptions, Parameters>

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:67

### `Protected` ngControl

ngControl: null | NgControl | AbstractControlDirective = null

Inherited from ExtractOptionsMethodMixin.ngControl

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:68

### options

options: null | ControlOptions = null

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:64

### `Optional` parameters

parameters?: Parameters

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:59

### `Optional` resetOnChange

resetOnChange?: Value

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:62

### `Protected` settings

settings: OptionsFromMethodDirectiveSettings = {}

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:70

### `Protected` `Readonly` viewContainerRef

viewContainerRef: ViewContainerRef = ...

- Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:71

##
Methods

### `Protected` extractControl

- extractControl(
  ngControl?: null | NgControl | AbstractControlDirective,
  ): RxapFormControl

  #### Parameters

  - ngControl: null | NgControl | AbstractControlDirective = ...

  #### Returns RxapFormControl

  Inherited from ExtractOptionsMethodMixin.extractControl

  - Defined in packages/angular/form-system/src/lib/mixins/extract-control.mixin.ts:16

### `Protected` extractFormDefinition

- extractFormDefinition(control: AbstractControl): FormDefinition

  #### Parameters

  - control: AbstractControl

  #### Returns FormDefinition

  Inherited from ExtractOptionsMethodMixin.extractFormDefinition

  - Defined in packages/angular/form-system/src/lib/mixins/extract-form-definition.mixin.ts:10

### extractMethod

- extractMethod(
  formDefinition: FormDefinition,
  controlId: string,
  name: string,
  ): Method<any, any>

  #### Parameters

  - formDefinition: FormDefinition
  - controlId: string
  - name: string

  #### Returns Method<any, any>

  Inherited from ExtractOptionsMethodMixin.extractMethod

  - Defined in packages/angular/form-system/src/lib/mixins/extract-method.mixin.ts:16

### `Protected` extractMethods

- extractMethods(
  formDefinition: FormDefinition,
  controlId: string,
  ): Map<
  string,
  UseMethodDefinition<
  unknown,
  unknown,
  UseMethodConfig<unknown, unknown, any, any>,
  >,
  >

  #### Parameters

  - formDefinition: FormDefinition
  - controlId: string

  #### Returns Map<
  string,
  UseMethodDefinition<
  unknown,
  unknown,
  UseMethodConfig<unknown, unknown, any, any>,
  >,
  >

  Inherited from ExtractOptionsMethodMixin.extractMethods

  - Defined in packages/angular/form-system/src/lib/mixins/extract-methods.mixin.ts:43

### `Protected` extractOptionsMethod

- extractOptionsMethod(
  control?: RxapFormControl,
  formDefinition?: FormDefinition<any, any, any>,
  ): Method<any, any>

  #### Parameters

  - control: RxapFormControl = ...
  - formDefinition: FormDefinition<any, any, any> = ...

  #### Returns Method<any, any>

  Inherited from ExtractOptionsMethodMixin.extractOptionsMethod

  - Defined in packages/angular/form-system/src/lib/mixins/extract-options-method.mixin.ts:29

### `Protected` loadOptions

- loadOptions(parameters?: Parameters): Promise<null | ControlOptions>

  #### Parameters

  - `Optional` parameters: Parameters

  #### Returns Promise<null | ControlOptions>

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:101

### ngAfterViewInit

- ngAfterViewInit(): Promise<void>

  A callback method that is invoked immediately after Angular has completed initialization of a component's view. It is invoked only once when the view is instantiated.

  #### Returns Promise<void>

  Inherited from AfterViewInit.ngAfterViewInit

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:76

### ngOnChanges

- ngOnChanges(changes: SimpleChanges): Promise<void>

  A callback method that is invoked immediately after the default change detector has checked data-bound properties if at least one has changed, and before the view and content children are checked.

  #### Parameters

  - changes: SimpleChanges

    The changed properties.

  #### Returns Promise<void>

  Inherited from OnChanges.ngOnChanges

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:88

### `Protected` renderTemplate

- renderTemplate(): void

  #### Returns void

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:105

### `Protected` setOptions

- setOptions(options: null | ControlOptions): void

  #### Parameters

  - options: null | ControlOptions

  #### Returns void

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:125

### `Static` ngTemplateContextGuard

- ngTemplateContextGuard(
  dir: OptionsFromMethodDirective,
  ctx: any,
  ): ctx is OptionsFromMethodTemplateContext

  #### Parameters

  - dir: OptionsFromMethodDirective
  - ctx: any

  #### Returns ctx is OptionsFromMethodTemplateContext

  - Defined in packages/angular/form-system/src/lib/directives/options-from-method.directive.ts:51