GithubCompareModel class abstract
Model for managing Github branch comparisons.
Githubのブランチ比較を管理するためのモデル。
- Available extensions
- Annotations
-
- @freezed
- @formValue
- @immutable
- @DocumentModelPath.new("organization/:organization_id/repository/:repository_id/compare/:compare_id", adapter: "GithubModelMasamuneAdapter.primary.modelAdapter")
Constructors
-
GithubCompareModel({String? status, @Default.new(0) int aheadBy, @Default.new(0) int behindBy, @Default.new(0) int totalCommits, @jsonParam GithubCommitModel? mergeBaseCommit, @jsonParam GithubCommitModel? baseCommit, @jsonParam @Default.new([]) List<
GithubCommitModel> commits, ModelUri? diffUrl, ModelUri? patchUrl, ModelUri? htmlUrl, ModelUri? permalinkUrl, @Default.new(false) bool fromServer}) -
Model for managing Github branch comparisons.
constfactory
-
GithubCompareModel.fromJson(Map<
String, Object?> json) -
Convert from JSON.
factory
Properties
- aheadBy → int
-
How many commits ahead
no setterinherited
- baseCommit → GithubCommitModel?
-
Base commit
no setterinherited
- behindBy → int
-
How many commits behind
no setterinherited
-
commits
→ List<
GithubCommitModel> -
Commits in the comparison
no setterinherited
-
copyWith
→ $GithubCompareModelCopyWith<
GithubCompareModel> -
Create a copy of GithubCompareModel
with the given fields replaced by the non-null parameter values.
no setterinherited
- diffUrl → ModelUri?
-
URL for diff
no setterinherited
- fromServer → bool
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- htmlUrl → ModelUri?
-
HTML URL
no setterinherited
- mergeBaseCommit → GithubCommitModel?
-
Merge base commit (divergence point)
no setterinherited
- patchUrl → ModelUri?
-
URL for patch
no setterinherited
- permalinkUrl → ModelUri?
-
Permalink URL
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- status → String?
-
Comparison status (behind, ahead, identical, diverged)
no setterinherited
- totalCommits → int
-
Total commits in comparison
no setterinherited
Methods
-
map<
TResult extends Object?> (TResult $default(_GithubCompareModel value)) → TResult -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_GithubCompareModel value)?) → TResult? -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_GithubCompareModel value)?, {required TResult orElse()}) → TResult -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> (TResult $default(String? status, int aheadBy, int behindBy, int totalCommits, GithubCommitModel? mergeBaseCommit, GithubCommitModel? baseCommit, List< GithubCommitModel> commits, ModelUri? diffUrl, ModelUri? patchUrl, ModelUri? htmlUrl, ModelUri? permalinkUrl, bool fromServer)?, {required TResult orElse()}) → TResult -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this GithubCompareModel to a JSON map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> (TResult $default(String? status, int aheadBy, int behindBy, int totalCommits, GithubCommitModel? mergeBaseCommit, GithubCommitModel? baseCommit, List< GithubCommitModel> commits, ModelUri? diffUrl, ModelUri? patchUrl, ModelUri? htmlUrl, ModelUri? permalinkUrl, bool fromServer)) → TResult -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> (TResult? $default(String? status, int aheadBy, int behindBy, int totalCommits, GithubCommitModel? mergeBaseCommit, GithubCommitModel? baseCommit, List< GithubCommitModel> commits, ModelUri? diffUrl, ModelUri? patchUrl, ModelUri? htmlUrl, ModelUri? permalinkUrl, bool fromServer)?) → TResult? -
Available on GithubCompareModel, provided by the GithubCompareModelPatterns extension
A variant ofwhenthat fallback to returningnull
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited