Item.createSync

Create a new item in the secret service.

If the @flags contains %SECRET_ITEM_CREATE_REPLACE, then the secret service will search for an item matching the @attributes, and update that item instead of creating a new one.

This method may block indefinitely and should not be used in user interface threads. The secret service may prompt the user. secret_service_prompt() will be used to handle any prompts that are required.

class Item
static
createSync
(,,
HashTable attributes
,
string label
,,
SecretItemCreateFlags flags
,
Cancellable cancellable
)

Parameters

collection Collection

a secret collection to create this item in

schema Schema

the schema for the attributes

attributes HashTable

attributes for the new item

label string

label for the new item

value Value

secret value for the new item

flags SecretItemCreateFlags

flags for the creation of the new item

cancellable Cancellable

optional cancellation object

Return Value

Type: Item

the new item, which should be unreferenced with g_object_unref()

Throws

GException on failure.

Meta