parseFile method

Map<String, MainMessage> parseFile(
  1. File file, [
  2. bool transformer = false
])

Parse the source of the Dart program file file and return a Map from message names to IntlMessage instances.

If transformer is true, assume the transformer will supply any "name" and "args" parameters required in Intl.message calls.

Implementation

Map<String, MainMessage> parseFile(File file, [bool transformer = false]) {
  var contents = file.readAsStringSync();
  return parseContent(contents, file.path, transformer);
}