newFile method

  1. @override
File newFile(
  1. String path,
  2. String content
)
inherited

Writes content to the file at path.

Implementation

@override
File newFile(String path, String content) {
  if (_analysisContextCollection != null && !path.endsWith('.dart')) {
    throw StateError('Only dart files can be changed after analysis.');
  }

  return super.newFile(path, content);
}