setAttribute method

Future<void> setAttribute(
  1. String key,
  2. String value
)

Sets a single metadata attribute on this item.

Granular alternative to setMetadata that updates one key without replacing the whole metadata map.

await item.setAttribute('status', 'final');

Implementation

Future<void> setAttribute(String key, String value) async {
  await client.setAttribute(kref.uri, key, value);
}