characters_handling

extras/characters_handling.vhdl

Description

This is a package of functions that replicate the behavior of the Ada standard library package Ada.Characters.Handling. Included are functions to test for different character classifications and perform conversion of characters and strings to upper and lower case.

Subprograms

characters_handling.Is_Alphanumeric (Ch : character) → boolean
Alphanumeric character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if alphanumeric character.

characters_handling.Is_Letter (Ch : character) → boolean
Letter character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if letter character.

characters_handling.Is_Control (Ch : character) → boolean
Control character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if control character.

characters_handling.Is_Digit (Ch : character) → boolean
Digit character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if digit character.

characters_handling.Is_Hexadecimal_Digit (Ch : character) → boolean
Hexadecimal digit character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if hexadecimal character.

characters_handling.Is_Basic (Ch : character) → boolean
Basic character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if basic character.

characters_handling.Is_Graphic (Ch : character) → boolean
Graphic character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if graphic character.

characters_handling.Is_Lower (Ch : character) → boolean
Lower-case character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if lower-case character.

characters_handling.Is_Upper (Ch : character) → boolean
Upper-case character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if upper-case character.

characters_handling.Is_Special (Ch : character) → boolean
Special character test.
Parameters:
  • Ch (character) – Character to test
Returns:

true if special character.

characters_handling.To_Lower (Ch : character) → character
Convert a character to lower-case.
Parameters:
  • Ch (character) – Character to convert
Returns:

Converted character.

characters_handling.To_Lower (Source : string) → string
Convert a string to lower-case.
Parameters:
  • Source (string) – String to convert
Returns:

Converted string.

characters_handling.To_Upper (Ch : character) → character
Convert a character to upper-case.
Parameters:
  • Ch (character) – Character to convert
Returns:

Converted character.

characters_handling.To_Upper (Source : string) → string
Convert a string to upper-case.
Parameters:
  • Source (string) – String to convert
Returns:

Converted string.

characters_handling.To_Basic (Ch : character) → character
Convert a character to its basic (unaccented) form.
Parameters:
  • Ch (character) – Character to convert
Returns:

Converted character.

characters_handling.To_Basic (Source : string) → string
Convert a string to its basic (unaccented) form.
Parameters:
  • Source (string) – String to convert
Returns:

Converted string.