Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(558)

Unified Diff: utils/pub/system_cache.dart

Issue 11638010: Convert /** comments to /// in pub. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Respond to review. Created 8 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « utils/pub/source_registry.dart ('k') | utils/pub/utils.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/system_cache.dart
diff --git a/utils/pub/system_cache.dart b/utils/pub/system_cache.dart
index ce913e0958968802e6ede6add45fc4d50e965150..abd23482441d3e8634b0c7e76bc8385ef036ecd1 100644
--- a/utils/pub/system_cache.dart
+++ b/utils/pub/system_cache.dart
@@ -18,34 +18,25 @@ import 'source_registry.dart';
import 'utils.dart';
import 'version.dart';
-/**
- * The system-wide cache of installed packages.
- *
- * This cache contains all packages that are downloaded from the internet.
- * Packages that are available locally (e.g. from the SDK) don't use this cache.
- */
+/// The system-wide cache of installed packages.
+///
+/// This cache contains all packages that are downloaded from the internet.
+/// Packages that are available locally (e.g. from the SDK) don't use this
+/// cache.
class SystemCache {
- /**
- * The root directory where this package cache is located.
- */
+ /// The root directory where this package cache is located.
final String rootDir;
String get tempDir => join(rootDir, '_temp');
- /**
- * Packages which are currently being asynchronously installed to the cache.
- */
+ /// Packages which are currently being asynchronously installed to the cache.
final Map<PackageId, Future<Package>> _pendingInstalls;
- /**
- * The sources from which to install packages.
- */
+ /// The sources from which to install packages.
final SourceRegistry sources;
- /**
- * Creates a new package cache which is backed by the given directory on the
- * user's file system.
- */
+ /// Creates a new package cache which is backed by the given directory on the
+ /// user's file system.
SystemCache(this.rootDir)
: _pendingInstalls = new Map<PackageId, Future<Package>>(),
sources = new SourceRegistry();
@@ -60,22 +51,18 @@ class SystemCache {
return cache;
}
- /**
- * Registers a new source. This source must not have the same name as a source
- * that's already been registered.
- */
+ /// Registers a new source. This source must not have the same name as a
+ /// source that's already been registered.
void register(Source source) {
source.bind(this);
sources.register(source);
}
- /**
- * Ensures that the package identified by [id] is installed to the cache,
- * loads it, and returns it.
- *
- * It is an error to try installing a package from a source with `shouldCache
- * == false` to the system cache.
- */
+ /// Ensures that the package identified by [id] is installed to the cache,
+ /// loads it, and returns it.
+ ///
+ /// It is an error to try installing a package from a source with `shouldCache
+ /// == false` to the system cache.
Future<Package> install(PackageId id) {
if (!id.source.shouldCache) {
throw new ArgumentError("Package $id is not cacheable.");
« no previous file with comments | « utils/pub/source_registry.dart ('k') | utils/pub/utils.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698