callCreateItem method

Future<(DBusObjectPath, DBusObjectPath)> callCreateItem(
  1. Map<String, DBusValue> properties,
  2. List<DBusValue> secret,
  3. bool replace, {
  4. bool noAutoStart = false,
  5. bool allowInteractiveAuthorization = false,
})

Invokes org.freedesktop.Secret.Collection.CreateItem()

Implementation

Future<(DBusObjectPath item, DBusObjectPath prompt)> callCreateItem(
  Map<String, DBusValue> properties,
  List<DBusValue> secret,
  bool replace, {
  bool noAutoStart = false,
  bool allowInteractiveAuthorization = false,
}) async {
  var result = await callMethod(
    'org.freedesktop.Secret.Collection',
    'CreateItem',
    [DBusDict.stringVariant(properties), DBusStruct(secret), DBusBoolean(replace)],
    replySignature: DBusSignature('oo'),
    noAutoStart: noAutoStart,
    allowInteractiveAuthorization: allowInteractiveAuthorization,
  );
  return (result.returnValues[0].asObjectPath(), result.returnValues[1].asObjectPath());
}