/* github.c generated by valac 0.56.19, the Vala compiler
 * generated from github.vala, do not modify */

#include <glib-object.h>
#include <gio/gio.h>
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <json-glib/json-glib.h>
#include <errno.h>

#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define PROTON_PLUS_MODELS_TYPE_RUNNER (proton_plus_models_runner_get_type ())
#define PROTON_PLUS_MODELS_RUNNER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_TYPE_RUNNER, ProtonPlusModelsRunner))
#define PROTON_PLUS_MODELS_RUNNER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_TYPE_RUNNER, ProtonPlusModelsRunnerClass))
#define PROTON_PLUS_MODELS_IS_RUNNER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_TYPE_RUNNER))
#define PROTON_PLUS_MODELS_IS_RUNNER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_TYPE_RUNNER))
#define PROTON_PLUS_MODELS_RUNNER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_TYPE_RUNNER, ProtonPlusModelsRunnerClass))

typedef struct _ProtonPlusModelsRunner ProtonPlusModelsRunner;
typedef struct _ProtonPlusModelsRunnerClass ProtonPlusModelsRunnerClass;
typedef struct _ProtonPlusModelsRunnerPrivate ProtonPlusModelsRunnerPrivate;

#define PROTON_PLUS_MODELS_TYPE_BASE_RELEASE (proton_plus_models_base_release_get_type ())
#define PROTON_PLUS_MODELS_BASE_RELEASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_TYPE_BASE_RELEASE, ProtonPlusModelsBaseRelease))
#define PROTON_PLUS_MODELS_BASE_RELEASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_TYPE_BASE_RELEASE, ProtonPlusModelsBaseReleaseClass))
#define PROTON_PLUS_MODELS_IS_BASE_RELEASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_TYPE_BASE_RELEASE))
#define PROTON_PLUS_MODELS_IS_BASE_RELEASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_TYPE_BASE_RELEASE))
#define PROTON_PLUS_MODELS_BASE_RELEASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_TYPE_BASE_RELEASE, ProtonPlusModelsBaseReleaseClass))

typedef struct _ProtonPlusModelsBaseRelease ProtonPlusModelsBaseRelease;
typedef struct _ProtonPlusModelsBaseReleaseClass ProtonPlusModelsBaseReleaseClass;

#define PROTON_PLUS_MODELS_TYPE_RELEASE (proton_plus_models_release_get_type ())
#define PROTON_PLUS_MODELS_RELEASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_TYPE_RELEASE, ProtonPlusModelsRelease))
#define PROTON_PLUS_MODELS_RELEASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_TYPE_RELEASE, ProtonPlusModelsReleaseClass))
#define PROTON_PLUS_MODELS_IS_RELEASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_TYPE_RELEASE))
#define PROTON_PLUS_MODELS_IS_RELEASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_TYPE_RELEASE))
#define PROTON_PLUS_MODELS_RELEASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_TYPE_RELEASE, ProtonPlusModelsReleaseClass))

typedef struct _ProtonPlusModelsRelease ProtonPlusModelsRelease;
typedef struct _ProtonPlusModelsReleaseClass ProtonPlusModelsReleaseClass;
typedef enum  {
	PROTON_PLUS_RETURN_CODE_UNKNOWN_ERROR,
	PROTON_PLUS_RETURN_CODE_RELEASES_LOADED,
	PROTON_PLUS_RETURN_CODE_NOTHING_TO_UPDATE,
	PROTON_PLUS_RETURN_CODE_RUNNERS_UPDATED,
	PROTON_PLUS_RETURN_CODE_RUNNER_UPDATED,
	PROTON_PLUS_RETURN_CODE_VALID_REQUEST,
	PROTON_PLUS_RETURN_CODE_CONNECTION_ISSUE,
	PROTON_PLUS_RETURN_CODE_CONNECTION_REFUSED,
	PROTON_PLUS_RETURN_CODE_CONNECTION_UNKNOWN,
	PROTON_PLUS_RETURN_CODE_API_LIMIT_REACHED,
	PROTON_PLUS_RETURN_CODE_INVALID_ACCESS_TOKEN
} ProtonPlusReturnCode;

#define PROTON_PLUS_TYPE_RETURN_CODE (proton_plus_return_code_get_type ())

#define PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC (proton_plus_models_runners_basic_get_type ())
#define PROTON_PLUS_MODELS_RUNNERS_BASIC(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC, ProtonPlusModelsRunnersBasic))
#define PROTON_PLUS_MODELS_RUNNERS_BASIC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC, ProtonPlusModelsRunnersBasicClass))
#define PROTON_PLUS_MODELS_RUNNERS_IS_BASIC(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC))
#define PROTON_PLUS_MODELS_RUNNERS_IS_BASIC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC))
#define PROTON_PLUS_MODELS_RUNNERS_BASIC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC, ProtonPlusModelsRunnersBasicClass))

typedef struct _ProtonPlusModelsRunnersBasic ProtonPlusModelsRunnersBasic;
typedef struct _ProtonPlusModelsRunnersBasicClass ProtonPlusModelsRunnersBasicClass;
typedef struct _ProtonPlusModelsRunnersBasicPrivate ProtonPlusModelsRunnersBasicPrivate;

#define PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB (proton_plus_models_runners_git_hub_get_type ())
#define PROTON_PLUS_MODELS_RUNNERS_GIT_HUB(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHub))
#define PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHubClass))
#define PROTON_PLUS_MODELS_RUNNERS_IS_GIT_HUB(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB))
#define PROTON_PLUS_MODELS_RUNNERS_IS_GIT_HUB_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB))
#define PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHubClass))

typedef struct _ProtonPlusModelsRunnersGitHub ProtonPlusModelsRunnersGitHub;
typedef struct _ProtonPlusModelsRunnersGitHubClass ProtonPlusModelsRunnersGitHubClass;
typedef struct _ProtonPlusModelsRunnersGitHubPrivate ProtonPlusModelsRunnersGitHubPrivate;
enum  {
	PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_0_PROPERTY,
	PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY,
	PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY,
	PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY,
	PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_NUM_PROPERTIES
};
static GParamSpec* proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_NUM_PROPERTIES];
typedef enum  {
	PROTON_PLUS_UTILS_WEB_GET_TYPE_OTHER,
	PROTON_PLUS_UTILS_WEB_GET_TYPE_GITHUB,
	PROTON_PLUS_UTILS_WEB_GET_TYPE_GITLAB,
	PROTON_PLUS_UTILS_WEB_GET_TYPE_FORGEJO,
	PROTON_PLUS_UTILS_WEB_GET_TYPE_STEAMTINKERLAUNCH
} ProtonPlusUtilsWebGetType;

#define PROTON_PLUS_UTILS_WEB_TYPE_GET_TYPE (proton_plus_utils_web_get_type_get_type ())
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
#define __vala_JsonNode_free0(var) ((var == NULL) ? NULL : (var = (_vala_JsonNode_free (var), NULL)))
#define _json_array_unref0(var) ((var == NULL) ? NULL : (var = (json_array_unref (var), NULL)))
#define _json_object_unref0(var) ((var == NULL) ? NULL : (var = (json_object_unref (var), NULL)))
#define _g_date_time_unref0(var) ((var == NULL) ? NULL : (var = (g_date_time_unref (var), NULL)))

#define PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC (proton_plus_models_releases_basic_get_type ())
#define PROTON_PLUS_MODELS_RELEASES_BASIC(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC, ProtonPlusModelsReleasesBasic))
#define PROTON_PLUS_MODELS_RELEASES_BASIC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC, ProtonPlusModelsReleasesBasicClass))
#define PROTON_PLUS_MODELS_RELEASES_IS_BASIC(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC))
#define PROTON_PLUS_MODELS_RELEASES_IS_BASIC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC))
#define PROTON_PLUS_MODELS_RELEASES_BASIC_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PROTON_PLUS_MODELS_RELEASES_TYPE_BASIC, ProtonPlusModelsReleasesBasicClass))

typedef struct _ProtonPlusModelsReleasesBasic ProtonPlusModelsReleasesBasic;
typedef struct _ProtonPlusModelsReleasesBasicClass ProtonPlusModelsReleasesBasicClass;
typedef struct _ProtonPlusModelsRunnersGitHubLoadData ProtonPlusModelsRunnersGitHubLoadData;

struct _ProtonPlusModelsRunner {
	GObject parent_instance;
	ProtonPlusModelsRunnerPrivate * priv;
	GList* releases;
};

struct _ProtonPlusModelsRunnerClass {
	GObjectClass parent_class;
	void (*load) (ProtonPlusModelsRunner* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
	ProtonPlusReturnCode (*load_finish) (ProtonPlusModelsRunner* self, GAsyncResult* _res_, GList** releases);
};

struct _ProtonPlusModelsRunnersBasic {
	ProtonPlusModelsRunner parent_instance;
	ProtonPlusModelsRunnersBasicPrivate * priv;
};

struct _ProtonPlusModelsRunnersBasicClass {
	ProtonPlusModelsRunnerClass parent_class;
	gchar* (*get_directory_name) (ProtonPlusModelsRunnersBasic* self, const gchar* release_name);
};

struct _ProtonPlusModelsRunnersGitHub {
	ProtonPlusModelsRunnersBasic parent_instance;
	ProtonPlusModelsRunnersGitHubPrivate * priv;
};

struct _ProtonPlusModelsRunnersGitHubClass {
	ProtonPlusModelsRunnersBasicClass parent_class;
};

struct _ProtonPlusModelsRunnersGitHubPrivate {
	gboolean _use_name_instead_of_tag_name;
	gchar** _request_asset_filter;
	gint _request_asset_filter_length1;
	gint __request_asset_filter_size_;
	gchar** _request_asset_exclude;
	gint _request_asset_exclude_length1;
	gint __request_asset_exclude_size_;
};

struct _ProtonPlusModelsRunnersGitHubLoadData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	ProtonPlusModelsRunnersGitHub* self;
	GList* releases;
	ProtonPlusReturnCode result;
	gchar* response;
	ProtonPlusReturnCode code;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gint _tmp2_;
	gint _tmp3_;
	gchar* _tmp4_;
	gchar* _tmp5_;
	ProtonPlusUtilsWebGetType _tmp6_;
	ProtonPlusUtilsWebGetType _tmp7_;
	gchar* _tmp8_;
	ProtonPlusReturnCode _tmp9_;
	ProtonPlusReturnCode _tmp10_;
	gint _tmp11_;
	gint _tmp12_;
	JsonNode* root_node;
	const gchar* _tmp13_;
	JsonNode* _tmp14_;
	JsonNode* _tmp15_;
	JsonNode* _tmp16_;
	JsonArray* root_array;
	JsonNode* _tmp17_;
	JsonArray* _tmp18_;
	JsonArray* _tmp19_;
	JsonArray* _tmp20_;
	gint i;
	gboolean _tmp21_;
	gint _tmp22_;
	JsonArray* _tmp23_;
	JsonObject* object;
	JsonArray* _tmp24_;
	JsonObject* _tmp25_;
	JsonObject* _tmp26_;
	JsonArray* asset_array;
	JsonObject* _tmp27_;
	JsonArray* _tmp28_;
	JsonArray* _tmp29_;
	JsonArray* _tmp30_;
	const gchar* _tmp31_;
	gboolean _tmp32_;
	JsonObject* _tmp33_;
	const gchar* _tmp34_;
	JsonObject* _tmp35_;
	const gchar* _tmp36_;
	gchar* title;
	gchar* _tmp37_;
	gchar* description;
	JsonObject* _tmp38_;
	const gchar* _tmp39_;
	gchar* _tmp40_;
	gchar* page_url;
	JsonObject* _tmp41_;
	const gchar* _tmp42_;
	gchar* _tmp43_;
	gchar* release_date;
	JsonObject* _tmp44_;
	const gchar* _tmp45_;
	gchar* _tmp46_;
	gchar** _tmp47_;
	gint _tmp47__length1;
	gint _tmp48_;
	gchar** _tmp49_;
	gint _tmp49__length1;
	gboolean excluded;
	gchar** _tmp50_;
	gint _tmp50__length1;
	gint _tmp51_;
	gchar** _tmp52_;
	gint _tmp52__length1;
	gchar** filter_collection;
	gint filter_collection_length1;
	gint _filter_collection_size_;
	gint filter_it;
	gchar* _tmp53_;
	gchar* filter;
	const gchar* _tmp54_;
	const gchar* _tmp55_;
	gchar** _tmp56_;
	gint _tmp56__length1;
	gint _tmp57_;
	gchar** _tmp58_;
	gint _tmp58__length1;
	gboolean _vala1_excluded;
	gchar** _tmp59_;
	gint _tmp59__length1;
	gint _tmp60_;
	gchar** _tmp61_;
	gint _tmp61__length1;
	gchar** excluded_asset_collection;
	gint excluded_asset_collection_length1;
	gint _excluded_asset_collection_size_;
	gint excluded_asset_it;
	gchar* _tmp62_;
	gchar* excluded_asset;
	const gchar* _tmp63_;
	const gchar* _tmp64_;
	gint real_asset_position;
	gint _tmp65_;
	gint _tmp66_;
	const gchar* _tmp67_;
	const gchar* _tmp68_;
	gchar** asset_position_time_condition_split;
	const gchar* _tmp69_;
	const gchar* _tmp70_;
	gchar** _tmp71_;
	gchar** _tmp72_;
	gint asset_position_time_condition_split_length1;
	gint _asset_position_time_condition_split_size_;
	gchar** _tmp73_;
	gint _tmp73__length1;
	GDateTime* condition_time;
	gchar** _tmp74_;
	gint _tmp74__length1;
	const gchar* _tmp75_;
	GDateTime* _tmp76_;
	GDateTime* release_time;
	const gchar* _tmp77_;
	GDateTime* _tmp78_;
	gint _result_;
	GDateTime* _tmp79_;
	GDateTime* _tmp80_;
	gint number;
	gboolean parsed;
	gchar** _tmp81_;
	gint _tmp81__length1;
	const gchar* _tmp82_;
	gint _tmp83_;
	gboolean _tmp84_;
	gboolean _tmp85_;
	gboolean _tmp86_;
	gint y;
	gboolean _tmp87_;
	gint _tmp88_;
	JsonArray* _tmp89_;
	JsonObject* asset_object;
	JsonArray* _tmp90_;
	JsonObject* _tmp91_;
	JsonObject* _tmp92_;
	JsonObject* _tmp93_;
	const gchar* _tmp94_;
	GList* _tmp95_;
	gconstpointer _tmp96_;
	gchar* _tmp97_;
	gchar* _tmp98_;
	gboolean _tmp99_;
	JsonArray* _tmp100_;
	JsonObject* _vala1_asset_object;
	JsonArray* _tmp101_;
	JsonObject* _tmp102_;
	JsonObject* _tmp103_;
	gchar* download_url;
	JsonObject* _tmp104_;
	const gchar* _tmp105_;
	gchar* _tmp106_;
	gint64 download_size;
	JsonObject* _tmp107_;
	ProtonPlusModelsReleasesBasic* release;
	const gchar* _tmp108_;
	const gchar* _tmp109_;
	const gchar* _tmp110_;
	const gchar* _tmp111_;
	const gchar* _tmp112_;
	ProtonPlusModelsReleasesBasic* _tmp113_;
	ProtonPlusModelsReleasesBasic* _tmp114_;
	ProtonPlusModelsRelease* _tmp115_;
	ProtonPlusModelsReleasesBasic* _tmp116_;
	ProtonPlusModelsRelease* _tmp117_;
	JsonArray* _tmp118_;
};

static gint ProtonPlusModelsRunnersGitHub_private_offset;
static gpointer proton_plus_models_runners_git_hub_parent_class = NULL;
VALA_EXTERN GList* proton_plus_globals_HWCAPS;

VALA_EXTERN GType proton_plus_models_runner_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsRunner, g_object_unref)
VALA_EXTERN GType proton_plus_models_base_release_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsBaseRelease, g_object_unref)
VALA_EXTERN GType proton_plus_models_release_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsRelease, g_object_unref)
VALA_EXTERN GType proton_plus_return_code_get_type (void) G_GNUC_CONST ;
VALA_EXTERN GType proton_plus_models_runners_basic_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsRunnersBasic, g_object_unref)
VALA_EXTERN GType proton_plus_models_runners_git_hub_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsRunnersGitHub, g_object_unref)
VALA_EXTERN void proton_plus_models_runner_load (ProtonPlusModelsRunner* self,
                                     GAsyncReadyCallback _callback_,
                                     gpointer _user_data_);
VALA_EXTERN ProtonPlusReturnCode proton_plus_models_runner_load_finish (ProtonPlusModelsRunner* self,
                                                            GAsyncResult* _res_,
                                                            GList** releases);
VALA_EXTERN ProtonPlusModelsRunnersGitHub* proton_plus_models_runners_git_hub_new (void);
VALA_EXTERN ProtonPlusModelsRunnersGitHub* proton_plus_models_runners_git_hub_construct (GType object_type);
VALA_EXTERN ProtonPlusModelsRunnersBasic* proton_plus_models_runners_basic_construct (GType object_type);
VALA_EXTERN GType proton_plus_utils_web_get_type_get_type (void) G_GNUC_CONST ;
VALA_EXTERN void proton_plus_models_runner_set_get_type (ProtonPlusModelsRunner* self,
                                             ProtonPlusUtilsWebGetType value);
static void proton_plus_models_runners_git_hub_real_load_data_free (gpointer _data);
static void proton_plus_models_runners_git_hub_real_load (ProtonPlusModelsRunner* base,
                                                   GAsyncReadyCallback _callback_,
                                                   gpointer _user_data_);
static void _g_object_unref0_ (gpointer var);
static inline void _g_list_free__g_object_unref0_ (GList* self);
static gboolean proton_plus_models_runners_git_hub_real_load_co (ProtonPlusModelsRunnersGitHubLoadData* _data_);
VALA_EXTERN void proton_plus_utils_web_get_request (const gchar* uri,
                                        ProtonPlusUtilsWebGetType get_type,
                                        GAsyncReadyCallback _callback_,
                                        gpointer _user_data_);
VALA_EXTERN ProtonPlusReturnCode proton_plus_utils_web_get_request_finish (GAsyncResult* _res_,
                                                               gchar** response);
VALA_EXTERN const gchar* proton_plus_models_runners_basic_get_endpoint (ProtonPlusModelsRunnersBasic* self);
VALA_EXTERN gint proton_plus_models_runners_basic_get_page (ProtonPlusModelsRunnersBasic* self);
VALA_EXTERN ProtonPlusUtilsWebGetType proton_plus_models_runner_get_get_type (ProtonPlusModelsRunner* self);
static void proton_plus_models_runners_git_hub_load_ready (GObject* source_object,
                                                    GAsyncResult* _res_,
                                                    gpointer _user_data_);
VALA_EXTERN void proton_plus_models_runners_basic_set_page (ProtonPlusModelsRunnersBasic* self,
                                                gint value);
VALA_EXTERN JsonNode* proton_plus_utils_parser_get_node_from_json (const gchar* json);
static void _vala_JsonNode_free (JsonNode* self);
VALA_EXTERN gboolean proton_plus_models_runners_git_hub_get_use_name_instead_of_tag_name (ProtonPlusModelsRunnersGitHub* self);
VALA_EXTERN gchar** proton_plus_models_runners_git_hub_get_request_asset_filter (ProtonPlusModelsRunnersGitHub* self,
                                                                     gint* result_length1);
VALA_EXTERN gchar** proton_plus_models_runners_git_hub_get_request_asset_exclude (ProtonPlusModelsRunnersGitHub* self,
                                                                      gint* result_length1);
VALA_EXTERN gint proton_plus_models_runners_basic_get_asset_position (ProtonPlusModelsRunnersBasic* self);
VALA_EXTERN const gchar* proton_plus_models_runners_basic_get_asset_position_time_condition (ProtonPlusModelsRunnersBasic* self);
VALA_EXTERN gboolean proton_plus_models_runner_get_asset_position_hwcaps_condition (ProtonPlusModelsRunner* self);
VALA_EXTERN GType proton_plus_models_releases_basic_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ProtonPlusModelsReleasesBasic, g_object_unref)
VALA_EXTERN ProtonPlusModelsReleasesBasic* proton_plus_models_releases_basic_new_github (ProtonPlusModelsRunnersBasic* runner,
                                                                             const gchar* title,
                                                                             const gchar* description,
                                                                             const gchar* release_date,
                                                                             gint64 download_size,
                                                                             const gchar* download_url,
                                                                             const gchar* page_url);
VALA_EXTERN ProtonPlusModelsReleasesBasic* proton_plus_models_releases_basic_construct_github (GType object_type,
                                                                                   ProtonPlusModelsRunnersBasic* runner,
                                                                                   const gchar* title,
                                                                                   const gchar* description,
                                                                                   const gchar* release_date,
                                                                                   gint64 download_size,
                                                                                   const gchar* download_url,
                                                                                   const gchar* page_url);
VALA_EXTERN void proton_plus_models_runner_set_has_more (ProtonPlusModelsRunner* self,
                                             gboolean value);
VALA_EXTERN void proton_plus_models_runners_git_hub_set_use_name_instead_of_tag_name (ProtonPlusModelsRunnersGitHub* self,
                                                                          gboolean value);
VALA_EXTERN void proton_plus_models_runners_git_hub_set_request_asset_filter (ProtonPlusModelsRunnersGitHub* self,
                                                                  gchar** value,
                                                                  gint value_length1);
static gchar** _vala_array_dup7 (gchar** self,
                          gssize length);
VALA_EXTERN void proton_plus_models_runners_git_hub_set_request_asset_exclude (ProtonPlusModelsRunnersGitHub* self,
                                                                   gchar** value,
                                                                   gint value_length1);
static gchar** _vala_array_dup8 (gchar** self,
                          gssize length);
static void proton_plus_models_runners_git_hub_finalize (GObject * obj);
static GType proton_plus_models_runners_git_hub_get_type_once (void);
static void _vala_proton_plus_models_runners_git_hub_get_property (GObject * object,
                                                            guint property_id,
                                                            GValue * value,
                                                            GParamSpec * pspec);
static void _vala_proton_plus_models_runners_git_hub_set_property (GObject * object,
                                                            guint property_id,
                                                            const GValue * value,
                                                            GParamSpec * pspec);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);
static gssize _vala_array_length (gpointer array);

static inline gpointer
proton_plus_models_runners_git_hub_get_instance_private (ProtonPlusModelsRunnersGitHub* self)
{
	return G_STRUCT_MEMBER_P (self, ProtonPlusModelsRunnersGitHub_private_offset);
}

ProtonPlusModelsRunnersGitHub*
proton_plus_models_runners_git_hub_construct (GType object_type)
{
	ProtonPlusModelsRunnersGitHub * self = NULL;
	self = (ProtonPlusModelsRunnersGitHub*) proton_plus_models_runners_basic_construct (object_type);
	proton_plus_models_runner_set_get_type ((ProtonPlusModelsRunner*) self, PROTON_PLUS_UTILS_WEB_GET_TYPE_GITHUB);
	return self;
}

ProtonPlusModelsRunnersGitHub*
proton_plus_models_runners_git_hub_new (void)
{
	return proton_plus_models_runners_git_hub_construct (PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB);
}

static void
proton_plus_models_runners_git_hub_real_load_data_free (gpointer _data)
{
	ProtonPlusModelsRunnersGitHubLoadData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->self);
	g_slice_free (ProtonPlusModelsRunnersGitHubLoadData, _data_);
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

static void
proton_plus_models_runners_git_hub_real_load (ProtonPlusModelsRunner* base,
                                              GAsyncReadyCallback _callback_,
                                              gpointer _user_data_)
{
	ProtonPlusModelsRunnersGitHub * self;
	ProtonPlusModelsRunnersGitHubLoadData* _data_;
	ProtonPlusModelsRunnersGitHub* _tmp0_;
	self = (ProtonPlusModelsRunnersGitHub*) base;
	_data_ = g_slice_new0 (ProtonPlusModelsRunnersGitHubLoadData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, proton_plus_models_runners_git_hub_real_load_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	proton_plus_models_runners_git_hub_real_load_co (_data_);
}

static void
_g_object_unref0_ (gpointer var)
{
	(var == NULL) ? NULL : (var = (g_object_unref (var), NULL));
}

static inline void
_g_list_free__g_object_unref0_ (GList* self)
{
	g_list_free_full (self, (GDestroyNotify) _g_object_unref0_);
}

static ProtonPlusReturnCode
proton_plus_models_runners_git_hub_load_finish (ProtonPlusModelsRunner* base,
                                                GAsyncResult* _res_,
                                                GList** releases)
{
	ProtonPlusReturnCode result;
	ProtonPlusModelsRunnersGitHubLoadData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), NULL);
	if (releases) {
		*releases = _data_->releases;
	} else {
		(_data_->releases == NULL) ? NULL : (_data_->releases = (_g_list_free__g_object_unref0_ (_data_->releases), NULL));
	}
	_data_->releases = NULL;
	result = _data_->result;
	return result;
}

static void
proton_plus_models_runners_git_hub_load_ready (GObject* source_object,
                                               GAsyncResult* _res_,
                                               gpointer _user_data_)
{
	ProtonPlusModelsRunnersGitHubLoadData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	proton_plus_models_runners_git_hub_real_load_co (_data_);
}

static void
_vala_JsonNode_free (JsonNode* self)
{
	g_boxed_free (json_node_get_type (), self);
}

static gpointer
_json_array_ref0 (gpointer self)
{
	return self ? json_array_ref (self) : NULL;
}

static gpointer
_json_object_ref0 (gpointer self)
{
	return self ? json_object_ref (self) : NULL;
}

static gchar*
string_strip (const gchar* self)
{
	gchar* _result_ = NULL;
	gchar* _tmp0_;
	gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = g_strdup (self);
	_result_ = _tmp0_;
	g_strstrip (_result_);
	result = _result_;
	return result;
}

static gboolean
string_contains (const gchar* self,
                 const gchar* needle)
{
	gchar* _tmp0_;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	g_return_val_if_fail (needle != NULL, FALSE);
	_tmp0_ = strstr ((gchar*) self, (gchar*) needle);
	result = _tmp0_ != NULL;
	return result;
}

static gboolean
int_try_parse (const gchar* str,
               gint* _result_,
               const gchar** unparsed,
               guint _base)
{
	gint _vala__result_ = 0;
	const gchar* _vala_unparsed = NULL;
	gchar* endptr = NULL;
	glong long_result = 0L;
	gchar* _tmp0_ = NULL;
	glong _tmp1_;
	gchar* _tmp2_;
	gint _tmp3_;
	gint _tmp4_;
	glong _tmp6_;
	gboolean result;
	g_return_val_if_fail (str != NULL, FALSE);
	errno = 0;
	_tmp1_ = strtol (str, &_tmp0_, (gint) _base);
	endptr = _tmp0_;
	long_result = _tmp1_;
	_tmp2_ = endptr;
	_tmp3_ = strlen (str);
	_tmp4_ = _tmp3_;
	if (_tmp2_ == (((gchar*) str) + _tmp4_)) {
		_vala_unparsed = "";
	} else {
		gchar* _tmp5_;
		_tmp5_ = endptr;
		_vala_unparsed = (const gchar*) _tmp5_;
	}
	_tmp6_ = long_result;
	if ((((glong) G_MININT) <= _tmp6_) && (_tmp6_ <= ((glong) G_MAXINT))) {
		gboolean _tmp7_ = FALSE;
		gboolean _tmp8_ = FALSE;
		_vala__result_ = (gint) long_result;
		if (errno != ERANGE) {
			_tmp8_ = errno != EINVAL;
		} else {
			_tmp8_ = FALSE;
		}
		if (_tmp8_) {
			const gchar* _tmp9_;
			gchar* _tmp10_;
			_tmp9_ = _vala_unparsed;
			_tmp10_ = endptr;
			_tmp7_ = _tmp9_ != _tmp10_;
		} else {
			_tmp7_ = FALSE;
		}
		result = _tmp7_;
		if (_result_) {
			*_result_ = _vala__result_;
		}
		if (unparsed) {
			*unparsed = _vala_unparsed;
		}
		return result;
	} else {
		_vala__result_ = G_MAXINT;
		result = FALSE;
		if (_result_) {
			*_result_ = _vala__result_;
		}
		if (unparsed) {
			*unparsed = _vala_unparsed;
		}
		return result;
	}
}

static gboolean
proton_plus_models_runners_git_hub_real_load_co (ProtonPlusModelsRunnersGitHubLoadData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	(_data_->releases == NULL) ? NULL : (_data_->releases = (_g_list_free__g_object_unref0_ (_data_->releases), NULL));
	_data_->releases = NULL;
	_data_->_tmp0_ = proton_plus_models_runners_basic_get_endpoint ((ProtonPlusModelsRunnersBasic*) _data_->self);
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = proton_plus_models_runners_basic_get_page ((ProtonPlusModelsRunnersBasic*) _data_->self);
	_data_->_tmp3_ = _data_->_tmp2_;
	_data_->_tmp4_ = g_strdup_printf ("%s?per_page=25&page=%i", _data_->_tmp1_, _data_->_tmp3_);
	_data_->_tmp5_ = _data_->_tmp4_;
	_data_->_tmp6_ = proton_plus_models_runner_get_get_type ((ProtonPlusModelsRunner*) _data_->self);
	_data_->_tmp7_ = _data_->_tmp6_;
	_data_->_tmp8_ = NULL;
	_data_->_state_ = 1;
	proton_plus_utils_web_get_request (_data_->_tmp5_, _data_->_tmp7_, proton_plus_models_runners_git_hub_load_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp9_ = proton_plus_utils_web_get_request_finish (_data_->_res_, &_data_->_tmp8_);
	_g_free0 (_data_->response);
	_data_->response = _data_->_tmp8_;
	_data_->_tmp10_ = _data_->_tmp9_;
	_g_free0 (_data_->_tmp5_);
	_data_->code = _data_->_tmp10_;
	if (_data_->code != PROTON_PLUS_RETURN_CODE_VALID_REQUEST) {
		_data_->result = _data_->code;
		_g_free0 (_data_->response);
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp11_ = proton_plus_models_runners_basic_get_page ((ProtonPlusModelsRunnersBasic*) _data_->self);
	_data_->_tmp12_ = _data_->_tmp11_;
	proton_plus_models_runners_basic_set_page ((ProtonPlusModelsRunnersBasic*) _data_->self, _data_->_tmp12_ + 1);
	_data_->_tmp13_ = _data_->response;
	_data_->_tmp14_ = proton_plus_utils_parser_get_node_from_json (_data_->_tmp13_);
	_data_->root_node = _data_->_tmp14_;
	_data_->_tmp15_ = _data_->root_node;
	if (_data_->_tmp15_ == NULL) {
		_data_->result = PROTON_PLUS_RETURN_CODE_UNKNOWN_ERROR;
		__vala_JsonNode_free0 (_data_->root_node);
		_g_free0 (_data_->response);
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp16_ = _data_->root_node;
	if (json_node_get_node_type (_data_->_tmp16_) != JSON_NODE_ARRAY) {
		_data_->result = PROTON_PLUS_RETURN_CODE_UNKNOWN_ERROR;
		__vala_JsonNode_free0 (_data_->root_node);
		_g_free0 (_data_->response);
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp17_ = _data_->root_node;
	_data_->_tmp18_ = json_node_get_array (_data_->_tmp17_);
	_data_->_tmp19_ = _json_array_ref0 (_data_->_tmp18_);
	_data_->root_array = _data_->_tmp19_;
	_data_->_tmp20_ = _data_->root_array;
	if (_data_->_tmp20_ == NULL) {
		_data_->result = PROTON_PLUS_RETURN_CODE_UNKNOWN_ERROR;
		_json_array_unref0 (_data_->root_array);
		__vala_JsonNode_free0 (_data_->root_node);
		_g_free0 (_data_->response);
		g_task_return_pointer (_data_->_async_result, _data_, NULL);
		if (_data_->_state_ != 0) {
			while (!g_task_get_completed (_data_->_async_result)) {
				g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
			}
		}
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	{
		_data_->i = 0;
		{
			_data_->_tmp21_ = TRUE;
			while (TRUE) {
				if (!_data_->_tmp21_) {
					_data_->_tmp22_ = _data_->i;
					_data_->i = _data_->_tmp22_ + 1;
				}
				_data_->_tmp21_ = FALSE;
				_data_->_tmp23_ = _data_->root_array;
				if (!(((guint) _data_->i) < json_array_get_length (_data_->_tmp23_))) {
					break;
				}
				_data_->_tmp24_ = _data_->root_array;
				_data_->_tmp25_ = json_array_get_object_element (_data_->_tmp24_, (guint) _data_->i);
				_data_->_tmp26_ = _json_object_ref0 (_data_->_tmp25_);
				_data_->object = _data_->_tmp26_;
				_data_->_tmp27_ = _data_->object;
				_data_->_tmp28_ = json_object_get_array_member (_data_->_tmp27_, "assets");
				_data_->_tmp29_ = _json_array_ref0 (_data_->_tmp28_);
				_data_->asset_array = _data_->_tmp29_;
				_data_->_tmp30_ = _data_->asset_array;
				if (_data_->_tmp30_ == NULL) {
					_json_array_unref0 (_data_->asset_array);
					_json_object_unref0 (_data_->object);
					continue;
				}
				_data_->_tmp32_ = _data_->self->priv->_use_name_instead_of_tag_name;
				if (_data_->_tmp32_) {
					_data_->_tmp33_ = _data_->object;
					_data_->_tmp34_ = json_object_get_string_member (_data_->_tmp33_, "name");
					_data_->_tmp31_ = _data_->_tmp34_;
				} else {
					_data_->_tmp35_ = _data_->object;
					_data_->_tmp36_ = json_object_get_string_member (_data_->_tmp35_, "tag_name");
					_data_->_tmp31_ = _data_->_tmp36_;
				}
				_data_->_tmp37_ = g_strdup (_data_->_tmp31_);
				_data_->title = _data_->_tmp37_;
				_data_->_tmp38_ = _data_->object;
				_data_->_tmp39_ = json_object_get_string_member (_data_->_tmp38_, "body");
				_data_->_tmp40_ = string_strip (_data_->_tmp39_);
				_data_->description = _data_->_tmp40_;
				_data_->_tmp41_ = _data_->object;
				_data_->_tmp42_ = json_object_get_string_member (_data_->_tmp41_, "html_url");
				_data_->_tmp43_ = g_strdup (_data_->_tmp42_);
				_data_->page_url = _data_->_tmp43_;
				_data_->_tmp44_ = _data_->object;
				_data_->_tmp45_ = json_object_get_string_member (_data_->_tmp44_, "created_at");
				_data_->_tmp46_ = g_strdup (_data_->_tmp45_);
				_data_->release_date = _data_->_tmp46_;
				_data_->_tmp48_ = 0;
				_data_->_tmp47_ = proton_plus_models_runners_git_hub_get_request_asset_filter (_data_->self, &_data_->_tmp48_);
				_data_->_tmp47__length1 = _data_->_tmp48_;
				_data_->_tmp49_ = _data_->_tmp47_;
				_data_->_tmp49__length1 = _data_->_tmp47__length1;
				if (_data_->_tmp49_ != NULL) {
					_data_->excluded = FALSE;
					_data_->_tmp51_ = 0;
					_data_->_tmp50_ = proton_plus_models_runners_git_hub_get_request_asset_filter (_data_->self, &_data_->_tmp51_);
					_data_->_tmp50__length1 = _data_->_tmp51_;
					_data_->_tmp52_ = _data_->_tmp50_;
					_data_->_tmp52__length1 = _data_->_tmp50__length1;
					{
						_data_->filter_collection_length1 = 0;
						_data_->_filter_collection_size_ = 0;
						_data_->filter_collection = _data_->_tmp52_;
						_data_->filter_collection_length1 = _data_->_tmp52__length1;
						for (_data_->filter_it = 0; _data_->filter_it < _data_->filter_collection_length1; _data_->filter_it = _data_->filter_it + 1) {
							_data_->_tmp53_ = g_strdup (_data_->filter_collection[_data_->filter_it]);
							_data_->filter = _data_->_tmp53_;
							{
								_data_->_tmp54_ = _data_->title;
								_data_->_tmp55_ = _data_->filter;
								if (!string_contains (_data_->_tmp54_, _data_->_tmp55_)) {
									_data_->excluded = TRUE;
									_g_free0 (_data_->filter);
									break;
								}
								_g_free0 (_data_->filter);
							}
						}
					}
					if (_data_->excluded) {
						_g_free0 (_data_->release_date);
						_g_free0 (_data_->page_url);
						_g_free0 (_data_->description);
						_g_free0 (_data_->title);
						_json_array_unref0 (_data_->asset_array);
						_json_object_unref0 (_data_->object);
						continue;
					}
				} else {
					_data_->_tmp57_ = 0;
					_data_->_tmp56_ = proton_plus_models_runners_git_hub_get_request_asset_exclude (_data_->self, &_data_->_tmp57_);
					_data_->_tmp56__length1 = _data_->_tmp57_;
					_data_->_tmp58_ = _data_->_tmp56_;
					_data_->_tmp58__length1 = _data_->_tmp56__length1;
					if (_data_->_tmp58_ != NULL) {
						_data_->_vala1_excluded = FALSE;
						_data_->_tmp60_ = 0;
						_data_->_tmp59_ = proton_plus_models_runners_git_hub_get_request_asset_exclude (_data_->self, &_data_->_tmp60_);
						_data_->_tmp59__length1 = _data_->_tmp60_;
						_data_->_tmp61_ = _data_->_tmp59_;
						_data_->_tmp61__length1 = _data_->_tmp59__length1;
						{
							_data_->excluded_asset_collection_length1 = 0;
							_data_->_excluded_asset_collection_size_ = 0;
							_data_->excluded_asset_collection = _data_->_tmp61_;
							_data_->excluded_asset_collection_length1 = _data_->_tmp61__length1;
							for (_data_->excluded_asset_it = 0; _data_->excluded_asset_it < _data_->excluded_asset_collection_length1; _data_->excluded_asset_it = _data_->excluded_asset_it + 1) {
								_data_->_tmp62_ = g_strdup (_data_->excluded_asset_collection[_data_->excluded_asset_it]);
								_data_->excluded_asset = _data_->_tmp62_;
								{
									_data_->_tmp63_ = _data_->title;
									_data_->_tmp64_ = _data_->excluded_asset;
									if (string_contains (_data_->_tmp63_, _data_->_tmp64_)) {
										_data_->_vala1_excluded = TRUE;
										_g_free0 (_data_->excluded_asset);
										break;
									}
									_g_free0 (_data_->excluded_asset);
								}
							}
						}
						if (_data_->_vala1_excluded) {
							_g_free0 (_data_->release_date);
							_g_free0 (_data_->page_url);
							_g_free0 (_data_->description);
							_g_free0 (_data_->title);
							_json_array_unref0 (_data_->asset_array);
							_json_object_unref0 (_data_->object);
							continue;
						}
					}
				}
				_data_->_tmp65_ = proton_plus_models_runners_basic_get_asset_position ((ProtonPlusModelsRunnersBasic*) _data_->self);
				_data_->_tmp66_ = _data_->_tmp65_;
				_data_->real_asset_position = _data_->_tmp66_;
				_data_->_tmp67_ = proton_plus_models_runners_basic_get_asset_position_time_condition ((ProtonPlusModelsRunnersBasic*) _data_->self);
				_data_->_tmp68_ = _data_->_tmp67_;
				if (_data_->_tmp68_ != NULL) {
					_data_->_tmp69_ = proton_plus_models_runners_basic_get_asset_position_time_condition ((ProtonPlusModelsRunnersBasic*) _data_->self);
					_data_->_tmp70_ = _data_->_tmp69_;
					_data_->_tmp72_ = _data_->_tmp71_ = g_strsplit (_data_->_tmp70_, "|", 0);
					_data_->asset_position_time_condition_split = _data_->_tmp72_;
					_data_->asset_position_time_condition_split_length1 = _vala_array_length (_data_->_tmp71_);
					_data_->_asset_position_time_condition_split_size_ = _data_->asset_position_time_condition_split_length1;
					_data_->_tmp73_ = _data_->asset_position_time_condition_split;
					_data_->_tmp73__length1 = _data_->asset_position_time_condition_split_length1;
					if (_data_->_tmp73__length1 == 2) {
						_data_->_tmp74_ = _data_->asset_position_time_condition_split;
						_data_->_tmp74__length1 = _data_->asset_position_time_condition_split_length1;
						_data_->_tmp75_ = _data_->_tmp74_[0];
						_data_->_tmp76_ = g_date_time_new_from_iso8601 (_data_->_tmp75_, NULL);
						_data_->condition_time = _data_->_tmp76_;
						_data_->_tmp77_ = _data_->release_date;
						_data_->_tmp78_ = g_date_time_new_from_iso8601 (_data_->_tmp77_, NULL);
						_data_->release_time = _data_->_tmp78_;
						_data_->_tmp79_ = _data_->release_time;
						_data_->_tmp80_ = _data_->condition_time;
						_data_->_result_ = g_date_time_compare (_data_->_tmp79_, _data_->_tmp80_);
						if (_data_->_result_ <= 0) {
							_data_->number = 0;
							_data_->_tmp81_ = _data_->asset_position_time_condition_split;
							_data_->_tmp81__length1 = _data_->asset_position_time_condition_split_length1;
							_data_->_tmp82_ = _data_->_tmp81_[1];
							_data_->_tmp83_ = 0;
							_data_->_tmp84_ = int_try_parse (_data_->_tmp82_, &_data_->_tmp83_, NULL, (guint) 0);
							_data_->number = _data_->_tmp83_;
							_data_->parsed = _data_->_tmp84_;
							if (!_data_->parsed) {
								_g_date_time_unref0 (_data_->release_time);
								_g_date_time_unref0 (_data_->condition_time);
								_data_->asset_position_time_condition_split = (_vala_array_free (_data_->asset_position_time_condition_split, _data_->asset_position_time_condition_split_length1, (GDestroyNotify) g_free), NULL);
								_g_free0 (_data_->release_date);
								_g_free0 (_data_->page_url);
								_g_free0 (_data_->description);
								_g_free0 (_data_->title);
								_json_array_unref0 (_data_->asset_array);
								_json_object_unref0 (_data_->object);
								continue;
							}
							_data_->real_asset_position = _data_->number;
						}
						_g_date_time_unref0 (_data_->release_time);
						_g_date_time_unref0 (_data_->condition_time);
					}
					_data_->asset_position_time_condition_split = (_vala_array_free (_data_->asset_position_time_condition_split, _data_->asset_position_time_condition_split_length1, (GDestroyNotify) g_free), NULL);
				}
				_data_->_tmp85_ = proton_plus_models_runner_get_asset_position_hwcaps_condition ((ProtonPlusModelsRunner*) _data_->self);
				_data_->_tmp86_ = _data_->_tmp85_;
				if (_data_->_tmp86_) {
					{
						_data_->y = 0;
						{
							_data_->_tmp87_ = TRUE;
							while (TRUE) {
								if (!_data_->_tmp87_) {
									_data_->_tmp88_ = _data_->y;
									_data_->y = _data_->_tmp88_ + 1;
								}
								_data_->_tmp87_ = FALSE;
								_data_->_tmp89_ = _data_->asset_array;
								if (!(((guint) _data_->y) < json_array_get_length (_data_->_tmp89_))) {
									break;
								}
								_data_->_tmp90_ = _data_->asset_array;
								_data_->_tmp91_ = json_array_get_object_element (_data_->_tmp90_, (guint) _data_->y);
								_data_->_tmp92_ = _json_object_ref0 (_data_->_tmp91_);
								_data_->asset_object = _data_->_tmp92_;
								_data_->_tmp93_ = _data_->asset_object;
								_data_->_tmp94_ = json_object_get_string_member (_data_->_tmp93_, "name");
								_data_->_tmp95_ = proton_plus_globals_HWCAPS;
								_data_->_tmp96_ = g_list_nth_data (_data_->_tmp95_, (guint) 0);
								_data_->_tmp97_ = g_strdup_printf ("%s.tar.xz", (const gchar*) _data_->_tmp96_);
								_data_->_tmp98_ = _data_->_tmp97_;
								_data_->_tmp99_ = string_contains (_data_->_tmp94_, _data_->_tmp98_);
								_g_free0 (_data_->_tmp98_);
								if (_data_->_tmp99_) {
									_data_->real_asset_position = _data_->y;
									_json_object_unref0 (_data_->asset_object);
									break;
								}
								_json_object_unref0 (_data_->asset_object);
							}
						}
					}
				}
				_data_->_tmp100_ = _data_->asset_array;
				if ((json_array_get_length (_data_->_tmp100_) - 1) >= ((guint) _data_->real_asset_position)) {
					_data_->_tmp101_ = _data_->asset_array;
					_data_->_tmp102_ = json_array_get_object_element (_data_->_tmp101_, (guint) _data_->real_asset_position);
					_data_->_tmp103_ = _json_object_ref0 (_data_->_tmp102_);
					_data_->_vala1_asset_object = _data_->_tmp103_;
					_data_->_tmp104_ = _data_->_vala1_asset_object;
					_data_->_tmp105_ = json_object_get_string_member (_data_->_tmp104_, "browser_download_url");
					_data_->_tmp106_ = g_strdup (_data_->_tmp105_);
					_data_->download_url = _data_->_tmp106_;
					_data_->_tmp107_ = _data_->_vala1_asset_object;
					_data_->download_size = json_object_get_int_member (_data_->_tmp107_, "size");
					_data_->_tmp108_ = _data_->title;
					_data_->_tmp109_ = _data_->description;
					_data_->_tmp110_ = _data_->release_date;
					_data_->_tmp111_ = _data_->download_url;
					_data_->_tmp112_ = _data_->page_url;
					_data_->_tmp113_ = proton_plus_models_releases_basic_new_github ((ProtonPlusModelsRunnersBasic*) _data_->self, _data_->_tmp108_, _data_->_tmp109_, _data_->_tmp110_, _data_->download_size, _data_->_tmp111_, _data_->_tmp112_);
					_data_->release = _data_->_tmp113_;
					_data_->_tmp114_ = _data_->release;
					_data_->_tmp115_ = _g_object_ref0 ((ProtonPlusModelsRelease*) _data_->_tmp114_);
					_data_->releases = g_list_append (_data_->releases, _data_->_tmp115_);
					_data_->_tmp116_ = _data_->release;
					_data_->_tmp117_ = _g_object_ref0 ((ProtonPlusModelsRelease*) _data_->_tmp116_);
					((ProtonPlusModelsRunner*) _data_->self)->releases = g_list_append (((ProtonPlusModelsRunner*) _data_->self)->releases, _data_->_tmp117_);
					_g_object_unref0 (_data_->release);
					_g_free0 (_data_->download_url);
					_json_object_unref0 (_data_->_vala1_asset_object);
				}
				_g_free0 (_data_->release_date);
				_g_free0 (_data_->page_url);
				_g_free0 (_data_->description);
				_g_free0 (_data_->title);
				_json_array_unref0 (_data_->asset_array);
				_json_object_unref0 (_data_->object);
			}
		}
	}
	_data_->_tmp118_ = _data_->root_array;
	proton_plus_models_runner_set_has_more ((ProtonPlusModelsRunner*) _data_->self, json_array_get_length (_data_->_tmp118_) == ((guint) 25));
	_data_->result = PROTON_PLUS_RETURN_CODE_RELEASES_LOADED;
	_json_array_unref0 (_data_->root_array);
	__vala_JsonNode_free0 (_data_->root_node);
	_g_free0 (_data_->response);
	g_task_return_pointer (_data_->_async_result, _data_, NULL);
	if (_data_->_state_ != 0) {
		while (!g_task_get_completed (_data_->_async_result)) {
			g_main_context_iteration (g_task_get_context (_data_->_async_result), TRUE);
		}
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}

gboolean
proton_plus_models_runners_git_hub_get_use_name_instead_of_tag_name (ProtonPlusModelsRunnersGitHub* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_use_name_instead_of_tag_name;
	return result;
}

void
proton_plus_models_runners_git_hub_set_use_name_instead_of_tag_name (ProtonPlusModelsRunnersGitHub* self,
                                                                     gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = proton_plus_models_runners_git_hub_get_use_name_instead_of_tag_name (self);
	if (old_value != value) {
		self->priv->_use_name_instead_of_tag_name = value;
		g_object_notify_by_pspec ((GObject *) self, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY]);
	}
}

gchar**
proton_plus_models_runners_git_hub_get_request_asset_filter (ProtonPlusModelsRunnersGitHub* self,
                                                             gint* result_length1)
{
	gchar** result;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar** _tmp1_;
	gint _tmp1__length1;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_request_asset_filter;
	_tmp0__length1 = self->priv->_request_asset_filter_length1;
	_tmp1_ = _tmp0_;
	_tmp1__length1 = _tmp0__length1;
	if (result_length1) {
		*result_length1 = _tmp1__length1;
	}
	result = _tmp1_;
	return result;
}

static gchar**
_vala_array_dup7 (gchar** self,
                  gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

void
proton_plus_models_runners_git_hub_set_request_asset_filter (ProtonPlusModelsRunnersGitHub* self,
                                                             gchar** value,
                                                             gint value_length1)
{
	gchar** old_value;
	gint old_value_length;
	g_return_if_fail (self != NULL);
	old_value = proton_plus_models_runners_git_hub_get_request_asset_filter (self, &old_value_length);
	if (old_value != value) {
		gchar** _tmp0_;
		gint _tmp0__length1;
		_tmp0_ = (value != NULL) ? _vala_array_dup7 (value, value_length1) : value;
		_tmp0__length1 = value_length1;
		self->priv->_request_asset_filter = (_vala_array_free (self->priv->_request_asset_filter, self->priv->_request_asset_filter_length1, (GDestroyNotify) g_free), NULL);
		self->priv->_request_asset_filter = _tmp0_;
		self->priv->_request_asset_filter_length1 = _tmp0__length1;
		self->priv->__request_asset_filter_size_ = self->priv->_request_asset_filter_length1;
		g_object_notify_by_pspec ((GObject *) self, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY]);
	}
}

gchar**
proton_plus_models_runners_git_hub_get_request_asset_exclude (ProtonPlusModelsRunnersGitHub* self,
                                                              gint* result_length1)
{
	gchar** result;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar** _tmp1_;
	gint _tmp1__length1;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_request_asset_exclude;
	_tmp0__length1 = self->priv->_request_asset_exclude_length1;
	_tmp1_ = _tmp0_;
	_tmp1__length1 = _tmp0__length1;
	if (result_length1) {
		*result_length1 = _tmp1__length1;
	}
	result = _tmp1_;
	return result;
}

static gchar**
_vala_array_dup8 (gchar** self,
                  gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

void
proton_plus_models_runners_git_hub_set_request_asset_exclude (ProtonPlusModelsRunnersGitHub* self,
                                                              gchar** value,
                                                              gint value_length1)
{
	gchar** old_value;
	gint old_value_length;
	g_return_if_fail (self != NULL);
	old_value = proton_plus_models_runners_git_hub_get_request_asset_exclude (self, &old_value_length);
	if (old_value != value) {
		gchar** _tmp0_;
		gint _tmp0__length1;
		_tmp0_ = (value != NULL) ? _vala_array_dup8 (value, value_length1) : value;
		_tmp0__length1 = value_length1;
		self->priv->_request_asset_exclude = (_vala_array_free (self->priv->_request_asset_exclude, self->priv->_request_asset_exclude_length1, (GDestroyNotify) g_free), NULL);
		self->priv->_request_asset_exclude = _tmp0_;
		self->priv->_request_asset_exclude_length1 = _tmp0__length1;
		self->priv->__request_asset_exclude_size_ = self->priv->_request_asset_exclude_length1;
		g_object_notify_by_pspec ((GObject *) self, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY]);
	}
}

static void
proton_plus_models_runners_git_hub_class_init (ProtonPlusModelsRunnersGitHubClass * klass,
                                               gpointer klass_data)
{
	proton_plus_models_runners_git_hub_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &ProtonPlusModelsRunnersGitHub_private_offset);
	((ProtonPlusModelsRunnerClass *) klass)->load = (void (*) (ProtonPlusModelsRunner*, GAsyncReadyCallback, gpointer)) proton_plus_models_runners_git_hub_real_load;
	((ProtonPlusModelsRunnerClass *) klass)->load_finish = (ProtonPlusReturnCode (*) (ProtonPlusModelsRunner*, GAsyncResult*, GList**)) proton_plus_models_runners_git_hub_load_finish;
	G_OBJECT_CLASS (klass)->get_property = _vala_proton_plus_models_runners_git_hub_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_proton_plus_models_runners_git_hub_set_property;
	G_OBJECT_CLASS (klass)->finalize = proton_plus_models_runners_git_hub_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY] = g_param_spec_boolean ("use-name-instead-of-tag-name", "use-name-instead-of-tag-name", "use-name-instead-of-tag-name", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY] = g_param_spec_boxed ("request-asset-filter", "request-asset-filter", "request-asset-filter", G_TYPE_STRV, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY, proton_plus_models_runners_git_hub_properties[PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY] = g_param_spec_boxed ("request-asset-exclude", "request-asset-exclude", "request-asset-exclude", G_TYPE_STRV, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
proton_plus_models_runners_git_hub_instance_init (ProtonPlusModelsRunnersGitHub * self,
                                                  gpointer klass)
{
	self->priv = proton_plus_models_runners_git_hub_get_instance_private (self);
}

static void
proton_plus_models_runners_git_hub_finalize (GObject * obj)
{
	ProtonPlusModelsRunnersGitHub * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHub);
	self->priv->_request_asset_filter = (_vala_array_free (self->priv->_request_asset_filter, self->priv->_request_asset_filter_length1, (GDestroyNotify) g_free), NULL);
	self->priv->_request_asset_exclude = (_vala_array_free (self->priv->_request_asset_exclude, self->priv->_request_asset_exclude_length1, (GDestroyNotify) g_free), NULL);
	G_OBJECT_CLASS (proton_plus_models_runners_git_hub_parent_class)->finalize (obj);
}

static GType
proton_plus_models_runners_git_hub_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (ProtonPlusModelsRunnersGitHubClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) proton_plus_models_runners_git_hub_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ProtonPlusModelsRunnersGitHub), 0, (GInstanceInitFunc) proton_plus_models_runners_git_hub_instance_init, NULL };
	GType proton_plus_models_runners_git_hub_type_id;
	proton_plus_models_runners_git_hub_type_id = g_type_register_static (PROTON_PLUS_MODELS_RUNNERS_TYPE_BASIC, "ProtonPlusModelsRunnersGitHub", &g_define_type_info, 0);
	ProtonPlusModelsRunnersGitHub_private_offset = g_type_add_instance_private (proton_plus_models_runners_git_hub_type_id, sizeof (ProtonPlusModelsRunnersGitHubPrivate));
	return proton_plus_models_runners_git_hub_type_id;
}

GType
proton_plus_models_runners_git_hub_get_type (void)
{
	static volatile gsize proton_plus_models_runners_git_hub_type_id__once = 0;
	if (g_once_init_enter (&proton_plus_models_runners_git_hub_type_id__once)) {
		GType proton_plus_models_runners_git_hub_type_id;
		proton_plus_models_runners_git_hub_type_id = proton_plus_models_runners_git_hub_get_type_once ();
		g_once_init_leave (&proton_plus_models_runners_git_hub_type_id__once, proton_plus_models_runners_git_hub_type_id);
	}
	return proton_plus_models_runners_git_hub_type_id__once;
}

static void
_vala_proton_plus_models_runners_git_hub_get_property (GObject * object,
                                                       guint property_id,
                                                       GValue * value,
                                                       GParamSpec * pspec)
{
	ProtonPlusModelsRunnersGitHub * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHub);
	switch (property_id) {
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY:
		g_value_set_boolean (value, proton_plus_models_runners_git_hub_get_use_name_instead_of_tag_name (self));
		break;
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY:
		{
			int length;
			g_value_set_boxed (value, proton_plus_models_runners_git_hub_get_request_asset_filter (self, &length));
		}
		break;
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY:
		{
			int length;
			g_value_set_boxed (value, proton_plus_models_runners_git_hub_get_request_asset_exclude (self, &length));
		}
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_proton_plus_models_runners_git_hub_set_property (GObject * object,
                                                       guint property_id,
                                                       const GValue * value,
                                                       GParamSpec * pspec)
{
	ProtonPlusModelsRunnersGitHub * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, PROTON_PLUS_MODELS_RUNNERS_TYPE_GIT_HUB, ProtonPlusModelsRunnersGitHub);
	switch (property_id) {
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_USE_NAME_INSTEAD_OF_TAG_NAME_PROPERTY:
		proton_plus_models_runners_git_hub_set_use_name_instead_of_tag_name (self, g_value_get_boolean (value));
		break;
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_FILTER_PROPERTY:
		{
			gpointer boxed;
			boxed = g_value_get_boxed (value);
			proton_plus_models_runners_git_hub_set_request_asset_filter (self, boxed, (boxed == NULL) ? 0 : g_strv_length (boxed));
		}
		break;
		case PROTON_PLUS_MODELS_RUNNERS_GIT_HUB_REQUEST_ASSET_EXCLUDE_PROPERTY:
		{
			gpointer boxed;
			boxed = g_value_get_boxed (value);
			proton_plus_models_runners_git_hub_set_request_asset_exclude (self, boxed, (boxed == NULL) ? 0 : g_strv_length (boxed));
		}
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}

static void
_vala_array_free (gpointer array,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

static gssize
_vala_array_length (gpointer array)
{
	gssize length;
	length = 0;
	if (array) {
		while (((gpointer*) array)[length]) {
			length++;
		}
	}
	return length;
}

