Class Item

java.lang.Object
All Implemented Interfaces:
AsyncInitable, DBusInterface, Initable, Retrievable, Proxy

@Generated("io.github.jwharm.JavaGI") public class Item extends DBusProxy implements AsyncInitable, DBusInterface, Initable, Retrievable
A secret item

SecretItem represents a secret item stored in the Secret Service.

Each item has a value, represented by a Value, which can be retrieved by getSecret() or set by setSecret(org.gnome.secret.Value, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback). The item is only available when the item is not locked.

Items can be locked or unlocked using the Service.lock(org.gnome.glib.List<org.gnome.gio.DBusProxy>, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback) or Service.unlock(org.gnome.glib.List<org.gnome.gio.DBusProxy>, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback) functions. The Secret Service may not be able to unlock individual items, and may unlock an entire collection when a single item is unlocked.

Each item has a set of attributes, which are used to locate the item later. These are not stored or transferred in a secure manner. Each attribute has a string name and a string value. Use Service.search(org.gnome.secret.Schema, org.gnome.glib.HashTable<java.lang.String, java.lang.String>, java.util.Set<org.gnome.secret.SearchFlags>, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback) to search for items based on their attributes, and setAttributes(org.gnome.secret.Schema, org.gnome.glib.HashTable<java.lang.String, java.lang.String>, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback) to change the attributes associated with an item.

Items can be created with create(org.gnome.secret.Collection, org.gnome.secret.Schema, org.gnome.glib.HashTable<java.lang.String, java.lang.String>, java.lang.String, org.gnome.secret.Value, java.util.Set<org.gnome.secret.ItemCreateFlags>, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback) or Service.store(org.gnome.secret.Schema, org.gnome.glib.HashTable<java.lang.String, java.lang.String>, java.lang.String, java.lang.String, org.gnome.secret.Value, org.gnome.gio.Cancellable, org.gnome.gio.AsyncReadyCallback).