GitStatusEntry class Getting started
One entry of the work tree status, as reported by git status.
An entry compares the same path on three sides — HEAD, the index and the
work tree — and reports the index and work tree sides separately, so a
path both staged and modified afterwards is a single entry with an index
state and a work tree state.
Constructors
- GitStatusEntry({required String code, required String path, required GitFileState indexState, required GitFileState workTreeState, String? originalPath})
-
Creates an entry from its status
codeandpath, with the state of each side and the originaloriginalPathof a rename or copy.const
Properties
- code → String
-
Two-letter status code, e.g.
M,Mor??.final - hashCode → int
-
The hash code for this object.
no setteroverride
- indexState → GitFileState
-
State of the path in the index.
final
- isConflicted → bool
-
Whether the path is part of an unresolved merge.
no setter
- isDeleted → bool
-
Whether the path was deleted, in the index or in the work tree.
no setter
- isIndexed → bool
-
Whether the index holds a change for this path — a staged addition,
modification, deletion, rename, copy or type change.
no setter
- isModified → bool
-
Whether the work tree holds an unstaged modification.
no setter
- isRenamed → bool
-
Whether the path was renamed, in the index or in the work tree.
no setter
- isUntracked → bool
-
Whether the path is untracked.
no setter
- originalPath → String?
-
Path this entry was renamed or copied from, or null when it was not.
final
- path → String
-
Path relative to the work tree root, with the original spelling and
encoding.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- workTreeState → GitFileState
-
State of the path in the work tree.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override