### Index

- formatLanguage (projects/.../utils.ts)
- getBrowserLanguage (projects/.../utils.ts)
- getSchema (projects/.../utils.ts)
- getTargetNode (projects/.../bfs.ts)
- getValue (projects/.../utils.ts)
- handleParams (projects/.../utils.ts)
- hasCollator (projects/.../utils.ts)
- hasDateTimeFormat (projects/.../utils.ts)
- hasIntl (projects/.../utils.ts)
- hasListFormat (projects/.../utils.ts)
- hasNumberFormat (projects/.../utils.ts)
- hasPluralRules (projects/.../utils.ts)
- hasRelativeTimeFormat (projects/.../utils.ts)
- hasTimeZone (projects/.../utils.ts)
- isDate (projects/.../utils.ts)
- isObject (projects/.../utils.ts)
- isoStringToDate (projects/.../utils.ts)
- isTargetNode (projects/.../bfs.ts)
- isValidNode (projects/.../bfs.ts)
- l10nError (projects/.../l10n-error.ts)
- l10nValidateDate (projects/.../l10n-validate-date.directive.ts)
- l10nValidateNumber (projects/.../l10n-validate-number.directive.ts)
- mergeDeep (projects/.../utils.ts)
- parseDigits (projects/.../utils.ts)
- parseLanguage (projects/.../utils.ts)
- toDate (projects/.../utils.ts)
- toNumber (projects/.../utils.ts)
- validateLanguage (projects/.../utils.ts)
- walk (projects/.../bfs.ts)

### projects/angular-l10n/src/lib/models/utils.ts

###

formatLanguage
`formatLanguage(language, format)`

Parameters :

Name | Optional
language | No
format | No

Returns : `string`

getBrowserLanguage
`getBrowserLanguage()`
Returns : `string | null`

getSchema
`getSchema(schema, language, format)`

Parameters :

Name | Optional
schema | No
language | No
format | No

Returns : `L10nSchema | undefined`

getValue
`getValue(key, data, keySeparator)`

Parameters :

Name | Optional
key | No
data | No
keySeparator | No

Returns : `string | any | null`

handleParams
`handleParams(value, params: any)`

Parameters :

Name | Type | Optional
value |  | No
params | `any` | No

Returns : `string`

hasCollator
`hasCollator()`
Returns : `boolean`

hasDateTimeFormat
`hasDateTimeFormat()`
Returns : `boolean`

hasIntl
`hasIntl()`
Returns : `boolean`

hasListFormat
`hasListFormat()`
Returns : `boolean`

hasNumberFormat
`hasNumberFormat()`
Returns : `boolean`

hasPluralRules
`hasPluralRules()`
Returns : `boolean`

hasRelativeTimeFormat
`hasRelativeTimeFormat()`
Returns : `boolean`

hasTimeZone
`hasTimeZone()`
Returns : `boolean`

isDate
`isDate(value: any)`

Parameters :

Name | Type | Optional
value | `any` | No

Returns : `Date`

isObject
`isObject(item: any)`

Parameters :

Name | Type | Optional
item | `any` | No

Returns : `boolean`

isoStringToDate
`isoStringToDate(match)`

Converts a date in ISO 8601 to a Date.

Parameters :

Name | Optional
match | No

Returns : `Date`

mergeDeep
`mergeDeep(target, source)`

Parameters :

Name | Optional
target | No
source | No

Returns : `any`

parseDigits
`parseDigits(digits)`

Parameters :

Name | Optional
digits | No

parseLanguage
`parseLanguage(language)`

Parameters :

Name | Optional
language | No

toDate
`toDate(value: any)`

Parameters :

Name | Type | Optional
value | `any` | No

Returns : `Date`

toNumber
`toNumber(value: any)`

Parameters :

Name | Type | Optional
value | `any` | No

Returns : `number`

validateLanguage
`validateLanguage(language)`

Parameters :

Name | Optional
language | No

Returns : `boolean`

### projects/angular-l10n/src/lib/models/bfs.ts

###

getTargetNode
`getTargetNode(rootNode)`

Breadth First Search (BFS) algorithm for traversing & searching tree data structure of DOM explores the neighbor nodes first, before moving to the next level neighbors. Time complexity: between O(1) and O(|V|^2).

Parameters :

Name | Optional
rootNode | No

Returns : `HTMLElement`

isTargetNode
`isTargetNode(node)`

Parameters :

Name | Optional
node | No

Returns : `boolean`

isValidNode
`isValidNode(node)`

A valid node is not marked for translation.

Parameters :

Name | Optional
node | No

Returns : `boolean`

walk
`walk(rootNode)`

Parameters :

Name | Optional
rootNode | No

Returns : `HTMLElement`

### projects/angular-l10n/src/lib/models/l10n-error.ts

###

l10nError
`l10nError(type, value)`

Parameters :

Name | Optional
type | No
value | No

Returns : `string`

### projects/angular-l10n/src/lib/directives/l10n-validate-date.directive.ts

###

l10nValidateDate
`l10nValidateDate(validation, options?, minDate?, maxDate?, language?)`

Function that takes a control and returns either null when it’s valid, or an error object if it’s not.

Parameters :

Name | Optional | Description
validation | No | The instance of L10nValidation service
options | Yes | A L10n or Intl DateTimeFormatOptions object
minDate | Yes | The minimum date
maxDate | Yes | The maximum date
language | Yes | The current language

Returns : `ValidatorFn`

An error object: 'format', 'minDate' or 'maxDate'; null in case the date is valid

### projects/angular-l10n/src/lib/directives/l10n-validate-number.directive.ts

###

l10nValidateNumber
`l10nValidateNumber(validation, options?, minValue, maxValue, language?)`

Function that takes a control and returns either null when it’s valid, or an error object if it’s not.

Parameters :

Name | Optional | Description
validation | No | The instance of L10nValidation service
options | Yes | A L10n or Intl NumberFormatOptions object
minValue | No | The minimum value
maxValue | No | The maximum value
language | Yes | The current language

Returns : `ValidatorFn`

An error object: 'format', 'minValue' or 'maxValue'; null in case the value is valid

# result-matching ""

# No results matching ""