PackageHealth class

Aggregates package metadata from pub.dev, GitHub, and local analysis.

Annotations
  • @immutable

Constructors

PackageHealth({String? latestVersion, DateTime? latestPublishedAt, String? publisher, double? popularity, int? likes, int? pubPoints, List<DateTime> publishedVersions = const <DateTime>[], bool isDiscontinued = false, String? repositoryUrl, String? githubOrg, int? stars, int? contributors, DateTime? lastCommitAt, int? openIssues, String? sdkConstraint, bool isSdkPackage = false, bool offline = false})
Creates a package health snapshot.
const

Properties

contributors → int?
The contributor count, when available.
final
githubOrg → String?
The GitHub organization or user extracted from repositoryUrl.
final
hashCode → int
The hash code for this object.
no setterinherited
isDiscontinued → bool
Whether the package is marked discontinued on pub.dev.
final
isSdkPackage → bool
Whether this package is provided by the Dart or Flutter SDK.
final
lastCommitAt → DateTime?
The timestamp of the latest known repository push.
final
latestPublishedAt → DateTime?
The publication date of the latest known version.
final
latestVersion → String?
The newest known package version.
final
likes → int?
The number of likes on pub.dev.
final
offline → bool
Whether network enrichment was unavailable.
final
openIssues → int?
The count of open issues reported by GitHub.
final
popularity → double?
The pub.dev popularity score as a percentage.
final
publishedVersions → List<DateTime>
Version publication timestamps used for release-frequency analysis.
final
publisher → String?
The pub.dev publisher identifier, when available.
final
pubPoints → int?
The pub points score.
final
repositoryUrl → String?
The repository or homepage URL associated with the package.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sdkConstraint → String?
The package SDK constraint used for compatibility checks.
final
stars → int?
The repository star count, when available.
final

Methods

merge(PackageHealth other) → PackageHealth
Returns a merged snapshot using non-null values from other.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, Object?>
Serializes this health snapshot for reports.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited