On this page:
get-codeset
2.1 Date and Time formatting
get-datetime-format
get-date-format
get-time-format
get-time-ampm-format
get-am-string
get-pm-string
get-weekday-name
get-abbrev-weekday-name
get-month-name
get-abbrev-month-name
get-era-description
get-era-date-format
get-era-datetime-format
get-era-time-format
2.2 Numeric and Currency formatting
get-alt-digit-symbol
get-radix-character
get-thousands-separator
get-currency-symbol
2.3 Other formatting
get-yes-expression
get-no-expression
8.12

2 Module locale/language-info🔗ℹ

 (require locale/language-info) package: racket-locale

More locale/language-info tools for Racket

Examples:
> (require locale/language-info)
> (get-codeset)

"ANSI_X3.4-1968"

> (get-datetime-format)

"%a %b %e %H:%M:%S %Y"

> (get-weekday-name 1)

"Sunday"

> (get-month-name 2)

"February"

> (get-era-description)

""

> (get-currency-symbol)

"-"

procedure

(get-codeset)  string?

Return a string with the name of the character encoding used in the selected locale, such as "UTF-8", "ISO-8859-1", or "ANSI_X3.4-1968" (better known as US-ASCII).

2.1 Date and Time formatting🔗ℹ

procedure

(get-datetime-format)  string?

Return a string that can be used as a format string to represent time and date in a locale-specific way.

procedure

(get-date-format)  string?

Return a string that can be used as a format string for strftime(3) to represent a date in a locale-specific way.

procedure

(get-time-format)  string?

Return a string that can be used as a format string for strftime(3) to represent a time in a locale-specific way.

procedure

(get-time-ampm-format)  string?

a.m. or p.m. time format string.

procedure

(get-am-string)  string?

Ante Meridian affix string.

procedure

(get-pm-string)  string?

Post Meridian affix string.

procedure

(get-weekday-name day)  string?

  day : integer?
Return name of the n-th day of the week. Warning: this follows the US convention where Sunday is the first day of the week, not the international convention (ISO 8601) of Monday.

procedure

(get-abbrev-weekday-name day)  string?

  day : integer?
Return abbreviated name of the n-th day of the week.

procedure

(get-month-name month)  string?

  month : integer
Return name of the n-th month.

procedure

(get-abbrev-month-name month)  string?

  month : integer
Return abbreviated name of the n-th month.

procedure

(get-era-description)  string?

Era description segments.

procedure

(get-era-date-format)  string?

Era date format string.

Era date and time format string.

procedure

(get-era-time-format)  string?

Era time format string.

2.2 Numeric and Currency formatting🔗ℹ

procedure

(get-alt-digit-symbol)  string?

Alternative symbols for digits.

procedure

(get-radix-character)  string?

Return radix character (decimal dot, decimal comma, etc.).

Return separator character for thousands (groups of three digits).

procedure

(get-currency-symbol)  string?

Return the currency symbol, preceded by "-" if the symbol should appear before the value, "+" if the symbol should appear after the value, or "." if the symbol should replace the radix character.

2.3 Other formatting🔗ℹ

procedure

(get-yes-expression)  string?

Return a regular expression that can be used with the regexp function to recognize a positive response to a yes/no question.

procedure

(get-no-expression)  string?

Return a regular expression that can be used with the regexp function to recognize a negative response to a yes/no question.