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

Unified Diff: sdk/lib/_internal/pub/lib/src/version.dart

Issue 344493003: Update doc comments to follow style guide. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 6 months 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 | « sdk/lib/_internal/pub/lib/src/validator/dependency.dart ('k') | sdk/lib/_internal/pub/test/test_pub.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/pub/lib/src/version.dart
diff --git a/sdk/lib/_internal/pub/lib/src/version.dart b/sdk/lib/_internal/pub/lib/src/version.dart
index a726fd076439ece7427527c7368ebf8473aa8aa0..7e33fe2de8e0909e22e88bcdf70c7ad9b4444888 100644
--- a/sdk/lib/_internal/pub/lib/src/version.dart
+++ b/sdk/lib/_internal/pub/lib/src/version.dart
@@ -125,9 +125,10 @@ class Version implements Comparable<Version>, VersionConstraint {
}
}
- /// Returns the primary version out of a list of candidates. This is the
- /// highest-numbered stable (non-prerelease) version. If there are no stable
- /// versions, it's just the highest-numbered version.
+ /// Returns the primary version out of a list of candidates.
+ ///
+ /// This is the highest-numbered stable (non-prerelease) version. If there
+ /// are no stable versions, it's just the highest-numbered version.
static Version primary(List<Version> versions) {
var primary;
for (var version in versions) {
@@ -203,7 +204,7 @@ class Version implements Comparable<Version>, VersionConstraint {
}
/// Gets the next patch version number that follows this one.
- ///bed8b33fda6ec81c3ba52274d189bc0661ed12bf
+ ///
/// If this version is a pre-release, then it just strips the pre-release
/// suffix. Otherwise, it increments the patch version.
Version get nextPatch {
@@ -292,9 +293,11 @@ class Version implements Comparable<Version>, VersionConstraint {
}
/// A [VersionConstraint] is a predicate that can determine whether a given
-/// version is valid or not. For example, a ">= 2.0.0" constraint allows any
-/// version that is "2.0.0" or greater. Version objects themselves implement
-/// this to match a specific version.
+/// version is valid or not.
+///
+/// For example, a ">= 2.0.0" constraint allows any version that is "2.0.0" or
+/// greater. Version objects themselves implement this to match a specific
+/// version.
abstract class VersionConstraint {
/// A [VersionConstraint] that allows all versions.
static VersionConstraint any = new VersionRange();
@@ -302,8 +305,10 @@ abstract class VersionConstraint {
/// A [VersionConstraint] that allows no versions: i.e. the empty set.
static VersionConstraint empty = const _EmptyVersion();
- /// Parses a version constraint. This string is either "any" or a series of
- /// version parts. Each part can be one of:
+ /// Parses a version constraint.
+ ///
+ /// This string is either "any" or a series of version parts. Each part can
+ /// be one of:
///
/// * A version string like `1.2.3`. In other words, anything that can be
/// parsed by [Version.parse()].
@@ -395,9 +400,11 @@ abstract class VersionConstraint {
}
/// Creates a new version constraint that is the intersection of
- /// [constraints]. It will only allow versions that all of those constraints
- /// allow. If constraints is empty, then it returns a VersionConstraint that
- /// allows all versions.
+ /// [constraints].
+ ///
+ /// It only allows versions that all of those constraints allow. If
+ /// constraints is empty, then it returns a VersionConstraint that allows
+ /// all versions.
factory VersionConstraint.intersection(
Iterable<VersionConstraint> constraints) {
var constraint = new VersionRange();
@@ -421,10 +428,11 @@ abstract class VersionConstraint {
VersionConstraint intersect(VersionConstraint other);
}
-/// Constrains versions to a fall within a given range. If there is a minimum,
-/// then this only allows versions that are at that minimum or greater. If there
-/// is a maximum, then only versions less than that are allowed. In other words,
-/// this allows `>= min, < max`.
+/// Constrains versions to a fall within a given range.
+///
+/// If there is a minimum, then this only allows versions that are at that
+/// minimum or greater. If there is a maximum, then only versions less than
+/// that are allowed. In other words, this allows `>= min, < max`.
class VersionRange implements VersionConstraint {
final Version min;
final Version max;
« no previous file with comments | « sdk/lib/_internal/pub/lib/src/validator/dependency.dart ('k') | sdk/lib/_internal/pub/test/test_pub.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698