Table of Contents

Class Service

Namespace
Secret
Assembly
Secret-1.dll
public class Service : DBusProxy, AsyncInitable, DBusInterface, Initable, Backend, NativeObject, IDisposable, GTypeProvider, InstanceFactory
Inheritance
Service
Implements
Inherited Members

Constructors

Service(params ConstructArgument[])

[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public Service(params ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

Service(CreationData)

[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected Service(CreationData data)

Parameters

data CreationData

Service(ServiceHandle)

protected Service(ServiceHandle handle)

Parameters

handle ServiceHandle

Properties

Flags

public ServiceFlags Flags { get; }

Property Value

ServiceFlags

Methods

ClearFinish(AsyncResult)

public bool ClearFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

ClearSync(Schema?, HashTable, Cancellable?)

public bool ClearSync(Schema? schema, HashTable attributes, Cancellable? cancellable)

Parameters

schema Schema
attributes HashTable
cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

CreateCollectionDbusPathFinish(AsyncResult)

public string CreateCollectionDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

string

Exceptions

GException

Throws a GException in case of an error.

CreateCollectionDbusPathSync(HashTable, string?, CollectionCreateFlags, Cancellable?)

public string CreateCollectionDbusPathSync(HashTable properties, string? alias, CollectionCreateFlags flags, Cancellable? cancellable)

Parameters

properties HashTable
alias string
flags CollectionCreateFlags
cancellable Cancellable

Returns

string

Exceptions

GException

Throws a GException in case of an error.

CreateItemDbusPathFinish(AsyncResult)

public string CreateItemDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

string

Exceptions

GException

Throws a GException in case of an error.

CreateItemDbusPathSync(string, HashTable, Value, ItemCreateFlags, Cancellable?)

public string CreateItemDbusPathSync(string collectionPath, HashTable properties, Value value, ItemCreateFlags flags, Cancellable? cancellable)

Parameters

collectionPath string
properties HashTable
value Value
flags ItemCreateFlags
cancellable Cancellable

Returns

string

Exceptions

GException

Throws a GException in case of an error.

DecodeDbusSecret(Variant)

public Value DecodeDbusSecret(Variant value)

Parameters

value Variant

Returns

Value

DeleteItemDbusPathFinish(AsyncResult)

public bool DeleteItemDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

DeleteItemDbusPathSync(string, Cancellable?)

public bool DeleteItemDbusPathSync(string itemPath, Cancellable? cancellable)

Parameters

itemPath string
cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

Disconnect()

public static void Disconnect()

DupObject()

[Version("2.32")]
public DBusObject? DupObject()

Returns

DBusObject

EncodeDbusSecret(Value)

public Variant EncodeDbusSecret(Value value)

Parameters

value Value

Returns

Variant

EnsureSessionFinish(AsyncResult)

public bool EnsureSessionFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

EnsureSessionSync(Cancellable?)

public bool EnsureSessionSync(Cancellable? cancellable)

Parameters

cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

GetCollectionGtype()

public Type GetCollectionGtype()

Returns

Type

GetCollections()

public List? GetCollections()

Returns

List

GetFinish(AsyncResult)

public static Service GetFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Service

Exceptions

GException

Throws a GException in case of an error.

GetFlags()

public ServiceFlags GetFlags()

Returns

ServiceFlags

GetGType()

public static Type GetGType()

Returns

Type

GetItemGtype()

public Type GetItemGtype()

Returns

Type

GetObject()

[Version("2.30")]
public DBusObject? GetObject()

Returns

DBusObject

GetSecretForDbusPathFinish(AsyncResult)

public Value? GetSecretForDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Value

Exceptions

GException

Throws a GException in case of an error.

GetSecretForDbusPathSync(string, Cancellable?)

public Value? GetSecretForDbusPathSync(string itemPath, Cancellable? cancellable)

Parameters

itemPath string
cancellable Cancellable

Returns

Value

Exceptions

GException

Throws a GException in case of an error.

GetSecretsForDbusPathsFinish(AsyncResult)

public HashTable GetSecretsForDbusPathsFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

HashTable

Exceptions

GException

Throws a GException in case of an error.

GetSecretsForDbusPathsSync(string, Cancellable?)

public HashTable GetSecretsForDbusPathsSync(string itemPaths, Cancellable? cancellable)

Parameters

itemPaths string
cancellable Cancellable

Returns

HashTable

Exceptions

GException

Throws a GException in case of an error.

GetSessionAlgorithms()

public string? GetSessionAlgorithms()

Returns

string

GetSessionDbusPath()

public string? GetSessionDbusPath()

Returns

string

GetSync(ServiceFlags, Cancellable?)

public static Service GetSync(ServiceFlags flags, Cancellable? cancellable)

Parameters

flags ServiceFlags
cancellable Cancellable

Returns

Service

Exceptions

GException

Throws a GException in case of an error.

Init(Cancellable?)

[Version("2.22")]
public bool Init(Cancellable? cancellable)

Parameters

cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

InitFinish(AsyncResult)

[Version("2.22")]
public bool InitFinish(AsyncResult res)

Parameters

res AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

LoadCollectionsFinish(AsyncResult)

public bool LoadCollectionsFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

LoadCollectionsSync(Cancellable?)

public bool LoadCollectionsSync(Cancellable? cancellable)

Parameters

cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

LockDbusPathsFinish(AsyncResult, out string[]?)

public int LockDbusPathsFinish(AsyncResult result, out string[]? locked)

Parameters

result AsyncResult
locked string[]

Returns

int

Exceptions

GException

Throws a GException in case of an error.

LockDbusPathsSync(string[], Cancellable?, out string[]?)

public int LockDbusPathsSync(string[] paths, Cancellable? cancellable, out string[]? locked)

Parameters

paths string[]
cancellable Cancellable
locked string[]

Returns

int

Exceptions

GException

Throws a GException in case of an error.

LookupFinish(AsyncResult)

public Value LookupFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Value

Exceptions

GException

Throws a GException in case of an error.

LookupSync(Schema?, HashTable, Cancellable?)

public Value LookupSync(Schema? schema, HashTable attributes, Cancellable? cancellable)

Parameters

schema Schema
attributes HashTable
cancellable Cancellable

Returns

Value

Exceptions

GException

Throws a GException in case of an error.

NewFromPointer(nint, bool)

Creates a new managed Service instance for a given pointer.

public static Service NewFromPointer(nint ptr, bool ownsHandle)

Parameters

ptr nint
ownsHandle bool

Returns

Service

NewWithProperties(ConstructArgument[])

Creates a new Service and sets the properties specified by the construct arguments.

public static Service NewWithProperties(ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

The properties to set.

Returns

Service

OpenFinish(AsyncResult)

public static Service OpenFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Service

Exceptions

GException

Throws a GException in case of an error.

OpenSync(Type, string?, ServiceFlags, Cancellable?)

public static Service OpenSync(Type serviceGtype, string? serviceBusName, ServiceFlags flags, Cancellable? cancellable)

Parameters

serviceGtype Type
serviceBusName string
flags ServiceFlags
cancellable Cancellable

Returns

Service

Exceptions

GException

Throws a GException in case of an error.

PromptAtDbusPathFinish(AsyncResult)

public Variant? PromptAtDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Variant

Exceptions

GException

Throws a GException in case of an error.

PromptAtDbusPathSync(string, Cancellable?, VariantType?)

public Variant? PromptAtDbusPathSync(string promptPath, Cancellable? cancellable, VariantType? returnType)

Parameters

promptPath string
cancellable Cancellable
returnType VariantType

Returns

Variant

Exceptions

GException

Throws a GException in case of an error.

PromptFinish(AsyncResult)

public Variant PromptFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

Variant

Exceptions

GException

Throws a GException in case of an error.

PromptSync(Prompt, Cancellable?, VariantType)

public Variant PromptSync(Prompt prompt, Cancellable? cancellable, VariantType returnType)

Parameters

prompt Prompt
cancellable Cancellable
returnType VariantType

Returns

Variant

Exceptions

GException

Throws a GException in case of an error.

ReadAliasDbusPathFinish(AsyncResult)

public string? ReadAliasDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

string

Exceptions

GException

Throws a GException in case of an error.

ReadAliasDbusPathSync(string, Cancellable?)

public string? ReadAliasDbusPathSync(string alias, Cancellable? cancellable)

Parameters

alias string
cancellable Cancellable

Returns

string

Exceptions

GException

Throws a GException in case of an error.

SearchFinish(AsyncResult)

public List SearchFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

List

Exceptions

GException

Throws a GException in case of an error.

SearchForDbusPathsFinish(AsyncResult, out string[]?, out string[]?)

public bool SearchForDbusPathsFinish(AsyncResult result, out string[]? unlocked, out string[]? locked)

Parameters

result AsyncResult
unlocked string[]
locked string[]

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SearchForDbusPathsSync(Schema?, HashTable, Cancellable?, out string[]?, out string[]?)

public bool SearchForDbusPathsSync(Schema? schema, HashTable attributes, Cancellable? cancellable, out string[]? unlocked, out string[]? locked)

Parameters

schema Schema
attributes HashTable
cancellable Cancellable
unlocked string[]
locked string[]

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SearchSync(Schema?, HashTable, SearchFlags, Cancellable?)

public List SearchSync(Schema? schema, HashTable attributes, SearchFlags flags, Cancellable? cancellable)

Parameters

schema Schema
attributes HashTable
flags SearchFlags
cancellable Cancellable

Returns

List

Exceptions

GException

Throws a GException in case of an error.

SetAliasFinish(AsyncResult)

public bool SetAliasFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SetAliasSync(string, Collection?, Cancellable?)

public bool SetAliasSync(string alias, Collection? collection, Cancellable? cancellable)

Parameters

alias string
collection Collection
cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SetAliasToDbusPathFinish(AsyncResult)

public bool SetAliasToDbusPathFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SetAliasToDbusPathSync(string, string?, Cancellable?)

public bool SetAliasToDbusPathSync(string alias, string? collectionPath, Cancellable? cancellable)

Parameters

alias string
collectionPath string
cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

SetObject(DBusObject?)

[Version("2.30")]
public void SetObject(DBusObject? @object)

Parameters

object DBusObject

StoreFinish(AsyncResult)

public bool StoreFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

StoreSync(Schema?, HashTable, string?, string, Value, Cancellable?)

public bool StoreSync(Schema? schema, HashTable attributes, string? collection, string label, Value value, Cancellable? cancellable)

Parameters

schema Schema
attributes HashTable
collection string
label string
value Value
cancellable Cancellable

Returns

bool

Exceptions

GException

Throws a GException in case of an error.

UnlockDbusPathsFinish(AsyncResult, out string[]?)

public int UnlockDbusPathsFinish(AsyncResult result, out string[]? unlocked)

Parameters

result AsyncResult
unlocked string[]

Returns

int

Exceptions

GException

Throws a GException in case of an error.

UnlockDbusPathsSync(string[], Cancellable?, out string[]?)

public int UnlockDbusPathsSync(string[] paths, Cancellable? cancellable, out string[]? unlocked)

Parameters

paths string[]
cancellable Cancellable
unlocked string[]

Returns

int

Exceptions

GException

Throws a GException in case of an error.