## ide-transfer-manager ide-transfer-manager |

## Functions

IdeTransferManager * | ide_transfer_manager_get_default ()
gdouble | ide_transfer_manager_get_progress ()
gboolean | ide_transfer_manager_get_has_active ()
void | ide_transfer_manager_cancel_all ()
void | ide_transfer_manager_clear ()
void | ide_transfer_manager_execute_async ()
gboolean | ide_transfer_manager_execute_finish ()

## Properties

gboolean | has-active | Read
gdouble | progress | Read

## Signals

void | all-transfers-completed | Run Last
void | transfer-completed | Run Last
void | transfer-failed | Run Last

## Types and Values

#define | IDE_TYPE_TRANSFER_MANAGER
| IdeTransferManager

## Object Hierarchy

        GObject
        ╰── IdeTransferManager

## Implemented Interfaces

IdeTransferManager implements GListModel.

## Description

## Functions

### ide_transfer_manager_get_default ()

    IdeTransferManager *
    ide_transfer_manager_get_default (void);

Gets the IdeTransferManager singleton.

#### Returns

an IdeTransferManager.

[transfer none]

Since: 3.32

### ide_transfer_manager_get_progress ()

    gdouble
    ide_transfer_manager_get_progress (IdeTransferManager *self);

### ide_transfer_manager_get_has_active ()

    gboolean
    ide_transfer_manager_get_has_active (IdeTransferManager *self);

Gets if there are active transfers.

#### Returns

`TRUE` if there are active transfers.

Since: 3.32

### ide_transfer_manager_cancel_all ()

    void
    ide_transfer_manager_cancel_all (IdeTransferManager *self);

### ide_transfer_manager_clear ()

    void
    ide_transfer_manager_clear (IdeTransferManager *self);

Removes all transfers from the manager that are completed.

Since: 3.32

### ide_transfer_manager_execute_async ()

    void
    ide_transfer_manager_execute_async (IdeTransferManager *self,
                                        IdeTransfer *transfer,
                                        GCancellable *cancellable,
                                        GAsyncReadyCallback callback,
                                        gpointer user_data);

This is a convenience function that will queue `transfer` into the transfer manager and execute callback upon completion of the transfer. The success or failure GError will be propagated to the caller via `ide_transfer_manager_execute_finish()`.

#### Parameters

self | An IdeTransferManager |
cancellable | a GCancellable. | [nullable]
callback | A callback or `NULL`. | [nullable]
user_data | user data for `callback` |

Since: 3.32

### ide_transfer_manager_execute_finish ()

    gboolean
    ide_transfer_manager_execute_finish (IdeTransferManager *self,
                                         GAsyncResult *result,
                                         GError **error);

## Types and Values

### IDE_TYPE_TRANSFER_MANAGER

    #define IDE_TYPE_TRANSFER_MANAGER (ide_transfer_manager_get_type())

### IdeTransferManager

    typedef struct _IdeTransferManager IdeTransferManager;

## Property Details

### The `“has-active”` property

      “has-active”               gboolean

If there are transfers active, this will be set.

Owner: IdeTransferManager

Flags: Read

Default value: FALSE

Since: 3.32

### The `“progress”` property

      “progress”                 gdouble

A double between and including 0.0 and 1.0 describing the progress of all tasks.

Owner: IdeTransferManager

Flags: Read

Allowed values: [0,1]

Default value: 0

Since: 3.32

## Signal Details

### The `“all-transfers-completed”` signal

    void
    user_function (IdeTransferManager *idetransfermanager,
                   gpointer            user_data)

This signal is emitted when all of the transfers have completed or failed.

#### Parameters

user_data | user data set when the signal handler was connected. |

Flags: Run Last

Since: 3.32

### The `“transfer-completed”` signal

    void
    user_function (IdeTransferManager *self,
                   IdeTransfer        *transfer,
                   gpointer            user_data)

This signal is emitted when a transfer has completed successfully.

#### Parameters

self | An IdeTransferManager |
transfer | An IdeTransfer |
user_data | user data set when the signal handler was connected. |

Flags: Run Last

Since: 3.32

### The `“transfer-failed”` signal

    void
    user_function (IdeTransferManager *self,
                   IdeTransfer        *transfer,
                   GError             *reason,
                   gpointer            user_data)

This signal is emitted when a transfer has failed to complete successfully.

#### Parameters

self | An IdeTransferManager |
transfer | An IdeTransfer |
reason | The reason for the failure. | [in]
user_data | user data set when the signal handler was connected. |

Flags: Run Last

Since: 3.32