withOverrides

Builds a profile based on one of this object's five language profiles.

Overrides are looked up first, are case-sensitive, and may contain only MRZ alphabet characters (A to Z, 0 to 9, <); an empty value drops the character. The identifier must not be blank. The map is copied, and the new profile is not registered automatically. Language rules still apply to characters that are not overridden, but an override wins over the base profile's own rules, so an override for Ь also wins over the Ukrainian profile's drop of the soft sign. The comma rule still applies, so an override for ',' has no effect.

Return

The new profile.

Since

1.0.0

Parameters

base

The profile to base the new one on. It must be one of all.

identifier

Identifier of the new profile. It must not be blank.

overrides

Replacement text for single characters.

Throws

If base is not one of all, identifier is blank, or an override value has a character outside the MRZ alphabet.