DiagnosticsNode constructor

DiagnosticsNode({@required String name, DiagnosticsTreeStyle style, bool showName: true, bool showSeparator: true })

Initializes the object.

The style, showName, and showSeparator arguments must not be null.

Implementation

DiagnosticsNode({
  @required this.name,
  this.style,
  this.showName = true,
  this.showSeparator = true,
}) : assert(showName != null),
     assert(showSeparator != null),
     // A name ending with ':' indicates that the user forgot that the ':' will
     // be automatically added for them when generating descriptions of the
     // property.
     assert(name == null || !name.endsWith(':'), 'Names of diagnostic nodes must not end with colons.');