| Index: third_party/pkg/angular/lib/tools/io_impl.dart
|
| diff --git a/third_party/pkg/angular/lib/tools/io_impl.dart b/third_party/pkg/angular/lib/tools/io_impl.dart
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..e0397cef072b617563cb4a1ffdbe08bdbf7c035d
|
| --- /dev/null
|
| +++ b/third_party/pkg/angular/lib/tools/io_impl.dart
|
| @@ -0,0 +1,22 @@
|
| +library angular.io_impl;
|
| +
|
| +import 'dart:io';
|
| +import 'io.dart';
|
| +
|
| +class IoServiceImpl implements IoService {
|
| +
|
| + String readAsStringSync(String filePath) =>
|
| + new File(filePath).readAsStringSync();
|
| +
|
| + void visitFs(String rootDir, FsVisitor visitor) {
|
| + Directory root = new Directory(rootDir);
|
| + if (!FileSystemEntity.isDirectorySync(rootDir)) {
|
| + throw 'Expected $rootDir to be a directory!';
|
| + }
|
| + root.listSync(recursive: true, followLinks: true).forEach((entity) {
|
| + if (entity.statSync().type == FileSystemEntityType.FILE) {
|
| + visitor(entity.path);
|
| + }
|
| + });
|
| + }
|
| +}
|
|
|