HelpInitialiserList class

Initialiser List (:)

Used to:

  • Initialise list of expressions that can:
    • access constructor parameters
    • assign to instance fields (even final instance fields!)
  • Call other constructors
    • e.g., superclass
  • Assert constructor parameters

NOTE:

  • Initialiser list is executed before constructor body
  • Use this.instanceVariable when there is a name conflict, else omit

Constructors

HelpInitialiserList.new()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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