write method

Future<void> write (
  1. {@required String key,
  2. @required String value,
  3. IOSOptions iOptions,
  4. AndroidOptions aOptions}
)

Encrypts and saves the key with the given value.

If the key was already in the storage, its associated value is changed. value and key shoudn't be null. iOptions optional iOS options aOptions optional Android options Can throw a PlatformException.

Implementation

Future<void> write({@required String key, @required String value, IOSOptions iOptions, AndroidOptions aOptions}) async =>
    _channel.invokeMethod('write', <String, dynamic>{'key': key, 'value': value, 'options': _selectOptions(iOptions, aOptions)});