GanttTask class
A task in the Gantt chart.
- Annotations
Constructors
-
GanttTask({required String id, required String label, required DateTime start, required DateTime end, double progress = 0.0, Color? color, List<
String> ? dependencies, bool isMilestone = false, TaskType type = TaskType.task, String? resourceId, String? resourceName, DateTime? baselineStart, DateTime? baselineEnd, String? parentId, int level = 0, bool isGroup = false, bool isExpanded = true, TaskConstraint constraint = TaskConstraint.asap, DateTime? constraintDate, String? notes, int? priority}) -
const
Properties
- baselineDuration → Duration?
-
Baseline duration (if baseline dates are set).
no setter
- baselineEnd → DateTime?
-
Baseline end date for variance tracking.
final
- baselineStart → DateTime?
-
Baseline start date for variance tracking.
final
- color → Color?
-
Optional custom color.
final
- constraint → TaskConstraint
-
Scheduling constraint type.
final
- constraintDate → DateTime?
-
Date for the constraint (required for some constraint types).
final
-
dependencies
→ List<
String> ? -
IDs of tasks this task depends on (simple FS dependencies).
final
- duration → Duration
-
Duration of the task.
no setter
- end → DateTime
-
End date/time.
final
- endVarianceDays → int?
-
End variance in days (positive = delayed, negative = ahead).
no setter
- hasBaseline → bool
-
Whether this task has baseline dates for comparison.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique identifier for this task.
final
- isExpanded → bool
-
Whether this group is expanded (children visible).
final
- isGroup → bool
-
Whether this is a group/summary task.
final
- isMilestone → bool
-
Whether this is a milestone (single point in time).
final
- isMilestoneType → bool
-
Whether this task is effectively a milestone.
no setter
- isSummaryType → bool
-
Whether this task is a summary/group task.
no setter
- label → String
-
Display label for this task.
final
- level → int
-
Hierarchy level (0 = root, 1 = child of root, etc.).
final
- notes → String?
-
Optional notes/description.
final
- parentId → String?
-
Parent task ID for hierarchy (WBS structure).
final
- priority → int?
-
Task priority (higher = more important).
final
- progress → double
-
Progress (0.0 to 1.0).
final
- resourceId → String?
-
Resource ID assigned to this task.
final
- resourceName → String?
-
Resource name for display.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- start → DateTime
-
Start date/time.
final
- startVarianceDays → int?
-
Start variance in days (positive = delayed, negative = ahead).
no setter
- type → TaskType
-
The type of task (task, milestone, or summary).
final
Methods
-
copyWith(
{String? id, String? label, DateTime? start, DateTime? end, double? progress, Color? color, List< String> ? dependencies, bool? isMilestone, TaskType? type, String? resourceId, String? resourceName, DateTime? baselineStart, DateTime? baselineEnd, String? parentId, int? level, bool? isGroup, bool? isExpanded, TaskConstraint? constraint, DateTime? constraintDate, String? notes, int? priority}) → GanttTask - Creates a copy with updated values.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited