validateConfig method
void
validateConfig()
Implementation
void validateConfig() {
if (config.directory == null) {
error(2, 'Parameter "directory" is not defined in config file');
}
if (config.filename == null) {
error(2, 'Parameter "filename" is not defined in config file');
}
if (!config.filename!.contains('{1}')) {
error(
2,
'File name pattern should contain {1} argument which refers to '
'the language name',
);
}
if (config.format == null) {
error(2, 'Parameter "format" is not defined in config file');
}
if (!kSimplelocalizeFormats.containsKey(config.format)) {
error(
2,
'Unfortunately "${config.format}" format is not supported currently. '
'Supported formats are: ${kSimplelocalizeFormats.keys}',
);
}
}