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

Unified Diff: pkg/args/lib/src/utils.dart

Issue 797473002: Add a CommandRunner class for dispatching commands to args. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Code review changes Created 6 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
Index: pkg/args/lib/src/utils.dart
diff --git a/pkg/collection/lib/src/utils.dart b/pkg/args/lib/src/utils.dart
similarity index 56%
copy from pkg/collection/lib/src/utils.dart
copy to pkg/args/lib/src/utils.dart
index c9c753777f07c1c5bd930fa4a3a7e32a5377db0f..dc355dfb63bef320a989c69e259859acf22352fd 100644
--- a/pkg/collection/lib/src/utils.dart
+++ b/pkg/args/lib/src/utils.dart
@@ -2,12 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-library dart.pkg.collection.utils;
+library args.utils;
-/// A pair of values.
-class Pair<E, F> {
- E first;
- F last;
-
- Pair(this.first, this.last);
-}
+/// Pads [source] to [length] by adding spaces at the end.
+String padRight(String source, int length) =>
+ source + ' ' * (length - source.length);

Powered by Google App Engine
This is Rietveld 408576698