# Interface FormController

interface FormController {
$addControl: ((arg0: NgModelController | FormController) => void);
$commitViewValue: (() => void);
$dirty: boolean;
$error: {};
$getControls: (() => readonly (NgModelController | FormController)[]);
$invalid: boolean;
$name: string;
$pending: {};
$pristine: boolean;
$removeControl: ((arg0: NgModelController | FormController) => void);
$rollbackViewValue: (() => void);
$setDirty: (() => void);
$setPristine: (() => void);
$setSubmitted: (() => void);
$setUntouched: (() => void);
$setValidity: ((arg0: string, arg1: boolean, arg2: NgModelController | FormController) => void);
$submitted: boolean;
$valid: boolean;
name: ((arg0: string) => any);
}

- Defined in types.js:369

#####
Index

### Properties

$addControl
$commitViewValue
$dirty
$error
$getControls
$invalid
$name
$pending
$pristine
$removeControl
$rollbackViewValue
$setDirty
$setPristine
$setSubmitted
$setUntouched
$setValidity
$submitted
$valid
name

##
Properties

### $addControl

$addControl: ((arg0: NgModelController | FormController) => void)

Adds a control to the form.

- Defined in types.js:378

### $commitViewValue

$commitViewValue: (() => void)

Commits the view value of all controls in the form.

- Defined in types.js:384

### $dirty

$dirty: boolean

True if the form has been modified.

- Defined in types.js:371

### $error

$error: {}

An object containing arrays of controls with validation errors keyed by validation error keys.

- Defined in types.js:375

### $getControls

$getControls: (() => readonly (NgModelController | FormController)[])

Returns an array of all controls in the form.

- Defined in types.js:379

### $invalid

$invalid: boolean

True if the form is invalid.

- Defined in types.js:373

### $name

$name: string

The name of the form.

- Defined in types.js:376

### $pending

$pending: {}

An object containing arrays of controls that are pending validation, keyed by validation error keys.

- Defined in types.js:377

### $pristine

$pristine: boolean

True if the form has not been modified.

- Defined in types.js:370

### $removeControl

$removeControl: ((arg0: NgModelController | FormController) => void)

Removes a control from the form.

- Defined in types.js:380

### $rollbackViewValue

$rollbackViewValue: (() => void)

Rolls back the view value of all controls in the form.

- Defined in types.js:385

### $setDirty

$setDirty: (() => void)

Marks the form as dirty.

- Defined in types.js:382

### $setPristine

$setPristine: (() => void)

Marks the form as pristine.

- Defined in types.js:383

### $setSubmitted

$setSubmitted: (() => void)

Marks the form as submitted.

- Defined in types.js:386

### $setUntouched

$setUntouched: (() => void)

Marks the form controls as untouched.

- Defined in types.js:387

### $setValidity

$setValidity: ((arg0: string, arg1: boolean, arg2: NgModelController | FormController) => void)

Sets the validity of a control in the form.

- Defined in types.js:381

### $submitted

$submitted: boolean

True if the form has been submitted.

- Defined in types.js:374

### $valid

$valid: boolean

True if the form is valid.

- Defined in types.js:372

### name

name: ((arg0: string) => any)

An indexer for additional properties.

- Defined in types.js:388