ide-device-manager

ide-device-manager

Functions

Properties

IdeDevice * device Read / Write
gdouble progress Read

Signals

void deploy-finished Run Last
void deploy-started Run Last

Types and Values

Object Hierarchy

    GObject
    ╰── IdeObject
        ╰── IdeDeviceManager

Implemented Interfaces

IdeDeviceManager implements GActionGroup and GListModel.

Description

Functions

ide_device_manager_get_progress ()

gdouble
ide_device_manager_get_progress (IdeDeviceManager *self);

ide_device_manager_get_device ()

IdeDevice *
ide_device_manager_get_device (IdeDeviceManager *self);

Gets the currently selected device. Usually, this is an IdeLocalDevice.

Parameters

self

a IdeDeviceManager

 

Returns

an IdeDevice.

[transfer none][not nullable]

Since: 3.28


ide_device_manager_set_device ()

void
ide_device_manager_set_device (IdeDeviceManager *self,
                               IdeDevice *device);

Sets the “device” property, which is the currently selected device. Builder uses this to determine how to build the current project for the devices architecture and operating system.

If device is NULL, the local device will be used.

Parameters

self

an IdeDeviceManager

 

device

an IdeDevice or NULL.

[nullable]

Since: 3.28


ide_device_manager_get_device_by_id ()

IdeDevice *
ide_device_manager_get_device_by_id (IdeDeviceManager *self,
                                     const gchar *device_id);

Fetches the first device that matches the device identifier device_id .

Parameters

self

an IdeDeviceManager

 

device_id

The device identifier string.

 

Returns

An IdeDevice or NULL.

[transfer none]


ide_device_manager_deploy_async ()

void
ide_device_manager_deploy_async (IdeDeviceManager *self,
                                 IdeBuildPipeline *pipeline,
                                 GCancellable *cancellable,
                                 GAsyncReadyCallback callback,
                                 gpointer user_data);

Requests that the application be deployed to the device. This may need to be done before running the application so that the device has the most up to date build.

Parameters

self

a IdeDeviceManager

 

pipeline

an IdeBuildPipeline

 

cancellable

a GCancellable, or NULL

 

callback

a GAsyncReadyCallback

 

user_data

closure data for callback

 

Since: 3.28


ide_device_manager_deploy_finish ()

gboolean
ide_device_manager_deploy_finish (IdeDeviceManager *self,
                                  GAsyncResult *result,
                                  GError **error);

Completes a request to deploy the application to the device.

Parameters

self

a IdeDeviceManager

 

result

a GAsyncResult provided to callback

 

error

a location for a GError, or NULL

 

Returns

TRUE if successful; otherwise FALSE and error is set

Since: 3.28

Types and Values

IDE_TYPE_DEVICE_MANAGER

#define IDE_TYPE_DEVICE_MANAGER (ide_device_manager_get_type())

IdeDeviceManager

typedef struct _IdeDeviceManager IdeDeviceManager;

Property Details

The “device” property

  “device”                   IdeDevice *

The "device" property indicates the currently selected device by the user. This is the device we will try to deploy to when running, and execute the application on.

Flags: Read / Write

Since: 3.28


The “progress” property

  “progress”                 gdouble

The "progress" property is updated with a value between 0.0 and 1.0 while the deployment is in progress.

Flags: Read

Allowed values: [0,1]

Default value: 0

Since: 3.28

Signal Details

The “deploy-finished” signal

void
user_function (IdeDeviceManager *idedevicemanager,
               gpointer          user_data)

Flags: Run Last


The “deploy-started” signal

void
user_function (IdeDeviceManager *idedevicemanager,
               gpointer          user_data)

Flags: Run Last