W3cubDocs

/Dart 2

start method

void start (String name, { Map arguments })

Start a synchronous operation within this task named name. Optionally takes a Map of arguments.

Implementation

void start(String name, {Map arguments}) {
  if (_isProduct) {
    return;
  }
  if (name is! String) {
    throw new ArgumentError.value(name, 'name', 'Must be a String');
  }
  var block = new _AsyncBlock._(name, _taskId);
  if (arguments is Map) {
    block._arguments = arguments;
  }
  _stack.add(block);
  block._start();
}

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/2.0.0/dart-developer/TimelineTask/start.html