- Source:
Methods
(inner) generateCharCode(charCodeRequest, flagsopt) → {number}
Generates a random integer of a requested type.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
charCodeRequest | charCodeRequest | An object contain the properties that describes the type of character code being requested and restrictions being place on it. | |
flags | charCodeGenerationFlag | <optional> | A flag object used to give more information about what stage of password generation we are at. |
- Source:
Requires:
- module:characterCodeConstraints
- module:characterCodeConstraintsAttributes
Throws:
Will throw an error if the requested character code type is not found within the character code constraints object.
- Type
- errors.nonGenerableCharacterType
Returns:
An integer representing a UTF-16 character code unit. The integer will be within range of the defined character code request constraints.
- Type
- number