Remove unused function (#2808)
diff --git a/lib/src/solver/package_lister.dart b/lib/src/solver/package_lister.dart
index f57573d..087c958 100644
--- a/lib/src/solver/package_lister.dart
+++ b/lib/src/solver/package_lister.dart
@@ -447,7 +447,5 @@
@override
Future<Pubspec> doDescribe(PackageId id) => throw _unsupported;
@override
- Future get(PackageId id, String symlink) => throw _unsupported;
- @override
String getDirectory(PackageId id) => throw _unsupported;
}
diff --git a/lib/src/source.dart b/lib/src/source.dart
index ce35fb0..50e631a 100644
--- a/lib/src/source.dart
+++ b/lib/src/source.dart
@@ -229,10 +229,6 @@
/// external code should not call this. Instead, call [describe].
Future<Pubspec> doDescribe(PackageId id);
- /// Ensures [id] is available locally and creates a symlink at [symlink]
- /// pointing it.
- Future get(PackageId id, String symlink);
-
/// Returns the directory where this package can (or could) be found locally.
///
/// If the source is cached, this will be a path in the system cache.
diff --git a/lib/src/source/cached.dart b/lib/src/source/cached.dart
index 28f903a..0ec9b1f 100644
--- a/lib/src/source/cached.dart
+++ b/lib/src/source/cached.dart
@@ -47,13 +47,6 @@
/// the system cache.
Future<Pubspec> describeUncached(PackageId id);
- @override
- Future get(PackageId id, String symlink) {
- return downloadToSystemCache(id).then((pkg) {
- createPackageSymlink(id.name, pkg.dir, symlink);
- });
- }
-
/// Determines if the package identified by [id] is already downloaded to the
/// system cache.
bool isInSystemCache(PackageId id) => dirExists(getDirectory(id));
diff --git a/lib/src/source/path.dart b/lib/src/source/path.dart
index 45b827a..1d06496 100644
--- a/lib/src/source/path.dart
+++ b/lib/src/source/path.dart
@@ -181,15 +181,6 @@
}
@override
- Future get(PackageId id, String symlink) {
- return Future.sync(() {
- var dir = _validatePath(id.name, id.description);
- createPackageSymlink(id.name, dir, symlink,
- relative: id.description['relative']);
- });
- }
-
- @override
String getDirectory(PackageId id) => id.description['path'];
/// Ensures that [description] is a valid path description and returns a
diff --git a/lib/src/source/sdk.dart b/lib/src/source/sdk.dart
index 38ae7ec..ec201f2 100644
--- a/lib/src/source/sdk.dart
+++ b/lib/src/source/sdk.dart
@@ -7,7 +7,6 @@
import 'package:pub_semver/pub_semver.dart';
import '../exceptions.dart';
-import '../io.dart';
import '../package_name.dart';
import '../pubspec.dart';
import '../sdk.dart';
@@ -89,11 +88,6 @@
Pubspec.load(_verifiedPackagePath(package), systemCache.sources,
expectedName: package.name);
- @override
- Future get(PackageId id, String symlink) async {
- createPackageSymlink(id.name, _verifiedPackagePath(id), symlink);
- }
-
/// Returns the path for the given [package].
///
/// Throws a [PackageNotFoundException] if [package]'s SDK is unavailable or
diff --git a/lib/src/source/unknown.dart b/lib/src/source/unknown.dart
index ac43447..a9ae1f2 100644
--- a/lib/src/source/unknown.dart
+++ b/lib/src/source/unknown.dart
@@ -69,10 +69,6 @@
Future<Pubspec> doDescribe(PackageId id) => throw UnsupportedError(
"Cannot describe a package from unknown source '${source.name}'.");
- @override
- Future get(PackageId id, String symlink) =>
- throw UnsupportedError("Cannot get an unknown source '${source.name}'.");
-
/// Returns the directory where this package can be found locally.
@override
String getDirectory(PackageId id) => throw UnsupportedError(