IdeTransfer: Builder SDK Reference

## IdeTransfer IdeTransfer |

## Functions

GQuark | ide_transfer_error_quark ()
void | ide_transfer_cancel ()
gboolean | ide_transfer_get_completed ()
gboolean | ide_transfer_get_active ()
const gchar * | ide_transfer_get_icon_name ()
void | ide_transfer_set_icon_name ()
gdouble | ide_transfer_get_progress ()
void | ide_transfer_set_progress ()
const gchar * | ide_transfer_get_status ()
void | ide_transfer_set_status ()
const gchar * | ide_transfer_get_title ()
void | ide_transfer_set_title ()
void | ide_transfer_execute_async ()
gboolean | ide_transfer_execute_finish ()
IdeNotification * | ide_transfer_create_notification ()

## Properties

gboolean | active | Read
gboolean | completed | Read
char * | icon-name | Read / Write
double | progress | Read / Write
char * | status | Read / Write
char * | title | Read / Write

## Signals

void | cancelled | Run Last

## Types and Values

#define | IDE_TYPE_TRANSFER
#define | IDE_TRANSFER_ERROR
struct | IdeTransferClass
enum | IdeTransferError
| IdeTransfer

## Object Hierarchy

        GObject
        ╰── IdeObject
            ╰── IdeTransfer
                ╰── IdePkconTransfer

## Description

## Functions

### ide_transfer_error_quark ()

    GQuark
    ide_transfer_error_quark (void);

### ide_transfer_cancel ()

    void
    ide_transfer_cancel (IdeTransfer *self);

### ide_transfer_get_completed ()

    gboolean
    ide_transfer_get_completed (IdeTransfer *self);

### ide_transfer_get_active ()

    gboolean
    ide_transfer_get_active (IdeTransfer *self);

### ide_transfer_get_icon_name ()

    const gchar *
    ide_transfer_get_icon_name (IdeTransfer *self);

### ide_transfer_set_icon_name ()

    void
    ide_transfer_set_icon_name (IdeTransfer *self,
                                const gchar *icon_name);

### ide_transfer_get_progress ()

    gdouble
    ide_transfer_get_progress (IdeTransfer *self);

### ide_transfer_set_progress ()

    void
    ide_transfer_set_progress (IdeTransfer *self,
                               gdouble progress);

### ide_transfer_get_status ()

    const gchar *
    ide_transfer_get_status (IdeTransfer *self);

### ide_transfer_set_status ()

    void
    ide_transfer_set_status (IdeTransfer *self,
                             const gchar *status);

### ide_transfer_get_title ()

    const gchar *
    ide_transfer_get_title (IdeTransfer *self);

### ide_transfer_set_title ()

    void
    ide_transfer_set_title (IdeTransfer *self,
                            const gchar *title);

### ide_transfer_execute_async ()

    void
    ide_transfer_execute_async (IdeTransfer *self,
                                GCancellable *cancellable,
                                GAsyncReadyCallback callback,
                                gpointer user_data);

### ide_transfer_execute_finish ()

    gboolean
    ide_transfer_execute_finish (IdeTransfer *self,
                                 GAsyncResult *result,
                                 GError **error);

### ide_transfer_create_notification ()

    IdeNotification *
    ide_transfer_create_notification (IdeTransfer *self);

Creates a new IdeNotification that is updated with the progress of the IdeTransfer. This is useful when you need to bridge an IdeTransfer into something that can be displayed to the user.

If the transfer has completed, `NULL` is returned.

#### Parameters

self | a IdeTransfer |

#### Returns

an IdeNotification or `NULL`.

[transfer full][nullable]

Since: 3.32

## Types and Values

### IDE_TYPE_TRANSFER

    #define IDE_TYPE_TRANSFER  (ide_transfer_get_type())

### IDE_TRANSFER_ERROR

    #define IDE_TRANSFER_ERROR (ide_transfer_error_quark())

### struct IdeTransferClass

    struct IdeTransferClass {
      IdeObjectClass parent_class;

      void     (*execute_async)  (IdeTransfer          *self,
                                  GCancellable         *cancellable,
                                  GAsyncReadyCallback   callback,
                                  gpointer              user_data);
      gboolean (*execute_finish) (IdeTransfer          *self,
                                  GAsyncResult         *result,
                                  GError              **error);
    };

### enum IdeTransferError

#### Members

IDE_TRANSFER_ERROR_UNKNOWN |  |
IDE_TRANSFER_ERROR_CONNECTION_IS_METERED |  |

### IdeTransfer

    typedef struct _IdeTransfer IdeTransfer;

## Property Details

### The `“active”` property

      “active”                   gboolean

If the transfer is active.

Owner: IdeTransfer

Flags: Read

Default value: FALSE

### The `“completed”` property

      “completed”                gboolean

If the transfer has completed successfully.

Owner: IdeTransfer

Flags: Read

Default value: FALSE

### The `“icon-name”` property

      “icon-name”                char *

The icon to display next to the transfer.

Owner: IdeTransfer

Flags: Read / Write

Default value: "folder-download-symbolic"

### The `“progress”` property

      “progress”                 double

The progress for the transfer between 0 adn 1.

Owner: IdeTransfer

Flags: Read / Write

Allowed values: [0,1]

Default value: 0

### The `“status”` property

      “status”                   char *

The status message for the transfer.

Owner: IdeTransfer

Flags: Read / Write

Default value: NULL

### The `“title”` property

      “title”                    char *

The title of the transfer.

Owner: IdeTransfer

Flags: Read / Write

Default value: NULL

## Signal Details

### The `“cancelled”` signal

    void
    user_function (IdeTransfer *idetransfer,
                   gpointer     user_data)

Flags: Run Last