setOffline method

Future<void> setOffline(
  1. bool enabled
)

Sets offline. If offline is true, then the SDK will not upload events to Amplitude servers; however, it will still log events.

Implementation

Future<void> setOffline(bool enabled) async {
  Map<String, dynamic> properties = _baseProperties();
  properties['offline'] = enabled;

  return await _channel.invokeMethod('setOffline', jsonEncode(properties));
}