start method

  1. @override
Future<void> start()
override

This starts the required action (eg. discovery, or broadcast).

Implementation

@override
Future<void> start() {
  assert(!isStopped, 'You should not try to start a stopped action.');
  assert(isReady, '''$runtimeType should be ready to start in order to call this method.
You must wait until this instance is ready by calling "await $runtimeType.ready".
If you have previously called "$runtimeType.stop()" on this instance, you have to create a new instance of this class.''');
  return _channel.invokeMethod('$_classType.start', toJson());
}