validate method
void
validate()
override
Verify that a constructed message is valid.
This is called after the message has already been built, as opposed to checkValidity which is called before creation. It can be used to validate conditions that can just be checked against the result, and/or are simpler to check there than on the AST nodes. For example, is a required clause like "other" included, or are there examples for all of the parameters. It should throw an IntlMessageExtractionException for errors.
Implementation
void validate() {
if (this["other"] == null) {
throw new IntlMessageExtractionException(
"Missing keyword other for Intl.select $this");
}
}