| Index: pkg/analyzer/lib/file_system/file_system.dart
|
| diff --git a/pkg/analyzer/lib/file_system/file_system.dart b/pkg/analyzer/lib/file_system/file_system.dart
|
| index 139330bb61740fa24900c03c859c30520b3baf86..11223c92fa8992a7505798a0ab63060c53b33b4f 100644
|
| --- a/pkg/analyzer/lib/file_system/file_system.dart
|
| +++ b/pkg/analyzer/lib/file_system/file_system.dart
|
| @@ -32,6 +32,9 @@ abstract class File implements Resource {
|
| */
|
| int get modificationStamp;
|
|
|
| + @override
|
| + File copyTo(Folder parentFolder);
|
| +
|
| /**
|
| * Create a new [Source] instance that serves this file.
|
| */
|
| @@ -114,6 +117,14 @@ abstract class Folder implements Resource {
|
| */
|
| bool contains(String path);
|
|
|
| + @override
|
| + Folder copyTo(Folder parentFolder);
|
| +
|
| + /**
|
| + * If this folder does not already exist, create it.
|
| + */
|
| + void create();
|
| +
|
| /**
|
| * Return an existing child [Resource] with the given [relPath].
|
| * Return a not existing [File] if no such child exist.
|
| @@ -170,6 +181,19 @@ abstract class Resource {
|
| String get shortName;
|
|
|
| /**
|
| + * Copy this resource to a child of the [parentFolder] with the same kind and
|
| + * [shortName] as this resource. If this resource is a folder, then all of the
|
| + * contents of the folder will be recursively copied.
|
| + *
|
| + * The parent folder is created if it does not already exist.
|
| + *
|
| + * Existing files and folders will be overwritten.
|
| + *
|
| + * Return the resource corresponding to this resource in the parent folder.
|
| + */
|
| + Resource copyTo(Folder parentFolder);
|
| +
|
| + /**
|
| * Synchronously deletes this resource and its children.
|
| *
|
| * Throws an exception if the resource cannot be deleted.
|
|
|