///
///
///
///
/**
* Type Definitions for Gjs (https://gjs.guide/)
*
* These type definitions are automatically generated, do not edit them by hand.
* If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
*
* The based EJS template file is used for the generated .d.ts file of each GIR module like Gtk-4.0, GObject-2.0, ...
*/
declare module 'gi://UDisks?version=2.0' {
// Module dependencies
import type Gio from 'gi://Gio?version=2.0';
import type GObject from 'gi://GObject?version=2.0';
import type GLib from 'gi://GLib?version=2.0';
import type GModule from 'gi://GModule?version=2.0';
export namespace UDisks {
/**
* UDisks-2.0
*/
/**
* Error codes for the #UDISKS_ERROR error domain and the
* corresponding D-Bus error names.
*/
class Error extends GLib.Error {
static $gtype: GObject.GType;
// Static fields
/**
* The operation failed.
*/
static FAILED: number;
/**
* The operation was cancelled.
*/
static CANCELLED: number;
/**
* The operation has already been cancelled.
*/
static ALREADY_CANCELLED: number;
/**
* Not authorized to perform the requested operation.
*/
static NOT_AUTHORIZED: number;
/**
* Like %UDISKS_ERROR_NOT_AUTHORIZED but authorization can be obtained through e.g. authentication.
*/
static NOT_AUTHORIZED_CAN_OBTAIN: number;
/**
* Like %UDISKS_ERROR_NOT_AUTHORIZED but an authentication was shown and the user dismissed it.
*/
static NOT_AUTHORIZED_DISMISSED: number;
/**
* The device is already mounted.
*/
static ALREADY_MOUNTED: number;
/**
* The device is not mounted.
*/
static NOT_MOUNTED: number;
/**
* Not permitted to use the requested option.
*/
static OPTION_NOT_PERMITTED: number;
/**
* The device is mounted by another user.
*/
static MOUNTED_BY_OTHER_USER: number;
/**
* The device is already unmounting.
*/
static ALREADY_UNMOUNTING: number;
/**
* The operation is not supported due to missing driver/tool support.
*/
static NOT_SUPPORTED: number;
/**
* The operation timed out.
*/
static TIMED_OUT: number;
/**
* The operation would wake up a disk that is in a deep-sleep state.
*/
static WOULD_WAKEUP: number;
/**
* Attempting to unmount a device that is busy.
*/
static DEVICE_BUSY: number;
static ISCSI_DAEMON_TRANSPORT_FAILED: number;
static ISCSI_HOST_NOT_FOUND: number;
static ISCSI_IDMB: number;
static ISCSI_LOGIN_FAILED: number;
static ISCSI_LOGIN_AUTH_FAILED: number;
static ISCSI_LOGIN_FATAL: number;
static ISCSI_LOGOUT_FAILED: number;
static ISCSI_NO_FIRMWARE: number;
static ISCSI_NO_OBJECTS_FOUND: number;
static ISCSI_NOT_CONNECTED: number;
static ISCSI_TRANSPORT_FAILED: number;
static ISCSI_UNKNOWN_DISCOVERY_TYPE: number;
// Constructors
constructor(options: { message: string; code: number });
_init(...args: any[]): void;
// Static methods
static quark(): GLib.Quark;
}
const ERROR_NUM_ENTRIES: number;
/**
* The major version of the libudisks2 header files.
*/
const MAJOR_VERSION: number;
/**
* The micro version of the libudisks2 header files.
*/
const MICRO_VERSION: number;
/**
* The minor version of the libudisks2 header files.
*/
const MINOR_VERSION: number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Block D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function block_interface_info(): Gio.DBusInterfaceInfo;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Block.LVM2 D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function block_lvm2_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksBlockLVM2 interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function block_lvm2_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Overrides all #GObject properties in the #UDisksBlock interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function block_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Drive.Ata D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function drive_ata_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksDriveAta interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function drive_ata_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Drive D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function drive_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksDrive interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function drive_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Encrypted D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function encrypted_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksEncrypted interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function encrypted_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
function error_quark(): GLib.Quark;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Filesystem.BTRFS D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function filesystem_btrfs_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksFilesystemBTRFS interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function filesystem_btrfs_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Filesystem D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function filesystem_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksFilesystem interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function filesystem_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Job D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function job_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksJob interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function job_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.LogicalVolume D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function logical_volume_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksLogicalVolume interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function logical_volume_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Loop D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function loop_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksLoop interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function loop_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Manager.BTRFS D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function manager_btrfs_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksManagerBTRFS interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function manager_btrfs_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Manager D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function manager_interface_info(): Gio.DBusInterfaceInfo;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Manager.LVM2 D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function manager_lvm2_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksManagerLVM2 interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function manager_lvm2_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Manager.NVMe D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function manager_nvme_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksManagerNVMe interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function manager_nvme_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Overrides all #GObject properties in the #UDisksManager interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function manager_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.MDRaid D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function mdraid_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksMDRaid interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function mdraid_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.NVMe.Controller D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function nvme_controller_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksNVMeController interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function nvme_controller_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.NVMe.Fabrics D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function nvme_fabrics_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksNVMeFabrics interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function nvme_fabrics_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.NVMe.Namespace D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function nvme_namespace_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksNVMeNamespace interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function nvme_namespace_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Partition D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function partition_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksPartition interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function partition_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.PartitionTable D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function partition_table_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksPartitionTable interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function partition_table_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.PhysicalVolume D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function physical_volume_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksPhysicalVolume interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function physical_volume_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.Swapspace D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function swapspace_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksSwapspace interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function swapspace_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.VDOVolume D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function vdo_volume_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksVDOVolume interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function vdo_volume_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Gets a machine-readable description of the org.freedesktop.UDisks2.VolumeGroup D-Bus interface.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
function volume_group_interface_info(): Gio.DBusInterfaceInfo;
/**
* Overrides all #GObject properties in the #UDisksVolumeGroup interface for a concrete class.
* The properties are overridden in the order they are defined.
* @param klass The class structure for a #GObject derived class.
* @param property_id_begin The property id to assign to the first overridden property.
* @returns The last property id.
*/
function volume_group_override_properties(klass: typeof GObject.Object, property_id_begin: number): number;
/**
* Flags describing a partition type.
*/
/**
* Flags describing a partition type.
*/
export namespace PartitionTypeInfoFlags {
export const $gtype: GObject.GType;
}
enum PartitionTypeInfoFlags {
/**
* No flags set.
*/
NONE,
/**
* Partition type is used for swap.
*/
SWAP,
/**
* Partition type is used for RAID/LVM or similar.
*/
RAID,
/**
* Partition type indicates the partition is hidden (e.g. 'dos' type 0x1b "Hidden W95 FAT32"). Note that this is not the same as user-toggleable attributes/flags for a partition.
*/
HIDDEN,
/**
* Partition type can only be used when creating a partition and e.g. should not be selectable in a "change partition type" user interface (e.g. 'dos' type 0x05, 0x0f and 0x85 for extended partitions).
*/
CREATE_ONLY,
/**
* Partition type indicates the partition is part of the system / bootloader (e.g. 'dos' types 0xee, 0xff, 'gpt' types for 'EFI System partition' and 'BIOS Boot partition').
*/
SYSTEM,
}
namespace BlockLVM2Proxy {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusProxy.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Gio.Initable.ConstructorProps,
BlockLVM2.ConstructorProps {}
}
/**
* The #UDisksBlockLVM2Proxy structure contains only private data and should only be accessed using the provided API.
*/
class BlockLVM2Proxy
extends Gio.DBusProxy
implements Gio.AsyncInitable, Gio.DBusInterface, Gio.Initable, BlockLVM2
{
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): BlockLVM2Proxy;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_bus_finish(res: Gio.AsyncResult): BlockLVM2Proxy;
static new_for_bus_sync(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
): BlockLVM2Proxy;
// Conflicted with Gio.DBusProxy.new_for_bus_sync
static new_for_bus_sync(...args: never[]): any;
static new_sync(
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
): BlockLVM2Proxy;
// Conflicted with Gio.DBusProxy.new_sync
static new_sync(...args: never[]): any;
// Static methods
/**
* Asynchronously creates a proxy for the D-Bus interface org.freedesktop.UDisks2.Block.LVM2. See g_dbus_proxy_new() for more details.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_lvm2_proxy_new_finish() to get the result of the operation.
*
* See udisks_block_lvm2_proxy_new_sync() for the synchronous, blocking version of this constructor.
* @param connection A #GDBusConnection.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static ['new'](
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new
static ['new'](...args: never[]): any;
/**
* Like udisks_block_lvm2_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_lvm2_proxy_new_for_bus_finish() to get the result of the operation.
*
* See udisks_block_lvm2_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
* @param bus_type A #GBusType.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique).
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static new_for_bus(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new_for_bus
static new_for_bus(...args: never[]): any;
// Inherited properties
/**
* Represents the D-Bus property "LogicalVolume".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get logical_volume(): string;
set logical_volume(val: string);
/**
* Represents the D-Bus property "LogicalVolume".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get logicalVolume(): string;
set logicalVolume(val: string);
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): BlockLVM2Proxy;
// Conflicted with Gio.DBusProxy.new_finish
new_finish(...args: never[]): any;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace BlockLVM2Skeleton {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusInterfaceSkeleton.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
BlockLVM2.ConstructorProps {}
}
/**
* The #UDisksBlockLVM2Skeleton structure contains only private data and should only be accessed using the provided API.
*/
class BlockLVM2Skeleton extends Gio.DBusInterfaceSkeleton implements Gio.DBusInterface, BlockLVM2 {
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): BlockLVM2Skeleton;
// Inherited properties
/**
* Represents the D-Bus property "LogicalVolume".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get logical_volume(): string;
set logical_volume(val: string);
/**
* Represents the D-Bus property "LogicalVolume".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get logicalVolume(): string;
set logicalVolume(val: string);
// Inherited methods
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace BlockProxy {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusProxy.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Gio.Initable.ConstructorProps,
Block.ConstructorProps {}
}
/**
* The #UDisksBlockProxy structure contains only private data and should only be accessed using the provided API.
*/
class BlockProxy
extends Gio.DBusProxy
implements Gio.AsyncInitable, Gio.DBusInterface, Gio.Initable, Block
{
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): BlockProxy;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_bus_finish(res: Gio.AsyncResult): BlockProxy;
static new_for_bus_sync(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
): BlockProxy;
// Conflicted with Gio.DBusProxy.new_for_bus_sync
static new_for_bus_sync(...args: never[]): any;
static new_sync(
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
): BlockProxy;
// Conflicted with Gio.DBusProxy.new_sync
static new_sync(...args: never[]): any;
// Static methods
/**
* Asynchronously creates a proxy for the D-Bus interface org.freedesktop.UDisks2.Block. See g_dbus_proxy_new() for more details.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_proxy_new_finish() to get the result of the operation.
*
* See udisks_block_proxy_new_sync() for the synchronous, blocking version of this constructor.
* @param connection A #GDBusConnection.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static ['new'](
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new
static ['new'](...args: never[]): any;
/**
* Like udisks_block_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_proxy_new_for_bus_finish() to get the result of the operation.
*
* See udisks_block_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
* @param bus_type A #GBusType.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique).
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static new_for_bus(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new_for_bus
static new_for_bus(...args: never[]): any;
// Inherited properties
/**
* Represents the D-Bus property "Configuration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get configuration(): GLib.Variant;
set configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "CryptoBackingDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get crypto_backing_device(): string;
set crypto_backing_device(val: string);
/**
* Represents the D-Bus property "CryptoBackingDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cryptoBackingDevice(): string;
set cryptoBackingDevice(val: string);
/**
* Represents the D-Bus property "Device".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get device(): string;
set device(val: string);
/**
* Represents the D-Bus property "DeviceNumber".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get device_number(): number;
set device_number(val: number);
/**
* Represents the D-Bus property "DeviceNumber".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get deviceNumber(): number;
set deviceNumber(val: number);
/**
* Represents the D-Bus property "Drive".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get drive(): string;
set drive(val: string);
/**
* Represents the D-Bus property "HintAuto".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_auto(): boolean;
set hint_auto(val: boolean);
/**
* Represents the D-Bus property "HintAuto".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintAuto(): boolean;
set hintAuto(val: boolean);
/**
* Represents the D-Bus property "HintIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_icon_name(): string;
set hint_icon_name(val: string);
/**
* Represents the D-Bus property "HintIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintIconName(): string;
set hintIconName(val: string);
/**
* Represents the D-Bus property "HintIgnore".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_ignore(): boolean;
set hint_ignore(val: boolean);
/**
* Represents the D-Bus property "HintIgnore".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintIgnore(): boolean;
set hintIgnore(val: boolean);
/**
* Represents the D-Bus property "HintName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_name(): string;
set hint_name(val: string);
/**
* Represents the D-Bus property "HintName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintName(): string;
set hintName(val: string);
/**
* Represents the D-Bus property "HintPartitionable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_partitionable(): boolean;
set hint_partitionable(val: boolean);
/**
* Represents the D-Bus property "HintPartitionable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintPartitionable(): boolean;
set hintPartitionable(val: boolean);
/**
* Represents the D-Bus property "HintSymbolicIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_symbolic_icon_name(): string;
set hint_symbolic_icon_name(val: string);
/**
* Represents the D-Bus property "HintSymbolicIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintSymbolicIconName(): string;
set hintSymbolicIconName(val: string);
/**
* Represents the D-Bus property "HintSystem".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_system(): boolean;
set hint_system(val: boolean);
/**
* Represents the D-Bus property "HintSystem".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintSystem(): boolean;
set hintSystem(val: boolean);
/**
* Represents the D-Bus property "Id".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id(): string;
set id(val: string);
/**
* Represents the D-Bus property "IdLabel".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_label(): string;
set id_label(val: string);
/**
* Represents the D-Bus property "IdLabel".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idLabel(): string;
set idLabel(val: string);
/**
* Represents the D-Bus property "IdType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_type(): string;
set id_type(val: string);
/**
* Represents the D-Bus property "IdType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idType(): string;
set idType(val: string);
/**
* Represents the D-Bus property "IdUsage".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_usage(): string;
set id_usage(val: string);
/**
* Represents the D-Bus property "IdUsage".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idUsage(): string;
set idUsage(val: string);
/**
* Represents the D-Bus property "IdUUID".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_uuid(): string;
set id_uuid(val: string);
/**
* Represents the D-Bus property "IdUUID".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idUuid(): string;
set idUuid(val: string);
/**
* Represents the D-Bus property "IdVersion".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_version(): string;
set id_version(val: string);
/**
* Represents the D-Bus property "IdVersion".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idVersion(): string;
set idVersion(val: string);
/**
* Represents the D-Bus property "MDRaid".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraid(): string;
set mdraid(val: string);
/**
* Represents the D-Bus property "MDRaidMember".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraid_member(): string;
set mdraid_member(val: string);
/**
* Represents the D-Bus property "MDRaidMember".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraidMember(): string;
set mdraidMember(val: string);
/**
* Represents the D-Bus property "PreferredDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get preferred_device(): string;
set preferred_device(val: string);
/**
* Represents the D-Bus property "PreferredDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get preferredDevice(): string;
set preferredDevice(val: string);
/**
* Represents the D-Bus property "ReadOnly".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_only(): boolean;
set read_only(val: boolean);
/**
* Represents the D-Bus property "ReadOnly".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readOnly(): boolean;
set readOnly(val: boolean);
/**
* Represents the D-Bus property "Size".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get size(): number;
set size(val: number);
/**
* Represents the D-Bus property "Symlinks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get symlinks(): string[];
set symlinks(val: string[]);
/**
* Represents the D-Bus property "UserspaceMountOptions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get userspace_mount_options(): string[];
set userspace_mount_options(val: string[]);
/**
* Represents the D-Bus property "UserspaceMountOptions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get userspaceMountOptions(): string[];
set userspaceMountOptions(val: string[]);
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): BlockProxy;
// Conflicted with Gio.DBusProxy.new_finish
new_finish(...args: never[]): any;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_add_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_add_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_add_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the AddConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_add_configuration_item() for the asynchronous version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_add_configuration_item_sync(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_format().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_format().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_format_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Format() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_format() for the asynchronous version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_format_sync(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_get_secret_configuration().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_get_secret_configuration().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_get_secret_configuration_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null];
/**
* Synchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_get_secret_configuration() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_get_secret_configuration_sync(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null];
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_device().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_device().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_device_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenDevice() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_device() for the asynchronous version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_device_sync(
arg_mode: string,
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_backup().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_backup().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_backup_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForBackup() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_backup() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_backup_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_benchmark().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_benchmark().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_benchmark_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForBenchmark() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_benchmark() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_benchmark_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_restore().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_restore().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_restore_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForRestore() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_restore() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_restore_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_remove_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_remove_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_remove_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_remove_configuration_item() for the asynchronous version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_remove_configuration_item_sync(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_rescan(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_rescan(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_rescan(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_rescan().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_rescan().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_rescan_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Rescan() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_rescan() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_rescan_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_update_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_update_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_update_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_update_configuration_item() for the asynchronous version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_update_configuration_item_sync(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the AddConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_add_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Format() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_format(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the GetSecretConfiguration() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param configuration Parameter to return.
*/
complete_get_secret_configuration(invocation: Gio.DBusMethodInvocation, configuration: GLib.Variant): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenDevice() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_device(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForBackup() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_backup(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForBenchmark() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_benchmark(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForRestore() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_restore(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the RemoveConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_remove_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Rescan() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_rescan(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the UpdateConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_update_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksBlock::handle-add-configuration-item signal.
* @param invocation
* @param arg_item
* @param arg_options
*/
vfunc_handle_add_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-format signal.
* @param invocation
* @param arg_type
* @param arg_options
*/
vfunc_handle_format(
invocation: Gio.DBusMethodInvocation,
arg_type: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-get-secret-configuration signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_get_secret_configuration(
invocation: Gio.DBusMethodInvocation,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-device signal.
* @param invocation
* @param fd_list
* @param arg_mode
* @param arg_options
*/
vfunc_handle_open_device(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_mode: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-backup signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_backup(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-benchmark signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_benchmark(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-restore signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_restore(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-remove-configuration-item signal.
* @param invocation
* @param arg_item
* @param arg_options
*/
vfunc_handle_remove_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-rescan signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_rescan(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksBlock::handle-update-configuration-item signal.
* @param invocation
* @param arg_old_item
* @param arg_new_item
* @param arg_options
*/
vfunc_handle_update_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace BlockSkeleton {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusInterfaceSkeleton.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Block.ConstructorProps {}
}
/**
* The #UDisksBlockSkeleton structure contains only private data and should only be accessed using the provided API.
*/
class BlockSkeleton extends Gio.DBusInterfaceSkeleton implements Gio.DBusInterface, Block {
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): BlockSkeleton;
// Inherited properties
/**
* Represents the D-Bus property "Configuration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get configuration(): GLib.Variant;
set configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "CryptoBackingDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get crypto_backing_device(): string;
set crypto_backing_device(val: string);
/**
* Represents the D-Bus property "CryptoBackingDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cryptoBackingDevice(): string;
set cryptoBackingDevice(val: string);
/**
* Represents the D-Bus property "Device".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get device(): string;
set device(val: string);
/**
* Represents the D-Bus property "DeviceNumber".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get device_number(): number;
set device_number(val: number);
/**
* Represents the D-Bus property "DeviceNumber".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get deviceNumber(): number;
set deviceNumber(val: number);
/**
* Represents the D-Bus property "Drive".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get drive(): string;
set drive(val: string);
/**
* Represents the D-Bus property "HintAuto".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_auto(): boolean;
set hint_auto(val: boolean);
/**
* Represents the D-Bus property "HintAuto".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintAuto(): boolean;
set hintAuto(val: boolean);
/**
* Represents the D-Bus property "HintIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_icon_name(): string;
set hint_icon_name(val: string);
/**
* Represents the D-Bus property "HintIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintIconName(): string;
set hintIconName(val: string);
/**
* Represents the D-Bus property "HintIgnore".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_ignore(): boolean;
set hint_ignore(val: boolean);
/**
* Represents the D-Bus property "HintIgnore".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintIgnore(): boolean;
set hintIgnore(val: boolean);
/**
* Represents the D-Bus property "HintName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_name(): string;
set hint_name(val: string);
/**
* Represents the D-Bus property "HintName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintName(): string;
set hintName(val: string);
/**
* Represents the D-Bus property "HintPartitionable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_partitionable(): boolean;
set hint_partitionable(val: boolean);
/**
* Represents the D-Bus property "HintPartitionable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintPartitionable(): boolean;
set hintPartitionable(val: boolean);
/**
* Represents the D-Bus property "HintSymbolicIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_symbolic_icon_name(): string;
set hint_symbolic_icon_name(val: string);
/**
* Represents the D-Bus property "HintSymbolicIconName".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintSymbolicIconName(): string;
set hintSymbolicIconName(val: string);
/**
* Represents the D-Bus property "HintSystem".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_system(): boolean;
set hint_system(val: boolean);
/**
* Represents the D-Bus property "HintSystem".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintSystem(): boolean;
set hintSystem(val: boolean);
/**
* Represents the D-Bus property "Id".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id(): string;
set id(val: string);
/**
* Represents the D-Bus property "IdLabel".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_label(): string;
set id_label(val: string);
/**
* Represents the D-Bus property "IdLabel".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idLabel(): string;
set idLabel(val: string);
/**
* Represents the D-Bus property "IdType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_type(): string;
set id_type(val: string);
/**
* Represents the D-Bus property "IdType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idType(): string;
set idType(val: string);
/**
* Represents the D-Bus property "IdUsage".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_usage(): string;
set id_usage(val: string);
/**
* Represents the D-Bus property "IdUsage".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idUsage(): string;
set idUsage(val: string);
/**
* Represents the D-Bus property "IdUUID".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_uuid(): string;
set id_uuid(val: string);
/**
* Represents the D-Bus property "IdUUID".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idUuid(): string;
set idUuid(val: string);
/**
* Represents the D-Bus property "IdVersion".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id_version(): string;
set id_version(val: string);
/**
* Represents the D-Bus property "IdVersion".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get idVersion(): string;
set idVersion(val: string);
/**
* Represents the D-Bus property "MDRaid".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraid(): string;
set mdraid(val: string);
/**
* Represents the D-Bus property "MDRaidMember".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraid_member(): string;
set mdraid_member(val: string);
/**
* Represents the D-Bus property "MDRaidMember".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mdraidMember(): string;
set mdraidMember(val: string);
/**
* Represents the D-Bus property "PreferredDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get preferred_device(): string;
set preferred_device(val: string);
/**
* Represents the D-Bus property "PreferredDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get preferredDevice(): string;
set preferredDevice(val: string);
/**
* Represents the D-Bus property "ReadOnly".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_only(): boolean;
set read_only(val: boolean);
/**
* Represents the D-Bus property "ReadOnly".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readOnly(): boolean;
set readOnly(val: boolean);
/**
* Represents the D-Bus property "Size".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get size(): number;
set size(val: number);
/**
* Represents the D-Bus property "Symlinks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get symlinks(): string[];
set symlinks(val: string[]);
/**
* Represents the D-Bus property "UserspaceMountOptions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get userspace_mount_options(): string[];
set userspace_mount_options(val: string[]);
/**
* Represents the D-Bus property "UserspaceMountOptions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get userspaceMountOptions(): string[];
set userspaceMountOptions(val: string[]);
// Inherited methods
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the AddConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_add_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_add_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_add_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_add_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_add_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_add_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the AddConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_add_configuration_item() for the asynchronous version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_add_configuration_item_sync(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Format() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_format_finish() to get the result of the operation.
*
* See udisks_block_call_format_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_format(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_format().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_format().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_format_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Format() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_format() for the asynchronous version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_format_sync(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_get_secret_configuration_finish() to get the result of the operation.
*
* See udisks_block_call_get_secret_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_get_secret_configuration(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_get_secret_configuration().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_get_secret_configuration().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_get_secret_configuration_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null];
/**
* Synchronously invokes the GetSecretConfiguration() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_get_secret_configuration() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_get_secret_configuration_sync(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null];
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenDevice() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_device_finish() to get the result of the operation.
*
* See udisks_block_call_open_device_sync() for the synchronous, blocking version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_device(
arg_mode: string,
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_device().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_device().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_device_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenDevice() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_device() for the asynchronous version of this method.
* @param arg_mode Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_device_sync(
arg_mode: string,
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForBackup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_backup_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_backup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_backup(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_backup().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_backup().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_backup_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForBackup() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_backup() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_backup_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForBenchmark() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_benchmark_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_benchmark_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_benchmark(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_benchmark().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_benchmark().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_benchmark_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForBenchmark() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_benchmark() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_benchmark_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]>;
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the OpenForRestore() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_open_for_restore_finish() to get the result of the operation.
*
* See udisks_block_call_open_for_restore_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_open_for_restore(
arg_options: GLib.Variant,
fd_list?: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise<[GLib.Variant | null, Gio.UnixFDList | null]> | void;
/**
* Finishes an operation started with udisks_block_call_open_for_restore().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_open_for_restore().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_restore_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null, Gio.UnixFDList | null];
/**
* Synchronously invokes the OpenForRestore() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_open_for_restore() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_open_for_restore_sync(
arg_options: GLib.Variant,
fd_list: Gio.UnixFDList | null,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null, Gio.UnixFDList];
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_remove_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_remove_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_remove_configuration_item(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_remove_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_remove_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_remove_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the RemoveConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_remove_configuration_item() for the asynchronous version of this method.
* @param arg_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_remove_configuration_item_sync(
arg_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_rescan(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_rescan(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Rescan() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_rescan_finish() to get the result of the operation.
*
* See udisks_block_call_rescan_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_rescan(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_rescan().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_rescan().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_rescan_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Rescan() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_rescan() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_rescan_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_block_call_update_configuration_item_finish() to get the result of the operation.
*
* See udisks_block_call_update_configuration_item_sync() for the synchronous, blocking version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_update_configuration_item(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_block_call_update_configuration_item().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_block_call_update_configuration_item().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_update_configuration_item_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the UpdateConfigurationItem() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_block_call_update_configuration_item() for the asynchronous version of this method.
* @param arg_old_item Argument to pass with the method invocation.
* @param arg_new_item Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_update_configuration_item_sync(
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the AddConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_add_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Format() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_format(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the GetSecretConfiguration() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param configuration Parameter to return.
*/
complete_get_secret_configuration(invocation: Gio.DBusMethodInvocation, configuration: GLib.Variant): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenDevice() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_device(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForBackup() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_backup(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForBenchmark() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_benchmark(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the OpenForRestore() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param fd_list A #GUnixFDList or %NULL.
* @param fd Parameter to return.
*/
complete_open_for_restore(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList | null,
fd: GLib.Variant,
): void;
/**
* Helper function used in service implementations to finish handling invocations of the RemoveConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_remove_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Rescan() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_rescan(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the UpdateConfigurationItem() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_update_configuration_item(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksBlock::handle-add-configuration-item signal.
* @param invocation
* @param arg_item
* @param arg_options
*/
vfunc_handle_add_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-format signal.
* @param invocation
* @param arg_type
* @param arg_options
*/
vfunc_handle_format(
invocation: Gio.DBusMethodInvocation,
arg_type: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-get-secret-configuration signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_get_secret_configuration(
invocation: Gio.DBusMethodInvocation,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-device signal.
* @param invocation
* @param fd_list
* @param arg_mode
* @param arg_options
*/
vfunc_handle_open_device(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_mode: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-backup signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_backup(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-benchmark signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_benchmark(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-open-for-restore signal.
* @param invocation
* @param fd_list
* @param arg_options
*/
vfunc_handle_open_for_restore(
invocation: Gio.DBusMethodInvocation,
fd_list: Gio.UnixFDList,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-remove-configuration-item signal.
* @param invocation
* @param arg_item
* @param arg_options
*/
vfunc_handle_remove_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksBlock::handle-rescan signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_rescan(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksBlock::handle-update-configuration-item signal.
* @param invocation
* @param arg_old_item
* @param arg_new_item
* @param arg_options
*/
vfunc_handle_update_configuration_item(
invocation: Gio.DBusMethodInvocation,
arg_old_item: GLib.Variant,
arg_new_item: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace Client {
// Signal callback interfaces
interface Changed {
(): void;
}
// Constructor properties interface
interface ConstructorProps
extends GObject.Object.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.Initable.ConstructorProps {
bus_connection: Gio.DBusConnection;
busConnection: Gio.DBusConnection;
manager: Manager;
object_manager: Gio.DBusObjectManager;
objectManager: Gio.DBusObjectManager;
}
}
/**
* #UDisksClient is used for accessing the UDisks service from a
* client program.
*/
class Client extends GObject.Object implements Gio.AsyncInitable, Gio.Initable {
static $gtype: GObject.GType;
// Properties
/**
* The #GDBusConnection used to create the #UDisksClient:object-manager, or
* %NULL if one wasn't specified during construction of the #UDisksClient (in
* which case a system bus connection is used).
*/
get bus_connection(): Gio.DBusConnection;
/**
* The #GDBusConnection used to create the #UDisksClient:object-manager, or
* %NULL if one wasn't specified during construction of the #UDisksClient (in
* which case a system bus connection is used).
*/
get busConnection(): Gio.DBusConnection;
/**
* The #UDisksManager interface on the well-known
* /org/freedesktop/UDisks2/Manager object
*/
get manager(): Manager;
/**
* The #GDBusObjectManager used by the #UDisksClient instance.
*/
get object_manager(): Gio.DBusObjectManager;
/**
* The #GDBusObjectManager used by the #UDisksClient instance.
*/
get objectManager(): Gio.DBusObjectManager;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): Client;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_connection_finish(res: Gio.AsyncResult): Client;
static new_sync(cancellable?: Gio.Cancellable | null): Client;
// Signals
connect(id: string, callback: (...args: any[]) => any): number;
connect_after(id: string, callback: (...args: any[]) => any): number;
emit(id: string, ...args: any[]): void;
connect(signal: 'changed', callback: (_source: this) => void): number;
connect_after(signal: 'changed', callback: (_source: this) => void): number;
emit(signal: 'changed'): void;
// Static methods
/**
* Gets a human-readable and localized text string describing a
* a job `operation`.
*
* For known job operation types, see the documentation for the
* Job:Operation
* D-Bus property.
* @param operation A job operation name.
*/
static get_job_description_from_operation(operation: string): string;
/**
* Asynchronously gets a #UDisksClient. When the operation is
* finished, `callback` will be invoked in the thread-default main
* loop of the thread you are calling this method from.
* @param cancellable A #GCancellable or %NULL.
* @param callback Function that will be called when the result is ready.
*/
static ['new'](
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Like #udisks_client_new() but takes a #GDBusConnection which will be used
* when connecting to the UDisks daemon over D-Bus. This is useful for unit
* tests which may want to use #GTestDBus to create a D-Bus daemon on the
* session bus.
* @param connection a #GDBusConnection. If %NULL, a system bus connection will be used.
* @param cancellable A #GCancellable or %NULL.
* @param callback Function that will be called when the result is ready.
*/
static new_for_connection(
connection?: Gio.DBusConnection | null,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Methods
/**
* Gets all RAID devices (e.g. /dev/md0 and /dev/md1) for `raid`.
*
* This is usually only useful in split-brain
* situations — see udisks_client_get_block_for_mdraid() for
* an example — and is normally used only to convey the problem in an
* user interface.
* @param raid A #UDisksMDRaid.
* @returns A list of #UDisksBlock instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_all_blocks_for_mdraid(raid: MDRaid): Block[];
/**
* Gets the #UDisksBlock corresponding to `block_device_number,` if any.
* @param block_device_number A #dev_t to get a #UDisksBlock for.
* @returns A #UDisksBlock or %NULL if not found.
*/
get_block_for_dev(block_device_number: number): Block;
/**
* Gets a block device corresponding to `drive`. The returned block
* device, if any, is for the whole disk drive, e.g. a partition block
* device is never returned.
*
* Set `get_physical` to %TRUE if you need a block device that you can
* send low-level SCSI commands with (for multipath, this returns one
* of the physical paths). Set it to %FALSE if you need a block device
* that you can read/write data with (for multipath, this returns the
* mapped device).
* @param drive A #UDisksDrive.
* @param get_physical %TRUE to get a physical device, %FALSE to get the logical device.
* @returns A #UDisksBlock or %NULL if the requested kind of block device is not available - use g_object_unref() to free the returned object.
*/
get_block_for_drive(drive: Drive, get_physical: boolean): Block;
/**
* Gets all the #UDisksBlock instances with the given label, if any.
* @param label The label.
* @returns A list of #UDisksBlock instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_block_for_label(label: string): Block[];
/**
* Gets the RAID device (e.g. /dev/md0) for `raid`.
*
* In the case of a split-brain
* syndrome, it is undefined which RAID device is
* returned. For example this can happen if
* /dev/sda and /dev/sdb are
* components of a two-disk RAID-1 and /dev/md0
* and /dev/md1 are two degraded arrays, each one
* using exactly one of the two devices. Use
* udisks_client_get_all_blocks_for_mdraid() to get all RAID devices.
* @param raid A #UDisksMDRaid.
* @returns A #UDisksBlock or %NULL if no RAID device is running.
*/
get_block_for_mdraid(raid: MDRaid): Block;
/**
* Gets all the #UDisksBlock instances with the given uuid, if any.
* @param uuid The uuid.
* @returns A list of #UDisksBlock instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_block_for_uuid(uuid: string): Block[];
/**
* If `block` is an unlocked encrypted device, gets the cleartext device.
* @param block A #UDisksBlock.
* @returns A #UDisksBlock or %NULL. Free with g_object_unref() when done with it.
*/
get_cleartext_block(block: Block): Block;
/**
* Gets the #UDisksDrive that `block` belongs to, if any.
* @param block A #UDisksBlock.
* @returns A #UDisksDrive or %NULL if there is no #UDisksDrive for @block - free the returned object with g_object_unref().
*/
get_drive_for_block(block: Block): Drive;
/**
* Gets information about a #UDisksDrive object that is suitable to
* present in an user interface. The returned strings are localized.
* @param drive A #UDisksDrive.
*/
get_drive_info(drive: Drive): [string, string, Gio.Icon | null, string, Gio.Icon | null];
/**
* Gets all siblings for `drive`.
* @param drive A #UDisksDrive.
* @returns A list of #UDisksDrive instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_drive_siblings(drive: Drive): Drive[];
/**
* Gets a human readable localized string for `usage,` `type` and `version`.
* @param usage Usage id e.g. "filesystem" or "crypto".
* @param type Type e.g. "ext4" or "crypto_LUKS"
* @param version Version.
* @param long_string Whether to produce a long string.
* @returns A string that should be freed with g_free().
*/
get_id_for_display(usage: string, type: string, version: string, long_string: boolean): string;
/**
* Gets a human-readable and localized text string describing the
* operation of `job`.
*
* For known job types, see the documentation for the
* Job:Operation
* D-Bus property.
* @param job A #UDisksJob.
* @returns A string that should be freed with g_free().
*/
get_job_description(job: Job): string;
/**
* Gets all the #UDisksJob instances that reference `object,` if any.
* @param object A #UDisksObject.
* @returns A list of #UDisksJob instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_jobs_for_object(object: Object): Job[];
/**
* Gets the corresponding loop interface for `block`.
*
* This only works if `block` itself is a loop device or a partition of
* a loop device.
* @param block A #UDisksBlock.
* @returns A #UDisksLoop or %NULL. Free with g_object_unref().
*/
get_loop_for_block(block: Block): Loop;
/**
* Gets the #UDisksManager interface on the well-known
* /org/freedesktop/UDisks2/Manager object.
* @returns A #UDisksManager or %NULL if the udisksd daemon is not currently running. Do not free, the instance is owned by @client.
*/
get_manager(): Manager;
/**
* Gets the #UDisksMDRaid that `block` is the block device for, if any.
* @param block A #UDisksBlock.
* @returns A #UDisksMDRaid or %NULL if there is no #UDisksMDRaid for @block or @block is not a MD-RAID block device. Free the returned object with g_object_unref().
*/
get_mdraid_for_block(block: Block): MDRaid;
/**
* Gets a human-readable string of the media described by
* `media_compat`. The returned information is localized.
* @param media_compat An array of media types.
* @returns A string that should be freed with g_free() or %NULL if unknown.
*/
get_media_compat_for_display(media_compat: string): string;
/**
* Gets the physical block devices that are part of `raid`.
* @param raid A #UDisksMDRaid.
* @returns A list of #UDisksBlock instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_members_for_mdraid(raid: MDRaid): Block[];
/**
* Convenience function for looking up an #UDisksObject for `object_path`.
* @param object_path Object path.
* @returns A #UDisksObject corresponding to @object_path or %NULL if not found. The returned object must be freed with g_object_unref().
*/
get_object(object_path: string): Object;
/**
* Gets information about a #UDisksObject instance that is suitable to
* present in an user interface. Information is returned in the
* #UDisksObjectInfo object and is localized.
* @param object A #UDisksObject.
* @returns A #UDisksObjectInfo instance that should be freed with g_object_unref().
*/
get_object_info(object: Object): ObjectInfo;
/**
* Gets the #GDBusObjectManager used by `client`.
* @returns A #GDBusObjectManager. Do not free, the instance is owned by @client.
*/
get_object_manager(): Gio.DBusObjectManager;
/**
* Gets information about `partition` that is suitable to present in an
* user interface in a single line of text.
*
* The returned string is localized and includes things like the
* partition type, flags (if any) and name (if any).
* @param partition # #UDisksPartition.
* @returns A string that should be freed with g_free().
*/
get_partition_info(partition: Partition): string;
/**
* Gets the #UDisksPartitionTable corresponding to `partition`.
* @param partition A #UDisksPartition.
* @returns A #UDisksPartitionTable. Free with g_object_unref().
*/
get_partition_table(partition: Partition): PartitionTable;
/**
* Gets a human readable localized string for `partition_table_type` and `partition_table_subtype`.
* @param partition_table_type A partition table type e.g. 'dos' or 'gpt'.
* @param partition_table_subtype A partition table type e.g. 'dos' or 'gpt'.
* @returns A description of @partition_table_type and @partition_table_subtype or %NULL.
*/
get_partition_table_subtype_for_display(
partition_table_type: string,
partition_table_subtype: string,
): string;
/**
* Gets all known subtypes for `partition_table_type`.
* @param partition_table_type A partition table type e.g. 'dos' or 'gpt'.
* @returns A %NULL-terminated array of strings. Only the container should be freed with g_free().
*/
get_partition_table_subtypes(partition_table_type: string): string[];
/**
* Gets a human readable localized string for `partition_table_type`.
* @param partition_table_type A partition table type e.g. 'dos' or 'gpt'.
* @returns A description of @partition_table_type or %NULL.
*/
get_partition_table_type_for_display(partition_table_type: string): string;
/**
* Like udisks_client_get_partition_type_for_display() but also takes
* the partition table subtype into account, if available. This is
* useful in scenarios where different subtypes is using the same
* partition type.
* @param partition_table_type A partitioning type e.g. 'dos' or 'gpt'.
* @param partition_table_subtype A partitioning subtype or %NULL.
* @param partition_type A partition type.
* @returns A description of @partition_type or %NULL if unknown.
*/
get_partition_type_and_subtype_for_display(
partition_table_type: string,
partition_table_subtype: string,
partition_type: string,
): string;
/**
* Gets a human readable localized string for `partiton_table_type` and `partition_type`.
* @param partition_table_type A partitioning type e.g. 'dos' or 'gpt'.
* @param partition_type A partition type.
* @returns A description of @partition_type or %NULL if unknown.
*/
get_partition_type_for_display(partition_table_type: string, partition_type: string): string;
/**
* Gets information about all known partition types for `partition_table_type` and `partition_table_subtype`.
* @param partition_table_type A partition table type e.g. 'dos' or 'gpt'.
* @param partition_table_subtype A partition table subtype or %NULL to get all known types.
* @returns A list of #UDisksPartitionTypeInfo instances. The returned list should be freed with g_list_free() after freeing each element with udisks_partition_type_info_free().
*/
get_partition_type_infos(
partition_table_type: string,
partition_table_subtype?: string | null,
): PartitionTypeInfo[];
/**
* Gets all partitions of `table`.
* @param table A #UDisksPartitionTable.
* @returns A list of #UDisksPartition instances. The returned list should be freed with g_list_free() after each element has been freed with g_object_unref().
*/
get_partitions(table: PartitionTable): Partition[];
/**
* Utility function to get a human-readable string that represents `size`.
* @param size Size in bytes
* @param use_pow2 Whether power-of-two units should be used instead of power-of-ten units.
* @param long_string Whether to produce a long string.
* @returns A string that should be freed with g_free().
*/
get_size_for_display(size: number, use_pow2: boolean, long_string: boolean): string;
/**
* Like udisks_client_get_object() but doesn't increase the reference
* count on the returned #UDisksObject.
*
* The returned object is only valid until removed so it is only safe to use this function on the thread where `client` was constructed. Use udisks_client_get_object() if on another thread.
* @param object_path Object path.
* @returns A #UDisksObject corresponding to @object_path or %NULL if not found.
*/
peek_object(object_path: string): Object;
/**
* Queues up a #UDisksClient::changed signal and rate-limit it. See
* the documentation for the #UDisksClient::changed property for more
* information.
*/
queue_changed(): void;
/**
* Blocks until all pending D-Bus messages have been delivered. Also
* emits the (rate-limited) #UDisksClient::changed signal if changes
* are currently pending.
*
* This is useful in two situations: 1. when using synchronous method
* calls since e.g. D-Bus signals received while waiting for the reply
* are queued up and dispatched after the synchronous call ends; and
* 2. when using asynchronous calls where the return value references
* a newly created object (such as the Manager.LoopSetup() method).
*/
settle(): void;
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): Client;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace DriveAtaProxy {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusProxy.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Gio.Initable.ConstructorProps,
DriveAta.ConstructorProps {}
}
/**
* The #UDisksDriveAtaProxy structure contains only private data and should only be accessed using the provided API.
*/
class DriveAtaProxy
extends Gio.DBusProxy
implements Gio.AsyncInitable, Gio.DBusInterface, Gio.Initable, DriveAta
{
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): DriveAtaProxy;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_bus_finish(res: Gio.AsyncResult): DriveAtaProxy;
static new_for_bus_sync(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
): DriveAtaProxy;
// Conflicted with Gio.DBusProxy.new_for_bus_sync
static new_for_bus_sync(...args: never[]): any;
static new_sync(
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
): DriveAtaProxy;
// Conflicted with Gio.DBusProxy.new_sync
static new_sync(...args: never[]): any;
// Static methods
/**
* Asynchronously creates a proxy for the D-Bus interface org.freedesktop.UDisks2.Drive.Ata. See g_dbus_proxy_new() for more details.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_proxy_new_finish() to get the result of the operation.
*
* See udisks_drive_ata_proxy_new_sync() for the synchronous, blocking version of this constructor.
* @param connection A #GDBusConnection.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static ['new'](
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new
static ['new'](...args: never[]): any;
/**
* Like udisks_drive_ata_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_proxy_new_for_bus_finish() to get the result of the operation.
*
* See udisks_drive_ata_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
* @param bus_type A #GBusType.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique).
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static new_for_bus(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new_for_bus
static new_for_bus(...args: never[]): any;
// Inherited properties
/**
* Represents the D-Bus property "AamEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_enabled(): boolean;
set aam_enabled(val: boolean);
/**
* Represents the D-Bus property "AamEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamEnabled(): boolean;
set aamEnabled(val: boolean);
/**
* Represents the D-Bus property "AamSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_supported(): boolean;
set aam_supported(val: boolean);
/**
* Represents the D-Bus property "AamSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamSupported(): boolean;
set aamSupported(val: boolean);
/**
* Represents the D-Bus property "AamVendorRecommendedValue".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_vendor_recommended_value(): number;
set aam_vendor_recommended_value(val: number);
/**
* Represents the D-Bus property "AamVendorRecommendedValue".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamVendorRecommendedValue(): number;
set aamVendorRecommendedValue(val: number);
/**
* Represents the D-Bus property "ApmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apm_enabled(): boolean;
set apm_enabled(val: boolean);
/**
* Represents the D-Bus property "ApmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apmEnabled(): boolean;
set apmEnabled(val: boolean);
/**
* Represents the D-Bus property "ApmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apm_supported(): boolean;
set apm_supported(val: boolean);
/**
* Represents the D-Bus property "ApmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apmSupported(): boolean;
set apmSupported(val: boolean);
/**
* Represents the D-Bus property "PmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pm_enabled(): boolean;
set pm_enabled(val: boolean);
/**
* Represents the D-Bus property "PmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pmEnabled(): boolean;
set pmEnabled(val: boolean);
/**
* Represents the D-Bus property "PmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pm_supported(): boolean;
set pm_supported(val: boolean);
/**
* Represents the D-Bus property "PmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pmSupported(): boolean;
set pmSupported(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_lookahead_enabled(): boolean;
set read_lookahead_enabled(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readLookaheadEnabled(): boolean;
set readLookaheadEnabled(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_lookahead_supported(): boolean;
set read_lookahead_supported(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readLookaheadSupported(): boolean;
set readLookaheadSupported(val: boolean);
/**
* Represents the D-Bus property "SecurityEnhancedEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_enhanced_erase_unit_minutes(): number;
set security_enhanced_erase_unit_minutes(val: number);
/**
* Represents the D-Bus property "SecurityEnhancedEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityEnhancedEraseUnitMinutes(): number;
set securityEnhancedEraseUnitMinutes(val: number);
/**
* Represents the D-Bus property "SecurityEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_erase_unit_minutes(): number;
set security_erase_unit_minutes(val: number);
/**
* Represents the D-Bus property "SecurityEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityEraseUnitMinutes(): number;
set securityEraseUnitMinutes(val: number);
/**
* Represents the D-Bus property "SecurityFrozen".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_frozen(): boolean;
set security_frozen(val: boolean);
/**
* Represents the D-Bus property "SecurityFrozen".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityFrozen(): boolean;
set securityFrozen(val: boolean);
/**
* Represents the D-Bus property "SmartEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_enabled(): boolean;
set smart_enabled(val: boolean);
/**
* Represents the D-Bus property "SmartEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartEnabled(): boolean;
set smartEnabled(val: boolean);
/**
* Represents the D-Bus property "SmartFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_failing(): boolean;
set smart_failing(val: boolean);
/**
* Represents the D-Bus property "SmartFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartFailing(): boolean;
set smartFailing(val: boolean);
/**
* Represents the D-Bus property "SmartNumAttributesFailedInThePast".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_attributes_failed_in_the_past(): number;
set smart_num_attributes_failed_in_the_past(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailedInThePast".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumAttributesFailedInThePast(): number;
set smartNumAttributesFailedInThePast(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_attributes_failing(): number;
set smart_num_attributes_failing(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumAttributesFailing(): number;
set smartNumAttributesFailing(val: number);
/**
* Represents the D-Bus property "SmartNumBadSectors".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_bad_sectors(): number;
set smart_num_bad_sectors(val: number);
/**
* Represents the D-Bus property "SmartNumBadSectors".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumBadSectors(): number;
set smartNumBadSectors(val: number);
/**
* Represents the D-Bus property "SmartPowerOnSeconds".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_power_on_seconds(): number;
set smart_power_on_seconds(val: number);
/**
* Represents the D-Bus property "SmartPowerOnSeconds".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartPowerOnSeconds(): number;
set smartPowerOnSeconds(val: number);
/**
* Represents the D-Bus property "SmartSelftestPercentRemaining".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_selftest_percent_remaining(): number;
set smart_selftest_percent_remaining(val: number);
/**
* Represents the D-Bus property "SmartSelftestPercentRemaining".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSelftestPercentRemaining(): number;
set smartSelftestPercentRemaining(val: number);
/**
* Represents the D-Bus property "SmartSelftestStatus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_selftest_status(): string;
set smart_selftest_status(val: string);
/**
* Represents the D-Bus property "SmartSelftestStatus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSelftestStatus(): string;
set smartSelftestStatus(val: string);
/**
* Represents the D-Bus property "SmartSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_supported(): boolean;
set smart_supported(val: boolean);
/**
* Represents the D-Bus property "SmartSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSupported(): boolean;
set smartSupported(val: boolean);
/**
* Represents the D-Bus property "SmartTemperature".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_temperature(): number;
set smart_temperature(val: number);
/**
* Represents the D-Bus property "SmartTemperature".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartTemperature(): number;
set smartTemperature(val: number);
/**
* Represents the D-Bus property "SmartUpdated".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_updated(): number;
set smart_updated(val: number);
/**
* Represents the D-Bus property "SmartUpdated".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartUpdated(): number;
set smartUpdated(val: number);
/**
* Represents the D-Bus property "WriteCacheEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get write_cache_enabled(): boolean;
set write_cache_enabled(val: boolean);
/**
* Represents the D-Bus property "WriteCacheEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get writeCacheEnabled(): boolean;
set writeCacheEnabled(val: boolean);
/**
* Represents the D-Bus property "WriteCacheSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get write_cache_supported(): boolean;
set write_cache_supported(val: boolean);
/**
* Represents the D-Bus property "WriteCacheSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get writeCacheSupported(): boolean;
set writeCacheSupported(val: boolean);
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): DriveAtaProxy;
// Conflicted with Gio.DBusProxy.new_finish
new_finish(...args: never[]): any;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_get_state(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_get_state(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_get_state(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_get_state().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_get_state().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_get_state_finish(res: Gio.AsyncResult): [boolean, number];
/**
* Synchronously invokes the PmGetState() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_get_state() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_get_state_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): [boolean, number];
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_standby(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_standby(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_standby(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_standby().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_standby().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_standby_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PmStandby() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_standby() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_standby_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_wakeup(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_wakeup(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_wakeup(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_wakeup().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_wakeup().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_wakeup_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PmWakeup() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_wakeup() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_wakeup_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_security_erase_unit(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_security_erase_unit(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_security_erase_unit(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_security_erase_unit().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_security_erase_unit().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_security_erase_unit_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_security_erase_unit() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_security_erase_unit_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_get_attributes().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_get_attributes().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_get_attributes_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null];
/**
* Synchronously invokes the SmartGetAttributes() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_get_attributes() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_get_attributes_sync(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null];
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_selftest_abort().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_selftest_abort().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_abort_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_selftest_abort() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_abort_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_selftest_start().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_selftest_start().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_start_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSelftestStart() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_selftest_start() for the asynchronous version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_start_sync(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_set_enabled().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_set_enabled().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_set_enabled_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSetEnabled() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_set_enabled() for the asynchronous version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_set_enabled_sync(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_update(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_update(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_update(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_update().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_update().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_update_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartUpdate() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_update() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_update_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the PmGetState() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param state Parameter to return.
*/
complete_pm_get_state(invocation: Gio.DBusMethodInvocation, state: number): void;
/**
* Helper function used in service implementations to finish handling invocations of the PmStandby() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_pm_standby(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the PmWakeup() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_pm_wakeup(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SecurityEraseUnit() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_security_erase_unit(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartGetAttributes() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param attributes Parameter to return.
*/
complete_smart_get_attributes(invocation: Gio.DBusMethodInvocation, attributes: GLib.Variant): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSelftestAbort() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_selftest_abort(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSelftestStart() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_selftest_start(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSetEnabled() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_set_enabled(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartUpdate() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_update(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksDriveAta::handle-pm-get-state signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_get_state(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-pm-standby signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_standby(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-pm-wakeup signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_wakeup(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-security-erase-unit signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_security_erase_unit(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-get-attributes signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_get_attributes(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-selftest-abort signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_selftest_abort(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-selftest-start signal.
* @param invocation
* @param arg_type
* @param arg_options
*/
vfunc_handle_smart_selftest_start(
invocation: Gio.DBusMethodInvocation,
arg_type: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-set-enabled signal.
* @param invocation
* @param arg_value
* @param arg_options
*/
vfunc_handle_smart_set_enabled(
invocation: Gio.DBusMethodInvocation,
arg_value: boolean,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-update signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_update(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace DriveAtaSkeleton {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusInterfaceSkeleton.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
DriveAta.ConstructorProps {}
}
/**
* The #UDisksDriveAtaSkeleton structure contains only private data and should only be accessed using the provided API.
*/
class DriveAtaSkeleton extends Gio.DBusInterfaceSkeleton implements Gio.DBusInterface, DriveAta {
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): DriveAtaSkeleton;
// Inherited properties
/**
* Represents the D-Bus property "AamEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_enabled(): boolean;
set aam_enabled(val: boolean);
/**
* Represents the D-Bus property "AamEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamEnabled(): boolean;
set aamEnabled(val: boolean);
/**
* Represents the D-Bus property "AamSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_supported(): boolean;
set aam_supported(val: boolean);
/**
* Represents the D-Bus property "AamSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamSupported(): boolean;
set aamSupported(val: boolean);
/**
* Represents the D-Bus property "AamVendorRecommendedValue".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aam_vendor_recommended_value(): number;
set aam_vendor_recommended_value(val: number);
/**
* Represents the D-Bus property "AamVendorRecommendedValue".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get aamVendorRecommendedValue(): number;
set aamVendorRecommendedValue(val: number);
/**
* Represents the D-Bus property "ApmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apm_enabled(): boolean;
set apm_enabled(val: boolean);
/**
* Represents the D-Bus property "ApmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apmEnabled(): boolean;
set apmEnabled(val: boolean);
/**
* Represents the D-Bus property "ApmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apm_supported(): boolean;
set apm_supported(val: boolean);
/**
* Represents the D-Bus property "ApmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get apmSupported(): boolean;
set apmSupported(val: boolean);
/**
* Represents the D-Bus property "PmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pm_enabled(): boolean;
set pm_enabled(val: boolean);
/**
* Represents the D-Bus property "PmEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pmEnabled(): boolean;
set pmEnabled(val: boolean);
/**
* Represents the D-Bus property "PmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pm_supported(): boolean;
set pm_supported(val: boolean);
/**
* Represents the D-Bus property "PmSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get pmSupported(): boolean;
set pmSupported(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_lookahead_enabled(): boolean;
set read_lookahead_enabled(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readLookaheadEnabled(): boolean;
set readLookaheadEnabled(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get read_lookahead_supported(): boolean;
set read_lookahead_supported(val: boolean);
/**
* Represents the D-Bus property "ReadLookaheadSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get readLookaheadSupported(): boolean;
set readLookaheadSupported(val: boolean);
/**
* Represents the D-Bus property "SecurityEnhancedEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_enhanced_erase_unit_minutes(): number;
set security_enhanced_erase_unit_minutes(val: number);
/**
* Represents the D-Bus property "SecurityEnhancedEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityEnhancedEraseUnitMinutes(): number;
set securityEnhancedEraseUnitMinutes(val: number);
/**
* Represents the D-Bus property "SecurityEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_erase_unit_minutes(): number;
set security_erase_unit_minutes(val: number);
/**
* Represents the D-Bus property "SecurityEraseUnitMinutes".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityEraseUnitMinutes(): number;
set securityEraseUnitMinutes(val: number);
/**
* Represents the D-Bus property "SecurityFrozen".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get security_frozen(): boolean;
set security_frozen(val: boolean);
/**
* Represents the D-Bus property "SecurityFrozen".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get securityFrozen(): boolean;
set securityFrozen(val: boolean);
/**
* Represents the D-Bus property "SmartEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_enabled(): boolean;
set smart_enabled(val: boolean);
/**
* Represents the D-Bus property "SmartEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartEnabled(): boolean;
set smartEnabled(val: boolean);
/**
* Represents the D-Bus property "SmartFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_failing(): boolean;
set smart_failing(val: boolean);
/**
* Represents the D-Bus property "SmartFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartFailing(): boolean;
set smartFailing(val: boolean);
/**
* Represents the D-Bus property "SmartNumAttributesFailedInThePast".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_attributes_failed_in_the_past(): number;
set smart_num_attributes_failed_in_the_past(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailedInThePast".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumAttributesFailedInThePast(): number;
set smartNumAttributesFailedInThePast(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_attributes_failing(): number;
set smart_num_attributes_failing(val: number);
/**
* Represents the D-Bus property "SmartNumAttributesFailing".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumAttributesFailing(): number;
set smartNumAttributesFailing(val: number);
/**
* Represents the D-Bus property "SmartNumBadSectors".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_num_bad_sectors(): number;
set smart_num_bad_sectors(val: number);
/**
* Represents the D-Bus property "SmartNumBadSectors".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartNumBadSectors(): number;
set smartNumBadSectors(val: number);
/**
* Represents the D-Bus property "SmartPowerOnSeconds".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_power_on_seconds(): number;
set smart_power_on_seconds(val: number);
/**
* Represents the D-Bus property "SmartPowerOnSeconds".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartPowerOnSeconds(): number;
set smartPowerOnSeconds(val: number);
/**
* Represents the D-Bus property "SmartSelftestPercentRemaining".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_selftest_percent_remaining(): number;
set smart_selftest_percent_remaining(val: number);
/**
* Represents the D-Bus property "SmartSelftestPercentRemaining".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSelftestPercentRemaining(): number;
set smartSelftestPercentRemaining(val: number);
/**
* Represents the D-Bus property "SmartSelftestStatus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_selftest_status(): string;
set smart_selftest_status(val: string);
/**
* Represents the D-Bus property "SmartSelftestStatus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSelftestStatus(): string;
set smartSelftestStatus(val: string);
/**
* Represents the D-Bus property "SmartSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_supported(): boolean;
set smart_supported(val: boolean);
/**
* Represents the D-Bus property "SmartSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartSupported(): boolean;
set smartSupported(val: boolean);
/**
* Represents the D-Bus property "SmartTemperature".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_temperature(): number;
set smart_temperature(val: number);
/**
* Represents the D-Bus property "SmartTemperature".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartTemperature(): number;
set smartTemperature(val: number);
/**
* Represents the D-Bus property "SmartUpdated".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smart_updated(): number;
set smart_updated(val: number);
/**
* Represents the D-Bus property "SmartUpdated".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get smartUpdated(): number;
set smartUpdated(val: number);
/**
* Represents the D-Bus property "WriteCacheEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get write_cache_enabled(): boolean;
set write_cache_enabled(val: boolean);
/**
* Represents the D-Bus property "WriteCacheEnabled".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get writeCacheEnabled(): boolean;
set writeCacheEnabled(val: boolean);
/**
* Represents the D-Bus property "WriteCacheSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get write_cache_supported(): boolean;
set write_cache_supported(val: boolean);
/**
* Represents the D-Bus property "WriteCacheSupported".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get writeCacheSupported(): boolean;
set writeCacheSupported(val: boolean);
// Inherited methods
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_get_state(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_get_state(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmGetState() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_get_state_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_get_state_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_get_state(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_get_state().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_get_state().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_get_state_finish(res: Gio.AsyncResult): [boolean, number];
/**
* Synchronously invokes the PmGetState() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_get_state() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_get_state_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): [boolean, number];
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_standby(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_standby(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmStandby() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_standby_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_standby_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_standby(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_standby().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_standby().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_standby_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PmStandby() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_standby() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_standby_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_pm_wakeup(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_wakeup(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PmWakeup() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_pm_wakeup_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_pm_wakeup_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_pm_wakeup(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_pm_wakeup().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_pm_wakeup().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_wakeup_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PmWakeup() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_pm_wakeup() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_pm_wakeup_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_security_erase_unit(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_security_erase_unit(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_security_erase_unit_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_security_erase_unit_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_security_erase_unit(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_security_erase_unit().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_security_erase_unit().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_security_erase_unit_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SecurityEraseUnit() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_security_erase_unit() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_security_erase_unit_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartGetAttributes() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_get_attributes_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_get_attributes_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_get_attributes(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_get_attributes().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_get_attributes().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_get_attributes_finish(res: Gio.AsyncResult): [boolean, GLib.Variant | null];
/**
* Synchronously invokes the SmartGetAttributes() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_get_attributes() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_get_attributes_sync(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): [boolean, GLib.Variant | null];
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_abort_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_abort_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_abort(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_selftest_abort().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_selftest_abort().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_abort_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSelftestAbort() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_selftest_abort() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_abort_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSelftestStart() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_selftest_start_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_selftest_start_sync() for the synchronous, blocking version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_selftest_start(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_selftest_start().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_selftest_start().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_start_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSelftestStart() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_selftest_start() for the asynchronous version of this method.
* @param arg_type Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_selftest_start_sync(
arg_type: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartSetEnabled() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_set_enabled_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_set_enabled_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_set_enabled(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_set_enabled().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_set_enabled().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_set_enabled_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartSetEnabled() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_set_enabled() for the asynchronous version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_set_enabled_sync(
arg_value: boolean,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_smart_update(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_update(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SmartUpdate() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_ata_call_smart_update_finish() to get the result of the operation.
*
* See udisks_drive_ata_call_smart_update_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_smart_update(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_ata_call_smart_update().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_ata_call_smart_update().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_update_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SmartUpdate() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_ata_call_smart_update() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_smart_update_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the PmGetState() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param state Parameter to return.
*/
complete_pm_get_state(invocation: Gio.DBusMethodInvocation, state: number): void;
/**
* Helper function used in service implementations to finish handling invocations of the PmStandby() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_pm_standby(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the PmWakeup() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_pm_wakeup(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SecurityEraseUnit() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_security_erase_unit(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartGetAttributes() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param attributes Parameter to return.
*/
complete_smart_get_attributes(invocation: Gio.DBusMethodInvocation, attributes: GLib.Variant): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSelftestAbort() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_selftest_abort(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSelftestStart() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_selftest_start(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartSetEnabled() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_set_enabled(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SmartUpdate() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_smart_update(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksDriveAta::handle-pm-get-state signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_get_state(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-pm-standby signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_standby(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-pm-wakeup signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_pm_wakeup(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-security-erase-unit signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_security_erase_unit(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-get-attributes signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_get_attributes(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-selftest-abort signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_selftest_abort(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-selftest-start signal.
* @param invocation
* @param arg_type
* @param arg_options
*/
vfunc_handle_smart_selftest_start(
invocation: Gio.DBusMethodInvocation,
arg_type: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-set-enabled signal.
* @param invocation
* @param arg_value
* @param arg_options
*/
vfunc_handle_smart_set_enabled(
invocation: Gio.DBusMethodInvocation,
arg_value: boolean,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksDriveAta::handle-smart-update signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_smart_update(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace DriveProxy {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusProxy.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Gio.Initable.ConstructorProps,
Drive.ConstructorProps {}
}
/**
* The #UDisksDriveProxy structure contains only private data and should only be accessed using the provided API.
*/
class DriveProxy
extends Gio.DBusProxy
implements Gio.AsyncInitable, Gio.DBusInterface, Gio.Initable, Drive
{
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): DriveProxy;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_bus_finish(res: Gio.AsyncResult): DriveProxy;
static new_for_bus_sync(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
): DriveProxy;
// Conflicted with Gio.DBusProxy.new_for_bus_sync
static new_for_bus_sync(...args: never[]): any;
static new_sync(
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
): DriveProxy;
// Conflicted with Gio.DBusProxy.new_sync
static new_sync(...args: never[]): any;
// Static methods
/**
* Asynchronously creates a proxy for the D-Bus interface org.freedesktop.UDisks2.Drive. See g_dbus_proxy_new() for more details.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_proxy_new_finish() to get the result of the operation.
*
* See udisks_drive_proxy_new_sync() for the synchronous, blocking version of this constructor.
* @param connection A #GDBusConnection.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static ['new'](
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new
static ['new'](...args: never[]): any;
/**
* Like udisks_drive_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_proxy_new_for_bus_finish() to get the result of the operation.
*
* See udisks_drive_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
* @param bus_type A #GBusType.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique).
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static new_for_bus(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new_for_bus
static new_for_bus(...args: never[]): any;
// Inherited properties
/**
* Represents the D-Bus property "CanPowerOff".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get can_power_off(): boolean;
set can_power_off(val: boolean);
/**
* Represents the D-Bus property "CanPowerOff".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get canPowerOff(): boolean;
set canPowerOff(val: boolean);
/**
* Represents the D-Bus property "Configuration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get configuration(): GLib.Variant;
set configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "ConnectionBus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get connection_bus(): string;
set connection_bus(val: string);
/**
* Represents the D-Bus property "ConnectionBus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get connectionBus(): string;
set connectionBus(val: string);
/**
* Represents the D-Bus property "Ejectable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get ejectable(): boolean;
set ejectable(val: boolean);
/**
* Represents the D-Bus property "Id".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id(): string;
set id(val: string);
/**
* Represents the D-Bus property "Media".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media(): string;
set media(val: string);
/**
* Represents the D-Bus property "MediaAvailable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_available(): boolean;
set media_available(val: boolean);
/**
* Represents the D-Bus property "MediaAvailable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaAvailable(): boolean;
set mediaAvailable(val: boolean);
/**
* Represents the D-Bus property "MediaChangeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_change_detected(): boolean;
set media_change_detected(val: boolean);
/**
* Represents the D-Bus property "MediaChangeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaChangeDetected(): boolean;
set mediaChangeDetected(val: boolean);
/**
* Represents the D-Bus property "MediaCompatibility".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_compatibility(): string[];
set media_compatibility(val: string[]);
/**
* Represents the D-Bus property "MediaCompatibility".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaCompatibility(): string[];
set mediaCompatibility(val: string[]);
/**
* Represents the D-Bus property "MediaRemovable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_removable(): boolean;
set media_removable(val: boolean);
/**
* Represents the D-Bus property "MediaRemovable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaRemovable(): boolean;
set mediaRemovable(val: boolean);
/**
* Represents the D-Bus property "Model".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get model(): string;
set model(val: string);
/**
* Represents the D-Bus property "Optical".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical(): boolean;
set optical(val: boolean);
/**
* Represents the D-Bus property "OpticalBlank".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_blank(): boolean;
set optical_blank(val: boolean);
/**
* Represents the D-Bus property "OpticalBlank".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalBlank(): boolean;
set opticalBlank(val: boolean);
/**
* Represents the D-Bus property "OpticalNumAudioTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_audio_tracks(): number;
set optical_num_audio_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumAudioTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumAudioTracks(): number;
set opticalNumAudioTracks(val: number);
/**
* Represents the D-Bus property "OpticalNumDataTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_data_tracks(): number;
set optical_num_data_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumDataTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumDataTracks(): number;
set opticalNumDataTracks(val: number);
/**
* Represents the D-Bus property "OpticalNumSessions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_sessions(): number;
set optical_num_sessions(val: number);
/**
* Represents the D-Bus property "OpticalNumSessions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumSessions(): number;
set opticalNumSessions(val: number);
/**
* Represents the D-Bus property "OpticalNumTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_tracks(): number;
set optical_num_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumTracks(): number;
set opticalNumTracks(val: number);
/**
* Represents the D-Bus property "Removable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get removable(): boolean;
set removable(val: boolean);
/**
* Represents the D-Bus property "Revision".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get revision(): string;
set revision(val: string);
/**
* Represents the D-Bus property "RotationRate".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get rotation_rate(): number;
set rotation_rate(val: number);
/**
* Represents the D-Bus property "RotationRate".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get rotationRate(): number;
set rotationRate(val: number);
/**
* Represents the D-Bus property "Seat".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get seat(): string;
set seat(val: string);
/**
* Represents the D-Bus property "Serial".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get serial(): string;
set serial(val: string);
/**
* Represents the D-Bus property "SiblingId".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sibling_id(): string;
set sibling_id(val: string);
/**
* Represents the D-Bus property "SiblingId".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get siblingId(): string;
set siblingId(val: string);
/**
* Represents the D-Bus property "Size".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get size(): number;
set size(val: number);
/**
* Represents the D-Bus property "SortKey".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sort_key(): string;
set sort_key(val: string);
/**
* Represents the D-Bus property "SortKey".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sortKey(): string;
set sortKey(val: string);
/**
* Represents the D-Bus property "TimeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get time_detected(): number;
set time_detected(val: number);
/**
* Represents the D-Bus property "TimeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get timeDetected(): number;
set timeDetected(val: number);
/**
* Represents the D-Bus property "TimeMediaDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get time_media_detected(): number;
set time_media_detected(val: number);
/**
* Represents the D-Bus property "TimeMediaDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get timeMediaDetected(): number;
set timeMediaDetected(val: number);
/**
* Represents the D-Bus property "Vendor".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get vendor(): string;
set vendor(val: string);
/**
* Represents the D-Bus property "WWN".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get wwn(): string;
set wwn(val: string);
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): DriveProxy;
// Conflicted with Gio.DBusProxy.new_finish
new_finish(...args: never[]): any;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_eject(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_eject(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_eject(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_eject().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_eject().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_eject_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Eject() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_eject() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_eject_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_power_off(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_power_off(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_power_off(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_power_off().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_power_off().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_power_off_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PowerOff() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_power_off() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_power_off_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_set_configuration().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_set_configuration().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_set_configuration_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SetConfiguration() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_set_configuration() for the asynchronous version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_set_configuration_sync(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the Eject() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_eject(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the PowerOff() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_power_off(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SetConfiguration() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_set_configuration(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksDrive::handle-eject signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_eject(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDrive::handle-power-off signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_power_off(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDrive::handle-set-configuration signal.
* @param invocation
* @param arg_value
* @param arg_options
*/
vfunc_handle_set_configuration(
invocation: Gio.DBusMethodInvocation,
arg_value: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace DriveSkeleton {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusInterfaceSkeleton.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Drive.ConstructorProps {}
}
/**
* The #UDisksDriveSkeleton structure contains only private data and should only be accessed using the provided API.
*/
class DriveSkeleton extends Gio.DBusInterfaceSkeleton implements Gio.DBusInterface, Drive {
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): DriveSkeleton;
// Inherited properties
/**
* Represents the D-Bus property "CanPowerOff".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get can_power_off(): boolean;
set can_power_off(val: boolean);
/**
* Represents the D-Bus property "CanPowerOff".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get canPowerOff(): boolean;
set canPowerOff(val: boolean);
/**
* Represents the D-Bus property "Configuration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get configuration(): GLib.Variant;
set configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "ConnectionBus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get connection_bus(): string;
set connection_bus(val: string);
/**
* Represents the D-Bus property "ConnectionBus".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get connectionBus(): string;
set connectionBus(val: string);
/**
* Represents the D-Bus property "Ejectable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get ejectable(): boolean;
set ejectable(val: boolean);
/**
* Represents the D-Bus property "Id".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get id(): string;
set id(val: string);
/**
* Represents the D-Bus property "Media".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media(): string;
set media(val: string);
/**
* Represents the D-Bus property "MediaAvailable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_available(): boolean;
set media_available(val: boolean);
/**
* Represents the D-Bus property "MediaAvailable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaAvailable(): boolean;
set mediaAvailable(val: boolean);
/**
* Represents the D-Bus property "MediaChangeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_change_detected(): boolean;
set media_change_detected(val: boolean);
/**
* Represents the D-Bus property "MediaChangeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaChangeDetected(): boolean;
set mediaChangeDetected(val: boolean);
/**
* Represents the D-Bus property "MediaCompatibility".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_compatibility(): string[];
set media_compatibility(val: string[]);
/**
* Represents the D-Bus property "MediaCompatibility".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaCompatibility(): string[];
set mediaCompatibility(val: string[]);
/**
* Represents the D-Bus property "MediaRemovable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get media_removable(): boolean;
set media_removable(val: boolean);
/**
* Represents the D-Bus property "MediaRemovable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get mediaRemovable(): boolean;
set mediaRemovable(val: boolean);
/**
* Represents the D-Bus property "Model".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get model(): string;
set model(val: string);
/**
* Represents the D-Bus property "Optical".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical(): boolean;
set optical(val: boolean);
/**
* Represents the D-Bus property "OpticalBlank".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_blank(): boolean;
set optical_blank(val: boolean);
/**
* Represents the D-Bus property "OpticalBlank".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalBlank(): boolean;
set opticalBlank(val: boolean);
/**
* Represents the D-Bus property "OpticalNumAudioTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_audio_tracks(): number;
set optical_num_audio_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumAudioTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumAudioTracks(): number;
set opticalNumAudioTracks(val: number);
/**
* Represents the D-Bus property "OpticalNumDataTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_data_tracks(): number;
set optical_num_data_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumDataTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumDataTracks(): number;
set opticalNumDataTracks(val: number);
/**
* Represents the D-Bus property "OpticalNumSessions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_sessions(): number;
set optical_num_sessions(val: number);
/**
* Represents the D-Bus property "OpticalNumSessions".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumSessions(): number;
set opticalNumSessions(val: number);
/**
* Represents the D-Bus property "OpticalNumTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get optical_num_tracks(): number;
set optical_num_tracks(val: number);
/**
* Represents the D-Bus property "OpticalNumTracks".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get opticalNumTracks(): number;
set opticalNumTracks(val: number);
/**
* Represents the D-Bus property "Removable".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get removable(): boolean;
set removable(val: boolean);
/**
* Represents the D-Bus property "Revision".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get revision(): string;
set revision(val: string);
/**
* Represents the D-Bus property "RotationRate".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get rotation_rate(): number;
set rotation_rate(val: number);
/**
* Represents the D-Bus property "RotationRate".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get rotationRate(): number;
set rotationRate(val: number);
/**
* Represents the D-Bus property "Seat".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get seat(): string;
set seat(val: string);
/**
* Represents the D-Bus property "Serial".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get serial(): string;
set serial(val: string);
/**
* Represents the D-Bus property "SiblingId".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sibling_id(): string;
set sibling_id(val: string);
/**
* Represents the D-Bus property "SiblingId".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get siblingId(): string;
set siblingId(val: string);
/**
* Represents the D-Bus property "Size".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get size(): number;
set size(val: number);
/**
* Represents the D-Bus property "SortKey".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sort_key(): string;
set sort_key(val: string);
/**
* Represents the D-Bus property "SortKey".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get sortKey(): string;
set sortKey(val: string);
/**
* Represents the D-Bus property "TimeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get time_detected(): number;
set time_detected(val: number);
/**
* Represents the D-Bus property "TimeDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get timeDetected(): number;
set timeDetected(val: number);
/**
* Represents the D-Bus property "TimeMediaDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get time_media_detected(): number;
set time_media_detected(val: number);
/**
* Represents the D-Bus property "TimeMediaDetected".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get timeMediaDetected(): number;
set timeMediaDetected(val: number);
/**
* Represents the D-Bus property "Vendor".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get vendor(): string;
set vendor(val: string);
/**
* Represents the D-Bus property "WWN".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get wwn(): string;
set wwn(val: string);
// Inherited methods
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_eject(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_eject(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Eject() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_eject_finish() to get the result of the operation.
*
* See udisks_drive_call_eject_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_eject(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_eject().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_eject().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_eject_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Eject() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_eject() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_eject_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_power_off(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_power_off(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the PowerOff() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_power_off_finish() to get the result of the operation.
*
* See udisks_drive_call_power_off_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_power_off(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_power_off().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_power_off().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_power_off_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the PowerOff() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_power_off() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_power_off_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the SetConfiguration() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_drive_call_set_configuration_finish() to get the result of the operation.
*
* See udisks_drive_call_set_configuration_sync() for the synchronous, blocking version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_set_configuration(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_drive_call_set_configuration().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_drive_call_set_configuration().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_set_configuration_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the SetConfiguration() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_drive_call_set_configuration() for the asynchronous version of this method.
* @param arg_value Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_set_configuration_sync(
arg_value: GLib.Variant,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Helper function used in service implementations to finish handling invocations of the Eject() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_eject(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the PowerOff() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_power_off(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the SetConfiguration() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_set_configuration(invocation: Gio.DBusMethodInvocation): void;
/**
* Handler for the #UDisksDrive::handle-eject signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_eject(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDrive::handle-power-off signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_power_off(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksDrive::handle-set-configuration signal.
* @param invocation
* @param arg_value
* @param arg_options
*/
vfunc_handle_set_configuration(
invocation: Gio.DBusMethodInvocation,
arg_value: GLib.Variant,
arg_options: GLib.Variant,
): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace EncryptedProxy {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusProxy.ConstructorProps,
Gio.AsyncInitable.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Gio.Initable.ConstructorProps,
Encrypted.ConstructorProps {}
}
/**
* The #UDisksEncryptedProxy structure contains only private data and should only be accessed using the provided API.
*/
class EncryptedProxy
extends Gio.DBusProxy
implements Gio.AsyncInitable, Gio.DBusInterface, Gio.Initable, Encrypted
{
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static new_finish(res: Gio.AsyncResult): EncryptedProxy;
// Conflicted with Gio.AsyncInitable.new_finish
static new_finish(...args: never[]): any;
static new_for_bus_finish(res: Gio.AsyncResult): EncryptedProxy;
static new_for_bus_sync(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
): EncryptedProxy;
// Conflicted with Gio.DBusProxy.new_for_bus_sync
static new_for_bus_sync(...args: never[]): any;
static new_sync(
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
): EncryptedProxy;
// Conflicted with Gio.DBusProxy.new_sync
static new_sync(...args: never[]): any;
// Static methods
/**
* Asynchronously creates a proxy for the D-Bus interface org.freedesktop.UDisks2.Encrypted. See g_dbus_proxy_new() for more details.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_proxy_new_finish() to get the result of the operation.
*
* See udisks_encrypted_proxy_new_sync() for the synchronous, blocking version of this constructor.
* @param connection A #GDBusConnection.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static ['new'](
connection: Gio.DBusConnection,
flags: Gio.DBusProxyFlags,
name: string | null,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new
static ['new'](...args: never[]): any;
/**
* Like udisks_encrypted_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
*
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_proxy_new_for_bus_finish() to get the result of the operation.
*
* See udisks_encrypted_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
* @param bus_type A #GBusType.
* @param flags Flags from the #GDBusProxyFlags enumeration.
* @param name A bus name (well-known or unique).
* @param object_path An object path.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied.
*/
static new_for_bus(
bus_type: Gio.BusType,
flags: Gio.DBusProxyFlags,
name: string,
object_path: string,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
// Conflicted with Gio.DBusProxy.new_for_bus
static new_for_bus(...args: never[]): any;
// Inherited properties
/**
* Represents the D-Bus property "ChildConfiguration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get child_configuration(): GLib.Variant;
set child_configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "ChildConfiguration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get childConfiguration(): GLib.Variant;
set childConfiguration(val: GLib.Variant);
/**
* Represents the D-Bus property "CleartextDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cleartext_device(): string;
set cleartext_device(val: string);
/**
* Represents the D-Bus property "CleartextDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cleartextDevice(): string;
set cleartextDevice(val: string);
/**
* Represents the D-Bus property "HintEncryptionType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_encryption_type(): string;
set hint_encryption_type(val: string);
/**
* Represents the D-Bus property "HintEncryptionType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintEncryptionType(): string;
set hintEncryptionType(val: string);
/**
* Represents the D-Bus property "MetadataSize".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get metadata_size(): number;
set metadata_size(val: number);
/**
* Represents the D-Bus property "MetadataSize".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get metadataSize(): number;
set metadataSize(val: number);
// Inherited methods
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
init_async(io_priority: number, cancellable?: Gio.Cancellable | null): Promise;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init_finish(res: Gio.AsyncResult): boolean;
/**
* Finishes the async construction for the various g_async_initable_new
* calls, returning the created object or %NULL on error.
* @param res the #GAsyncResult from the callback
* @returns a newly created #GObject, or %NULL on error. Free with g_object_unref().
*/
new_finish(res: Gio.AsyncResult): EncryptedProxy;
// Conflicted with Gio.DBusProxy.new_finish
new_finish(...args: never[]): any;
/**
* Starts asynchronous initialization of the object implementing the
* interface. This must be done before any real use of the object after
* initial construction. If the object also implements #GInitable you can
* optionally call g_initable_init() instead.
*
* This method is intended for language bindings. If writing in C,
* g_async_initable_new_async() should typically be used instead.
*
* When the initialization is finished, `callback` will be called. You can
* then call g_async_initable_init_finish() to get the result of the
* initialization.
*
* Implementations may also support cancellation. If `cancellable` is not
* %NULL, then initialization can be cancelled by triggering the cancellable
* object from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL, and
* the object doesn't support cancellable initialization, the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* As with #GInitable, if the object is not initialized, or initialization
* returns with an error, then all operations on the object except
* g_object_ref() and g_object_unref() are considered to be invalid, and
* have undefined behaviour. They will often fail with g_critical() or
* g_warning(), but this must not be relied on.
*
* Callers should not assume that a class which implements #GAsyncInitable can
* be initialized multiple times; for more information, see g_initable_init().
* If a class explicitly supports being initialized multiple times,
* implementation requires yielding all subsequent calls to init_async() on the
* results of the first call.
*
* For classes that also support the #GInitable interface, the default
* implementation of this method will run the g_initable_init() function
* in a thread, so if you want to support asynchronous initialization via
* threads, just implement the #GAsyncInitable interface without overriding
* any interface methods.
* @param io_priority the [I/O priority](iface.AsyncResult.html#io-priority) of the operation
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @param callback a #GAsyncReadyCallback to call when the request is satisfied
*/
vfunc_init_async(
io_priority: number,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): void;
/**
* Finishes asynchronous initialization and returns the result.
* See g_async_initable_init_async().
* @param res a #GAsyncResult.
*/
vfunc_init_finish(res: Gio.AsyncResult): boolean;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
* @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
*/
init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Initializes the object implementing the interface.
*
* This method is intended for language bindings. If writing in C,
* g_initable_new() should typically be used instead.
*
* The object must be initialized before any real use after initial
* construction, either with this function or g_async_initable_init_async().
*
* Implementations may also support cancellation. If `cancellable` is not %NULL,
* then initialization can be cancelled by triggering the cancellable object
* from another thread. If the operation was cancelled, the error
* %G_IO_ERROR_CANCELLED will be returned. If `cancellable` is not %NULL and
* the object doesn't support cancellable initialization the error
* %G_IO_ERROR_NOT_SUPPORTED will be returned.
*
* If the object is not initialized, or initialization returns with an
* error, then all operations on the object except g_object_ref() and
* g_object_unref() are considered to be invalid, and have undefined
* behaviour. See the [description][iface`Gio`.Initable#description] for more details.
*
* Callers should not assume that a class which implements #GInitable can be
* initialized multiple times, unless the class explicitly documents itself as
* supporting this. Generally, a class’ implementation of init() can assume
* (and assert) that it will only be called once. Previously, this documentation
* recommended all #GInitable implementations should be idempotent; that
* recommendation was relaxed in GLib 2.54.
*
* If a class explicitly supports being initialized multiple times, it is
* recommended that the method is idempotent: multiple calls with the same
* arguments should return the same results. Only the first call initializes
* the object; further calls return the result of the first call.
*
* One reason why a class might need to support idempotent initialization is if
* it is designed to be used via the singleton pattern, with a
* #GObjectClass.constructor that sometimes returns an existing instance.
* In this pattern, a caller would expect to be able to call g_initable_init()
* on the result of g_object_new(), regardless of whether it is in fact a new
* instance.
* @param cancellable optional #GCancellable object, %NULL to ignore.
*/
vfunc_init(cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_encrypted_call_change_passphrase().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_encrypted_call_change_passphrase().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_change_passphrase_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the ChangePassphrase() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_encrypted_call_change_passphrase() for the asynchronous version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_change_passphrase_sync(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Lock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_lock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_lock_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_lock(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Lock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_lock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_lock_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_lock(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Lock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_lock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_lock_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_lock(
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_encrypted_call_lock().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_encrypted_call_lock().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_lock_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Lock() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_encrypted_call_lock() for the asynchronous version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_lock_sync(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): boolean;
/**
* Asynchronously invokes the Resize() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_resize_finish() to get the result of the operation.
*
* See udisks_encrypted_call_resize_sync() for the synchronous, blocking version of this method.
* @param arg_size Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_resize(
arg_size: number,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the Resize() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_resize_finish() to get the result of the operation.
*
* See udisks_encrypted_call_resize_sync() for the synchronous, blocking version of this method.
* @param arg_size Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_resize(
arg_size: number,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Resize() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_resize_finish() to get the result of the operation.
*
* See udisks_encrypted_call_resize_sync() for the synchronous, blocking version of this method.
* @param arg_size Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_resize(
arg_size: number,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_encrypted_call_resize().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_encrypted_call_resize().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_resize_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the Resize() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_encrypted_call_resize() for the asynchronous version of this method.
* @param arg_size Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_resize_sync(
arg_size: number,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Unlock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_unlock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_unlock_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_unlock(
arg_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the Unlock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_unlock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_unlock_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_unlock(
arg_passphrase: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the Unlock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_unlock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_unlock_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_unlock(
arg_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_encrypted_call_unlock().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_encrypted_call_unlock().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_unlock_finish(res: Gio.AsyncResult): [boolean, string];
/**
* Synchronously invokes the Unlock() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_encrypted_call_unlock() for the asynchronous version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_unlock_sync(
arg_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): [boolean, string];
/**
* Helper function used in service implementations to finish handling invocations of the ChangePassphrase() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_change_passphrase(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Lock() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_lock(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Resize() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
*/
complete_resize(invocation: Gio.DBusMethodInvocation): void;
/**
* Helper function used in service implementations to finish handling invocations of the Unlock() D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
*
* This method will free `invocation,` you cannot use it afterwards.
* @param invocation A #GDBusMethodInvocation.
* @param cleartext_device Parameter to return.
*/
complete_unlock(invocation: Gio.DBusMethodInvocation, cleartext_device: string): void;
/**
* Handler for the #UDisksEncrypted::handle-change-passphrase signal.
* @param invocation
* @param arg_passphrase
* @param arg_new_passphrase
* @param arg_options
*/
vfunc_handle_change_passphrase(
invocation: Gio.DBusMethodInvocation,
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksEncrypted::handle-lock signal.
* @param invocation
* @param arg_options
*/
vfunc_handle_lock(invocation: Gio.DBusMethodInvocation, arg_options: GLib.Variant): boolean;
/**
* Handler for the #UDisksEncrypted::handle-resize signal.
* @param invocation
* @param arg_size
* @param arg_options
*/
vfunc_handle_resize(
invocation: Gio.DBusMethodInvocation,
arg_size: number,
arg_options: GLib.Variant,
): boolean;
/**
* Handler for the #UDisksEncrypted::handle-unlock signal.
* @param invocation
* @param arg_passphrase
* @param arg_options
*/
vfunc_handle_unlock(
invocation: Gio.DBusMethodInvocation,
arg_passphrase: string,
arg_options: GLib.Variant,
): boolean;
/**
* Creates a binding between `source_property` on `source` and `target_property`
* on `target`.
*
* Whenever the `source_property` is changed the `target_property` is
* updated using the same value. For instance:
*
*
* ```c
* g_object_bind_property (action, "active", widget, "sensitive", 0);
* ```
*
*
* Will result in the "sensitive" property of the widget #GObject instance to be
* updated with the same value of the "active" property of the action #GObject
* instance.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well.
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. To remove the binding without affecting the
* `source` and the `target` you can just call g_object_unref() on the returned
* #GBinding instance.
*
* Removing the binding by calling g_object_unref() on it must only be done if
* the binding, `source` and `target` are only used from a single thread and it
* is clear that both `source` and `target` outlive the binding. Especially it
* is not safe to rely on this if the binding, `source` or `target` can be
* finalized from different threads. Keep another reference to the binding and
* use g_binding_unbind() instead to be on the safe side.
*
* A #GObject can have multiple bindings.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
): GObject.Binding;
/**
* Complete version of g_object_bind_property().
*
* Creates a binding between `source_property` on `source` and `target_property`
* on `target,` allowing you to set the transformation functions to be used by
* the binding.
*
* If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
* if `target_property` on `target` changes then the `source_property` on `source`
* will be updated as well. The `transform_from` function is only used in case
* of bidirectional bindings, otherwise it will be ignored
*
* The binding will automatically be removed when either the `source` or the
* `target` instances are finalized. This will release the reference that is
* being held on the #GBinding instance; if you want to hold on to the
* #GBinding instance, you will need to hold a reference to it.
*
* To remove the binding, call g_binding_unbind().
*
* A #GObject can have multiple bindings.
*
* The same `user_data` parameter will be used for both `transform_to`
* and `transform_from` transformation functions; the `notify` function will
* be called once, when the binding is removed. If you need different data
* for each transformation function, please use
* g_object_bind_property_with_closures() instead.
* @param source_property the property on @source to bind
* @param target the target #GObject
* @param target_property the property on @target to bind
* @param flags flags to pass to #GBinding
* @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
* @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
* @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
* @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
*/
bind_property_full(
source_property: string,
target: GObject.Object,
target_property: string,
flags: GObject.BindingFlags | null,
transform_to?: GObject.BindingTransformFunc | null,
transform_from?: GObject.BindingTransformFunc | null,
notify?: GLib.DestroyNotify | null,
): GObject.Binding;
// Conflicted with GObject.Object.bind_property_full
bind_property_full(...args: never[]): any;
/**
* This function is intended for #GObject implementations to re-enforce
* a [floating][floating-ref] object reference. Doing this is seldom
* required: all #GInitiallyUnowneds are created with a floating reference
* which usually just needs to be sunken by calling g_object_ref_sink().
*/
force_floating(): void;
/**
* Increases the freeze count on `object`. If the freeze count is
* non-zero, the emission of "notify" signals on `object` is
* stopped. The signals are queued until the freeze count is decreased
* to zero. Duplicate notifications are squashed so that at most one
* #GObject::notify signal is emitted for each property modified while the
* object is frozen.
*
* This is necessary for accessors that modify multiple properties to prevent
* premature notification while the object is still being modified.
*/
freeze_notify(): void;
/**
* Gets a named field from the objects table of associations (see g_object_set_data()).
* @param key name of the key for that association
* @returns the data if found, or %NULL if no such data exists.
*/
get_data(key: string): any | null;
/**
* Gets a property of an object.
*
* The value can be:
* - an empty GObject.Value initialized by G_VALUE_INIT, which will be automatically initialized with the expected type of the property (since GLib 2.60)
* - a GObject.Value initialized with the expected type of the property
* - a GObject.Value initialized with a type to which the expected type of the property can be transformed
*
* In general, a copy is made of the property contents and the caller is responsible for freeing the memory by calling GObject.Value.unset.
*
* Note that GObject.Object.get_property is really intended for language bindings, GObject.Object.get is much more convenient for C programming.
* @param property_name The name of the property to get
* @param value Return location for the property value. Can be an empty GObject.Value initialized by G_VALUE_INIT (auto-initialized with expected type since GLib 2.60), a GObject.Value initialized with the expected property type, or a GObject.Value initialized with a transformable type
*/
get_property(property_name: string, value: GObject.Value | any): any;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
get_qdata(quark: GLib.Quark): any | null;
/**
* Gets `n_properties` properties for an `object`.
* Obtained properties will be set to `values`. All properties must be valid.
* Warnings will be emitted and undefined behaviour may result if invalid
* properties are passed in.
* @param names the names of each property to get
* @param values the values of each property to get
*/
getv(names: string[], values: (GObject.Value | any)[]): void;
/**
* Checks whether `object` has a [floating][floating-ref] reference.
* @returns %TRUE if @object has a floating reference
*/
is_floating(): boolean;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param property_name the name of a property installed on the class of @object.
*/
notify(property_name: string): void;
/**
* Emits a "notify" signal for the property specified by `pspec` on `object`.
*
* This function omits the property name lookup, hence it is faster than
* g_object_notify().
*
* One way to avoid using g_object_notify() from within the
* class that registered the properties, and using g_object_notify_by_pspec()
* instead, is to store the GParamSpec used with
* g_object_class_install_property() inside a static array, e.g.:
*
*
* ```c
* typedef enum
* {
* PROP_FOO = 1,
* PROP_LAST
* } MyObjectProperty;
*
* static GParamSpec *properties[PROP_LAST];
*
* static void
* my_object_class_init (MyObjectClass *klass)
* {
* properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
* 0, 100,
* 50,
* G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
* g_object_class_install_property (gobject_class,
* PROP_FOO,
* properties[PROP_FOO]);
* }
* ```
*
*
* and then notify a change on the "foo" property with:
*
*
* ```c
* g_object_notify_by_pspec (self, properties[PROP_FOO]);
* ```
*
* @param pspec the #GParamSpec of a property installed on the class of @object.
*/
notify_by_pspec(pspec: GObject.ParamSpec): void;
/**
* Increases the reference count of `object`.
*
* Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
* of `object` will be propagated to the return type (using the GCC typeof()
* extension), so any casting the caller needs to do on the return type must be
* explicit.
* @returns the same @object
*/
ref(): GObject.Object;
/**
* Increase the reference count of `object,` and possibly remove the
* [floating][floating-ref] reference, if `object` has a floating reference.
*
* In other words, if the object is floating, then this call "assumes
* ownership" of the floating reference, converting it to a normal
* reference by clearing the floating flag while leaving the reference
* count unchanged. If the object is not floating, then this call
* adds a new normal reference increasing the reference count by one.
*
* Since GLib 2.56, the type of `object` will be propagated to the return type
* under the same conditions as for g_object_ref().
* @returns @object
*/
ref_sink(): GObject.Object;
/**
* Releases all references to other objects. This can be used to break
* reference cycles.
*
* This function should only be called from object system implementations.
*/
run_dispose(): void;
/**
* Each object carries around a table of associations from
* strings to pointers. This function lets you set an association.
*
* If the object already had an association with that name,
* the old association will be destroyed.
*
* Internally, the `key` is converted to a #GQuark using g_quark_from_string().
* This means a copy of `key` is kept permanently (even after `object` has been
* finalized) — so it is recommended to only use a small, bounded set of values
* for `key` in your program, to avoid the #GQuark storage growing unbounded.
* @param key name of the key
* @param data data to associate with that key
*/
set_data(key: string, data?: any | null): void;
/**
* Sets a property on an object.
* @param property_name The name of the property to set
* @param value The value to set the property to
*/
set_property(property_name: string, value: GObject.Value | any): void;
/**
* Remove a specified datum from the object's data associations,
* without invoking the association's destroy handler.
* @param key name of the key
* @returns the data if found, or %NULL if no such data exists.
*/
steal_data(key: string): any | null;
/**
* This function gets back user data pointers stored via
* g_object_set_qdata() and removes the `data` from object
* without invoking its destroy() function (if any was
* set).
* Usually, calling this function is only required to update
* user data pointers with a destroy notifier, for example:
*
* ```c
* void
* object_add_to_user_list (GObject *object,
* const gchar *new_string)
* {
* // the quark, naming the object data
* GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
* // retrieve the old string list
* GList *list = g_object_steal_qdata (object, quark_string_list);
*
* // prepend new string
* list = g_list_prepend (list, g_strdup (new_string));
* // this changed 'list', so we need to set it again
* g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
* }
* static void
* free_string_list (gpointer data)
* {
* GList *node, *list = data;
*
* for (node = list; node; node = node->next)
* g_free (node->data);
* g_list_free (list);
* }
* ```
*
* Using g_object_get_qdata() in the above example, instead of
* g_object_steal_qdata() would have left the destroy function set,
* and thus the partial string list would have been freed upon
* g_object_set_qdata_full().
* @param quark A #GQuark, naming the user data pointer
* @returns The user data pointer set, or %NULL
*/
steal_qdata(quark: GLib.Quark): any | null;
/**
* Reverts the effect of a previous call to
* g_object_freeze_notify(). The freeze count is decreased on `object`
* and when it reaches zero, queued "notify" signals are emitted.
*
* Duplicate notifications for each property are squashed so that at most one
* #GObject::notify signal is emitted for each property, in the reverse order
* in which they have been queued.
*
* It is an error to call this function when the freeze count is zero.
*/
thaw_notify(): void;
/**
* Decreases the reference count of `object`. When its reference count
* drops to 0, the object is finalized (i.e. its memory is freed).
*
* If the pointer to the #GObject may be reused in future (for example, if it is
* an instance variable of another object), it is recommended to clear the
* pointer to %NULL rather than retain a dangling pointer to a potentially
* invalid #GObject instance. Use g_clear_object() for this.
*/
unref(): void;
/**
* This function essentially limits the life time of the `closure` to
* the life time of the object. That is, when the object is finalized,
* the `closure` is invalidated by calling g_closure_invalidate() on
* it, in order to prevent invocations of the closure with a finalized
* (nonexisting) object. Also, g_object_ref() and g_object_unref() are
* added as marshal guards to the `closure,` to ensure that an extra
* reference count is held on `object` during invocation of the
* `closure`. Usually, this function will be called on closures that
* use this `object` as closure data.
* @param closure #GClosure to watch
*/
watch_closure(closure: GObject.Closure): void;
/**
* the `constructed` function is called by g_object_new() as the
* final step of the object creation process. At the point of the call, all
* construction properties have been set on the object. The purpose of this
* call is to allow for object initialisation steps that can only be performed
* after construction properties have been set. `constructed` implementors
* should chain up to the `constructed` call of their parent class to allow it
* to complete its initialisation.
*/
vfunc_constructed(): void;
/**
* emits property change notification for a bunch
* of properties. Overriding `dispatch_properties_changed` should be rarely
* needed.
* @param n_pspecs
* @param pspecs
*/
vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
/**
* the `dispose` function is supposed to drop all references to other
* objects, but keep the instance otherwise intact, so that client method
* invocations still work. It may be run multiple times (due to reference
* loops). Before returning, `dispose` should chain up to the `dispose` method
* of the parent class.
*/
vfunc_dispose(): void;
/**
* instance finalization function, should finish the finalization of
* the instance begun in `dispose` and chain up to the `finalize` method of the
* parent class.
*/
vfunc_finalize(): void;
/**
* the generic getter for all properties of this type. Should be
* overridden for every type with properties.
* @param property_id
* @param value
* @param pspec
*/
vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Emits a "notify" signal for the property `property_name` on `object`.
*
* When possible, eg. when signaling a property change from within the class
* that registered the property, you should use g_object_notify_by_pspec()
* instead.
*
* Note that emission of the notify signal may be blocked with
* g_object_freeze_notify(). In this case, the signal emissions are queued
* and will be emitted (in reverse order) when g_object_thaw_notify() is
* called.
* @param pspec
*/
vfunc_notify(pspec: GObject.ParamSpec): void;
/**
* the generic setter for all properties of this type. Should be
* overridden for every type with properties. If implementations of
* `set_property` don't emit property change notification explicitly, this will
* be done implicitly by the type system. However, if the notify signal is
* emitted explicitly, the type system will not emit it a second time.
* @param property_id
* @param value
* @param pspec
*/
vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
/**
* Disconnects a handler from an instance so it will not be called during any future or currently ongoing emissions of the signal it has been connected to.
* @param id Handler ID of the handler to be disconnected
*/
disconnect(id: number): void;
/**
* Sets multiple properties of an object at once. The properties argument should be a dictionary mapping property names to values.
* @param properties Object containing the properties to set
*/
set(properties: { [key: string]: any }): void;
/**
* Blocks a handler of an instance so it will not be called during any signal emissions
* @param id Handler ID of the handler to be blocked
*/
block_signal_handler(id: number): void;
/**
* Unblocks a handler so it will be called again during any signal emissions
* @param id Handler ID of the handler to be unblocked
*/
unblock_signal_handler(id: number): void;
/**
* Stops a signal's emission by the given signal name. This will prevent the default handler and any subsequent signal handlers from being invoked.
* @param detailedName Name of the signal to stop emission of
*/
stop_emission_by_name(detailedName: string): void;
}
namespace EncryptedSkeleton {
// Constructor properties interface
interface ConstructorProps
extends Gio.DBusInterfaceSkeleton.ConstructorProps,
Gio.DBusInterface.ConstructorProps,
Encrypted.ConstructorProps {}
}
/**
* The #UDisksEncryptedSkeleton structure contains only private data and should only be accessed using the provided API.
*/
class EncryptedSkeleton extends Gio.DBusInterfaceSkeleton implements Gio.DBusInterface, Encrypted {
static $gtype: GObject.GType;
// Constructors
constructor(properties?: Partial, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): EncryptedSkeleton;
// Inherited properties
/**
* Represents the D-Bus property "ChildConfiguration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get child_configuration(): GLib.Variant;
set child_configuration(val: GLib.Variant);
/**
* Represents the D-Bus property "ChildConfiguration".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get childConfiguration(): GLib.Variant;
set childConfiguration(val: GLib.Variant);
/**
* Represents the D-Bus property "CleartextDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cleartext_device(): string;
set cleartext_device(val: string);
/**
* Represents the D-Bus property "CleartextDevice".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get cleartextDevice(): string;
set cleartextDevice(val: string);
/**
* Represents the D-Bus property "HintEncryptionType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hint_encryption_type(): string;
set hint_encryption_type(val: string);
/**
* Represents the D-Bus property "HintEncryptionType".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get hintEncryptionType(): string;
set hintEncryptionType(val: string);
/**
* Represents the D-Bus property "MetadataSize".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get metadata_size(): number;
set metadata_size(val: number);
/**
* Represents the D-Bus property "MetadataSize".
*
* Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
*/
get metadataSize(): number;
set metadataSize(val: number);
// Inherited methods
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
* @returns A #GDBusObject or %NULL. The returned reference should be freed with g_object_unref().
*/
get_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
* @returns A #GDBusInterfaceInfo. Do not free.
*/
get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
set_object(object?: Gio.DBusObject | null): void;
/**
* Gets the #GDBusObject that `interface_` belongs to, if any.
*/
vfunc_dup_object(): Gio.DBusObject | null;
/**
* Gets D-Bus introspection information for the D-Bus interface
* implemented by `interface_`.
*/
vfunc_get_info(): Gio.DBusInterfaceInfo;
/**
* Sets the #GDBusObject for `interface_` to `object`.
*
* Note that `interface_` will hold a weak reference to `object`.
* @param object A #GDBusObject or %NULL.
*/
vfunc_set_object(object?: Gio.DBusObject | null): void;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): Promise;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the ChangePassphrase() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_change_passphrase_finish() to get the result of the operation.
*
* See udisks_encrypted_call_change_passphrase_sync() for the synchronous, blocking version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_change_passphrase(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
callback?: Gio.AsyncReadyCallback | null,
): Promise | void;
/**
* Finishes an operation started with udisks_encrypted_call_change_passphrase().
* @param res The #GAsyncResult obtained from the #GAsyncReadyCallback passed to udisks_encrypted_call_change_passphrase().
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_change_passphrase_finish(res: Gio.AsyncResult): boolean;
/**
* Synchronously invokes the ChangePassphrase() D-Bus method on `proxy`. The calling thread is blocked until a reply is received.
*
* See udisks_encrypted_call_change_passphrase() for the asynchronous version of this method.
* @param arg_passphrase Argument to pass with the method invocation.
* @param arg_new_passphrase Argument to pass with the method invocation.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @returns %TRUE if the call succeeded, %FALSE if @error is set.
*/
call_change_passphrase_sync(
arg_passphrase: string,
arg_new_passphrase: string,
arg_options: GLib.Variant,
cancellable?: Gio.Cancellable | null,
): boolean;
/**
* Asynchronously invokes the Lock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_lock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_lock_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
*/
call_lock(arg_options: GLib.Variant, cancellable?: Gio.Cancellable | null): Promise;
/**
* Asynchronously invokes the Lock() D-Bus method on `proxy`.
* When the operation is finished, `callback` will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
* You can then call udisks_encrypted_call_lock_finish() to get the result of the operation.
*
* See udisks_encrypted_call_lock_sync() for the synchronous, blocking version of this method.
* @param arg_options Argument to pass with the method invocation.
* @param cancellable A #GCancellable or %NULL.
* @param callback A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
*/
call_lock(
arg_options: GLib.Variant,
cancellable: Gio.Cancellable | null,
callback: Gio.AsyncReadyCallback | null,
): void;
/**
* Asynchronously invokes the