IdeDeployStrategy: Builder SDK Reference

## IdeDeployStrategy IdeDeployStrategy |

## Functions

void | ide_deploy_strategy_load_async ()
gboolean | ide_deploy_strategy_load_finish ()
void | ide_deploy_strategy_deploy_async ()
gboolean | ide_deploy_strategy_deploy_finish ()

## Types and Values

#define | IDE_TYPE_DEPLOY_STRATEGY
struct | IdeDeployStrategyClass
| IdeDeployStrategy

## Object Hierarchy

        GObject
        ╰── IdeObject
            ╰── IdeDeployStrategy

## Description

## Functions

### ide_deploy_strategy_load_async ()

    void
    ide_deploy_strategy_load_async (IdeDeployStrategy *self,
                                    IdePipeline *pipeline,
                                    GCancellable *cancellable,
                                    GAsyncReadyCallback callback,
                                    gpointer user_data);

Asynchronously requests that the IdeDeployStrategy load anything necessary to support deployment for `pipeline` . If the strategy cannot support the pipeline, it should fail with `G_IO_ERROR` error domain and `G_IO_ERROR_NOT_SUPPORTED` error code.

Generally, the deployment strategy is responsible for checking if it can support deployment to the given device, and determine how to get the install data out of the pipeline. Given so many moving parts in build systems, how to determine that is an implementation detail of the specific IdeDeployStrategy.

#### Parameters

self | an IdeDeployStrategy |
pipeline | an IdePipeline |
cancellable | a GCancellable, or `NULL`. | [nullable]
callback | a callback to execute upon completion |
user_data | closure data for `callback` |

Since: 3.32

### ide_deploy_strategy_load_finish ()

    gboolean
    ide_deploy_strategy_load_finish (IdeDeployStrategy *self,
                                     GAsyncResult *result,
                                     GError **error);

Completes an asynchronous request to load the IdeDeployStrategy.

#### Parameters

self | an IdeDeployStrategy |
result | a GAsyncResult provided to callback |
error | a location for a GError, or `NULL` |

#### Returns

`TRUE` if successful and the pipeline was supported; otherwise `FALSE` and `error` is set.

Since: 3.32

### ide_deploy_strategy_deploy_async ()

    void
    ide_deploy_strategy_deploy_async (IdeDeployStrategy *self,
                                      IdePipeline *pipeline,
                                      GFileProgressCallback progress,
                                      gpointer progress_data,
                                      GDestroyNotify progress_data_destroy,
                                      GCancellable *cancellable,
                                      GAsyncReadyCallback callback,
                                      gpointer user_data);

Requests that the IdeDeployStrategy deploy the application to the configured device in the build pipeline.

If supported, the strategy will call `progress` with periodic updates as the application is deployed.

#### Parameters

self | a IdeDeployStrategy |
pipeline | an IdePipeline |
progress | a GFileProgressCallback or `NULL`. | [nullable][closure progress_data][scope notified]
progress_data | closure data for `progress` or `NULL`. | [nullable]
progress_data_destroy | destroy callback for `progress_data` . | [nullable]
cancellable | a GCancellable or `NULL`. | [nullable]
callback | a callback to execute upon completion. | [closure user_data]
user_data | closure data for `callback` |

Since: 3.32

### ide_deploy_strategy_deploy_finish ()

    gboolean
    ide_deploy_strategy_deploy_finish (IdeDeployStrategy *self,
                                       GAsyncResult *result,
                                       GError **error);

Completes an asynchronous request to deploy the application to the build pipeline's device.

#### Parameters

self | an IdeDeployStrategy |
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.32

## Types and Values

### IDE_TYPE_DEPLOY_STRATEGY

    #define IDE_TYPE_DEPLOY_STRATEGY (ide_deploy_strategy_get_type())

### struct IdeDeployStrategyClass

    struct IdeDeployStrategyClass {
      IdeObjectClass parent;

      void     (*load_async)    (IdeDeployStrategy     *self,
                                 IdePipeline      *pipeline,
                                 GCancellable          *cancellable,
                                 GAsyncReadyCallback    callback,
                                 gpointer               user_data);
      gboolean (*load_finish)   (IdeDeployStrategy     *self,
                                 GAsyncResult          *result,
                                 GError               **error);
      void     (*deploy_async)  (IdeDeployStrategy     *self,
                                 IdePipeline      *pipeline,
                                 GFileProgressCallback  progress,
                                 gpointer               progress_data,
                                 GDestroyNotify         progress_data_destroy,
                                 GCancellable          *cancellable,
                                 GAsyncReadyCallback    callback,
                                 gpointer               user_data);
      gboolean (*deploy_finish) (IdeDeployStrategy     *self,
                                 GAsyncResult          *result,
                                 GError               **error);

      gpointer _reserved[16];
    };

### IdeDeployStrategy

    typedef struct _IdeDeployStrategy IdeDeployStrategy;