Table of Contents

Class Permission

Namespace
Gio
Assembly
Gio-2.0.dll
public class Permission : Object, IDisposable, NativeObject, GTypeProvider, InstanceFactory
Inheritance
Permission
Implements
Derived
Inherited Members

Constructors

Permission(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 Permission(params ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

Permission(CreationData)

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

Parameters

data CreationData

Permission(PermissionHandle)

protected Permission(PermissionHandle handle)

Parameters

handle PermissionHandle

Fields

AllowedPropertyDefinition

public static readonly Property<bool, Permission> AllowedPropertyDefinition

Field Value

Property<bool, Permission>

CanAcquirePropertyDefinition

public static readonly Property<bool, Permission> CanAcquirePropertyDefinition

Field Value

Property<bool, Permission>

CanReleasePropertyDefinition

public static readonly Property<bool, Permission> CanReleasePropertyDefinition

Field Value

Property<bool, Permission>

Properties

Allowed

public bool Allowed { get; }

Property Value

bool

CanAcquire

public bool CanAcquire { get; }

Property Value

bool

CanRelease

public bool CanRelease { get; }

Property Value

bool

Methods

Acquire(Cancellable?)

[Version("2.26")]
public bool Acquire(Cancellable? cancellable)

Parameters

cancellable Cancellable

Returns

bool

AcquireFinish(AsyncResult)

[Version("2.26")]
public bool AcquireFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool

GetAllowed()

[Version("2.26")]
public bool GetAllowed()

Returns

bool

GetCanAcquire()

[Version("2.26")]
public bool GetCanAcquire()

Returns

bool

GetCanRelease()

[Version("2.26")]
public bool GetCanRelease()

Returns

bool

GetGType()

public static Type GetGType()

Returns

Type

ImplUpdate(bool, bool, bool)

[Version("2.26")]
public void ImplUpdate(bool allowed, bool canAcquire, bool canRelease)

Parameters

allowed bool
canAcquire bool
canRelease bool

NewFromPointer(nint, bool)

Creates a new managed Permission instance for a given pointer.

public static Permission NewFromPointer(nint ptr, bool ownsHandle)

Parameters

ptr nint
ownsHandle bool

Returns

Permission

NewWithProperties(ConstructArgument[])

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

public static Permission NewWithProperties(ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

The properties to set.

Returns

Permission

Release(Cancellable?)

[Version("2.26")]
public bool Release(Cancellable? cancellable)

Parameters

cancellable Cancellable

Returns

bool

ReleaseFinish(AsyncResult)

[Version("2.26")]
public bool ReleaseFinish(AsyncResult result)

Parameters

result AsyncResult

Returns

bool