setCustomLocaleMessages static method

void setCustomLocaleMessages(
  1. String customLocale,
  2. Messages customMessages
)

Sets a customLocale with the provided customMessages to be available when using the parse function.

Example:

setLocaleMessages('hi', HindiMessages());

If you want to define locale message implement Messages interface with the desired messages

Implementation

static void setCustomLocaleMessages(
  String customLocale,
  Messages customMessages,
) {
  _messageMap[customLocale] = customMessages;
}