/* InstanceAccount.c generated by valac 0.56.18-dirty, the Vala compiler
 * generated from InstanceAccount.vala, do not modify */

#include <glib-object.h>
#include <gtk/gtk.h>
#include <json-glib/json-glib.h>
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <gee.h>
#include <adwaita.h>
#include <libsoup/soup.h>
#include <glib/gi18n-lib.h>

#define TUBA_INSTANCE_ACCOUNT_EVENT_NEW_POST "update"
#define TUBA_INSTANCE_ACCOUNT_EVENT_EDIT_POST "status.update"
#define TUBA_INSTANCE_ACCOUNT_EVENT_DELETE_POST "delete"
#define TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATION "notification"
#define TUBA_INSTANCE_ACCOUNT_EVENT_CONVERSATION "conversation"
#define TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATIONS_MERGED "notifications_merged"
#define TUBA_INSTANCE_ACCOUNT_KIND_MENTION "mention"
#define TUBA_INSTANCE_ACCOUNT_KIND_REBLOG "reblog"
#define TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE "favourite"
#define TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW "follow"
#define TUBA_INSTANCE_ACCOUNT_KIND_POLL "poll"
#define TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST "follow_request"
#define TUBA_INSTANCE_ACCOUNT_KIND_REMOTE_REBLOG "__remote-reblog"
#define TUBA_INSTANCE_ACCOUNT_KIND_EDITED "update"
#define TUBA_INSTANCE_ACCOUNT_KIND_REPLY "tuba_reply"
#define TUBA_INSTANCE_ACCOUNT_KIND_SEVERED_RELATIONSHIPS "severed_relationships"
#define TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_REPORT "admin.report"
#define TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_SIGNUP "admin.sign_up"
#define TUBA_INSTANCE_ACCOUNT_KIND_STATUS "status"
#define TUBA_INSTANCE_ACCOUNT_KIND_PLEROMA_REACTION "pleroma:emoji_reaction"
#define TUBA_INSTANCE_ACCOUNT_KIND_REACTION "reaction"
#define TUBA_INSTANCE_ACCOUNT_KIND_ANNUAL_REPORT "annual_report"
#define TUBA_INSTANCE_ACCOUNT_KIND_MODERATION_WARNING "moderation_warning"
#define TUBA_INSTANCE_ACCOUNT_KIND_QUOTE "quote"
#define TUBA_INSTANCE_ACCOUNT_KIND_QUOTE_UPDATE "quoted_update"
#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 TUBA_TYPE_WIDGETIZABLE (tuba_widgetizable_get_type ())
#define TUBA_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizable))
#define TUBA_IS_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_WIDGETIZABLE))
#define TUBA_WIDGETIZABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizableIface))

typedef struct _TubaWidgetizable TubaWidgetizable;
typedef struct _TubaWidgetizableIface TubaWidgetizableIface;

#define TUBA_TYPE_ENTITY (tuba_entity_get_type ())
#define TUBA_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ENTITY, TubaEntity))
#define TUBA_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ENTITY, TubaEntityClass))
#define TUBA_IS_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ENTITY))
#define TUBA_IS_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ENTITY))
#define TUBA_ENTITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ENTITY, TubaEntityClass))

typedef struct _TubaEntity TubaEntity;
typedef struct _TubaEntityClass TubaEntityClass;

#define TUBA_API_TYPE_ACCOUNT (tuba_api_account_get_type ())
#define TUBA_API_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccount))
#define TUBA_API_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))
#define TUBA_API_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))

typedef struct _TubaAPIAccount TubaAPIAccount;
typedef struct _TubaAPIAccountClass TubaAPIAccountClass;

#define TUBA_TYPE_INSTANCE_ACCOUNT (tuba_instance_account_get_type ())
#define TUBA_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount))
#define TUBA_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))
#define TUBA_IS_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_IS_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_INSTANCE_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))

typedef struct _TubaInstanceAccount TubaInstanceAccount;
typedef struct _TubaInstanceAccountClass TubaInstanceAccountClass;
typedef struct _TubaEntityPrivate TubaEntityPrivate;

#define TUBA_API_TYPE_SEARCH_RESULT (tuba_api_search_result_get_type ())
#define TUBA_API_SEARCH_RESULT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_SEARCH_RESULT, TubaAPISearchResult))
#define TUBA_API_IS_SEARCH_RESULT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_SEARCH_RESULT))
#define TUBA_API_SEARCH_RESULT_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_API_TYPE_SEARCH_RESULT, TubaAPISearchResultIface))

typedef struct _TubaAPISearchResult TubaAPISearchResult;
typedef struct _TubaAPISearchResultIface TubaAPISearchResultIface;
typedef struct _TubaAPIAccountPrivate TubaAPIAccountPrivate;

#define TUBA_TYPE_STREAMABLE (tuba_streamable_get_type ())
#define TUBA_STREAMABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_STREAMABLE, TubaStreamable))
#define TUBA_IS_STREAMABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_STREAMABLE))
#define TUBA_STREAMABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_TYPE_STREAMABLE, TubaStreamableIface))

typedef struct _TubaStreamable TubaStreamable;
typedef struct _TubaStreamableIface TubaStreamableIface;
typedef struct _TubaInstanceAccountPrivate TubaInstanceAccountPrivate;

#define TUBA_INSTANCE_ACCOUNT_TYPE_KIND (tuba_instance_account_kind_get_type ())
typedef struct _TubaInstanceAccountKind TubaInstanceAccountKind;

#define TUBA_TYPE_PLACE (tuba_place_get_type ())
#define TUBA_PLACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_PLACE, TubaPlace))
#define TUBA_PLACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_PLACE, TubaPlaceClass))
#define TUBA_IS_PLACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_PLACE))
#define TUBA_IS_PLACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_PLACE))
#define TUBA_PLACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_PLACE, TubaPlaceClass))

typedef struct _TubaPlace TubaPlace;
typedef struct _TubaPlaceClass TubaPlaceClass;

#define TUBA_STREAMABLE_TYPE_EVENT (tuba_streamable_event_get_type ())
typedef struct _TubaStreamableEvent TubaStreamableEvent;

#define TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY (tuba_instance_account_visibility_get_type ())
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility))
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibilityClass))
#define TUBA_INSTANCE_ACCOUNT_IS_VISIBILITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY))
#define TUBA_INSTANCE_ACCOUNT_IS_VISIBILITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY))
#define TUBA_INSTANCE_ACCOUNT_VISIBILITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibilityClass))

typedef struct _TubaInstanceAccountVisibility TubaInstanceAccountVisibility;
typedef struct _TubaInstanceAccountVisibilityClass TubaInstanceAccountVisibilityClass;
typedef enum  {
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE = 1 << 0,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE = 1 << 1,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS = 1 << 2,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE = 1 << 3,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS = 1 << 4,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS = 1 << 5,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS = 1 << 6,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS = 1 << 7,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION = 1 << 8,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP = 1 << 9,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH = 1 << 10,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY = 1 << 11
} TubaInstanceAccountInstanceFeatures;

#define TUBA_INSTANCE_ACCOUNT_TYPE_INSTANCE_FEATURES (tuba_instance_account_instance_features_get_type ())

#define TUBA_API_TYPE_INSTANCE (tuba_api_instance_get_type ())
#define TUBA_API_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_INSTANCE, TubaAPIInstance))
#define TUBA_API_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_INSTANCE, TubaAPIInstanceClass))
#define TUBA_API_IS_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_INSTANCE))
#define TUBA_API_IS_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_INSTANCE))
#define TUBA_API_INSTANCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_INSTANCE, TubaAPIInstanceClass))

typedef struct _TubaAPIInstance TubaAPIInstance;
typedef struct _TubaAPIInstanceClass TubaAPIInstanceClass;

#define TUBA_API_TYPE_EMOJI (tuba_api_emoji_get_type ())
#define TUBA_API_EMOJI(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_EMOJI, TubaAPIEmoji))
#define TUBA_API_EMOJI_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_EMOJI, TubaAPIEmojiClass))
#define TUBA_API_IS_EMOJI(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_EMOJI))
#define TUBA_API_IS_EMOJI_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_EMOJI))
#define TUBA_API_EMOJI_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_EMOJI, TubaAPIEmojiClass))

typedef struct _TubaAPIEmoji TubaAPIEmoji;
typedef struct _TubaAPIEmojiClass TubaAPIEmojiClass;

#define TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS (tuba_api_instance_v2_api_versions_get_type ())
#define TUBA_API_INSTANCE_V2_API_VERSIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersions))
#define TUBA_API_INSTANCE_V2_API_VERSIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersionsClass))
#define TUBA_API_INSTANCE_V2_IS_API_VERSIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS))
#define TUBA_API_INSTANCE_V2_IS_API_VERSIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS))
#define TUBA_API_INSTANCE_V2_API_VERSIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, TubaAPIInstanceV2APIVersionsClass))

typedef struct _TubaAPIInstanceV2APIVersions TubaAPIInstanceV2APIVersions;
typedef struct _TubaAPIInstanceV2APIVersionsClass TubaAPIInstanceV2APIVersionsClass;

#define TUBA_API_TYPE_ANNUAL_REPORTS (tuba_api_annual_reports_get_type ())
#define TUBA_API_ANNUAL_REPORTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReports))
#define TUBA_API_ANNUAL_REPORTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReportsClass))
#define TUBA_API_IS_ANNUAL_REPORTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ANNUAL_REPORTS))
#define TUBA_API_IS_ANNUAL_REPORTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ANNUAL_REPORTS))
#define TUBA_API_ANNUAL_REPORTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ANNUAL_REPORTS, TubaAPIAnnualReportsClass))

typedef struct _TubaAPIAnnualReports TubaAPIAnnualReports;
typedef struct _TubaAPIAnnualReportsClass TubaAPIAnnualReportsClass;
enum  {
	TUBA_INSTANCE_ACCOUNT_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NUM_PROPERTIES];
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))

#define TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE (tuba_instance_account_status_content_type_get_type ())
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType))
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentTypeClass))
#define TUBA_INSTANCE_ACCOUNT_IS_STATUS_CONTENT_TYPE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE))
#define TUBA_INSTANCE_ACCOUNT_IS_STATUS_CONTENT_TYPE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE))
#define TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentTypeClass))

typedef struct _TubaInstanceAccountStatusContentType TubaInstanceAccountStatusContentType;
typedef struct _TubaInstanceAccountStatusContentTypeClass TubaInstanceAccountStatusContentTypeClass;

#define TUBA_TYPE_SETTINGS (tuba_settings_get_type ())
#define TUBA_SETTINGS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_SETTINGS, TubaSettings))
#define TUBA_SETTINGS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_SETTINGS, TubaSettingsClass))
#define TUBA_IS_SETTINGS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_SETTINGS))
#define TUBA_IS_SETTINGS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_SETTINGS))
#define TUBA_SETTINGS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_SETTINGS, TubaSettingsClass))

typedef struct _TubaSettings TubaSettings;
typedef struct _TubaSettingsClass TubaSettingsClass;

#define TUBA_TYPE_ACCOUNT_STORE (tuba_account_store_get_type ())
#define TUBA_ACCOUNT_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStore))
#define TUBA_ACCOUNT_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStoreClass))
#define TUBA_IS_ACCOUNT_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ACCOUNT_STORE))
#define TUBA_IS_ACCOUNT_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ACCOUNT_STORE))
#define TUBA_ACCOUNT_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ACCOUNT_STORE, TubaAccountStoreClass))

typedef struct _TubaAccountStore TubaAccountStore;
typedef struct _TubaAccountStoreClass TubaAccountStoreClass;
#define _g_uri_unref0(var) ((var == NULL) ? NULL : (var = (g_uri_unref (var), NULL)))

#define TUBA_TYPE_APPLICATION (tuba_application_get_type ())
#define TUBA_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_APPLICATION, TubaApplication))
#define TUBA_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_APPLICATION, TubaApplicationClass))
#define TUBA_IS_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_APPLICATION))
#define TUBA_IS_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_APPLICATION))
#define TUBA_APPLICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_APPLICATION, TubaApplicationClass))

typedef struct _TubaApplication TubaApplication;
typedef struct _TubaApplicationClass TubaApplicationClass;

#define TUBA_TYPE_STREAMS (tuba_streams_get_type ())
#define TUBA_STREAMS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_STREAMS, TubaStreams))
#define TUBA_STREAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_STREAMS, TubaStreamsClass))
#define TUBA_IS_STREAMS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_STREAMS))
#define TUBA_IS_STREAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_STREAMS))
#define TUBA_STREAMS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_STREAMS, TubaStreamsClass))

typedef struct _TubaStreams TubaStreams;
typedef struct _TubaStreamsClass TubaStreamsClass;

#define TUBA_TYPE_REQUEST (tuba_request_get_type ())
#define TUBA_REQUEST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_REQUEST, TubaRequest))
#define TUBA_REQUEST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_REQUEST, TubaRequestClass))
#define TUBA_IS_REQUEST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_REQUEST))
#define TUBA_IS_REQUEST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_REQUEST))
#define TUBA_REQUEST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_REQUEST, TubaRequestClass))

typedef struct _TubaRequest TubaRequest;
typedef struct _TubaRequestClass TubaRequestClass;
typedef void (*TubaNetworkSuccessCallback) (GInputStream* in_stream, SoupMessageHeaders* response_headers, gpointer user_data, GError** error);

#define TUBA_TYPE_NETWORK (tuba_network_get_type ())
#define TUBA_NETWORK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_NETWORK, TubaNetwork))
#define TUBA_NETWORK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_NETWORK, TubaNetworkClass))
#define TUBA_IS_NETWORK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_NETWORK))
#define TUBA_IS_NETWORK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_NETWORK))
#define TUBA_NETWORK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_NETWORK, TubaNetworkClass))

typedef struct _TubaNetwork TubaNetwork;
typedef struct _TubaNetworkClass TubaNetworkClass;
#define __vala_JsonNode_free0(var) ((var == NULL) ? NULL : (var = (_vala_JsonNode_free (var), NULL)))
typedef struct _TubaInstanceAccountVerifyCredentialsData TubaInstanceAccountVerifyCredentialsData;

#define TUBA_API_TYPE_SEARCH_RESULTS (tuba_api_search_results_get_type ())
#define TUBA_API_SEARCH_RESULTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResults))
#define TUBA_API_SEARCH_RESULTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResultsClass))
#define TUBA_API_IS_SEARCH_RESULTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_SEARCH_RESULTS))
#define TUBA_API_IS_SEARCH_RESULTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_SEARCH_RESULTS))
#define TUBA_API_SEARCH_RESULTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_SEARCH_RESULTS, TubaAPISearchResultsClass))

typedef struct _TubaAPISearchResults TubaAPISearchResults;
typedef struct _TubaAPISearchResultsClass TubaAPISearchResultsClass;
typedef struct _TubaInstanceAccountResolveData TubaInstanceAccountResolveData;

#define TUBA_API_PLEROMA_TYPE_INSTANCE (tuba_api_pleroma_instance_get_type ())
#define TUBA_API_PLEROMA_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstance))
#define TUBA_API_PLEROMA_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstanceClass))
#define TUBA_API_PLEROMA_IS_INSTANCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE))
#define TUBA_API_PLEROMA_IS_INSTANCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_PLEROMA_TYPE_INSTANCE))
#define TUBA_API_PLEROMA_INSTANCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_PLEROMA_TYPE_INSTANCE, TubaAPIPleromaInstanceClass))

typedef struct _TubaAPIPleromaInstance TubaAPIPleromaInstance;
typedef struct _TubaAPIPleromaInstanceClass TubaAPIPleromaInstanceClass;

#define TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA (tuba_api_pleroma_instance_metadata_get_type ())
#define TUBA_API_PLEROMA_INSTANCE_METADATA(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadata))
#define TUBA_API_PLEROMA_INSTANCE_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadataClass))
#define TUBA_API_PLEROMA_INSTANCE_IS_METADATA(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA))
#define TUBA_API_PLEROMA_INSTANCE_IS_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA))
#define TUBA_API_PLEROMA_INSTANCE_METADATA_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_PLEROMA_INSTANCE_TYPE_METADATA, TubaAPIPleromaInstanceMetadataClass))

typedef struct _TubaAPIPleromaInstanceMetadata TubaAPIPleromaInstanceMetadata;
typedef struct _TubaAPIPleromaInstanceMetadataClass TubaAPIPleromaInstanceMetadataClass;

#define TUBA_API_INSTANCE_TYPE_URLS (tuba_api_instance_urls_get_type ())
#define TUBA_API_INSTANCE_URLS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrls))
#define TUBA_API_INSTANCE_URLS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrlsClass))
#define TUBA_API_INSTANCE_IS_URLS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_TYPE_URLS))
#define TUBA_API_INSTANCE_IS_URLS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_TYPE_URLS))
#define TUBA_API_INSTANCE_URLS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_TYPE_URLS, TubaAPIInstanceUrlsClass))

typedef struct _TubaAPIInstanceUrls TubaAPIInstanceUrls;
typedef struct _TubaAPIInstanceUrlsClass TubaAPIInstanceUrlsClass;

#define TUBA_API_TYPE_INSTANCE_V2 (tuba_api_instance_v2_get_type ())
#define TUBA_API_INSTANCE_V2(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2))
#define TUBA_API_INSTANCE_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2Class))
#define TUBA_API_IS_INSTANCE_V2(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_INSTANCE_V2))
#define TUBA_API_IS_INSTANCE_V2_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_INSTANCE_V2))
#define TUBA_API_INSTANCE_V2_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_INSTANCE_V2, TubaAPIInstanceV2Class))

typedef struct _TubaAPIInstanceV2 TubaAPIInstanceV2;
typedef struct _TubaAPIInstanceV2Class TubaAPIInstanceV2Class;

#define TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION (tuba_api_instance_v2_configuration_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2Configuration))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2ConfigurationClass))
#define TUBA_API_INSTANCE_V2_IS_CONFIGURATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION))
#define TUBA_API_INSTANCE_V2_IS_CONFIGURATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_TYPE_CONFIGURATION, TubaAPIInstanceV2ConfigurationClass))

typedef struct _TubaAPIInstanceV2Configuration TubaAPIInstanceV2Configuration;
typedef struct _TubaAPIInstanceV2ConfigurationClass TubaAPIInstanceV2ConfigurationClass;

#define TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION (tuba_api_instance_v2_configuration_translation_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslation))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslationClass))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_TRANSLATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_TRANSLATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_TRANSLATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_TRANSLATION, TubaAPIInstanceV2ConfigurationTranslationClass))

typedef struct _TubaAPIInstanceV2ConfigurationTranslation TubaAPIInstanceV2ConfigurationTranslation;
typedef struct _TubaAPIInstanceV2ConfigurationTranslationClass TubaAPIInstanceV2ConfigurationTranslationClass;

#define TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS (tuba_api_instance_v2_configuration_media_attachments_get_type ())
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachments))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachmentsClass))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_MEDIA_ATTACHMENTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_IS_MEDIA_ATTACHMENTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS))
#define TUBA_API_INSTANCE_V2_CONFIGURATION_MEDIA_ATTACHMENTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_INSTANCE_V2_CONFIGURATION_TYPE_MEDIA_ATTACHMENTS, TubaAPIInstanceV2ConfigurationMediaAttachmentsClass))

typedef struct _TubaAPIInstanceV2ConfigurationMediaAttachments TubaAPIInstanceV2ConfigurationMediaAttachments;
typedef struct _TubaAPIInstanceV2ConfigurationMediaAttachmentsClass TubaAPIInstanceV2ConfigurationMediaAttachmentsClass;
typedef struct _Block50Data Block50Data;
#define _g_time_zone_unref0(var) ((var == NULL) ? NULL : (var = (g_time_zone_unref (var), NULL)))
#define _g_date_time_unref0(var) ((var == NULL) ? NULL : (var = (g_date_time_unref (var), NULL)))

#define TUBA_API_ANNUAL_REPORTS_TYPE_REPORT (tuba_api_annual_reports_report_get_type ())
#define TUBA_API_ANNUAL_REPORTS_REPORT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReport))
#define TUBA_API_ANNUAL_REPORTS_REPORT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReportClass))
#define TUBA_API_ANNUAL_REPORTS_IS_REPORT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT))
#define TUBA_API_ANNUAL_REPORTS_IS_REPORT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT))
#define TUBA_API_ANNUAL_REPORTS_REPORT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_ANNUAL_REPORTS_TYPE_REPORT, TubaAPIAnnualReportsReportClass))

typedef struct _TubaAPIAnnualReportsReport TubaAPIAnnualReportsReport;
typedef struct _TubaAPIAnnualReportsReportClass TubaAPIAnnualReportsReportClass;

#define TUBA_DIALOGS_TYPE_MAIN_WINDOW (tuba_dialogs_main_window_get_type ())
#define TUBA_DIALOGS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindow))
#define TUBA_DIALOGS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindowClass))
#define TUBA_DIALOGS_IS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW))
#define TUBA_DIALOGS_IS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_DIALOGS_TYPE_MAIN_WINDOW))
#define TUBA_DIALOGS_MAIN_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_DIALOGS_TYPE_MAIN_WINDOW, TubaDialogsMainWindowClass))

typedef struct _TubaDialogsMainWindow TubaDialogsMainWindow;
typedef struct _TubaDialogsMainWindowClass TubaDialogsMainWindowClass;

#define TUBA_VIEWS_TYPE_BASE (tuba_views_base_get_type ())
#define TUBA_VIEWS_BASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_BASE, TubaViewsBase))
#define TUBA_VIEWS_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_BASE, TubaViewsBaseClass))
#define TUBA_VIEWS_IS_BASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_BASE))
#define TUBA_VIEWS_IS_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_BASE))
#define TUBA_VIEWS_BASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_BASE, TubaViewsBaseClass))

typedef struct _TubaViewsBase TubaViewsBase;
typedef struct _TubaViewsBaseClass TubaViewsBaseClass;

#define TUBA_VIEWS_TYPE_CONTENT_BASE (tuba_views_content_base_get_type ())
#define TUBA_VIEWS_CONTENT_BASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBase))
#define TUBA_VIEWS_CONTENT_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBaseClass))
#define TUBA_VIEWS_IS_CONTENT_BASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE))
#define TUBA_VIEWS_IS_CONTENT_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_CONTENT_BASE))
#define TUBA_VIEWS_CONTENT_BASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_CONTENT_BASE, TubaViewsContentBaseClass))

typedef struct _TubaViewsContentBase TubaViewsContentBase;
typedef struct _TubaViewsContentBaseClass TubaViewsContentBaseClass;

#define TUBA_VIEWS_TYPE_TIMELINE (tuba_views_timeline_get_type ())
#define TUBA_VIEWS_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimeline))
#define TUBA_VIEWS_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimelineClass))
#define TUBA_VIEWS_IS_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_TIMELINE))
#define TUBA_VIEWS_IS_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_TIMELINE))
#define TUBA_VIEWS_TIMELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_TIMELINE, TubaViewsTimelineClass))

typedef struct _TubaViewsTimeline TubaViewsTimeline;
typedef struct _TubaViewsTimelineClass TubaViewsTimelineClass;

#define TUBA_VIEWS_TYPE_HASHTAG (tuba_views_hashtag_get_type ())
#define TUBA_VIEWS_HASHTAG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtag))
#define TUBA_VIEWS_HASHTAG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtagClass))
#define TUBA_VIEWS_IS_HASHTAG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_HASHTAG))
#define TUBA_VIEWS_IS_HASHTAG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_HASHTAG))
#define TUBA_VIEWS_HASHTAG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_HASHTAG, TubaViewsHashtagClass))

typedef struct _TubaViewsHashtag TubaViewsHashtag;
typedef struct _TubaViewsHashtagClass TubaViewsHashtagClass;
typedef void (*TubaPlaceOpenFunc) (TubaDialogsMainWindow* window, GObject* extra);
typedef struct _Block51Data Block51Data;
typedef void (*TubaNetworkNodeCallback) (JsonNode* node, gpointer user_data, GError** error);

#define TUBA_API_TYPE_LIST (tuba_api_list_get_type ())
#define TUBA_API_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_LIST, TubaAPIList))
#define TUBA_API_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_LIST, TubaAPIListClass))
#define TUBA_API_IS_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_LIST))
#define TUBA_API_IS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_LIST))
#define TUBA_API_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_LIST, TubaAPIListClass))

typedef struct _TubaAPIList TubaAPIList;
typedef struct _TubaAPIListClass TubaAPIListClass;

#define TUBA_VIEWS_TYPE_LIST (tuba_views_list_get_type ())
#define TUBA_VIEWS_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_TYPE_LIST, TubaViewsList))
#define TUBA_VIEWS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_TYPE_LIST, TubaViewsListClass))
#define TUBA_VIEWS_IS_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_TYPE_LIST))
#define TUBA_VIEWS_IS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_TYPE_LIST))
#define TUBA_VIEWS_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_TYPE_LIST, TubaViewsListClass))

typedef struct _TubaViewsList TubaViewsList;
typedef struct _TubaViewsListClass TubaViewsListClass;
#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)))
typedef struct _Block52Data Block52Data;

#define TUBA_API_TYPE_NOTIFICATION (tuba_api_notification_get_type ())
#define TUBA_API_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_NOTIFICATION, TubaAPINotification))
#define TUBA_API_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_NOTIFICATION, TubaAPINotificationClass))
#define TUBA_API_IS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_NOTIFICATION))
#define TUBA_API_IS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_NOTIFICATION))
#define TUBA_API_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_NOTIFICATION, TubaAPINotificationClass))

typedef struct _TubaAPINotification TubaAPINotification;
typedef struct _TubaAPINotificationClass TubaAPINotificationClass;
typedef struct _Block53Data Block53Data;

#define TUBA_API_TYPE_STATUS (tuba_api_status_get_type ())
#define TUBA_API_STATUS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_STATUS, TubaAPIStatus))
#define TUBA_API_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_STATUS, TubaAPIStatusClass))
#define TUBA_API_IS_STATUS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_STATUS))
#define TUBA_API_IS_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_STATUS))
#define TUBA_API_STATUS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_STATUS, TubaAPIStatusClass))

typedef struct _TubaAPIStatus TubaAPIStatus;
typedef struct _TubaAPIStatusClass TubaAPIStatusClass;

#define TUBA_SETTINGS_TYPE_ACCOUNT (tuba_settings_account_get_type ())
#define TUBA_SETTINGS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccount))
#define TUBA_SETTINGS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccountClass))
#define TUBA_SETTINGS_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_SETTINGS_TYPE_ACCOUNT))
#define TUBA_SETTINGS_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_SETTINGS_TYPE_ACCOUNT))
#define TUBA_SETTINGS_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccountClass))

typedef struct _TubaSettingsAccount TubaSettingsAccount;
typedef struct _TubaSettingsAccountClass TubaSettingsAccountClass;
typedef struct _TubaInstanceAccountVisibilityPrivate TubaInstanceAccountVisibilityPrivate;
enum  {
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_VISIBILITY_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NUM_PROPERTIES];
typedef struct _TubaInstanceAccountStatusContentTypePrivate TubaInstanceAccountStatusContentTypePrivate;
enum  {
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_0_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY,
	TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_NUM_PROPERTIES
};
static GParamSpec* tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_NUM_PROPERTIES];
enum  {
	TUBA_INSTANCE_ACCOUNT_ACTIVATED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_DEACTIVATED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_ADDED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_REMOVED_SIGNAL,
	TUBA_INSTANCE_ACCOUNT_NUM_SIGNALS
};
static guint tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_NUM_SIGNALS] = {0};

struct _TubaWidgetizableIface {
	GTypeInterface parent_iface;
	GtkWidget* (*to_widget) (TubaWidgetizable* self);
	void (*open) (TubaWidgetizable* self);
	void (*resolve_open) (TubaWidgetizable* self, TubaInstanceAccount* account);
};

struct _TubaEntity {
	GObject parent_instance;
	TubaEntityPrivate * priv;
};

struct _TubaEntityClass {
	GObjectClass parent_class;
	gboolean (*is_local) (TubaEntity* self, TubaInstanceAccount* account);
	GType (*deserialize_array_type) (TubaEntity* self, const gchar* prop);
};

struct _TubaAPISearchResultIface {
	GTypeInterface parent_iface;
	GRegex* (*get_tuba_search_query_regex) (TubaAPISearchResult* self);
	void (*set_tuba_search_query_regex) (TubaAPISearchResult* self, GRegex* value);
};

struct _TubaAPIAccount {
	TubaEntity parent_instance;
	TubaAPIAccountPrivate * priv;
};

struct _TubaAPIAccountClass {
	TubaEntityClass parent_class;
};

struct _TubaStreamableIface {
	GTypeInterface parent_iface;
	gchar* (*get_stream_url) (TubaStreamable* self);
	void (*on_streaming_policy_changed) (TubaStreamable* self);
	const gchar* (*get_t_connection_url) (TubaStreamable* self);
	void (*set_t_connection_url) (TubaStreamable* self, const gchar* value);
	gboolean (*get_subscribed) (TubaStreamable* self);
	void (*set_subscribed) (TubaStreamable* self, gboolean value);
};

struct _TubaInstanceAccountKind {
	gchar* icon;
	gchar* description;
	gchar* url;
};

struct _TubaStreamableEvent {
	gchar* type;
	JsonNode* payload;
};

struct _TubaInstanceAccount {
	TubaAPIAccount parent_instance;
	TubaInstanceAccountPrivate * priv;
	GListStore* known_places;
	GListStore* list_places;
	GListStore* tags_places;
	GeeHashMap* type_overrides;
	GeeHashMap* visibility;
	GListStore* visibility_list;
	GListStore* supported_mime_types;
};

struct _TubaInstanceAccountClass {
	TubaAPIAccountClass parent_class;
	void (*describe_kind) (TubaInstanceAccount* self, const gchar* kind, TubaInstanceAccountKind* _result_, const gchar* actor_name, const gchar* callback_url, const gchar* other_data);
	void (*register_known_places) (TubaInstanceAccount* self, GListStore* places);
	void (*register_extra) (TubaInstanceAccount* self, GListStore* places, TubaPlace** extra, gint extra_length1);
	void (*bump_sidebar_items) (TubaInstanceAccount* self);
	void (*check_notifications) (TubaInstanceAccount* self);
	gchar* (*get_stream_url) (TubaInstanceAccount* self);
	void (*on_notification_event) (TubaInstanceAccount* self, TubaStreamableEvent* ev);
	void (*open_status_url) (TubaInstanceAccount* self, const gchar* url);
	void (*answer_follow_request) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* fr_id, gboolean accept);
	void (*follow_back) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* acc_id);
	void (*reply_to_status_uri) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* uri);
	void (*remove_from_followers) (TubaInstanceAccount* self, const gchar* issuer_id, const gchar* acc_id);
	void (*activated) (TubaInstanceAccount* self);
	void (*deactivated) (TubaInstanceAccount* self);
	void (*added) (TubaInstanceAccount* self);
	void (*removed) (TubaInstanceAccount* self);
};

struct _TubaInstanceAccountPrivate {
	TubaInstanceAccountInstanceFeatures _tuba_instance_features;
	gchar* _tuba_iceshrimp_api_key;
	gchar* _tuba_streaming_url;
	gchar* _uuid;
	gboolean _admin_mode;
	gchar* _backend;
	TubaAPIInstance* _instance_info;
	GeeArrayList* _instance_emojis;
	gchar* _instance;
	gchar* _client_id;
	gchar* _client_secret;
	gchar* _access_token;
	gboolean _needs_update;
	GError* _error;
	gboolean _tuba_probably_has_notification_filters;
	TubaAPIInstanceV2APIVersions* _tuba_api_versions;
	gint _unreviewed_follow_requests;
	gint _unread_announcements;
	gint _filtered_notifications_count;
	gint _unread_count;
	gint _last_read_id;
	gint _last_received_id;
	gint _tuba_last_fediwrapped_year;
	TubaAPIAnnualReports* annual_report;
	GeeHashMap* sent_notifications;
	gchar* _t_connection_url;
	gboolean _subscribed;
	GSettings* _account_settings;
};

struct _TubaInstanceAccountVerifyCredentialsData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	TubaRequest* req;
	TubaRequest* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	GInputStream* _tmp8_;
	GInputStream* _tmp9_;
	GError* _inner_error0_;
};

struct _TubaInstanceAccountResolveData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GTask* _async_result;
	TubaInstanceAccount* self;
	gchar* url;
	TubaEntity* result;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	TubaAPISearchResults* results;
	TubaAPISearchResults* _tmp3_;
	TubaEntity* entity;
	TubaAPISearchResults* _tmp4_;
	TubaEntity* _tmp5_;
	TubaEntity* _tmp6_;
	GObjectClass* _tmp7_;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	GError* _inner_error0_;
};

struct _Block50Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	gint year;
};

struct _Block51Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	TubaPlace** fav_lists;
	gint fav_lists_length1;
	gint _fav_lists_size_;
	gchar** all_ids;
	gint all_ids_length1;
	gint _all_ids_size_;
};

struct _Block52Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	gint t_unread_announcements;
};

struct _Block53Data {
	int _ref_count_;
	TubaInstanceAccount* self;
	gchar* id;
	TubaAPINotification* obj;
};

struct _TubaInstanceAccountVisibility {
	GObject parent_instance;
	TubaInstanceAccountVisibilityPrivate * priv;
};

struct _TubaInstanceAccountVisibilityClass {
	GObjectClass parent_class;
};

struct _TubaInstanceAccountVisibilityPrivate {
	gchar* _id;
	gchar* _name;
	gchar* _icon_name;
	gchar* _description;
	gchar* _small_icon_name;
};

struct _TubaInstanceAccountStatusContentType {
	GObject parent_instance;
	TubaInstanceAccountStatusContentTypePrivate * priv;
};

struct _TubaInstanceAccountStatusContentTypeClass {
	GObjectClass parent_class;
};

struct _TubaInstanceAccountStatusContentTypePrivate {
	gchar* _mime;
	gchar* _icon_name;
	gchar* _title;
	gchar* _syntax;
};

static gint TubaInstanceAccount_private_offset;
static gpointer tuba_instance_account_parent_class = NULL;
VALA_EXTERN TubaSettings* tuba_settings;
VALA_EXTERN TubaAccountStore* tuba_accounts;
VALA_EXTERN TubaApplication* tuba_app;
VALA_EXTERN TubaNetwork* tuba_network;
static gint TubaInstanceAccountVisibility_private_offset;
static gpointer tuba_instance_account_visibility_parent_class = NULL;
static gint TubaInstanceAccountStatusContentType_private_offset;
static gpointer tuba_instance_account_status_content_type_parent_class = NULL;
VALA_EXTERN GEqualFunc tuba_instance_account_status_content_type_compare;
GEqualFunc tuba_instance_account_status_content_type_compare = NULL;
static TubaStreamableIface * tuba_instance_account_tuba_streamable_parent_iface = NULL;

VALA_EXTERN GType tuba_entity_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaEntity, g_object_unref)
VALA_EXTERN GType tuba_api_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAccount, g_object_unref)
VALA_EXTERN GType tuba_instance_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccount, g_object_unref)
VALA_EXTERN GType tuba_widgetizable_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaWidgetizable, g_object_unref)
VALA_EXTERN GType tuba_api_search_result_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPISearchResult, g_object_unref)
VALA_EXTERN GType tuba_streamable_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaStreamable, g_object_unref)
VALA_EXTERN GType tuba_instance_account_kind_get_type (void) G_GNUC_CONST ;
VALA_EXTERN TubaInstanceAccountKind* tuba_instance_account_kind_dup (const TubaInstanceAccountKind* self);
VALA_EXTERN void tuba_instance_account_kind_free (TubaInstanceAccountKind* self);
VALA_EXTERN void tuba_instance_account_kind_copy (const TubaInstanceAccountKind* self,
                                      TubaInstanceAccountKind* dest);
VALA_EXTERN void tuba_instance_account_kind_destroy (TubaInstanceAccountKind* self);
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (TubaInstanceAccountKind, tuba_instance_account_kind_destroy)
VALA_EXTERN GType tuba_place_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaPlace, g_object_unref)
VALA_EXTERN GType tuba_streamable_event_get_type (void) G_GNUC_CONST ;
VALA_EXTERN TubaStreamableEvent* tuba_streamable_event_dup (const TubaStreamableEvent* self);
VALA_EXTERN void tuba_streamable_event_free (TubaStreamableEvent* self);
VALA_EXTERN void tuba_streamable_event_copy (const TubaStreamableEvent* self,
                                 TubaStreamableEvent* dest);
VALA_EXTERN void tuba_streamable_event_destroy (TubaStreamableEvent* self);
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (TubaStreamableEvent, tuba_streamable_event_destroy)
VALA_EXTERN GType tuba_instance_account_visibility_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccountVisibility, g_object_unref)
VALA_EXTERN GType tuba_instance_account_instance_features_get_type (void) G_GNUC_CONST ;
VALA_EXTERN GType tuba_api_instance_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstance, g_object_unref)
VALA_EXTERN GType tuba_api_emoji_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIEmoji, g_object_unref)
VALA_EXTERN GType tuba_api_instance_v2_api_versions_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2APIVersions, g_object_unref)
VALA_EXTERN GType tuba_api_annual_reports_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAnnualReports, g_object_unref)
VALA_EXTERN void tuba_instance_account_describe_kind (TubaInstanceAccount* self,
                                          const gchar* kind,
                                          TubaInstanceAccountKind* _result_,
                                          const gchar* actor_name,
                                          const gchar* callback_url,
                                          const gchar* other_data);
VALA_EXTERN void tuba_instance_account_register_known_places (TubaInstanceAccount* self,
                                                  GListStore* places);
VALA_EXTERN void tuba_instance_account_register_extra (TubaInstanceAccount* self,
                                           GListStore* places,
                                           TubaPlace** extra,
                                           gint extra_length1);
VALA_EXTERN void tuba_instance_account_bump_sidebar_items (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_check_notifications (TubaInstanceAccount* self);
VALA_EXTERN gchar* tuba_instance_account_get_stream_url (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_on_notification_event (TubaInstanceAccount* self,
                                                  TubaStreamableEvent* ev);
VALA_EXTERN void tuba_instance_account_open_status_url (TubaInstanceAccount* self,
                                            const gchar* url);
VALA_EXTERN void tuba_instance_account_answer_follow_request (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* fr_id,
                                                  gboolean accept);
VALA_EXTERN void tuba_instance_account_follow_back (TubaInstanceAccount* self,
                                        const gchar* issuer_id,
                                        const gchar* acc_id);
VALA_EXTERN void tuba_instance_account_reply_to_status_uri (TubaInstanceAccount* self,
                                                const gchar* issuer_id,
                                                const gchar* uri);
VALA_EXTERN void tuba_instance_account_remove_from_followers (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* acc_id);
VALA_EXTERN void tuba_streamable_destruct_streamable (TubaStreamable* self);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_api_versions_new (void);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_api_versions_construct (GType object_type);
VALA_EXTERN GType tuba_instance_account_status_content_type_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccountStatusContentType, g_object_unref)
static void tuba_instance_account_tuba_instance_features_update_and_save (TubaInstanceAccount* self,
                                                                   TubaInstanceAccountInstanceFeatures features);
VALA_EXTERN TubaInstanceAccountInstanceFeatures tuba_instance_account_get_tuba_instance_features (TubaInstanceAccount* self);
VALA_EXTERN GType tuba_settings_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaSettings, g_object_unref)
VALA_EXTERN void tuba_instance_account_set_tuba_instance_features (TubaInstanceAccount* self,
                                                       TubaInstanceAccountInstanceFeatures value);
VALA_EXTERN GType tuba_account_store_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAccountStore, g_object_unref)
VALA_EXTERN void tuba_account_store_update_account (TubaAccountStore* self,
                                        TubaInstanceAccount* account,
                                        GError** error);
VALA_EXTERN const gchar* tuba_api_account_get_id (TubaAPIAccount* self);
VALA_EXTERN void tuba_instance_account_tuba_update_iceshrimp_api_key (TubaInstanceAccount* self,
                                                          const gchar* new_key);
VALA_EXTERN const gchar* tuba_instance_account_get_tuba_iceshrimp_api_key (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_tuba_iceshrimp_api_key (TubaInstanceAccount* self,
                                                       const gchar* value);
static void tuba_instance_account_tuba_update_streaming_url (TubaInstanceAccount* self,
                                                      const gchar* new_url);
VALA_EXTERN const gchar* tuba_instance_account_get_instance (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_instance_account_get_tuba_streaming_url (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_tuba_streaming_url (TubaInstanceAccount* self,
                                                   const gchar* value);
VALA_EXTERN GType tuba_application_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaApplication, g_object_unref)
VALA_EXTERN GType tuba_streams_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaStreams, g_object_unref)
VALA_EXTERN TubaStreams* tuba_application_get_app_streams (TubaApplication* self);
VALA_EXTERN void tuba_streams_upgrade (TubaStreams* self,
                           const gchar* old_url,
                           const gchar* new_url);
VALA_EXTERN void tuba_instance_account_reconnect (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_gather_instance_info (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_gather_instance_custom_emojis (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_instance_account_gather_fav_lists (TubaInstanceAccount* self);
static gboolean _tuba_instance_account_gather_fav_lists_gsource_func (gpointer self);
VALA_EXTERN gboolean tuba_instance_account_gather_fav_tags (TubaInstanceAccount* self);
static gboolean _tuba_instance_account_gather_fav_tags_gsource_func (gpointer self);
VALA_EXTERN void tuba_instance_account_check_announcements (TubaInstanceAccount* self);
static void tuba_instance_account_on_network_change (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_instance_account_get_is_active (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_application_get_is_online (TubaApplication* self);
VALA_EXTERN gboolean tuba_instance_account_get_needs_update (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_needs_update (TubaInstanceAccount* self,
                                             gboolean value);
VALA_EXTERN TubaRequest* tuba_request_new_GET (const gchar* url);
VALA_EXTERN TubaRequest* tuba_request_construct_GET (GType object_type,
                                         const gchar* url);
VALA_EXTERN GType tuba_request_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaRequest, g_object_unref)
VALA_EXTERN TubaRequest* tuba_request_with_account (TubaRequest* self,
                                        TubaInstanceAccount* account);
VALA_EXTERN TubaRequest* tuba_request_then (TubaRequest* self,
                                TubaNetworkSuccessCallback cb,
                                gpointer cb_target,
                                GDestroyNotify cb_target_destroy_notify);
static void ____lambda313_ (TubaInstanceAccount* self,
                     GInputStream* in_stream,
                     GError** error);
VALA_EXTERN JsonParser* tuba_network_get_parser_from_inputstream (GInputStream* in_stream,
                                                      GError** error);
VALA_EXTERN GType tuba_network_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaNetwork, g_object_unref)
VALA_EXTERN JsonNode* tuba_network_parse_node (TubaNetwork* self,
                                   JsonParser* parser);
static void _vala_JsonNode_free (JsonNode* self);
VALA_EXTERN TubaAPIAccount* tuba_api_account_from (JsonNode* node,
                                       GError** error);
VALA_EXTERN const gchar* tuba_api_account_get_display_name (TubaAPIAccount* self);
VALA_EXTERN const gchar* tuba_api_account_get_avatar (TubaAPIAccount* self);
VALA_EXTERN void tuba_api_account_set_display_name (TubaAPIAccount* self,
                                        const gchar* value);
VALA_EXTERN void tuba_api_account_set_avatar (TubaAPIAccount* self,
                                  const gchar* value);
static void _____lambda313__tuba_network_success_callback (GInputStream* in_stream,
                                                    SoupMessageHeaders* response_headers,
                                                    gpointer self,
                                                    GError** error);
VALA_EXTERN TubaRequest* tuba_request_exec (TubaRequest* self);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_new_empty (const gchar* instance);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_construct_empty (GType object_type,
                                                            const gchar* instance);
VALA_EXTERN void tuba_instance_account_set_visibility (TubaInstanceAccount* self,
                                           TubaInstanceAccountVisibility* obj);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_id (TubaInstanceAccountVisibility* self);
VALA_EXTERN gpointer tuba_instance_account_create_entity (TubaInstanceAccount* self,
                                              GType t_type,
                                              GBoxedCopyFunc t_dup_func,
                                              GDestroyNotify t_destroy_func,
                                              JsonNode* node,
                                              GError** error);
VALA_EXTERN TubaEntity* tuba_entity_from_json (GType type,
                                   JsonNode* node,
                                   GError** error);
VALA_EXTERN TubaEntity* tuba_instance_account_create_dynamic_entity (TubaInstanceAccount* self,
                                                         GType type,
                                                         JsonNode* node,
                                                         GError** error);
static void tuba_instance_account_verify_credentials_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_verify_credentials (TubaInstanceAccount* self,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_verify_credentials_finish (TubaInstanceAccount* self,
                                                      GAsyncResult* _res_,
                                                      GError** error);
static gboolean tuba_instance_account_verify_credentials_co (TubaInstanceAccountVerifyCredentialsData* _data_);
VALA_EXTERN void tuba_request_await (TubaRequest* self,
                         GAsyncReadyCallback _callback_,
                         gpointer _user_data_);
VALA_EXTERN TubaRequest* tuba_request_await_finish (TubaRequest* self,
                                        GAsyncResult* _res_,
                                        GError** error);
static void tuba_instance_account_verify_credentials_ready (GObject* source_object,
                                                     GAsyncResult* _res_,
                                                     gpointer _user_data_);
VALA_EXTERN void tuba_instance_account_update_object (TubaInstanceAccount* self,
                                          GInputStream* in_stream,
                                          GError** error);
VALA_EXTERN GInputStream* tuba_request_get_response_body (TubaRequest* self);
VALA_EXTERN void tuba_entity_patch (TubaEntity* self,
                        GObject* with);
VALA_EXTERN gchar* tuba_instance_account_get_handle (TubaInstanceAccount* self);
static void tuba_instance_account_resolve_data_free (gpointer _data);
VALA_EXTERN void tuba_instance_account_resolve (TubaInstanceAccount* self,
                                    const gchar* url,
                                    GAsyncReadyCallback _callback_,
                                    gpointer _user_data_);
VALA_EXTERN TubaEntity* tuba_instance_account_resolve_finish (TubaInstanceAccount* self,
                                                  GAsyncResult* _res_,
                                                  GError** error);
static gboolean tuba_instance_account_resolve_co (TubaInstanceAccountResolveData* _data_);
VALA_EXTERN GType tuba_api_search_results_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPISearchResults, g_object_unref)
VALA_EXTERN void tuba_api_search_results_request (const gchar* q,
                                      TubaInstanceAccount* account,
                                      GAsyncReadyCallback _callback_,
                                      gpointer _user_data_);
VALA_EXTERN TubaAPISearchResults* tuba_api_search_results_request_finish (GAsyncResult* _res_,
                                                              GError** error);
static void tuba_instance_account_resolve_ready (GObject* source_object,
                                          GAsyncResult* _res_,
                                          gpointer _user_data_);
VALA_EXTERN TubaEntity* tuba_api_search_results_first (TubaAPISearchResults* self,
                                           GError** error);
static void tuba_instance_account_real_describe_kind (TubaInstanceAccount* self,
                                               const gchar* kind,
                                               TubaInstanceAccountKind* _result_,
                                               const gchar* actor_name,
                                               const gchar* callback_url,
                                               const gchar* other_data);
static void tuba_instance_account_real_register_known_places (TubaInstanceAccount* self,
                                                       GListStore* places);
static void tuba_instance_account_real_register_extra (TubaInstanceAccount* self,
                                                GListStore* places,
                                                TubaPlace** extra,
                                                gint extra_length1);
VALA_EXTERN TubaAPIInstance* tuba_instance_account_get_instance_info (TubaInstanceAccount* self);
static void __lambda199_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN TubaAPIInstance* tuba_api_instance_from (JsonNode* node,
                                         GError** error);
VALA_EXTERN void tuba_instance_account_set_instance_info (TubaInstanceAccount* self,
                                              TubaAPIInstance* value);
VALA_EXTERN gchar** tuba_api_instance_get_compat_supported_mime_types (TubaAPIInstance* self,
                                                           gint* result_length1);
static gchar** _vala_array_dup27 (gchar** self,
                           gssize length);
VALA_EXTERN TubaInstanceAccountStatusContentType* tuba_instance_account_status_content_type_new (const gchar* content_type);
VALA_EXTERN TubaInstanceAccountStatusContentType* tuba_instance_account_status_content_type_construct (GType object_type,
                                                                                           const gchar* content_type);
VALA_EXTERN GType tuba_api_pleroma_instance_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIPleromaInstance, g_object_unref)
VALA_EXTERN TubaAPIPleromaInstance* tuba_api_instance_get_pleroma (TubaAPIInstance* self);
static void tuba_instance_account_gather_v2_instance_info (TubaInstanceAccount* self);
VALA_EXTERN GType tuba_api_pleroma_instance_metadata_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIPleromaInstanceMetadata, g_object_unref)
VALA_EXTERN TubaAPIPleromaInstanceMetadata* tuba_api_pleroma_instance_get_metadata (TubaAPIPleromaInstance* self);
VALA_EXTERN gchar** tuba_api_pleroma_instance_metadata_get_features (TubaAPIPleromaInstanceMetadata* self,
                                                         gint* result_length1);
static gboolean _vala_string_array_contains (gchar* * stack,
                                      gssize stack_length,
                                      const gchar* needle);
VALA_EXTERN void tuba_api_instance_set_tuba_can_translate (TubaAPIInstance* self,
                                               gboolean value);
VALA_EXTERN gboolean tuba_api_instance_get_supports_quote_posting (TubaAPIInstance* self);
VALA_EXTERN gboolean tuba_api_instance_get_tuba_can_translate (TubaAPIInstance* self);
VALA_EXTERN gboolean tuba_api_instance_get_supports_bubble (TubaAPIInstance* self);
VALA_EXTERN const gchar* tuba_api_instance_get_version (TubaAPIInstance* self);
VALA_EXTERN GType tuba_api_instance_urls_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceUrls, g_object_unref)
VALA_EXTERN TubaAPIInstanceUrls* tuba_api_instance_get_urls (TubaAPIInstance* self);
VALA_EXTERN const gchar* tuba_api_instance_urls_get_streaming_api (TubaAPIInstanceUrls* self);
VALA_EXTERN void tuba_application_handle_share (TubaApplication* self);
static void ___lambda199__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
static void tuba_instance_account_real_bump_sidebar_items (TubaInstanceAccount* self);
static void __lambda200_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN GType tuba_api_instance_v2_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2* tuba_api_instance_v2_from (JsonNode* node,
                                              GError** error);
static TubaInstanceAccountInstanceFeatures* _tuba_instance_account_instance_features_dup (TubaInstanceAccountInstanceFeatures* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2Configuration, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2Configuration* tuba_api_instance_v2_get_configuration (TubaAPIInstanceV2* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_translation_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2ConfigurationTranslation, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2ConfigurationTranslation* tuba_api_instance_v2_configuration_get_translation (TubaAPIInstanceV2Configuration* self);
VALA_EXTERN gboolean tuba_api_instance_v2_configuration_translation_get_enabled (TubaAPIInstanceV2ConfigurationTranslation* self);
VALA_EXTERN GType tuba_api_instance_v2_configuration_media_attachments_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIInstanceV2ConfigurationMediaAttachments, g_object_unref)
VALA_EXTERN TubaAPIInstanceV2ConfigurationMediaAttachments* tuba_api_instance_v2_configuration_get_media_attachments (TubaAPIInstanceV2Configuration* self);
VALA_EXTERN gint64 tuba_api_instance_v2_configuration_media_attachments_get_description_limit (TubaAPIInstanceV2ConfigurationMediaAttachments* self);
VALA_EXTERN void tuba_api_instance_set_tuba_max_alt_chars (TubaAPIInstance* self,
                                               gint64 value);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_api_instance_v2_get_api_versions (TubaAPIInstanceV2* self);
VALA_EXTERN gint8 tuba_api_instance_v2_api_versions_get_mastodon (TubaAPIInstanceV2APIVersions* self);
VALA_EXTERN TubaAPIInstanceV2APIVersions* tuba_instance_account_get_tuba_api_versions (TubaInstanceAccount* self);
VALA_EXTERN gboolean tuba_api_instance_v2_api_versions_tuba_same (TubaAPIInstanceV2APIVersions* self,
                                                      TubaAPIInstanceV2APIVersions* new_val);
VALA_EXTERN void tuba_instance_account_set_tuba_api_versions (TubaInstanceAccount* self,
                                                  TubaAPIInstanceV2APIVersions* value);
VALA_EXTERN void tuba_instance_account_set_tuba_probably_has_notification_filters (TubaInstanceAccount* self,
                                                                       gboolean value);
static void tuba_instance_account_gather_annual_report (TubaInstanceAccount* self);
VALA_EXTERN gint8 tuba_api_instance_v2_api_versions_get_chuckya (TubaAPIInstanceV2APIVersions* self);
static void ___lambda200__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
static Block50Data* block50_data_ref (Block50Data* _data50_);
static void block50_data_unref (void * _userdata_);
static void __lambda201_ (Block50Data* _data50_,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN TubaAPIAnnualReports* tuba_api_annual_reports_from (JsonNode* node,
                                                    GError** error);
VALA_EXTERN GType tuba_api_annual_reports_report_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAnnualReportsReport, g_object_unref)
VALA_EXTERN GeeArrayList* tuba_api_annual_reports_get_annual_reports (TubaAPIAnnualReports* self);
VALA_EXTERN void tuba_instance_account_set_tuba_last_fediwrapped_year (TubaInstanceAccount* self,
                                                           gint value);
static void ___lambda201__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
VALA_EXTERN void tuba_instance_account_open_latest_wrapped (TubaInstanceAccount* self);
VALA_EXTERN gint tuba_instance_account_get_tuba_last_fediwrapped_year (TubaInstanceAccount* self);
VALA_EXTERN void tuba_api_annual_reports_open (TubaAPIAnnualReports* self,
                                   gint year);
VALA_EXTERN GeeArrayList* tuba_instance_account_get_instance_emojis (TubaInstanceAccount* self);
static void __lambda202_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN gboolean tuba_entity_des_list (GValue* val,
                               JsonNode* node,
                               GType type);
VALA_EXTERN void tuba_instance_account_set_instance_emojis (TubaInstanceAccount* self,
                                                GeeArrayList* value);
static void ___lambda202__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
VALA_EXTERN gchar** tuba_settings_get_favorite_tags_ids (TubaSettings* self,
                                             gint* result_length1);
VALA_EXTERN GType tuba_dialogs_main_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaDialogsMainWindow, g_object_unref)
static void ____lambda49_ (TubaDialogsMainWindow* win,
                    GObject* tag_obj);
VALA_EXTERN GType tuba_views_base_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsBase, g_object_unref)
VALA_EXTERN TubaViewsBase* tuba_dialogs_main_window_open_view (TubaDialogsMainWindow* self,
                                                   TubaViewsBase* view);
VALA_EXTERN TubaViewsBase* tuba_instance_account_set_as_sidebar_item (TubaViewsBase* view);
VALA_EXTERN TubaViewsHashtag* tuba_views_hashtag_new (const gchar* tag,
                                          gboolean* following,
                                          const gchar* url_basename,
                                          gboolean* featured);
VALA_EXTERN TubaViewsHashtag* tuba_views_hashtag_construct (GType object_type,
                                                const gchar* tag,
                                                gboolean* following,
                                                const gchar* url_basename,
                                                gboolean* featured);
VALA_EXTERN GType tuba_views_content_base_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsContentBase, g_object_unref)
VALA_EXTERN GType tuba_views_timeline_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsTimeline, g_object_unref)
VALA_EXTERN GType tuba_views_hashtag_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsHashtag, g_object_unref)
static void _____lambda49__tuba_place_open_func (TubaDialogsMainWindow* window,
                                          GObject* extra);
VALA_EXTERN TubaPlace* tuba_place_new (void);
VALA_EXTERN TubaPlace* tuba_place_construct (GType object_type);
VALA_EXTERN void tuba_place_set_icon (TubaPlace* self,
                          const gchar* value);
VALA_EXTERN void tuba_place_set_title (TubaPlace* self,
                           const gchar* value);
VALA_EXTERN void tuba_place_set_extra_data (TubaPlace* self,
                                GObject* value);
VALA_EXTERN void tuba_place_set_open_func (TubaPlace* self,
                               TubaPlaceOpenFunc value);
static void _vala_array_add28 (TubaPlace** * array,
                        gint* length,
                        gint* size,
                        TubaPlace* value);
VALA_EXTERN gchar** tuba_settings_get_favorite_lists_ids (TubaSettings* self,
                                              gint* result_length1);
static void __lambda172_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
static Block51Data* block51_data_ref (Block51Data* _data51_);
static void block51_data_unref (void * _userdata_);
VALA_EXTERN void tuba_network_parse_array (JsonParser* parser,
                               TubaNetworkNodeCallback cb,
                               gpointer cb_target,
                               GDestroyNotify cb_target_destroy_notify,
                               GError** error);
static void __lambda173_ (Block51Data* _data51_,
                   JsonNode* node,
                   GError** error);
VALA_EXTERN GType tuba_api_list_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIList, g_object_unref)
VALA_EXTERN TubaAPIList* tuba_api_list_from (JsonNode* node,
                                 GError** error);
VALA_EXTERN const gchar* tuba_api_list_get_id (TubaAPIList* self);
VALA_EXTERN const gchar* tuba_api_list_get_title (TubaAPIList* self);
static void ___lambda174_ (TubaDialogsMainWindow* win,
                    GObject* list);
VALA_EXTERN TubaViewsList* tuba_views_list_new (TubaAPIList* l);
VALA_EXTERN TubaViewsList* tuba_views_list_construct (GType object_type,
                                          TubaAPIList* l);
VALA_EXTERN GType tuba_views_list_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsList, g_object_unref)
static void ____lambda174__tuba_place_open_func (TubaDialogsMainWindow* window,
                                          GObject* extra);
static void _vala_array_add29 (TubaPlace** * array,
                        gint* length,
                        gint* size,
                        TubaPlace* value);
static void _vala_array_add30 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
static void ___lambda173__tuba_network_node_callback (JsonNode* node,
                                               gpointer self,
                                               GError** error);
static void _vala_array_add31 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
VALA_EXTERN void tuba_settings_set_favorite_lists_ids (TubaSettings* self,
                                           gchar** value,
                                           gint value_length1);
static void ___lambda172__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
VALA_EXTERN void tuba_views_base_set_is_sidebar_item (TubaViewsBase* self,
                                          gboolean value);
VALA_EXTERN void tuba_views_base_set_show_back_button (TubaViewsBase* self,
                                           gboolean value);
VALA_EXTERN void tuba_instance_account_init_notifications (TubaInstanceAccount* self);
VALA_EXTERN gchar* tuba_views_notifications_get_notifications_excluded_types_query_param (void);
VALA_EXTERN TubaRequest* tuba_request_with_param (TubaRequest* self,
                                      const gchar* name,
                                      const gchar* val);
VALA_EXTERN gint tuba_instance_account_get_last_read_id (TubaInstanceAccount* self);
static void __lambda312_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN JsonArray* tuba_network_get_array_mstd (JsonParser* parser);
VALA_EXTERN void tuba_instance_account_set_unread_count (TubaInstanceAccount* self,
                                             gint value);
VALA_EXTERN gint tuba_instance_account_get_unread_count (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_last_received_id (TubaInstanceAccount* self,
                                                 gint value);
static void ___lambda312__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
static void tuba_instance_account_real_check_notifications (TubaInstanceAccount* self);
static void __lambda205_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
VALA_EXTERN JsonObject* tuba_network_parse (TubaNetwork* self,
                                JsonParser* parser);
VALA_EXTERN void tuba_instance_account_set_last_read_id (TubaInstanceAccount* self,
                                             gint value);
static void ___lambda205__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
static void __lambda203_ (TubaInstanceAccount* self,
                   GInputStream* in_stream,
                   GError** error);
static Block52Data* block52_data_ref (Block52Data* _data52_);
static void block52_data_unref (void * _userdata_);
static void ___lambda204_ (Block52Data* _data52_,
                    JsonArray* array,
                    guint i,
                    JsonNode* node);
static void ____lambda204__json_array_foreach (JsonArray* array,
                                        guint index_,
                                        JsonNode* element_node,
                                        gpointer self);
VALA_EXTERN void tuba_instance_account_set_unread_announcements (TubaInstanceAccount* self,
                                                     gint value);
static void ___lambda203__tuba_network_success_callback (GInputStream* in_stream,
                                                  SoupMessageHeaders* response_headers,
                                                  gpointer self,
                                                  GError** error);
VALA_EXTERN void tuba_instance_account_read_notifications (TubaInstanceAccount* self,
                                               gint up_to_id);
VALA_EXTERN TubaRequest* tuba_request_new_POST (const gchar* url);
VALA_EXTERN TubaRequest* tuba_request_construct_POST (GType object_type,
                                          const gchar* url);
VALA_EXTERN TubaRequest* tuba_request_with_form_data (TubaRequest* self,
                                          const gchar* name,
                                          const gchar* val);
VALA_EXTERN GType tuba_api_notification_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPINotification, g_object_unref)
VALA_EXTERN void tuba_instance_account_send_toast (TubaInstanceAccount* self,
                                       TubaAPINotification* obj);
static Block53Data* block53_data_ref (Block53Data* _data53_);
static void block53_data_unref (void * _userdata_);
VALA_EXTERN const gchar* tuba_api_notification_get_kind (TubaAPINotification* self);
VALA_EXTERN gchar** tuba_settings_get_muted_notification_types (TubaSettings* self,
                                                    gint* result_length1);
VALA_EXTERN gboolean tuba_settings_get_group_push_notifications (TubaSettings* self);
VALA_EXTERN GType tuba_api_status_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIStatus, g_object_unref)
VALA_EXTERN TubaAPIStatus* tuba_api_notification_get_status (TubaAPINotification* self);
VALA_EXTERN const gchar* tuba_api_status_get_id (TubaAPIStatus* self);
VALA_EXTERN const gchar* tuba_api_notification_get_id (TubaAPINotification* self);
VALA_EXTERN void tuba_api_notification_to_toast (TubaAPINotification* self,
                                     TubaInstanceAccount* issuer,
                                     gint others,
                                     GAsyncReadyCallback _callback_,
                                     gpointer _user_data_);
VALA_EXTERN GNotification* tuba_api_notification_to_toast_finish (TubaAPINotification* self,
                                                      GAsyncResult* _res_);
static void __lambda314_ (Block53Data* _data53_,
                   GObject* _obj,
                   GAsyncResult* res);
static void ___lambda314__gasync_ready_callback (GObject* source_object,
                                          GAsyncResult* res,
                                          gpointer self);
static gchar* tuba_instance_account_real_get_stream_url (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_instance_account_get_access_token (TubaInstanceAccount* self);
static void tuba_instance_account_real_on_notification_event (TubaInstanceAccount* self,
                                                       TubaStreamableEvent* ev);
VALA_EXTERN JsonNode* tuba_streamable_event_get_node (TubaStreamableEvent *self,
                                          GError** error);
VALA_EXTERN TubaAPIStatus* tuba_api_status_get_formal (TubaAPIStatus* self);
VALA_EXTERN gboolean tuba_api_status_get_tuba_filter_hidden (TubaAPIStatus* self);
VALA_EXTERN gint tuba_instance_account_get_unreviewed_follow_requests (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_unreviewed_follow_requests (TubaInstanceAccount* self,
                                                           gint value);
VALA_EXTERN gint tuba_instance_account_get_last_received_id (TubaInstanceAccount* self);
static gchar** tuba_instance_account_account_settings_notification_filters (TubaInstanceAccount* self,
                                                                     gint* result_length1);
static void tuba_instance_account_real_open_status_url (TubaInstanceAccount* self,
                                                 const gchar* url);
static void tuba_instance_account_real_answer_follow_request (TubaInstanceAccount* self,
                                                       const gchar* issuer_id,
                                                       const gchar* fr_id,
                                                       gboolean accept);
static void tuba_instance_account_real_follow_back (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* acc_id);
static void tuba_instance_account_real_reply_to_status_uri (TubaInstanceAccount* self,
                                                     const gchar* issuer_id,
                                                     const gchar* uri);
static void tuba_instance_account_real_remove_from_followers (TubaInstanceAccount* self,
                                                       const gchar* issuer_id,
                                                       const gchar* acc_id);
static GSettings* tuba_instance_account_account_settings (TubaInstanceAccount* self);
VALA_EXTERN TubaInstanceAccount* tuba_account_store_get_active (TubaAccountStore* self);
VALA_EXTERN const gchar* tuba_instance_account_get_uuid (TubaInstanceAccount* self);
VALA_EXTERN TubaSettingsAccount* tuba_settings_account_new (const gchar* id);
VALA_EXTERN TubaSettingsAccount* tuba_settings_account_construct (GType object_type,
                                                      const gchar* id);
VALA_EXTERN GType tuba_settings_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaSettingsAccount, g_object_unref)
VALA_EXTERN gchar** tuba_settings_get_notification_filters (TubaSettings* self,
                                                gint* result_length1);
static gchar** _vala_array_dup28 (gchar** self,
                           gssize length);
VALA_EXTERN gchar** tuba_settings_account_get_notification_filters (TubaSettingsAccount* self,
                                                        gint* result_length1);
static gchar** _vala_array_dup29 (gchar** self,
                           gssize length);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_new (void);
VALA_EXTERN TubaInstanceAccount* tuba_instance_account_construct (GType object_type);
VALA_EXTERN TubaAPIAccount* tuba_api_account_new (void);
VALA_EXTERN TubaAPIAccount* tuba_api_account_construct (GType object_type);
VALA_EXTERN void tuba_instance_account_set_uuid (TubaInstanceAccount* self,
                                     const gchar* value);
VALA_EXTERN gboolean tuba_instance_account_get_admin_mode (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_admin_mode (TubaInstanceAccount* self,
                                           gboolean value);
VALA_EXTERN const gchar* tuba_instance_account_get_backend (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_backend (TubaInstanceAccount* self,
                                        const gchar* value);
VALA_EXTERN void tuba_instance_account_set_instance (TubaInstanceAccount* self,
                                         const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_get_client_id (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_client_id (TubaInstanceAccount* self,
                                          const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_get_client_secret (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_client_secret (TubaInstanceAccount* self,
                                              const gchar* value);
VALA_EXTERN void tuba_instance_account_set_access_token (TubaInstanceAccount* self,
                                             const gchar* value);
VALA_EXTERN GError* tuba_instance_account_get_error (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_error (TubaInstanceAccount* self,
                                      GError* value);
VALA_EXTERN gboolean tuba_instance_account_get_tuba_probably_has_notification_filters (TubaInstanceAccount* self);
VALA_EXTERN gchar* tuba_instance_account_get_handle_short (TubaInstanceAccount* self);
VALA_EXTERN const gchar* tuba_api_account_get_username (TubaAPIAccount* self);
VALA_EXTERN gchar* tuba_api_account_get_full_handle (TubaAPIAccount* self);
VALA_EXTERN gint tuba_instance_account_get_unread_announcements (TubaInstanceAccount* self);
VALA_EXTERN gint tuba_instance_account_get_filtered_notifications_count (TubaInstanceAccount* self);
VALA_EXTERN void tuba_instance_account_set_filtered_notifications_count (TubaInstanceAccount* self,
                                                             gint value);
static void tuba_instance_account_real_activated (TubaInstanceAccount* self);
static void tuba_instance_account_real_deactivated (TubaInstanceAccount* self);
static void tuba_instance_account_real_added (TubaInstanceAccount* self);
VALA_EXTERN void tuba_streamable_set_subscribed (TubaStreamable* self,
                                     gboolean value);
static void tuba_instance_account_real_removed (TubaInstanceAccount* self);
VALA_EXTERN TubaInstanceAccountVisibility* tuba_instance_account_visibility_new (void);
VALA_EXTERN TubaInstanceAccountVisibility* tuba_instance_account_visibility_construct (GType object_type);
VALA_EXTERN void tuba_instance_account_visibility_set_id (TubaInstanceAccountVisibility* self,
                                              const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_name (TubaInstanceAccountVisibility* self,
                                                const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_icon_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_icon_name (TubaInstanceAccountVisibility* self,
                                                     const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_description (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_description (TubaInstanceAccountVisibility* self,
                                                       const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_visibility_get_small_icon_name (TubaInstanceAccountVisibility* self);
VALA_EXTERN void tuba_instance_account_visibility_set_small_icon_name (TubaInstanceAccountVisibility* self,
                                                           const gchar* value);
static void tuba_instance_account_visibility_finalize (GObject * obj);
static GType tuba_instance_account_visibility_get_type_once (void);
static void _vala_tuba_instance_account_visibility_get_property (GObject * object,
                                                          guint property_id,
                                                          GValue * value,
                                                          GParamSpec * pspec);
static void _vala_tuba_instance_account_visibility_set_property (GObject * object,
                                                          guint property_id,
                                                          const GValue * value,
                                                          GParamSpec * pspec);
static gboolean _tuba_instance_account_status_content_type_compare_lambda84_ (const gchar* a,
                                                                       const gchar* b);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_mime (TubaInstanceAccountStatusContentType* self);
static gboolean __tuba_instance_account_status_content_type_compare_lambda84__gequal_func (gconstpointer a,
                                                                                    gconstpointer b);
VALA_EXTERN void tuba_instance_account_status_content_type_set_mime (TubaInstanceAccountStatusContentType* self,
                                                         const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_icon_name (TubaInstanceAccountStatusContentType* self,
                                                              const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_title (TubaInstanceAccountStatusContentType* self,
                                                          const gchar* value);
VALA_EXTERN void tuba_instance_account_status_content_type_set_syntax (TubaInstanceAccountStatusContentType* self,
                                                           const gchar* value);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_icon_name (TubaInstanceAccountStatusContentType* self);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_title (TubaInstanceAccountStatusContentType* self);
VALA_EXTERN const gchar* tuba_instance_account_status_content_type_get_syntax (TubaInstanceAccountStatusContentType* self);
static void tuba_instance_account_status_content_type_finalize (GObject * obj);
static GType tuba_instance_account_status_content_type_get_type_once (void);
static void _vala_tuba_instance_account_status_content_type_get_property (GObject * object,
                                                                   guint property_id,
                                                                   GValue * value,
                                                                   GParamSpec * pspec);
static void _vala_tuba_instance_account_status_content_type_set_property (GObject * object,
                                                                   guint property_id,
                                                                   const GValue * value,
                                                                   GParamSpec * pspec);
static GObject * tuba_instance_account_constructor (GType type,
                                             guint n_construct_properties,
                                             GObjectConstructParam * construct_properties);
VALA_EXTERN void tuba_streamable_construct_streamable (TubaStreamable* self);
static void _tuba_instance_account_on_notification_event_tuba_streamable_stream_event (TubaStreamable* _sender,
                                                                                TubaStreamableEvent* ev,
                                                                                gpointer self);
static void _tuba_instance_account_on_network_change_g_object_notify (GObject* _sender,
                                                               GParamSpec* pspec,
                                                               gpointer self);
VALA_EXTERN gchar* tuba_streamable_get_stream_url (TubaStreamable* self);
VALA_EXTERN const gchar* tuba_streamable_get_t_connection_url (TubaStreamable* self);
VALA_EXTERN void tuba_streamable_set_t_connection_url (TubaStreamable* self,
                                           const gchar* value);
VALA_EXTERN gboolean tuba_streamable_get_subscribed (TubaStreamable* self);
static void tuba_instance_account_finalize (GObject * obj);
static GType tuba_instance_account_get_type_once (void);
static void _vala_tuba_instance_account_get_property (GObject * object,
                                               guint property_id,
                                               GValue * value,
                                               GParamSpec * pspec);
static void _vala_tuba_instance_account_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 const gchar* TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS[2] = {TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE, TUBA_INSTANCE_ACCOUNT_KIND_REBLOG};

static inline gpointer
tuba_instance_account_get_instance_private (TubaInstanceAccount* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccount_private_offset);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_instance_features_get_type_once (void)
{
	static const GFlagsValue values[] = {{TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE", "none"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE", "quote"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS", "emoji-reactions"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE", "bubble"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS", "group-notifications"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS", "feature-tags"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS", "endorse-users"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS", "mutuals"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION", "translation"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP", "iceshrimp"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH", "glitch"}, {TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY, "TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY", "local-only"}, {0, NULL, NULL}};
	GType tuba_instance_account_instance_features_type_id;
	tuba_instance_account_instance_features_type_id = g_flags_register_static ("TubaInstanceAccountInstanceFeatures", values);
	return tuba_instance_account_instance_features_type_id;
}

GType
tuba_instance_account_instance_features_get_type (void)
{
	static gsize tuba_instance_account_instance_features_type_id__once = 0;
	if (g_once_init_enter (&tuba_instance_account_instance_features_type_id__once)) {
		GType tuba_instance_account_instance_features_type_id;
		tuba_instance_account_instance_features_type_id = tuba_instance_account_instance_features_get_type_once ();
		g_once_init_leave (&tuba_instance_account_instance_features_type_id__once, tuba_instance_account_instance_features_type_id);
	}
	return tuba_instance_account_instance_features_type_id__once;
}

static const gchar*
string_to_string (const gchar* self)
{
	const gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	result = self;
	return result;
}

static void
tuba_instance_account_tuba_instance_features_update_and_save (TubaInstanceAccount* self,
                                                              TubaInstanceAccountInstanceFeatures features)
{
	gboolean _tmp0_ = FALSE;
	TubaInstanceAccountInstanceFeatures _tmp1_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	_tmp1_ = self->priv->_tuba_instance_features;
	if (features == _tmp1_) {
		_tmp0_ = TRUE;
	} else {
		TubaSettings* _tmp2_;
		_tmp2_ = tuba_settings;
		_tmp0_ = !g_settings_get_boolean ((GSettings*) _tmp2_, "auto-detect-features");
	}
	if (_tmp0_) {
		return;
	}
	tuba_instance_account_set_tuba_instance_features (self, features);
	{
		TubaAccountStore* _tmp3_;
		_tmp3_ = tuba_accounts;
		tuba_account_store_update_account (_tmp3_, self, &_inner_error0_);
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		GError* _tmp7_;
		gchar* _tmp8_;
		gchar* _tmp9_;
		GError* _tmp10_;
		const gchar* _tmp11_;
		const gchar* _tmp12_;
		gchar* _tmp13_;
		gchar* _tmp14_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp4_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
		_tmp5_ = _tmp4_;
		_tmp6_ = string_to_string (_tmp5_);
		_tmp7_ = e;
		_tmp8_ = g_strdup_printf ("%i", _tmp7_->code);
		_tmp9_ = _tmp8_;
		_tmp10_ = e;
		_tmp11_ = _tmp10_->message;
		_tmp12_ = string_to_string (_tmp11_);
		_tmp13_ = g_strconcat ("Couldn't update instance features for ", _tmp6_, ": ", _tmp9_, " ", _tmp12_, NULL);
		_tmp14_ = _tmp13_;
		g_critical ("InstanceAccount.vala:67: %s", _tmp14_);
		_g_free0 (_tmp14_);
		_g_free0 (_tmp9_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

void
tuba_instance_account_tuba_update_iceshrimp_api_key (TubaInstanceAccount* self,
                                                     const gchar* new_key)
{
	const gchar* _tmp0_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->_tuba_iceshrimp_api_key;
	if (g_strcmp0 (_tmp0_, new_key) == 0) {
		return;
	}
	tuba_instance_account_set_tuba_iceshrimp_api_key (self, new_key);
	{
		TubaAccountStore* _tmp1_;
		_tmp1_ = tuba_accounts;
		tuba_account_store_update_account (_tmp1_, self, &_inner_error0_);
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp2_;
		const gchar* _tmp3_;
		const gchar* _tmp4_;
		GError* _tmp5_;
		gchar* _tmp6_;
		gchar* _tmp7_;
		GError* _tmp8_;
		const gchar* _tmp9_;
		const gchar* _tmp10_;
		gchar* _tmp11_;
		gchar* _tmp12_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp2_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
		_tmp3_ = _tmp2_;
		_tmp4_ = string_to_string (_tmp3_);
		_tmp5_ = e;
		_tmp6_ = g_strdup_printf ("%i", _tmp5_->code);
		_tmp7_ = _tmp6_;
		_tmp8_ = e;
		_tmp9_ = _tmp8_->message;
		_tmp10_ = string_to_string (_tmp9_);
		_tmp11_ = g_strconcat ("Couldn't update instance features for ", _tmp4_, ": ", _tmp7_, " ", _tmp10_, NULL);
		_tmp12_ = _tmp11_;
		g_critical ("InstanceAccount.vala:78: %s", _tmp12_);
		_g_free0 (_tmp12_);
		_g_free0 (_tmp7_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

static void
tuba_instance_account_tuba_update_streaming_url (TubaInstanceAccount* self,
                                                 const gchar* new_url)
{
	gchar* new_host = NULL;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp21_;
	const gchar* _tmp22_;
	const gchar* _tmp23_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	g_return_if_fail (new_url != NULL);
	if (g_strcmp0 (new_url, "") == 0) {
		return;
	}
	_tmp0_ = self->priv->_instance;
	_tmp1_ = g_strdup (_tmp0_);
	new_host = _tmp1_;
	{
		GUri* new_uri = NULL;
		GUri* _tmp2_;
		gchar* new_host_uri = NULL;
		GUri* _tmp3_;
		const gchar* _tmp4_;
		gchar* _tmp5_;
		gboolean _tmp6_ = FALSE;
		const gchar* _tmp7_;
		_tmp2_ = g_uri_parse (new_url, G_URI_FLAGS_NONE, &_inner_error0_);
		new_uri = _tmp2_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_tmp3_ = new_uri;
		_tmp4_ = g_uri_get_host (_tmp3_);
		_tmp5_ = g_strdup (_tmp4_);
		new_host_uri = _tmp5_;
		_tmp7_ = new_host_uri;
		if (_tmp7_ != NULL) {
			const gchar* _tmp8_;
			_tmp8_ = new_host_uri;
			_tmp6_ = g_strcmp0 (_tmp8_, "") != 0;
		} else {
			_tmp6_ = FALSE;
		}
		if (_tmp6_) {
			const gchar* _tmp9_;
			const gchar* _tmp10_;
			gchar* _tmp11_;
			_tmp9_ = new_host_uri;
			_tmp10_ = string_to_string (_tmp9_);
			_tmp11_ = g_strconcat ("https://", _tmp10_, NULL);
			_g_free0 (new_host);
			new_host = _tmp11_;
		}
		_g_free0 (new_host_uri);
		_g_uri_unref0 (new_uri);
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		const gchar* _tmp12_;
		GError* _tmp13_;
		gchar* _tmp14_;
		gchar* _tmp15_;
		GError* _tmp16_;
		const gchar* _tmp17_;
		const gchar* _tmp18_;
		gchar* _tmp19_;
		gchar* _tmp20_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp12_ = string_to_string (new_url);
		_tmp13_ = e;
		_tmp14_ = g_strdup_printf ("%i", _tmp13_->code);
		_tmp15_ = _tmp14_;
		_tmp16_ = e;
		_tmp17_ = _tmp16_->message;
		_tmp18_ = string_to_string (_tmp17_);
		_tmp19_ = g_strconcat (_tmp12_, " is not a valid URI: ", _tmp15_, " ", _tmp18_, NULL);
		_tmp20_ = _tmp19_;
		g_warning ("InstanceAccount.vala:93: %s", _tmp20_);
		_g_free0 (_tmp20_);
		_g_free0 (_tmp15_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		_g_free0 (new_host);
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
	_tmp21_ = new_host;
	_tmp22_ = tuba_instance_account_get_tuba_streaming_url (self);
	_tmp23_ = _tmp22_;
	if (g_strcmp0 (_tmp21_, _tmp23_) != 0) {
		const gchar* _tmp24_;
		_tmp24_ = new_host;
		tuba_instance_account_set_tuba_streaming_url (self, _tmp24_);
		{
			TubaAccountStore* _tmp25_;
			TubaApplication* _tmp26_;
			TubaStreams* _tmp27_;
			TubaStreams* _tmp28_;
			const gchar* _tmp29_;
			const gchar* _tmp30_;
			_tmp25_ = tuba_accounts;
			tuba_account_store_update_account (_tmp25_, self, &_inner_error0_);
			if (G_UNLIKELY (_inner_error0_ != NULL)) {
				goto __catch1_g_error;
			}
			_tmp26_ = tuba_app;
			_tmp27_ = tuba_application_get_app_streams (_tmp26_);
			_tmp28_ = _tmp27_;
			_tmp29_ = self->priv->_instance;
			_tmp30_ = new_host;
			tuba_streams_upgrade (_tmp28_, _tmp29_, _tmp30_);
		}
		goto __finally1;
		__catch1_g_error:
		{
			GError* e = NULL;
			const gchar* _tmp31_;
			const gchar* _tmp32_;
			const gchar* _tmp33_;
			GError* _tmp34_;
			gchar* _tmp35_;
			gchar* _tmp36_;
			GError* _tmp37_;
			const gchar* _tmp38_;
			const gchar* _tmp39_;
			gchar* _tmp40_;
			gchar* _tmp41_;
			e = _inner_error0_;
			_inner_error0_ = NULL;
			_tmp31_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
			_tmp32_ = _tmp31_;
			_tmp33_ = string_to_string (_tmp32_);
			_tmp34_ = e;
			_tmp35_ = g_strdup_printf ("%i", _tmp34_->code);
			_tmp36_ = _tmp35_;
			_tmp37_ = e;
			_tmp38_ = _tmp37_->message;
			_tmp39_ = string_to_string (_tmp38_);
			_tmp40_ = g_strconcat ("Couldn't update instance features for ", _tmp33_, ": ", _tmp36_, " ", _tmp39_, NULL);
			_tmp41_ = _tmp40_;
			g_critical ("InstanceAccount.vala:102: %s", _tmp41_);
			_g_free0 (_tmp41_);
			_g_free0 (_tmp36_);
			_g_error_free0 (e);
		}
		__finally1:
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			_g_free0 (new_host);
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
			g_clear_error (&_inner_error0_);
			return;
		}
	}
	_g_free0 (new_host);
}

static gboolean
_tuba_instance_account_gather_fav_lists_gsource_func (gpointer self)
{
	gboolean result;
	result = tuba_instance_account_gather_fav_lists ((TubaInstanceAccount*) self);
	return result;
}

static gboolean
_tuba_instance_account_gather_fav_tags_gsource_func (gpointer self)
{
	gboolean result;
	result = tuba_instance_account_gather_fav_tags ((TubaInstanceAccount*) self);
	return result;
}

void
tuba_instance_account_reconnect (TubaInstanceAccount* self)
{
	g_return_if_fail (self != NULL);
	tuba_instance_account_gather_instance_info (self);
	tuba_instance_account_gather_instance_custom_emojis (self);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_lists_gsource_func, g_object_ref (self), g_object_unref);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_tags_gsource_func, g_object_ref (self), g_object_unref);
	tuba_instance_account_check_announcements (self);
	tuba_instance_account_check_notifications (self);
}

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

static void
____lambda313_ (TubaInstanceAccount* self,
                GInputStream* in_stream,
                GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	JsonNode* _tmp4_;
	TubaAPIAccount* acc = NULL;
	JsonNode* _tmp5_;
	TubaAPIAccount* _tmp6_;
	gboolean _tmp7_ = FALSE;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	TubaAPIAccount* _tmp10_;
	const gchar* _tmp11_;
	const gchar* _tmp12_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = parser;
	_tmp3_ = tuba_network_parse_node (_tmp1_, _tmp2_);
	node = _tmp3_;
	_tmp4_ = node;
	if (_tmp4_ == NULL) {
		tuba_instance_account_set_needs_update (self, TRUE);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp5_ = node;
	_tmp6_ = tuba_api_account_from (_tmp5_, &_inner_error0_);
	acc = _tmp6_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp8_ = tuba_api_account_get_display_name ((TubaAPIAccount*) self);
	_tmp9_ = _tmp8_;
	_tmp10_ = acc;
	_tmp11_ = tuba_api_account_get_display_name (_tmp10_);
	_tmp12_ = _tmp11_;
	if (g_strcmp0 (_tmp9_, _tmp12_) != 0) {
		_tmp7_ = TRUE;
	} else {
		const gchar* _tmp13_;
		const gchar* _tmp14_;
		TubaAPIAccount* _tmp15_;
		const gchar* _tmp16_;
		const gchar* _tmp17_;
		_tmp13_ = tuba_api_account_get_avatar ((TubaAPIAccount*) self);
		_tmp14_ = _tmp13_;
		_tmp15_ = acc;
		_tmp16_ = tuba_api_account_get_avatar (_tmp15_);
		_tmp17_ = _tmp16_;
		_tmp7_ = g_strcmp0 (_tmp14_, _tmp17_) != 0;
	}
	if (_tmp7_) {
		TubaAPIAccount* _tmp18_;
		const gchar* _tmp19_;
		const gchar* _tmp20_;
		TubaAPIAccount* _tmp21_;
		const gchar* _tmp22_;
		const gchar* _tmp23_;
		_tmp18_ = acc;
		_tmp19_ = tuba_api_account_get_display_name (_tmp18_);
		_tmp20_ = _tmp19_;
		tuba_api_account_set_display_name ((TubaAPIAccount*) self, _tmp20_);
		_tmp21_ = acc;
		_tmp22_ = tuba_api_account_get_avatar (_tmp21_);
		_tmp23_ = _tmp22_;
		tuba_api_account_set_avatar ((TubaAPIAccount*) self, _tmp23_);
	}
	_g_object_unref0 (acc);
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
_____lambda313__tuba_network_success_callback (GInputStream* in_stream,
                                               SoupMessageHeaders* response_headers,
                                               gpointer self,
                                               GError** error)
{
	____lambda313_ ((TubaInstanceAccount*) self, in_stream, error);
}

static void
tuba_instance_account_on_network_change (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_;
	gboolean _tmp2_;
	g_return_if_fail (self != NULL);
	_tmp1_ = tuba_instance_account_get_is_active (self);
	_tmp2_ = _tmp1_;
	if (_tmp2_) {
		TubaApplication* _tmp3_;
		gboolean _tmp4_;
		gboolean _tmp5_;
		_tmp3_ = tuba_app;
		_tmp4_ = tuba_application_get_is_online (_tmp3_);
		_tmp5_ = _tmp4_;
		_tmp0_ = _tmp5_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		gboolean _tmp6_;
		_tmp6_ = self->priv->_needs_update;
		if (_tmp6_) {
			const gchar* _tmp7_;
			const gchar* _tmp8_;
			const gchar* _tmp9_;
			gchar* _tmp10_;
			gchar* _tmp11_;
			TubaRequest* _tmp12_;
			TubaRequest* _tmp13_;
			TubaRequest* _tmp14_;
			TubaRequest* _tmp15_;
			TubaRequest* _tmp16_;
			TubaRequest* _tmp17_;
			TubaRequest* _tmp18_;
			TubaRequest* _tmp19_;
			tuba_instance_account_set_needs_update (self, FALSE);
			_tmp7_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
			_tmp8_ = _tmp7_;
			_tmp9_ = string_to_string (_tmp8_);
			_tmp10_ = g_strconcat ("/api/v1/accounts/", _tmp9_, NULL);
			_tmp11_ = _tmp10_;
			_tmp12_ = tuba_request_new_GET (_tmp11_);
			_tmp13_ = _tmp12_;
			_tmp14_ = tuba_request_with_account (_tmp13_, self);
			_tmp15_ = _tmp14_;
			_tmp16_ = tuba_request_then (_tmp15_, _____lambda313__tuba_network_success_callback, g_object_ref (self), g_object_unref);
			_tmp17_ = _tmp16_;
			_tmp18_ = tuba_request_exec (_tmp17_);
			_tmp19_ = _tmp18_;
			_g_object_unref0 (_tmp19_);
			_g_object_unref0 (_tmp17_);
			_g_object_unref0 (_tmp15_);
			_g_object_unref0 (_tmp13_);
			_g_free0 (_tmp11_);
		}
		tuba_instance_account_reconnect (self);
	}
}

TubaInstanceAccount*
tuba_instance_account_construct_empty (GType object_type,
                                       const gchar* instance)
{
	TubaInstanceAccount * self = NULL;
	g_return_val_if_fail (instance != NULL, NULL);
	self = (TubaInstanceAccount*) g_object_new (object_type, "id", "", "instance", instance, NULL);
	return self;
}

TubaInstanceAccount*
tuba_instance_account_new_empty (const gchar* instance)
{
	return tuba_instance_account_construct_empty (TUBA_TYPE_INSTANCE_ACCOUNT, instance);
}

void
tuba_instance_account_set_visibility (TubaInstanceAccount* self,
                                      TubaInstanceAccountVisibility* obj)
{
	GeeHashMap* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	GListStore* _tmp3_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (obj != NULL);
	_tmp0_ = self->visibility;
	_tmp1_ = tuba_instance_account_visibility_get_id (obj);
	_tmp2_ = _tmp1_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp0_, _tmp2_, obj);
	_tmp3_ = self->visibility_list;
	g_list_store_append (_tmp3_, (GObject*) obj);
}

gpointer
tuba_instance_account_create_entity (TubaInstanceAccount* self,
                                     GType t_type,
                                     GBoxedCopyFunc t_dup_func,
                                     GDestroyNotify t_destroy_func,
                                     JsonNode* node,
                                     GError** error)
{
	GType type = 0UL;
	GeeHashMap* _tmp0_;
	TubaEntity* _tmp3_ = NULL;
	TubaEntity* _tmp4_;
	TubaEntity* _tmp5_;
	GError* _inner_error0_ = NULL;
	gpointer result;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (node != NULL, NULL);
	type = t_type;
	_tmp0_ = self->type_overrides;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, (gpointer) ((gintptr) type))) {
		GeeHashMap* _tmp1_;
		gpointer _tmp2_;
		_tmp1_ = self->type_overrides;
		_tmp2_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp1_, (gpointer) ((gintptr) type));
		type = (GType) ((gintptr) _tmp2_);
	}
	_tmp4_ = tuba_entity_from_json (type, node, &_inner_error0_);
	_tmp3_ = _tmp4_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return NULL;
	}
	_tmp5_ = _tmp3_;
	_tmp3_ = NULL;
	result = _tmp5_;
	_g_object_unref0 (_tmp3_);
	return result;
}

TubaEntity*
tuba_instance_account_create_dynamic_entity (TubaInstanceAccount* self,
                                             GType type,
                                             JsonNode* node,
                                             GError** error)
{
	GeeHashMap* _tmp0_;
	TubaEntity* _tmp3_ = NULL;
	TubaEntity* _tmp4_;
	TubaEntity* _tmp5_;
	GError* _inner_error0_ = NULL;
	TubaEntity* result;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (node != NULL, NULL);
	_tmp0_ = self->type_overrides;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, (gpointer) ((gintptr) type))) {
		GeeHashMap* _tmp1_;
		gpointer _tmp2_;
		_tmp1_ = self->type_overrides;
		_tmp2_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp1_, (gpointer) ((gintptr) type));
		type = (GType) ((gintptr) _tmp2_);
	}
	_tmp4_ = tuba_entity_from_json (type, node, &_inner_error0_);
	_tmp3_ = _tmp4_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return NULL;
	}
	_tmp5_ = _tmp3_;
	_tmp3_ = NULL;
	result = _tmp5_;
	_g_object_unref0 (_tmp3_);
	return result;
}

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

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

void
tuba_instance_account_verify_credentials (TubaInstanceAccount* self,
                                          GAsyncReadyCallback _callback_,
                                          gpointer _user_data_)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	TubaInstanceAccount* _tmp0_;
	g_return_if_fail (self != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountVerifyCredentialsData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_verify_credentials_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	tuba_instance_account_verify_credentials_co (_data_);
}

void
tuba_instance_account_verify_credentials_finish (TubaInstanceAccount* self,
                                                 GAsyncResult* _res_,
                                                 GError** error)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), error);
	if (NULL == _data_) {
		return;
	}
}

static void
tuba_instance_account_verify_credentials_ready (GObject* source_object,
                                                GAsyncResult* _res_,
                                                gpointer _user_data_)
{
	TubaInstanceAccountVerifyCredentialsData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_verify_credentials_co (_data_);
}

static gboolean
tuba_instance_account_verify_credentials_co (TubaInstanceAccountVerifyCredentialsData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = tuba_request_new_GET ("/api/v1/accounts/verify_credentials");
	_data_->_tmp1_ = _data_->_tmp0_;
	_data_->_tmp2_ = tuba_request_with_account (_data_->_tmp1_, _data_->self);
	_data_->_tmp3_ = _data_->_tmp2_;
	_g_object_unref0 (_data_->_tmp1_);
	_data_->req = _data_->_tmp3_;
	_data_->_tmp4_ = _data_->req;
	_data_->_state_ = 1;
	tuba_request_await (_data_->_tmp4_, tuba_instance_account_verify_credentials_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp5_ = tuba_request_await_finish (_data_->_tmp4_, _data_->_res_, &_data_->_inner_error0_);
	_data_->_tmp6_ = _data_->_tmp5_;
	_g_object_unref0 (_data_->_tmp6_);
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->req);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp7_ = _data_->req;
	_data_->_tmp8_ = tuba_request_get_response_body (_data_->_tmp7_);
	_data_->_tmp9_ = _data_->_tmp8_;
	tuba_instance_account_update_object (_data_->self, _data_->_tmp9_, &_data_->_inner_error0_);
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->req);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_g_object_unref0 (_data_->req);
	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;
}

void
tuba_instance_account_update_object (TubaInstanceAccount* self,
                                     GInputStream* in_stream,
                                     GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	TubaAPIAccount* updated = NULL;
	JsonNode* _tmp4_;
	TubaAPIAccount* _tmp5_;
	TubaAPIAccount* _tmp6_;
	gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* _tmp9_;
	const gchar* _tmp10_;
	gchar* _tmp11_;
	gchar* _tmp12_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (self != NULL);
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = parser;
	_tmp3_ = tuba_network_parse_node (_tmp1_, _tmp2_);
	node = _tmp3_;
	_tmp4_ = node;
	_tmp5_ = tuba_api_account_from (_tmp4_, &_inner_error0_);
	updated = _tmp5_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp6_ = updated;
	tuba_entity_patch ((TubaEntity*) self, (GObject*) _tmp6_);
	_tmp7_ = tuba_instance_account_get_handle (self);
	_tmp8_ = _tmp7_;
	_tmp9_ = _tmp8_;
	_tmp10_ = string_to_string (_tmp9_);
	_tmp11_ = g_strconcat (_tmp10_, ": profile updated", NULL);
	_tmp12_ = _tmp11_;
	g_debug ("InstanceAccount.vala:297: %s", _tmp12_);
	_g_free0 (_tmp12_);
	_g_free0 (_tmp9_);
	_g_object_unref0 (updated);
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
tuba_instance_account_resolve_data_free (gpointer _data)
{
	TubaInstanceAccountResolveData* _data_;
	_data_ = _data;
	_g_free0 (_data_->url);
	_g_object_unref0 (_data_->result);
	_g_object_unref0 (_data_->self);
	g_slice_free (TubaInstanceAccountResolveData, _data_);
}

void
tuba_instance_account_resolve (TubaInstanceAccount* self,
                               const gchar* url,
                               GAsyncReadyCallback _callback_,
                               gpointer _user_data_)
{
	TubaInstanceAccountResolveData* _data_;
	TubaInstanceAccount* _tmp0_;
	gchar* _tmp1_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (url != NULL);
	_data_ = g_slice_new0 (TubaInstanceAccountResolveData);
	_data_->_async_result = g_task_new (G_OBJECT (self), NULL, _callback_, _user_data_);
	g_task_set_task_data (_data_->_async_result, _data_, tuba_instance_account_resolve_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = g_strdup (url);
	_g_free0 (_data_->url);
	_data_->url = _tmp1_;
	tuba_instance_account_resolve_co (_data_);
}

TubaEntity*
tuba_instance_account_resolve_finish (TubaInstanceAccount* self,
                                      GAsyncResult* _res_,
                                      GError** error)
{
	TubaEntity* result;
	TubaInstanceAccountResolveData* _data_;
	_data_ = g_task_propagate_pointer (G_TASK (_res_), error);
	if (NULL == _data_) {
		return NULL;
	}
	result = _data_->result;
	_data_->result = NULL;
	return result;
}

static void
tuba_instance_account_resolve_ready (GObject* source_object,
                                     GAsyncResult* _res_,
                                     gpointer _user_data_)
{
	TubaInstanceAccountResolveData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	tuba_instance_account_resolve_co (_data_);
}

static gboolean
tuba_instance_account_resolve_co (TubaInstanceAccountResolveData* _data_)
{
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	_data_->_tmp0_ = string_to_string (_data_->url);
	_data_->_tmp1_ = g_strconcat ("Resolving URL: \"", _data_->_tmp0_, "\"…", NULL);
	_data_->_tmp2_ = _data_->_tmp1_;
	g_debug ("InstanceAccount.vala:301: %s", _data_->_tmp2_);
	_g_free0 (_data_->_tmp2_);
	_data_->_state_ = 1;
	tuba_api_search_results_request (_data_->url, _data_->self, tuba_instance_account_resolve_ready, _data_);
	return FALSE;
	_state_1:
	_data_->_tmp3_ = tuba_api_search_results_request_finish (_data_->_res_, &_data_->_inner_error0_);
	_data_->results = _data_->_tmp3_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp4_ = _data_->results;
	_data_->_tmp5_ = tuba_api_search_results_first (_data_->_tmp4_, &_data_->_inner_error0_);
	_data_->entity = _data_->_tmp5_;
	if (G_UNLIKELY (_data_->_inner_error0_ != NULL)) {
		g_task_return_error (_data_->_async_result, _data_->_inner_error0_);
		_g_object_unref0 (_data_->results);
		g_object_unref (_data_->_async_result);
		return FALSE;
	}
	_data_->_tmp6_ = _data_->entity;
	_data_->_tmp7_ = G_OBJECT_GET_CLASS ((GObject*) _data_->_tmp6_);
	_data_->_tmp8_ = G_OBJECT_CLASS_NAME (_data_->_tmp7_);
	_data_->_tmp9_ = string_to_string (_data_->_tmp8_);
	_data_->_tmp10_ = g_strconcat ("Found ", _data_->_tmp9_, NULL);
	_data_->_tmp11_ = _data_->_tmp10_;
	g_debug ("InstanceAccount.vala:304: %s", _data_->_tmp11_);
	_g_free0 (_data_->_tmp11_);
	_data_->result = _data_->entity;
	_g_object_unref0 (_data_->results);
	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;
}

static void
tuba_instance_account_real_describe_kind (TubaInstanceAccount* self,
                                          const gchar* kind,
                                          TubaInstanceAccountKind* _result_,
                                          const gchar* actor_name,
                                          const gchar* callback_url,
                                          const gchar* other_data)
{
	TubaInstanceAccountKind _vala__result_ = {0};
	const gchar* _tmp0_;
	GQuark _tmp2_ = 0U;
	static GQuark _tmp1_label0 = 0;
	static GQuark _tmp1_label1 = 0;
	static GQuark _tmp1_label2 = 0;
	static GQuark _tmp1_label3 = 0;
	static GQuark _tmp1_label4 = 0;
	static GQuark _tmp1_label5 = 0;
	static GQuark _tmp1_label6 = 0;
	static GQuark _tmp1_label7 = 0;
	static GQuark _tmp1_label8 = 0;
	static GQuark _tmp1_label9 = 0;
	static GQuark _tmp1_label10 = 0;
	static GQuark _tmp1_label11 = 0;
	static GQuark _tmp1_label12 = 0;
	static GQuark _tmp1_label13 = 0;
	static GQuark _tmp1_label14 = 0;
	static GQuark _tmp1_label15 = 0;
	static GQuark _tmp1_label16 = 0;
	static GQuark _tmp1_label17 = 0;
	static GQuark _tmp1_label18 = 0;
	_tmp0_ = kind;
	_tmp2_ = (NULL == _tmp0_) ? 0 : g_quark_from_string (_tmp0_);
	if (_tmp2_ == ((0 != _tmp1_label0) ? _tmp1_label0 : (_tmp1_label0 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_MENTION)))) {
		switch (0) {
			default:
			{
				gchar* _tmp3_;
				gchar* _tmp4_;
				gchar* _tmp5_;
				TubaInstanceAccountKind _tmp6_ = {0};
				_tmp3_ = g_strdup ("tuba-chat-symbolic");
				_tmp4_ = g_strdup_printf (_ ("%s mentioned you"), actor_name);
				_tmp5_ = g_strdup (callback_url);
				_g_free0 (_tmp6_.icon);
				_tmp6_.icon = _tmp3_;
				_g_free0 (_tmp6_.description);
				_tmp6_.description = _tmp4_;
				_g_free0 (_tmp6_.url);
				_tmp6_.url = _tmp5_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp6_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label1) ? _tmp1_label1 : (_tmp1_label1 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REBLOG)))) {
		switch (0) {
			default:
			{
				gchar* _tmp7_;
				gchar* _tmp8_;
				gchar* _tmp9_;
				TubaInstanceAccountKind _tmp10_ = {0};
				_tmp7_ = g_strdup ("tuba-media-playlist-repeat-symbolic");
				_tmp8_ = g_strdup_printf (_ ("%s boosted your post"), actor_name);
				_tmp9_ = g_strdup (callback_url);
				_g_free0 (_tmp10_.icon);
				_tmp10_.icon = _tmp7_;
				_g_free0 (_tmp10_.description);
				_tmp10_.description = _tmp8_;
				_g_free0 (_tmp10_.url);
				_tmp10_.url = _tmp9_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp10_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label2) ? _tmp1_label2 : (_tmp1_label2 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REMOTE_REBLOG)))) {
		switch (0) {
			default:
			{
				gchar* _tmp11_;
				gchar* _tmp12_;
				gchar* _tmp13_;
				TubaInstanceAccountKind _tmp14_ = {0};
				_tmp11_ = g_strdup ("tuba-media-playlist-repeat-symbolic");
				_tmp12_ = g_strdup_printf (_ ("%s boosted"), actor_name);
				_tmp13_ = g_strdup (callback_url);
				_g_free0 (_tmp14_.icon);
				_tmp14_.icon = _tmp11_;
				_g_free0 (_tmp14_.description);
				_tmp14_.description = _tmp12_;
				_g_free0 (_tmp14_.url);
				_tmp14_.url = _tmp13_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp14_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label3) ? _tmp1_label3 : (_tmp1_label3 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FAVOURITE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp15_;
				gchar* _tmp16_;
				gchar* _tmp17_;
				TubaInstanceAccountKind _tmp18_ = {0};
				_tmp15_ = g_strdup ("tuba-starred-symbolic");
				_tmp16_ = g_strdup_printf (_ ("%s favorited your post"), actor_name);
				_tmp17_ = g_strdup (callback_url);
				_g_free0 (_tmp18_.icon);
				_tmp18_.icon = _tmp15_;
				_g_free0 (_tmp18_.description);
				_tmp18_.description = _tmp16_;
				_g_free0 (_tmp18_.url);
				_tmp18_.url = _tmp17_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp18_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label4) ? _tmp1_label4 : (_tmp1_label4 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW)))) {
		switch (0) {
			default:
			{
				gchar* _tmp19_;
				gchar* _tmp20_;
				gchar* _tmp21_;
				TubaInstanceAccountKind _tmp22_ = {0};
				_tmp19_ = g_strdup ("contact-new-symbolic");
				_tmp20_ = g_strdup_printf (_ ("%s now follows you"), actor_name);
				_tmp21_ = g_strdup (callback_url);
				_g_free0 (_tmp22_.icon);
				_tmp22_.icon = _tmp19_;
				_g_free0 (_tmp22_.description);
				_tmp22_.description = _tmp20_;
				_g_free0 (_tmp22_.url);
				_tmp22_.url = _tmp21_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp22_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label5) ? _tmp1_label5 : (_tmp1_label5 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST)))) {
		switch (0) {
			default:
			{
				gchar* _tmp23_;
				gchar* _tmp24_;
				gchar* _tmp25_;
				TubaInstanceAccountKind _tmp26_ = {0};
				_tmp23_ = g_strdup ("contact-new-symbolic");
				_tmp24_ = g_strdup_printf (_ ("%s wants to follow you"), actor_name);
				_tmp25_ = g_strdup (callback_url);
				_g_free0 (_tmp26_.icon);
				_tmp26_.icon = _tmp23_;
				_g_free0 (_tmp26_.description);
				_tmp26_.description = _tmp24_;
				_g_free0 (_tmp26_.url);
				_tmp26_.url = _tmp25_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp26_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label6) ? _tmp1_label6 : (_tmp1_label6 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_POLL)))) {
		switch (0) {
			default:
			{
				gchar* _tmp27_;
				gchar* _tmp28_;
				TubaInstanceAccountKind _tmp29_ = {0};
				_tmp27_ = g_strdup ("tuba-check-round-outline-symbolic");
				_tmp28_ = g_strdup (_ ("Poll results"));
				_g_free0 (_tmp29_.icon);
				_tmp29_.icon = _tmp27_;
				_g_free0 (_tmp29_.description);
				_tmp29_.description = _tmp28_;
				_g_free0 (_tmp29_.url);
				_tmp29_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp29_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label7) ? _tmp1_label7 : (_tmp1_label7 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_EDITED)))) {
		switch (0) {
			default:
			{
				gchar* _tmp30_;
				gchar* _tmp31_;
				TubaInstanceAccountKind _tmp32_ = {0};
				_tmp30_ = g_strdup ("document-edit-symbolic");
				_tmp31_ = g_strdup_printf (_ ("%s edited a post"), actor_name);
				_g_free0 (_tmp32_.icon);
				_tmp32_.icon = _tmp30_;
				_g_free0 (_tmp32_.description);
				_tmp32_.description = _tmp31_;
				_g_free0 (_tmp32_.url);
				_tmp32_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp32_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label8) ? _tmp1_label8 : (_tmp1_label8 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REPLY)))) {
		switch (0) {
			default:
			{
				gchar* reply_text = NULL;
				gchar* _tmp35_;
				const gchar* _tmp36_;
				gchar* _tmp37_;
				TubaInstanceAccountKind _tmp38_ = {0};
				if (actor_name == NULL) {
					gchar* _tmp33_;
					_tmp33_ = g_strdup (_ ("In Reply"));
					_g_free0 (reply_text);
					reply_text = _tmp33_;
				} else {
					gchar* _tmp34_;
					_tmp34_ = g_strdup_printf (_ ("In Reply to %s"), actor_name);
					_g_free0 (reply_text);
					reply_text = _tmp34_;
				}
				_tmp35_ = g_strdup ("tuba-reply-sender-symbolic");
				_tmp36_ = reply_text;
				_tmp37_ = g_strdup (_tmp36_);
				_g_free0 (_tmp38_.icon);
				_tmp38_.icon = _tmp35_;
				_g_free0 (_tmp38_.description);
				_tmp38_.description = _tmp37_;
				_g_free0 (_tmp38_.url);
				_tmp38_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp38_;
				_g_free0 (reply_text);
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label9) ? _tmp1_label9 : (_tmp1_label9 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_SIGNUP)))) {
		switch (0) {
			default:
			{
				gchar* _tmp39_;
				gchar* _tmp40_;
				TubaInstanceAccountKind _tmp41_ = {0};
				_tmp39_ = g_strdup ("tuba-build-alt-symbolic");
				_tmp40_ = g_strdup_printf (_ ("%s signed up"), actor_name);
				_g_free0 (_tmp41_.icon);
				_tmp41_.icon = _tmp39_;
				_g_free0 (_tmp41_.description);
				_tmp41_.description = _tmp40_;
				_g_free0 (_tmp41_.url);
				_tmp41_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp41_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label10) ? _tmp1_label10 : (_tmp1_label10 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_SEVERED_RELATIONSHIPS)))) {
		switch (0) {
			default:
			{
				gchar* _tmp42_;
				gchar* _tmp43_;
				TubaInstanceAccountKind _tmp44_ = {0};
				_tmp42_ = g_strdup ("tuba-heart-broken-symbolic");
				_tmp43_ = g_strdup (_ ("Some of your relationships got severed"));
				_g_free0 (_tmp44_.icon);
				_tmp44_.icon = _tmp42_;
				_g_free0 (_tmp44_.description);
				_tmp44_.description = _tmp43_;
				_g_free0 (_tmp44_.url);
				_tmp44_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp44_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label11) ? _tmp1_label11 : (_tmp1_label11 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ANNUAL_REPORT)))) {
		switch (0) {
			default:
			{
				gchar* _tmp45_;
				gchar* _tmp46_;
				TubaInstanceAccountKind _tmp47_ = {0};
				_tmp45_ = g_strdup ("tuba-heart-broken-symbolic");
				_tmp46_ = g_strdup_printf (_ ("Your %s #FediWrapped is ready!"), other_data);
				_g_free0 (_tmp47_.icon);
				_tmp47_.icon = _tmp45_;
				_g_free0 (_tmp47_.description);
				_tmp47_.description = _tmp46_;
				_g_free0 (_tmp47_.url);
				_tmp47_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp47_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label12) ? _tmp1_label12 : (_tmp1_label12 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_MODERATION_WARNING)))) {
		switch (0) {
			default:
			{
				gchar* _tmp48_;
				gchar* _tmp49_;
				TubaInstanceAccountKind _tmp50_ = {0};
				_tmp48_ = g_strdup ("tuba-police-badge2-symbolic");
				_tmp49_ = g_strdup (_ ("Your account has received a moderation warning"));
				_g_free0 (_tmp50_.icon);
				_tmp50_.icon = _tmp48_;
				_g_free0 (_tmp50_.description);
				_tmp50_.description = _tmp49_;
				_g_free0 (_tmp50_.url);
				_tmp50_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp50_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label13) ? _tmp1_label13 : (_tmp1_label13 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_ADMIN_REPORT)))) {
		switch (0) {
			default:
			{
				gchar* _tmp51_;
				gchar* _tmp52_;
				TubaInstanceAccountKind _tmp53_ = {0};
				_tmp51_ = g_strdup ("tuba-build-alt-symbolic");
				_tmp52_ = g_strdup (_ ("Received a new report"));
				_g_free0 (_tmp53_.icon);
				_tmp53_.icon = _tmp51_;
				_g_free0 (_tmp53_.description);
				_tmp53_.description = _tmp52_;
				_g_free0 (_tmp53_.url);
				_tmp53_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp53_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label14) ? _tmp1_label14 : (_tmp1_label14 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_STATUS)))) {
		switch (0) {
			default:
			{
				gchar* _tmp54_;
				gchar* _tmp55_;
				TubaInstanceAccountKind _tmp56_ = {0};
				_tmp54_ = g_strdup ("tuba-bell-outline-symbolic");
				_tmp55_ = g_strdup_printf (_ ("%s just posted"), actor_name);
				_g_free0 (_tmp56_.icon);
				_tmp56_.icon = _tmp54_;
				_g_free0 (_tmp56_.description);
				_tmp56_.description = _tmp55_;
				_g_free0 (_tmp56_.url);
				_tmp56_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp56_;
				break;
			}
		}
	} else if ((_tmp2_ == ((0 != _tmp1_label15) ? _tmp1_label15 : (_tmp1_label15 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_PLEROMA_REACTION)))) || (_tmp2_ == ((0 != _tmp1_label16) ? _tmp1_label16 : (_tmp1_label16 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_REACTION))))) {
		switch (0) {
			default:
			{
				gchar* body = NULL;
				gchar* _tmp59_;
				const gchar* _tmp60_;
				gchar* _tmp61_;
				gchar* _tmp62_;
				TubaInstanceAccountKind _tmp63_ = {0};
				if (other_data == NULL) {
					gchar* _tmp57_;
					_tmp57_ = g_strdup_printf (_ ("%s reacted to your post"), actor_name);
					_g_free0 (body);
					body = _tmp57_;
				} else {
					gchar* _tmp58_;
					_tmp58_ = g_strdup_printf (_ ("%s reacted to your post with %s"), actor_name, other_data);
					_g_free0 (body);
					body = _tmp58_;
				}
				_tmp59_ = g_strdup ("tuba-smile-symbolic");
				_tmp60_ = body;
				_tmp61_ = g_strdup (_tmp60_);
				_tmp62_ = g_strdup (callback_url);
				_g_free0 (_tmp63_.icon);
				_tmp63_.icon = _tmp59_;
				_g_free0 (_tmp63_.description);
				_tmp63_.description = _tmp61_;
				_g_free0 (_tmp63_.url);
				_tmp63_.url = _tmp62_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp63_;
				_g_free0 (body);
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label17) ? _tmp1_label17 : (_tmp1_label17 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_QUOTE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp64_;
				gchar* _tmp65_;
				gchar* _tmp66_;
				TubaInstanceAccountKind _tmp67_ = {0};
				_tmp64_ = g_strdup ("tuba-quotation-symbolic");
				_tmp65_ = g_strdup_printf (_ ("%s quoted your post"), actor_name);
				_tmp66_ = g_strdup (callback_url);
				_g_free0 (_tmp67_.icon);
				_tmp67_.icon = _tmp64_;
				_g_free0 (_tmp67_.description);
				_tmp67_.description = _tmp65_;
				_g_free0 (_tmp67_.url);
				_tmp67_.url = _tmp66_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp67_;
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label18) ? _tmp1_label18 : (_tmp1_label18 = g_quark_from_static_string (TUBA_INSTANCE_ACCOUNT_KIND_QUOTE_UPDATE)))) {
		switch (0) {
			default:
			{
				gchar* _tmp68_;
				gchar* _tmp69_;
				gchar* _tmp70_;
				TubaInstanceAccountKind _tmp71_ = {0};
				_tmp68_ = g_strdup ("tuba-quotation-symbolic");
				_tmp69_ = g_strdup_printf (_ ("%s edited a post you have quoted"), actor_name);
				_tmp70_ = g_strdup (callback_url);
				_g_free0 (_tmp71_.icon);
				_tmp71_.icon = _tmp68_;
				_g_free0 (_tmp71_.description);
				_tmp71_.description = _tmp69_;
				_g_free0 (_tmp71_.url);
				_tmp71_.url = _tmp70_;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp71_;
				break;
			}
		}
	} else {
		switch (0) {
			default:
			{
				TubaInstanceAccountKind _tmp72_ = {0};
				_g_free0 (_tmp72_.icon);
				_tmp72_.icon = NULL;
				_g_free0 (_tmp72_.description);
				_tmp72_.description = NULL;
				_g_free0 (_tmp72_.url);
				_tmp72_.url = NULL;
				tuba_instance_account_kind_destroy (&_vala__result_);
				_vala__result_ = _tmp72_;
				break;
			}
		}
	}
	if (_result_) {
		*_result_ = _vala__result_;
	} else {
		tuba_instance_account_kind_destroy (&_vala__result_);
	}
}

void
tuba_instance_account_describe_kind (TubaInstanceAccount* self,
                                     const gchar* kind,
                                     TubaInstanceAccountKind* _result_,
                                     const gchar* actor_name,
                                     const gchar* callback_url,
                                     const gchar* other_data)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->describe_kind) {
		_klass_->describe_kind (self, kind, _result_, actor_name, callback_url, other_data);
	}
}

static void
tuba_instance_account_real_register_known_places (TubaInstanceAccount* self,
                                                  GListStore* places)
{
	g_return_if_fail (places != NULL);
}

void
tuba_instance_account_register_known_places (TubaInstanceAccount* self,
                                             GListStore* places)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->register_known_places) {
		_klass_->register_known_places (self, places);
	}
}

static void
tuba_instance_account_real_register_extra (TubaInstanceAccount* self,
                                           GListStore* places,
                                           TubaPlace** extra,
                                           gint extra_length1)
{
	g_return_if_fail (places != NULL);
}

void
tuba_instance_account_register_extra (TubaInstanceAccount* self,
                                      GListStore* places,
                                      TubaPlace** extra,
                                      gint extra_length1)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->register_extra) {
		_klass_->register_extra (self, places, extra, extra_length1);
	}
}

static gchar**
_vala_array_dup27 (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;
}

static gboolean
_vala_string_array_contains (gchar* * stack,
                             gssize stack_length,
                             const gchar* needle)
{
	gssize i;
	for (i = 0; i < stack_length; i++) {
		if (g_strcmp0 (stack[i], needle) == 0) {
			return TRUE;
		}
	}
	return FALSE;
}

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 void
__lambda199_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	JsonNode* _tmp4_;
	TubaAPIInstance* _tmp5_ = NULL;
	JsonNode* _tmp6_;
	TubaAPIInstance* _tmp7_;
	gchar** content_types = NULL;
	TubaAPIInstance* _tmp8_;
	gchar** _tmp9_;
	gint _tmp9__length1;
	gint _tmp10_ = 0;
	gchar** _tmp11_;
	gint _tmp11__length1;
	gchar** _tmp12_;
	gint _tmp12__length1;
	gint content_types_length1;
	gint _content_types_size_;
	gchar** _tmp13_;
	gint _tmp13__length1;
	TubaInstanceAccountInstanceFeatures new_flags = 0U;
	TubaInstanceAccountInstanceFeatures _tmp21_;
	TubaAPIInstance* _tmp22_;
	TubaAPIPleromaInstance* _tmp23_;
	TubaAPIPleromaInstance* _tmp24_;
	gboolean _tmp59_ = FALSE;
	TubaAPIInstance* _tmp60_;
	const gchar* _tmp61_;
	const gchar* _tmp62_;
	gboolean _tmp78_ = FALSE;
	TubaAPIInstance* _tmp79_;
	TubaAPIInstanceUrls* _tmp80_;
	TubaAPIInstanceUrls* _tmp81_;
	TubaApplication* _tmp92_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = parser;
	_tmp3_ = tuba_network_parse_node (_tmp1_, _tmp2_);
	node = _tmp3_;
	_tmp4_ = node;
	if (_tmp4_ == NULL) {
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp6_ = node;
	_tmp7_ = tuba_api_instance_from (_tmp6_, &_inner_error0_);
	_tmp5_ = _tmp7_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	tuba_instance_account_set_instance_info (self, _tmp5_);
	_tmp8_ = self->priv->_instance_info;
	_tmp9_ = tuba_api_instance_get_compat_supported_mime_types (_tmp8_, &_tmp10_);
	_tmp9__length1 = _tmp10_;
	_tmp11_ = _tmp9_;
	_tmp11__length1 = _tmp9__length1;
	_tmp12_ = (_tmp11_ != NULL) ? _vala_array_dup27 (_tmp11_, _tmp11__length1) : _tmp11_;
	_tmp12__length1 = _tmp11__length1;
	content_types = _tmp12_;
	content_types_length1 = _tmp12__length1;
	_content_types_size_ = content_types_length1;
	_tmp13_ = content_types;
	_tmp13__length1 = content_types_length1;
	if (_tmp13_ != NULL) {
		GListStore* _tmp14_;
		gchar** _tmp15_;
		gint _tmp15__length1;
		_tmp14_ = self->supported_mime_types;
		g_list_store_remove_all (_tmp14_);
		_tmp15_ = content_types;
		_tmp15__length1 = content_types_length1;
		{
			gchar** content_type_collection = NULL;
			gint content_type_collection_length1 = 0;
			gint _content_type_collection_size_ = 0;
			gint content_type_it = 0;
			content_type_collection = _tmp15_;
			content_type_collection_length1 = _tmp15__length1;
			for (content_type_it = 0; content_type_it < content_type_collection_length1; content_type_it = content_type_it + 1) {
				gchar* _tmp16_;
				gchar* content_type = NULL;
				_tmp16_ = g_strdup (content_type_collection[content_type_it]);
				content_type = _tmp16_;
				{
					GListStore* _tmp17_;
					const gchar* _tmp18_;
					TubaInstanceAccountStatusContentType* _tmp19_;
					TubaInstanceAccountStatusContentType* _tmp20_;
					_tmp17_ = self->supported_mime_types;
					_tmp18_ = content_type;
					_tmp19_ = tuba_instance_account_status_content_type_new (_tmp18_);
					_tmp20_ = _tmp19_;
					g_list_store_append (_tmp17_, (GObject*) _tmp20_);
					_g_object_unref0 (_tmp20_);
					_g_free0 (content_type);
				}
			}
		}
	}
	_tmp21_ = self->priv->_tuba_instance_features;
	new_flags = _tmp21_;
	_tmp22_ = self->priv->_instance_info;
	_tmp23_ = tuba_api_instance_get_pleroma (_tmp22_);
	_tmp24_ = _tmp23_;
	if (_tmp24_ == NULL) {
		tuba_instance_account_gather_v2_instance_info (self);
	} else {
		gboolean _tmp25_ = FALSE;
		TubaAPIInstance* _tmp26_;
		TubaAPIPleromaInstance* _tmp27_;
		TubaAPIPleromaInstance* _tmp28_;
		TubaAPIPleromaInstanceMetadata* _tmp29_;
		TubaAPIPleromaInstanceMetadata* _tmp30_;
		_tmp26_ = self->priv->_instance_info;
		_tmp27_ = tuba_api_instance_get_pleroma (_tmp26_);
		_tmp28_ = _tmp27_;
		_tmp29_ = tuba_api_pleroma_instance_get_metadata (_tmp28_);
		_tmp30_ = _tmp29_;
		if (_tmp30_ != NULL) {
			TubaAPIInstance* _tmp31_;
			TubaAPIPleromaInstance* _tmp32_;
			TubaAPIPleromaInstance* _tmp33_;
			TubaAPIPleromaInstanceMetadata* _tmp34_;
			TubaAPIPleromaInstanceMetadata* _tmp35_;
			gchar** _tmp36_;
			gint _tmp36__length1;
			gint _tmp37_ = 0;
			gchar** _tmp38_;
			gint _tmp38__length1;
			_tmp31_ = self->priv->_instance_info;
			_tmp32_ = tuba_api_instance_get_pleroma (_tmp31_);
			_tmp33_ = _tmp32_;
			_tmp34_ = tuba_api_pleroma_instance_get_metadata (_tmp33_);
			_tmp35_ = _tmp34_;
			_tmp36_ = tuba_api_pleroma_instance_metadata_get_features (_tmp35_, &_tmp37_);
			_tmp36__length1 = _tmp37_;
			_tmp38_ = _tmp36_;
			_tmp38__length1 = _tmp36__length1;
			_tmp25_ = _tmp38_ != NULL;
		} else {
			_tmp25_ = FALSE;
		}
		if (_tmp25_) {
			TubaAPIInstance* _tmp39_;
			TubaAPIInstance* _tmp40_;
			TubaAPIPleromaInstance* _tmp41_;
			TubaAPIPleromaInstance* _tmp42_;
			TubaAPIPleromaInstanceMetadata* _tmp43_;
			TubaAPIPleromaInstanceMetadata* _tmp44_;
			gchar** _tmp45_;
			gint _tmp45__length1;
			gint _tmp46_ = 0;
			gchar** _tmp47_;
			gint _tmp47__length1;
			TubaInstanceAccountInstanceFeatures _tmp48_ = 0U;
			TubaAPIInstance* _tmp49_;
			gboolean _tmp50_;
			gboolean _tmp51_;
			TubaInstanceAccountInstanceFeatures _tmp52_ = 0U;
			TubaAPIInstance* _tmp53_;
			gboolean _tmp54_;
			gboolean _tmp55_;
			TubaAPIInstance* _tmp56_;
			gboolean _tmp57_;
			gboolean _tmp58_;
			_tmp39_ = self->priv->_instance_info;
			_tmp40_ = self->priv->_instance_info;
			_tmp41_ = tuba_api_instance_get_pleroma (_tmp40_);
			_tmp42_ = _tmp41_;
			_tmp43_ = tuba_api_pleroma_instance_get_metadata (_tmp42_);
			_tmp44_ = _tmp43_;
			_tmp45_ = tuba_api_pleroma_instance_metadata_get_features (_tmp44_, &_tmp46_);
			_tmp45__length1 = _tmp46_;
			_tmp47_ = _tmp45_;
			_tmp47__length1 = _tmp45__length1;
			tuba_api_instance_set_tuba_can_translate (_tmp39_, _vala_string_array_contains (_tmp47_, _tmp47__length1, "akkoma:machine_translation"));
			_tmp49_ = self->priv->_instance_info;
			_tmp50_ = tuba_api_instance_get_supports_quote_posting (_tmp49_);
			_tmp51_ = _tmp50_;
			if (_tmp51_) {
				_tmp48_ = new_flags | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE;
			} else {
				_tmp48_ = new_flags & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_QUOTE);
			}
			new_flags = _tmp48_;
			_tmp53_ = self->priv->_instance_info;
			_tmp54_ = tuba_api_instance_get_tuba_can_translate (_tmp53_);
			_tmp55_ = _tmp54_;
			if (_tmp55_) {
				_tmp52_ = new_flags | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION;
			} else {
				_tmp52_ = new_flags & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION);
			}
			new_flags = _tmp52_;
			_tmp56_ = self->priv->_instance_info;
			_tmp57_ = tuba_api_instance_get_supports_bubble (_tmp56_);
			_tmp58_ = _tmp57_;
			if (_tmp58_) {
				new_flags |= TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
			}
		}
	}
	_tmp60_ = self->priv->_instance_info;
	_tmp61_ = tuba_api_instance_get_version (_tmp60_);
	_tmp62_ = _tmp61_;
	if (_tmp62_ != NULL) {
		_tmp59_ = !((new_flags & TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) == TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY);
	} else {
		_tmp59_ = FALSE;
	}
	if (_tmp59_) {
		TubaAPIInstance* _tmp63_;
		const gchar* _tmp64_;
		const gchar* _tmp65_;
		_tmp63_ = self->priv->_instance_info;
		_tmp64_ = tuba_api_instance_get_version (_tmp63_);
		_tmp65_ = _tmp64_;
		if (string_contains (_tmp65_, "Pleroma ")) {
			new_flags |= (((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY;
		} else {
			TubaAPIInstance* _tmp66_;
			const gchar* _tmp67_;
			const gchar* _tmp68_;
			_tmp66_ = self->priv->_instance_info;
			_tmp67_ = tuba_api_instance_get_version (_tmp66_);
			_tmp68_ = _tmp67_;
			if (string_contains (_tmp68_, "Iceshrimp.NET/")) {
				new_flags |= ((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ICESHRIMP | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
			} else {
				TubaAPIInstance* _tmp69_;
				const gchar* _tmp70_;
				const gchar* _tmp71_;
				_tmp69_ = self->priv->_instance_info;
				_tmp70_ = tuba_api_instance_get_version (_tmp69_);
				_tmp71_ = _tmp70_;
				if (string_contains (_tmp71_, "+glitch")) {
					new_flags |= ((TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GLITCH | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
				} else {
					TubaAPIInstance* _tmp72_;
					const gchar* _tmp73_;
					const gchar* _tmp74_;
					_tmp72_ = self->priv->_instance_info;
					_tmp73_ = tuba_api_instance_get_version (_tmp72_);
					_tmp74_ = _tmp73_;
					if (string_contains (_tmp74_, "+hometown")) {
						new_flags |= (TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
					} else {
						TubaAPIInstance* _tmp75_;
						const gchar* _tmp76_;
						const gchar* _tmp77_;
						_tmp75_ = self->priv->_instance_info;
						_tmp76_ = tuba_api_instance_get_version (_tmp75_);
						_tmp77_ = _tmp76_;
						if (string_contains (_tmp77_, "Akkoma ")) {
							new_flags |= TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_LOCAL_ONLY;
						}
					}
				}
			}
		}
	}
	tuba_instance_account_tuba_instance_features_update_and_save (self, new_flags);
	_tmp79_ = self->priv->_instance_info;
	_tmp80_ = tuba_api_instance_get_urls (_tmp79_);
	_tmp81_ = _tmp80_;
	if (_tmp81_ != NULL) {
		TubaAPIInstance* _tmp82_;
		TubaAPIInstanceUrls* _tmp83_;
		TubaAPIInstanceUrls* _tmp84_;
		const gchar* _tmp85_;
		const gchar* _tmp86_;
		_tmp82_ = self->priv->_instance_info;
		_tmp83_ = tuba_api_instance_get_urls (_tmp82_);
		_tmp84_ = _tmp83_;
		_tmp85_ = tuba_api_instance_urls_get_streaming_api (_tmp84_);
		_tmp86_ = _tmp85_;
		_tmp78_ = _tmp86_ != NULL;
	} else {
		_tmp78_ = FALSE;
	}
	if (_tmp78_) {
		TubaAPIInstance* _tmp87_;
		TubaAPIInstanceUrls* _tmp88_;
		TubaAPIInstanceUrls* _tmp89_;
		const gchar* _tmp90_;
		const gchar* _tmp91_;
		_tmp87_ = self->priv->_instance_info;
		_tmp88_ = tuba_api_instance_get_urls (_tmp87_);
		_tmp89_ = _tmp88_;
		_tmp90_ = tuba_api_instance_urls_get_streaming_api (_tmp89_);
		_tmp91_ = _tmp90_;
		tuba_instance_account_tuba_update_streaming_url (self, _tmp91_);
	}
	_tmp92_ = tuba_app;
	tuba_application_handle_share (_tmp92_);
	tuba_instance_account_bump_sidebar_items (self);
	content_types = (_vala_array_free (content_types, content_types_length1, (GDestroyNotify) g_free), NULL);
	_g_object_unref0 (_tmp5_);
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
___lambda199__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda199_ ((TubaInstanceAccount*) self, in_stream, error);
}

void
tuba_instance_account_gather_instance_info (TubaInstanceAccount* self)
{
	TubaAPIInstance* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	TubaRequest* _tmp8_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->_instance_info;
	if (_tmp0_ != NULL) {
		return;
	}
	_tmp1_ = tuba_request_new_GET ("/api/v1/instance");
	_tmp2_ = _tmp1_;
	_tmp3_ = tuba_request_with_account (_tmp2_, self);
	_tmp4_ = _tmp3_;
	_tmp5_ = tuba_request_then (_tmp4_, ___lambda199__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_request_exec (_tmp6_);
	_tmp8_ = _tmp7_;
	_g_object_unref0 (_tmp8_);
	_g_object_unref0 (_tmp6_);
	_g_object_unref0 (_tmp4_);
	_g_object_unref0 (_tmp2_);
}

static void
tuba_instance_account_real_bump_sidebar_items (TubaInstanceAccount* self)
{
}

void
tuba_instance_account_bump_sidebar_items (TubaInstanceAccount* self)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->bump_sidebar_items) {
		_klass_->bump_sidebar_items (self);
	}
}

static TubaInstanceAccountInstanceFeatures*
_tuba_instance_account_instance_features_dup (TubaInstanceAccountInstanceFeatures* self)
{
	TubaInstanceAccountInstanceFeatures* dup;
	dup = g_new0 (TubaInstanceAccountInstanceFeatures, 1);
	memcpy (dup, self, sizeof (TubaInstanceAccountInstanceFeatures));
	return dup;
}

static gpointer
__tuba_instance_account_instance_features_dup0 (gpointer self)
{
	return self ? _tuba_instance_account_instance_features_dup (self) : NULL;
}

static void
__lambda200_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	JsonNode* _tmp4_;
	TubaInstanceAccountInstanceFeatures* new_flags = NULL;
	TubaAPIInstanceV2* instance_v2 = NULL;
	JsonNode* _tmp5_;
	TubaAPIInstanceV2* _tmp6_;
	TubaAPIInstanceV2* _tmp7_;
	TubaInstanceAccountInstanceFeatures* _tmp90_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = parser;
	_tmp3_ = tuba_network_parse_node (_tmp1_, _tmp2_);
	node = _tmp3_;
	_tmp4_ = node;
	if (_tmp4_ == NULL) {
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	new_flags = NULL;
	_tmp5_ = node;
	_tmp6_ = tuba_api_instance_v2_from (_tmp5_, &_inner_error0_);
	instance_v2 = _tmp6_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		_g_free0 (new_flags);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp7_ = instance_v2;
	if (_tmp7_ != NULL) {
		TubaInstanceAccountInstanceFeatures _tmp8_;
		TubaInstanceAccountInstanceFeatures* _tmp9_;
		TubaAPIInstanceV2* _tmp10_;
		TubaAPIInstanceV2Configuration* _tmp11_;
		TubaAPIInstanceV2Configuration* _tmp12_;
		gboolean _tmp46_ = FALSE;
		TubaAPIInstanceV2* _tmp47_;
		TubaAPIInstanceV2APIVersions* _tmp48_;
		TubaAPIInstanceV2APIVersions* _tmp49_;
		_tmp8_ = self->priv->_tuba_instance_features;
		_tmp9_ = __tuba_instance_account_instance_features_dup0 (&_tmp8_);
		_g_free0 (new_flags);
		new_flags = _tmp9_;
		_tmp10_ = instance_v2;
		_tmp11_ = tuba_api_instance_v2_get_configuration (_tmp10_);
		_tmp12_ = _tmp11_;
		if (_tmp12_ != NULL) {
			TubaAPIInstanceV2* _tmp13_;
			TubaAPIInstanceV2Configuration* _tmp14_;
			TubaAPIInstanceV2Configuration* _tmp15_;
			TubaAPIInstanceV2ConfigurationTranslation* _tmp16_;
			TubaAPIInstanceV2ConfigurationTranslation* _tmp17_;
			TubaAPIInstanceV2* _tmp26_;
			TubaAPIInstanceV2Configuration* _tmp27_;
			TubaAPIInstanceV2Configuration* _tmp28_;
			TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp29_;
			TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp30_;
			TubaInstanceAccountInstanceFeatures _tmp39_ = 0U;
			TubaAPIInstance* _tmp40_;
			gboolean _tmp41_;
			gboolean _tmp42_;
			TubaInstanceAccountInstanceFeatures* _tmp45_;
			_tmp13_ = instance_v2;
			_tmp14_ = tuba_api_instance_v2_get_configuration (_tmp13_);
			_tmp15_ = _tmp14_;
			_tmp16_ = tuba_api_instance_v2_configuration_get_translation (_tmp15_);
			_tmp17_ = _tmp16_;
			if (_tmp17_ != NULL) {
				TubaAPIInstance* _tmp18_;
				TubaAPIInstanceV2* _tmp19_;
				TubaAPIInstanceV2Configuration* _tmp20_;
				TubaAPIInstanceV2Configuration* _tmp21_;
				TubaAPIInstanceV2ConfigurationTranslation* _tmp22_;
				TubaAPIInstanceV2ConfigurationTranslation* _tmp23_;
				gboolean _tmp24_;
				gboolean _tmp25_;
				_tmp18_ = self->priv->_instance_info;
				_tmp19_ = instance_v2;
				_tmp20_ = tuba_api_instance_v2_get_configuration (_tmp19_);
				_tmp21_ = _tmp20_;
				_tmp22_ = tuba_api_instance_v2_configuration_get_translation (_tmp21_);
				_tmp23_ = _tmp22_;
				_tmp24_ = tuba_api_instance_v2_configuration_translation_get_enabled (_tmp23_);
				_tmp25_ = _tmp24_;
				tuba_api_instance_set_tuba_can_translate (_tmp18_, _tmp25_);
			}
			_tmp26_ = instance_v2;
			_tmp27_ = tuba_api_instance_v2_get_configuration (_tmp26_);
			_tmp28_ = _tmp27_;
			_tmp29_ = tuba_api_instance_v2_configuration_get_media_attachments (_tmp28_);
			_tmp30_ = _tmp29_;
			if (_tmp30_ != NULL) {
				TubaAPIInstance* _tmp31_;
				TubaAPIInstanceV2* _tmp32_;
				TubaAPIInstanceV2Configuration* _tmp33_;
				TubaAPIInstanceV2Configuration* _tmp34_;
				TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp35_;
				TubaAPIInstanceV2ConfigurationMediaAttachments* _tmp36_;
				gint64 _tmp37_;
				gint64 _tmp38_;
				_tmp31_ = self->priv->_instance_info;
				_tmp32_ = instance_v2;
				_tmp33_ = tuba_api_instance_v2_get_configuration (_tmp32_);
				_tmp34_ = _tmp33_;
				_tmp35_ = tuba_api_instance_v2_configuration_get_media_attachments (_tmp34_);
				_tmp36_ = _tmp35_;
				_tmp37_ = tuba_api_instance_v2_configuration_media_attachments_get_description_limit (_tmp36_);
				_tmp38_ = _tmp37_;
				tuba_api_instance_set_tuba_max_alt_chars (_tmp31_, _tmp38_);
			}
			_tmp40_ = self->priv->_instance_info;
			_tmp41_ = tuba_api_instance_get_tuba_can_translate (_tmp40_);
			_tmp42_ = _tmp41_;
			if (_tmp42_) {
				TubaInstanceAccountInstanceFeatures* _tmp43_;
				_tmp43_ = new_flags;
				_tmp39_ = (*_tmp43_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION;
			} else {
				TubaInstanceAccountInstanceFeatures* _tmp44_;
				_tmp44_ = new_flags;
				_tmp39_ = (*_tmp44_) & (~TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_TRANSLATION);
			}
			_tmp45_ = __tuba_instance_account_instance_features_dup0 (&_tmp39_);
			_g_free0 (new_flags);
			new_flags = _tmp45_;
		}
		_tmp47_ = instance_v2;
		_tmp48_ = tuba_api_instance_v2_get_api_versions (_tmp47_);
		_tmp49_ = _tmp48_;
		if (_tmp49_ != NULL) {
			TubaAPIInstanceV2* _tmp50_;
			TubaAPIInstanceV2APIVersions* _tmp51_;
			TubaAPIInstanceV2APIVersions* _tmp52_;
			gint8 _tmp53_;
			gint8 _tmp54_;
			_tmp50_ = instance_v2;
			_tmp51_ = tuba_api_instance_v2_get_api_versions (_tmp50_);
			_tmp52_ = _tmp51_;
			_tmp53_ = tuba_api_instance_v2_api_versions_get_mastodon (_tmp52_);
			_tmp54_ = _tmp53_;
			_tmp46_ = ((gint) _tmp54_) > 0;
		} else {
			_tmp46_ = FALSE;
		}
		if (_tmp46_) {
			TubaAPIInstanceV2APIVersions* _tmp55_;
			TubaAPIInstanceV2* _tmp56_;
			TubaAPIInstanceV2APIVersions* _tmp57_;
			TubaAPIInstanceV2APIVersions* _tmp58_;
			TubaAPIInstanceV2APIVersions* _tmp63_;
			gint8 _tmp64_;
			gint8 _tmp65_;
			TubaAPIInstanceV2APIVersions* _tmp69_;
			gint8 _tmp70_;
			gint8 _tmp71_;
			TubaAPIInstanceV2APIVersions* _tmp75_;
			gint8 _tmp76_;
			gint8 _tmp77_;
			TubaInstanceAccountInstanceFeatures* _tmp81_;
			TubaInstanceAccountInstanceFeatures _tmp82_;
			TubaInstanceAccountInstanceFeatures* _tmp83_;
			TubaAPIInstance* _tmp84_;
			gboolean _tmp85_;
			gboolean _tmp86_;
			_tmp55_ = self->priv->_tuba_api_versions;
			_tmp56_ = instance_v2;
			_tmp57_ = tuba_api_instance_v2_get_api_versions (_tmp56_);
			_tmp58_ = _tmp57_;
			if (!tuba_api_instance_v2_api_versions_tuba_same (_tmp55_, _tmp58_)) {
				TubaAPIInstanceV2* _tmp59_;
				TubaAPIInstanceV2APIVersions* _tmp60_;
				TubaAPIInstanceV2APIVersions* _tmp61_;
				TubaAccountStore* _tmp62_;
				_tmp59_ = instance_v2;
				_tmp60_ = tuba_api_instance_v2_get_api_versions (_tmp59_);
				_tmp61_ = _tmp60_;
				tuba_instance_account_set_tuba_api_versions (self, _tmp61_);
				_tmp62_ = tuba_accounts;
				tuba_account_store_update_account (_tmp62_, self, &_inner_error0_);
				if (G_UNLIKELY (_inner_error0_ != NULL)) {
					g_propagate_error (error, _inner_error0_);
					_g_object_unref0 (instance_v2);
					_g_free0 (new_flags);
					__vala_JsonNode_free0 (node);
					_g_object_unref0 (parser);
					return;
				}
			}
			tuba_instance_account_set_tuba_probably_has_notification_filters (self, TRUE);
			_tmp63_ = self->priv->_tuba_api_versions;
			_tmp64_ = tuba_api_instance_v2_api_versions_get_mastodon (_tmp63_);
			_tmp65_ = _tmp64_;
			if (((gint) _tmp65_) > 1) {
				TubaInstanceAccountInstanceFeatures* _tmp66_;
				TubaInstanceAccountInstanceFeatures _tmp67_;
				TubaInstanceAccountInstanceFeatures* _tmp68_;
				tuba_instance_account_gather_annual_report (self);
				_tmp66_ = new_flags;
				_tmp67_ = (*_tmp66_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_GROUP_NOTIFICATIONS;
				_tmp68_ = __tuba_instance_account_instance_features_dup0 (&_tmp67_);
				_g_free0 (new_flags);
				new_flags = _tmp68_;
			}
			_tmp69_ = self->priv->_tuba_api_versions;
			_tmp70_ = tuba_api_instance_v2_api_versions_get_mastodon (_tmp69_);
			_tmp71_ = _tmp70_;
			if (((gint) _tmp71_) > 5) {
				TubaInstanceAccountInstanceFeatures* _tmp72_;
				TubaInstanceAccountInstanceFeatures _tmp73_;
				TubaInstanceAccountInstanceFeatures* _tmp74_;
				_tmp72_ = new_flags;
				_tmp73_ = (*_tmp72_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_ENDORSE_USERS;
				_tmp74_ = __tuba_instance_account_instance_features_dup0 (&_tmp73_);
				_g_free0 (new_flags);
				new_flags = _tmp74_;
			}
			_tmp75_ = self->priv->_tuba_api_versions;
			_tmp76_ = tuba_api_instance_v2_api_versions_get_chuckya (_tmp75_);
			_tmp77_ = _tmp76_;
			if (((gint) _tmp77_) > 0) {
				TubaInstanceAccountInstanceFeatures* _tmp78_;
				TubaInstanceAccountInstanceFeatures _tmp79_;
				TubaInstanceAccountInstanceFeatures* _tmp80_;
				_tmp78_ = new_flags;
				_tmp79_ = (*_tmp78_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_EMOJI_REACTIONS;
				_tmp80_ = __tuba_instance_account_instance_features_dup0 (&_tmp79_);
				_g_free0 (new_flags);
				new_flags = _tmp80_;
			}
			_tmp81_ = new_flags;
			_tmp82_ = (*_tmp81_) | (TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_FEATURE_TAGS | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_MUTUALS);
			_tmp83_ = __tuba_instance_account_instance_features_dup0 (&_tmp82_);
			_g_free0 (new_flags);
			new_flags = _tmp83_;
			_tmp84_ = self->priv->_instance_info;
			_tmp85_ = tuba_api_instance_get_supports_bubble (_tmp84_);
			_tmp86_ = _tmp85_;
			if (_tmp86_) {
				TubaInstanceAccountInstanceFeatures* _tmp87_;
				TubaInstanceAccountInstanceFeatures _tmp88_;
				TubaInstanceAccountInstanceFeatures* _tmp89_;
				_tmp87_ = new_flags;
				_tmp88_ = (*_tmp87_) | TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_BUBBLE;
				_tmp89_ = __tuba_instance_account_instance_features_dup0 (&_tmp88_);
				_g_free0 (new_flags);
				new_flags = _tmp89_;
			}
		}
	}
	_tmp90_ = new_flags;
	if (_tmp90_ != NULL) {
		TubaInstanceAccountInstanceFeatures* _tmp91_;
		_tmp91_ = new_flags;
		tuba_instance_account_tuba_instance_features_update_and_save (self, *_tmp91_);
	}
	tuba_instance_account_bump_sidebar_items (self);
	_g_object_unref0 (instance_v2);
	_g_free0 (new_flags);
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
___lambda200__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda200_ ((TubaInstanceAccount*) self, in_stream, error);
}

static void
tuba_instance_account_gather_v2_instance_info (TubaInstanceAccount* self)
{
	TubaRequest* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	g_return_if_fail (self != NULL);
	_tmp0_ = tuba_request_new_GET ("/api/v2/instance");
	_tmp1_ = _tmp0_;
	_tmp2_ = tuba_request_with_account (_tmp1_, self);
	_tmp3_ = _tmp2_;
	_tmp4_ = tuba_request_then (_tmp3_, ___lambda200__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp5_ = _tmp4_;
	_tmp6_ = tuba_request_exec (_tmp5_);
	_tmp7_ = _tmp6_;
	_g_object_unref0 (_tmp7_);
	_g_object_unref0 (_tmp5_);
	_g_object_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
}

static Block50Data*
block50_data_ref (Block50Data* _data50_)
{
	g_atomic_int_inc (&_data50_->_ref_count_);
	return _data50_;
}

static void
block50_data_unref (void * _userdata_)
{
	Block50Data* _data50_;
	_data50_ = (Block50Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data50_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data50_->self;
		_g_object_unref0 (self);
		g_slice_free (Block50Data, _data50_);
	}
}

static void
__lambda201_ (Block50Data* _data50_,
              GInputStream* in_stream,
              GError** error)
{
	TubaInstanceAccount* self;
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonParser* _tmp2_;
	JsonNode* _tmp3_;
	TubaAPIAnnualReports* _tmp4_ = NULL;
	JsonNode* _tmp5_;
	TubaAPIAnnualReports* _tmp6_;
	TubaAPIAnnualReports* _tmp7_;
	TubaAPIAnnualReports* _tmp8_;
	GeeArrayList* _tmp9_;
	GeeArrayList* _tmp10_;
	gint _tmp11_;
	gint _tmp12_;
	GError* _inner_error0_ = NULL;
	self = _data50_->self;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = parser;
	_tmp3_ = tuba_network_parse_node (_tmp1_, _tmp2_);
	node = _tmp3_;
	_tmp5_ = node;
	_tmp6_ = tuba_api_annual_reports_from (_tmp5_, &_inner_error0_);
	_tmp4_ = _tmp6_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp7_ = _tmp4_;
	_tmp4_ = NULL;
	_g_object_unref0 (self->priv->annual_report);
	self->priv->annual_report = _tmp7_;
	_tmp8_ = self->priv->annual_report;
	_tmp9_ = tuba_api_annual_reports_get_annual_reports (_tmp8_);
	_tmp10_ = _tmp9_;
	_tmp11_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp10_);
	_tmp12_ = _tmp11_;
	if (_tmp12_ > 0) {
		tuba_instance_account_set_tuba_last_fediwrapped_year (self, _data50_->year);
	}
	_g_object_unref0 (_tmp4_);
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
___lambda201__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda201_ (self, in_stream, error);
}

static void
tuba_instance_account_gather_annual_report (TubaInstanceAccount* self)
{
	Block50Data* _data50_;
	GDateTime* now = NULL;
	GTimeZone* _tmp0_;
	GTimeZone* _tmp1_;
	GDateTime* _tmp2_;
	GDateTime* _tmp3_;
	GDateTime* _tmp4_;
	gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* _tmp9_;
	gchar* _tmp10_;
	TubaRequest* _tmp11_;
	TubaRequest* _tmp12_;
	TubaRequest* _tmp13_;
	TubaRequest* _tmp14_;
	TubaRequest* _tmp15_;
	TubaRequest* _tmp16_;
	TubaRequest* _tmp17_;
	TubaRequest* _tmp18_;
	g_return_if_fail (self != NULL);
	_data50_ = g_slice_new0 (Block50Data);
	_data50_->_ref_count_ = 1;
	_data50_->self = g_object_ref (self);
	_tmp0_ = g_time_zone_new_local ();
	_tmp1_ = _tmp0_;
	_tmp2_ = g_date_time_new_now (_tmp1_);
	_tmp3_ = _tmp2_;
	_g_time_zone_unref0 (_tmp1_);
	now = _tmp3_;
	_data50_->year = 0;
	_tmp4_ = now;
	switch (g_date_time_get_month (_tmp4_)) {
		case 12:
		{
			GDateTime* _tmp5_;
			_tmp5_ = now;
			_data50_->year = g_date_time_get_year (_tmp5_);
			break;
		}
		case 1:
		{
			GDateTime* _tmp6_;
			_tmp6_ = now;
			_data50_->year = g_date_time_get_year (_tmp6_) - 1;
			break;
		}
		default:
		{
			_g_date_time_unref0 (now);
			block50_data_unref (_data50_);
			_data50_ = NULL;
			return;
		}
	}
	_tmp7_ = g_strdup_printf ("%i", _data50_->year);
	_tmp8_ = _tmp7_;
	_tmp9_ = g_strconcat ("/api/v1/annual_reports/", _tmp8_, NULL);
	_tmp10_ = _tmp9_;
	_tmp11_ = tuba_request_new_GET (_tmp10_);
	_tmp12_ = _tmp11_;
	_tmp13_ = tuba_request_with_account (_tmp12_, self);
	_tmp14_ = _tmp13_;
	_tmp15_ = tuba_request_then (_tmp14_, ___lambda201__tuba_network_success_callback, block50_data_ref (_data50_), block50_data_unref);
	_tmp16_ = _tmp15_;
	_tmp17_ = tuba_request_exec (_tmp16_);
	_tmp18_ = _tmp17_;
	_g_object_unref0 (_tmp18_);
	_g_object_unref0 (_tmp16_);
	_g_object_unref0 (_tmp14_);
	_g_object_unref0 (_tmp12_);
	_g_free0 (_tmp10_);
	_g_free0 (_tmp8_);
	_g_date_time_unref0 (now);
	block50_data_unref (_data50_);
	_data50_ = NULL;
}

void
tuba_instance_account_open_latest_wrapped (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	gint _tmp1_;
	TubaAPIAnnualReports* _tmp3_;
	gint _tmp4_;
	g_return_if_fail (self != NULL);
	_tmp1_ = self->priv->_tuba_last_fediwrapped_year;
	if (_tmp1_ == 0) {
		_tmp0_ = TRUE;
	} else {
		TubaAPIAnnualReports* _tmp2_;
		_tmp2_ = self->priv->annual_report;
		_tmp0_ = _tmp2_ == NULL;
	}
	if (_tmp0_) {
		return;
	}
	_tmp3_ = self->priv->annual_report;
	_tmp4_ = self->priv->_tuba_last_fediwrapped_year;
	tuba_api_annual_reports_open (_tmp3_, _tmp4_);
	tuba_instance_account_set_tuba_last_fediwrapped_year (self, 0);
	_g_object_unref0 (self->priv->annual_report);
	self->priv->annual_report = NULL;
}

static void
__lambda202_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonNode* node = NULL;
	TubaNetwork* _tmp1_;
	JsonNode* _tmp2_;
	JsonNode* _tmp3_;
	GValue res_emojis = {0};
	JsonNode* _tmp4_;
	GValue _tmp5_ = {0};
	GValue _tmp6_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = tuba_network_parse_node (_tmp1_, parser);
	node = _tmp2_;
	_tmp3_ = node;
	if (_tmp3_ == NULL) {
		__vala_JsonNode_free0 (node);
		_g_object_unref0 (parser);
		return;
	}
	_tmp4_ = node;
	tuba_entity_des_list (&_tmp5_, _tmp4_, TUBA_API_TYPE_EMOJI);
	G_IS_VALUE (&res_emojis) ? (g_value_unset (&res_emojis), NULL) : NULL;
	res_emojis = _tmp5_;
	_tmp6_ = res_emojis;
	tuba_instance_account_set_instance_emojis (self, g_value_get_object (&_tmp6_));
	G_IS_VALUE (&res_emojis) ? (g_value_unset (&res_emojis), NULL) : NULL;
	__vala_JsonNode_free0 (node);
	_g_object_unref0 (parser);
}

static void
___lambda202__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda202_ ((TubaInstanceAccount*) self, in_stream, error);
}

void
tuba_instance_account_gather_instance_custom_emojis (TubaInstanceAccount* self)
{
	GeeArrayList* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	TubaRequest* _tmp8_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->_instance_emojis;
	if (_tmp0_ != NULL) {
		return;
	}
	_tmp1_ = tuba_request_new_GET ("/api/v1/custom_emojis");
	_tmp2_ = _tmp1_;
	_tmp3_ = tuba_request_with_account (_tmp2_, self);
	_tmp4_ = _tmp3_;
	_tmp5_ = tuba_request_then (_tmp4_, ___lambda202__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_request_exec (_tmp6_);
	_tmp8_ = _tmp7_;
	_g_object_unref0 (_tmp8_);
	_g_object_unref0 (_tmp6_);
	_g_object_unref0 (_tmp4_);
	_g_object_unref0 (_tmp2_);
}

static void
____lambda49_ (TubaDialogsMainWindow* win,
               GObject* tag_obj)
{
	gchar* tag_str = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	TubaViewsHashtag* _tmp5_;
	TubaViewsHashtag* _tmp6_;
	TubaViewsBase* _tmp7_;
	TubaViewsBase* _tmp8_;
	TubaViewsBase* _tmp9_;
	TubaViewsBase* _tmp10_;
	g_return_if_fail (win != NULL);
	_tmp0_ = gtk_string_object_get_string (G_TYPE_CHECK_INSTANCE_CAST (tag_obj, gtk_string_object_get_type (), GtkStringObject));
	_tmp1_ = _tmp0_;
	_tmp2_ = g_strdup (_tmp1_);
	tag_str = _tmp2_;
	_tmp3_ = g_uri_escape_string (tag_str, NULL, TRUE);
	_tmp4_ = _tmp3_;
	_tmp5_ = tuba_views_hashtag_new (tag_str, NULL, _tmp4_, NULL);
	g_object_ref_sink (_tmp5_);
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_instance_account_set_as_sidebar_item ((TubaViewsBase*) _tmp6_);
	_tmp8_ = _tmp7_;
	_tmp9_ = tuba_dialogs_main_window_open_view (win, _tmp8_);
	_tmp10_ = _tmp9_;
	_g_object_unref0 (_tmp10_);
	_g_object_unref0 (_tmp8_);
	_g_object_unref0 (_tmp6_);
	_g_free0 (_tmp4_);
	_g_free0 (tag_str);
}

static void
_____lambda49__tuba_place_open_func (TubaDialogsMainWindow* window,
                                     GObject* extra)
{
	____lambda49_ (window, extra);
}

static void
_vala_array_add28 (TubaPlace** * array,
                   gint* length,
                   gint* size,
                   TubaPlace* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (TubaPlace*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

gboolean
tuba_instance_account_gather_fav_tags (TubaInstanceAccount* self)
{
	TubaSettings* _tmp0_;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gint _tmp2_ = 0;
	gchar** _tmp3_;
	gint _tmp3__length1;
	TubaPlace** fav_tags = NULL;
	TubaPlace** _tmp5_;
	gint fav_tags_length1;
	gint _fav_tags_size_;
	TubaSettings* _tmp6_;
	gchar** _tmp7_;
	gint _tmp7__length1;
	gint _tmp8_ = 0;
	gchar** _tmp9_;
	gint _tmp9__length1;
	TubaPlace** _tmp17_;
	gint _tmp17__length1;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = tuba_settings;
	_tmp1_ = tuba_settings_get_favorite_tags_ids (_tmp0_, &_tmp2_);
	_tmp1__length1 = _tmp2_;
	_tmp3_ = _tmp1_;
	_tmp3__length1 = _tmp1__length1;
	if (_tmp3__length1 == 0) {
		GListStore* _tmp4_;
		_tmp4_ = self->tags_places;
		tuba_instance_account_register_extra (self, _tmp4_, NULL, (gint) 0);
		result = G_SOURCE_REMOVE;
		return result;
	}
	_tmp5_ = g_new0 (TubaPlace*, 0 + 1);
	fav_tags = _tmp5_;
	fav_tags_length1 = 0;
	_fav_tags_size_ = fav_tags_length1;
	_tmp6_ = tuba_settings;
	_tmp7_ = tuba_settings_get_favorite_tags_ids (_tmp6_, &_tmp8_);
	_tmp7__length1 = _tmp8_;
	_tmp9_ = _tmp7_;
	_tmp9__length1 = _tmp7__length1;
	{
		gchar** tag_collection = NULL;
		gint tag_collection_length1 = 0;
		gint _tag_collection_size_ = 0;
		gint tag_it = 0;
		tag_collection = _tmp9_;
		tag_collection_length1 = _tmp9__length1;
		for (tag_it = 0; tag_it < tag_collection_length1; tag_it = tag_it + 1) {
			gchar* _tmp10_;
			gchar* tag = NULL;
			_tmp10_ = g_strdup (tag_collection[tag_it]);
			tag = _tmp10_;
			{
				gchar* _tmp11_;
				const gchar* _tmp12_;
				gchar* _tmp13_;
				const gchar* _tmp14_;
				GtkStringObject* _tmp15_;
				TubaPlace* _tmp16_ = NULL;
				_tmp11_ = g_strdup ("tuba-hashtag-symbolic");
				_tmp12_ = tag;
				_tmp13_ = g_strdup (_tmp12_);
				_tmp14_ = tag;
				_tmp15_ = gtk_string_object_new (_tmp14_);
				_tmp16_ = tuba_place_new ();
				tuba_place_set_icon (_tmp16_, _tmp11_);
				_g_free0 (_tmp11_);
				tuba_place_set_title (_tmp16_, _tmp13_);
				_g_free0 (_tmp13_);
				tuba_place_set_extra_data (_tmp16_, (GObject*) _tmp15_);
				_g_object_unref0 (_tmp15_);
				tuba_place_set_open_func (_tmp16_, _____lambda49__tuba_place_open_func);
				_vala_array_add28 (&fav_tags, &fav_tags_length1, &_fav_tags_size_, _tmp16_);
				_g_free0 (tag);
			}
		}
	}
	_tmp17_ = fav_tags;
	_tmp17__length1 = fav_tags_length1;
	if (_tmp17__length1 > 0) {
		GListStore* _tmp18_;
		TubaPlace** _tmp19_;
		gint _tmp19__length1;
		_tmp18_ = self->tags_places;
		_tmp19_ = fav_tags;
		_tmp19__length1 = fav_tags_length1;
		tuba_instance_account_register_extra (self, _tmp18_, _tmp19_, (gint) _tmp19__length1);
	}
	result = G_SOURCE_REMOVE;
	fav_tags = (_vala_array_free (fav_tags, fav_tags_length1, (GDestroyNotify) g_object_unref), NULL);
	return result;
}

static Block51Data*
block51_data_ref (Block51Data* _data51_)
{
	g_atomic_int_inc (&_data51_->_ref_count_);
	return _data51_;
}

static void
block51_data_unref (void * _userdata_)
{
	Block51Data* _data51_;
	_data51_ = (Block51Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data51_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data51_->self;
		_data51_->all_ids = (_vala_array_free (_data51_->all_ids, _data51_->all_ids_length1, (GDestroyNotify) g_free), NULL);
		_data51_->fav_lists = (_vala_array_free (_data51_->fav_lists, _data51_->fav_lists_length1, (GDestroyNotify) g_object_unref), NULL);
		_g_object_unref0 (self);
		g_slice_free (Block51Data, _data51_);
	}
}

static void
___lambda174_ (TubaDialogsMainWindow* win,
               GObject* list)
{
	TubaViewsList* _tmp0_;
	TubaViewsList* _tmp1_;
	TubaViewsBase* _tmp2_;
	TubaViewsBase* _tmp3_;
	TubaViewsBase* _tmp4_;
	TubaViewsBase* _tmp5_;
	g_return_if_fail (win != NULL);
	_tmp0_ = tuba_views_list_new (G_TYPE_CHECK_INSTANCE_CAST (list, TUBA_API_TYPE_LIST, TubaAPIList));
	g_object_ref_sink (_tmp0_);
	_tmp1_ = _tmp0_;
	_tmp2_ = tuba_instance_account_set_as_sidebar_item ((TubaViewsBase*) _tmp1_);
	_tmp3_ = _tmp2_;
	_tmp4_ = tuba_dialogs_main_window_open_view (win, _tmp3_);
	_tmp5_ = _tmp4_;
	_g_object_unref0 (_tmp5_);
	_g_object_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
}

static void
____lambda174__tuba_place_open_func (TubaDialogsMainWindow* window,
                                     GObject* extra)
{
	___lambda174_ (window, extra);
}

static void
_vala_array_add29 (TubaPlace** * array,
                   gint* length,
                   gint* size,
                   TubaPlace* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (TubaPlace*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
_vala_array_add30 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
__lambda173_ (Block51Data* _data51_,
              JsonNode* node,
              GError** error)
{
	TubaInstanceAccount* self;
	TubaAPIList* list = NULL;
	TubaAPIList* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	TubaSettings* _tmp3_;
	gchar** _tmp4_;
	gint _tmp4__length1;
	gint _tmp5_ = 0;
	gchar** _tmp6_;
	gint _tmp6__length1;
	const gchar* _tmp13_;
	const gchar* _tmp14_;
	gchar* _tmp15_;
	GError* _inner_error0_ = NULL;
	self = _data51_->self;
	g_return_if_fail (node != NULL);
	_tmp0_ = tuba_api_list_from (node, &_inner_error0_);
	list = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_api_list_get_id (list);
	_tmp2_ = _tmp1_;
	_tmp3_ = tuba_settings;
	_tmp4_ = tuba_settings_get_favorite_lists_ids (_tmp3_, &_tmp5_);
	_tmp4__length1 = _tmp5_;
	_tmp6_ = _tmp4_;
	_tmp6__length1 = _tmp4__length1;
	if (_vala_string_array_contains (_tmp6_, _tmp6__length1, _tmp2_)) {
		gchar* _tmp7_;
		const gchar* _tmp8_;
		const gchar* _tmp9_;
		gchar* _tmp10_;
		GObject* _tmp11_;
		TubaPlace* _tmp12_ = NULL;
		_tmp7_ = g_strdup ("tuba-list-compact-symbolic");
		_tmp8_ = tuba_api_list_get_title (list);
		_tmp9_ = _tmp8_;
		_tmp10_ = g_strdup (_tmp9_);
		_tmp11_ = _g_object_ref0 ((GObject*) list);
		_tmp12_ = tuba_place_new ();
		tuba_place_set_icon (_tmp12_, _tmp7_);
		_g_free0 (_tmp7_);
		tuba_place_set_title (_tmp12_, _tmp10_);
		_g_free0 (_tmp10_);
		tuba_place_set_extra_data (_tmp12_, _tmp11_);
		_g_object_unref0 (_tmp11_);
		tuba_place_set_open_func (_tmp12_, ____lambda174__tuba_place_open_func);
		_vala_array_add29 (&_data51_->fav_lists, &_data51_->fav_lists_length1, &_data51_->_fav_lists_size_, _tmp12_);
	}
	_tmp13_ = tuba_api_list_get_id (list);
	_tmp14_ = _tmp13_;
	_tmp15_ = g_strdup (_tmp14_);
	_vala_array_add30 (&_data51_->all_ids, &_data51_->all_ids_length1, &_data51_->_all_ids_size_, _tmp15_);
	_g_object_unref0 (list);
}

static void
___lambda173__tuba_network_node_callback (JsonNode* node,
                                          gpointer self,
                                          GError** error)
{
	__lambda173_ (self, node, error);
}

static void
_vala_array_add31 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
__lambda172_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	Block51Data* _data51_;
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	TubaPlace** _tmp1_;
	gchar** _tmp2_;
	JsonParser* _tmp3_;
	GListStore* _tmp4_;
	TubaPlace** _tmp5_;
	gint _tmp5__length1;
	gchar** new_favs = NULL;
	gchar** _tmp6_;
	gint new_favs_length1;
	gint _new_favs_size_;
	TubaSettings* _tmp7_;
	gchar** _tmp8_;
	gint _tmp8__length1;
	gint _tmp9_ = 0;
	gchar** _tmp10_;
	gint _tmp10__length1;
	TubaSettings* _tmp16_;
	gchar** _tmp17_;
	gint _tmp17__length1;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_data51_ = g_slice_new0 (Block51Data);
	_data51_->_ref_count_ = 1;
	_data51_->self = g_object_ref (self);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		block51_data_unref (_data51_);
		_data51_ = NULL;
		return;
	}
	_tmp1_ = g_new0 (TubaPlace*, 0 + 1);
	_data51_->fav_lists = _tmp1_;
	_data51_->fav_lists_length1 = 0;
	_data51_->_fav_lists_size_ = _data51_->fav_lists_length1;
	_tmp2_ = g_new0 (gchar*, 0 + 1);
	_data51_->all_ids = _tmp2_;
	_data51_->all_ids_length1 = 0;
	_data51_->_all_ids_size_ = _data51_->all_ids_length1;
	_tmp3_ = parser;
	tuba_network_parse_array (_tmp3_, ___lambda173__tuba_network_node_callback, block51_data_ref (_data51_), block51_data_unref, &_inner_error0_);
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		_g_object_unref0 (parser);
		block51_data_unref (_data51_);
		_data51_ = NULL;
		return;
	}
	_tmp4_ = self->list_places;
	_tmp5_ = _data51_->fav_lists;
	_tmp5__length1 = _data51_->fav_lists_length1;
	tuba_instance_account_register_extra (self, _tmp4_, _tmp5_, (gint) _tmp5__length1);
	_tmp6_ = g_new0 (gchar*, 0 + 1);
	new_favs = _tmp6_;
	new_favs_length1 = 0;
	_new_favs_size_ = new_favs_length1;
	_tmp7_ = tuba_settings;
	_tmp8_ = tuba_settings_get_favorite_lists_ids (_tmp7_, &_tmp9_);
	_tmp8__length1 = _tmp9_;
	_tmp10_ = _tmp8_;
	_tmp10__length1 = _tmp8__length1;
	{
		gchar** fav_id_collection = NULL;
		gint fav_id_collection_length1 = 0;
		gint _fav_id_collection_size_ = 0;
		gint fav_id_it = 0;
		fav_id_collection = _tmp10_;
		fav_id_collection_length1 = _tmp10__length1;
		for (fav_id_it = 0; fav_id_it < fav_id_collection_length1; fav_id_it = fav_id_it + 1) {
			gchar* _tmp11_;
			gchar* fav_id = NULL;
			_tmp11_ = g_strdup (fav_id_collection[fav_id_it]);
			fav_id = _tmp11_;
			{
				const gchar* _tmp12_;
				gchar** _tmp13_;
				gint _tmp13__length1;
				_tmp12_ = fav_id;
				_tmp13_ = _data51_->all_ids;
				_tmp13__length1 = _data51_->all_ids_length1;
				if (_vala_string_array_contains (_tmp13_, _tmp13__length1, _tmp12_)) {
					const gchar* _tmp14_;
					gchar* _tmp15_;
					_tmp14_ = fav_id;
					_tmp15_ = g_strdup (_tmp14_);
					_vala_array_add31 (&new_favs, &new_favs_length1, &_new_favs_size_, _tmp15_);
				}
				_g_free0 (fav_id);
			}
		}
	}
	_tmp16_ = tuba_settings;
	_tmp17_ = new_favs;
	_tmp17__length1 = new_favs_length1;
	tuba_settings_set_favorite_lists_ids (_tmp16_, _tmp17_, _tmp17__length1);
	new_favs = (_vala_array_free (new_favs, new_favs_length1, (GDestroyNotify) g_free), NULL);
	_g_object_unref0 (parser);
	block51_data_unref (_data51_);
	_data51_ = NULL;
}

static void
___lambda172__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda172_ ((TubaInstanceAccount*) self, in_stream, error);
}

gboolean
tuba_instance_account_gather_fav_lists (TubaInstanceAccount* self)
{
	TubaSettings* _tmp0_;
	gchar** _tmp1_;
	gint _tmp1__length1;
	gint _tmp2_ = 0;
	gchar** _tmp3_;
	gint _tmp3__length1;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	TubaRequest* _tmp8_;
	TubaRequest* _tmp9_;
	TubaRequest* _tmp10_;
	TubaRequest* _tmp11_;
	TubaRequest* _tmp12_;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = tuba_settings;
	_tmp1_ = tuba_settings_get_favorite_lists_ids (_tmp0_, &_tmp2_);
	_tmp1__length1 = _tmp2_;
	_tmp3_ = _tmp1_;
	_tmp3__length1 = _tmp1__length1;
	if (_tmp3__length1 == 0) {
		GListStore* _tmp4_;
		_tmp4_ = self->list_places;
		tuba_instance_account_register_extra (self, _tmp4_, NULL, (gint) 0);
		result = G_SOURCE_REMOVE;
		return result;
	}
	_tmp5_ = tuba_request_new_GET ("/api/v1/lists");
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_request_with_account (_tmp6_, self);
	_tmp8_ = _tmp7_;
	_tmp9_ = tuba_request_then (_tmp8_, ___lambda172__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp10_ = _tmp9_;
	_tmp11_ = tuba_request_exec (_tmp10_);
	_tmp12_ = _tmp11_;
	_g_object_unref0 (_tmp12_);
	_g_object_unref0 (_tmp10_);
	_g_object_unref0 (_tmp8_);
	_g_object_unref0 (_tmp6_);
	result = G_SOURCE_REMOVE;
	return result;
}

TubaViewsBase*
tuba_instance_account_set_as_sidebar_item (TubaViewsBase* view)
{
	TubaViewsBase* _tmp0_;
	TubaViewsBase* result;
	g_return_val_if_fail (view != NULL, NULL);
	tuba_views_base_set_is_sidebar_item (view, TRUE);
	tuba_views_base_set_show_back_button (view, FALSE);
	_tmp0_ = _g_object_ref0 (view);
	result = _tmp0_;
	return result;
}

static void
__lambda312_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonArray* array = NULL;
	JsonArray* _tmp1_;
	JsonArray* _tmp2_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network_get_array_mstd (parser);
	array = _tmp1_;
	_tmp2_ = array;
	if (_tmp2_ != NULL) {
		JsonArray* _tmp3_;
		gint _tmp4_;
		_tmp3_ = array;
		tuba_instance_account_set_unread_count (self, (gint) json_array_get_length (_tmp3_));
		_tmp4_ = self->priv->_unread_count;
		if (_tmp4_ > 0) {
			JsonArray* _tmp5_;
			JsonObject* _tmp6_;
			const gchar* _tmp7_;
			_tmp5_ = array;
			_tmp6_ = json_array_get_object_element (_tmp5_, (guint) 0);
			_tmp7_ = json_object_get_string_member_with_default (_tmp6_, "id", "-1");
			tuba_instance_account_set_last_received_id (self, atoi (_tmp7_));
		}
	}
	_json_array_unref0 (array);
	_g_object_unref0 (parser);
}

static void
___lambda312__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda312_ ((TubaInstanceAccount*) self, in_stream, error);
}

void
tuba_instance_account_init_notifications (TubaInstanceAccount* self)
{
	gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	TubaRequest* _tmp8_;
	gint _tmp9_;
	gchar* _tmp10_;
	gchar* _tmp11_;
	TubaRequest* _tmp12_;
	TubaRequest* _tmp13_;
	TubaRequest* _tmp14_;
	TubaRequest* _tmp15_;
	TubaRequest* _tmp16_;
	TubaRequest* _tmp17_;
	g_return_if_fail (self != NULL);
	_tmp0_ = tuba_views_notifications_get_notifications_excluded_types_query_param ();
	_tmp1_ = _tmp0_;
	_tmp2_ = string_to_string (_tmp1_);
	_tmp3_ = g_strconcat ("/api/v1/notifications", _tmp2_, NULL);
	_tmp4_ = _tmp3_;
	_tmp5_ = tuba_request_new_GET (_tmp4_);
	_tmp6_ = _tmp5_;
	_tmp7_ = tuba_request_with_account (_tmp6_, self);
	_tmp8_ = _tmp7_;
	_tmp9_ = self->priv->_last_read_id;
	_tmp10_ = g_strdup_printf ("%i", _tmp9_);
	_tmp11_ = _tmp10_;
	_tmp12_ = tuba_request_with_param (_tmp8_, "min_id", _tmp11_);
	_tmp13_ = _tmp12_;
	_tmp14_ = tuba_request_then (_tmp13_, ___lambda312__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp15_ = _tmp14_;
	_tmp16_ = tuba_request_exec (_tmp15_);
	_tmp17_ = _tmp16_;
	_g_object_unref0 (_tmp17_);
	_g_object_unref0 (_tmp15_);
	_g_object_unref0 (_tmp13_);
	_g_free0 (_tmp11_);
	_g_object_unref0 (_tmp8_);
	_g_object_unref0 (_tmp6_);
	_g_free0 (_tmp4_);
	_g_free0 (_tmp1_);
}

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

static void
__lambda205_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonObject* root = NULL;
	TubaNetwork* _tmp1_;
	JsonObject* _tmp2_;
	JsonObject* _tmp3_;
	JsonObject* notifications = NULL;
	JsonObject* _tmp4_;
	JsonObject* _tmp5_;
	JsonObject* _tmp6_;
	JsonObject* _tmp7_;
	const gchar* _tmp8_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network;
	_tmp2_ = tuba_network_parse (_tmp1_, parser);
	root = _tmp2_;
	_tmp3_ = root;
	if (!json_object_has_member (_tmp3_, "notifications")) {
		_json_object_unref0 (root);
		_g_object_unref0 (parser);
		return;
	}
	_tmp4_ = root;
	_tmp5_ = json_object_get_object_member (_tmp4_, "notifications");
	_tmp6_ = _json_object_ref0 (_tmp5_);
	notifications = _tmp6_;
	_tmp7_ = notifications;
	_tmp8_ = json_object_get_string_member_with_default (_tmp7_, "last_read_id", "-1");
	tuba_instance_account_set_last_read_id (self, atoi (_tmp8_));
	tuba_instance_account_init_notifications (self);
	_json_object_unref0 (notifications);
	_json_object_unref0 (root);
	_g_object_unref0 (parser);
}

static void
___lambda205__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda205_ ((TubaInstanceAccount*) self, in_stream, error);
}

static void
tuba_instance_account_real_check_notifications (TubaInstanceAccount* self)
{
	TubaRequest* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	_tmp0_ = tuba_request_new_GET ("/api/v1/markers?timeline[]=notifications");
	_tmp1_ = _tmp0_;
	_tmp2_ = tuba_request_with_account (_tmp1_, self);
	_tmp3_ = _tmp2_;
	_tmp4_ = tuba_request_then (_tmp3_, ___lambda205__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp5_ = _tmp4_;
	_tmp6_ = tuba_request_exec (_tmp5_);
	_tmp7_ = _tmp6_;
	_g_object_unref0 (_tmp7_);
	_g_object_unref0 (_tmp5_);
	_g_object_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
}

void
tuba_instance_account_check_notifications (TubaInstanceAccount* self)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->check_notifications) {
		_klass_->check_notifications (self);
	}
}

static Block52Data*
block52_data_ref (Block52Data* _data52_)
{
	g_atomic_int_inc (&_data52_->_ref_count_);
	return _data52_;
}

static void
block52_data_unref (void * _userdata_)
{
	Block52Data* _data52_;
	_data52_ = (Block52Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data52_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data52_->self;
		_g_object_unref0 (self);
		g_slice_free (Block52Data, _data52_);
	}
}

static void
___lambda204_ (Block52Data* _data52_,
               JsonArray* array,
               guint i,
               JsonNode* node)
{
	TubaInstanceAccount* self;
	JsonObject* _tmp0_;
	self = _data52_->self;
	g_return_if_fail (array != NULL);
	g_return_if_fail (node != NULL);
	_tmp0_ = json_node_get_object (node);
	if (json_object_get_boolean_member_with_default (_tmp0_, "read", TRUE) == FALSE) {
		_data52_->t_unread_announcements += 1;
	}
}

static void
____lambda204__json_array_foreach (JsonArray* array,
                                   guint index_,
                                   JsonNode* element_node,
                                   gpointer self)
{
	___lambda204_ (self, array, index_, element_node);
}

static void
__lambda203_ (TubaInstanceAccount* self,
              GInputStream* in_stream,
              GError** error)
{
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonArray* array = NULL;
	JsonArray* _tmp1_;
	JsonArray* _tmp2_;
	GError* _inner_error0_ = NULL;
	g_return_if_fail (in_stream != NULL);
	_tmp0_ = tuba_network_get_parser_from_inputstream (in_stream, &_inner_error0_);
	parser = _tmp0_;
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		return;
	}
	_tmp1_ = tuba_network_get_array_mstd (parser);
	array = _tmp1_;
	_tmp2_ = array;
	if (_tmp2_ != NULL) {
		Block52Data* _data52_;
		JsonArray* _tmp3_;
		_data52_ = g_slice_new0 (Block52Data);
		_data52_->_ref_count_ = 1;
		_data52_->self = g_object_ref (self);
		_data52_->t_unread_announcements = 0;
		_tmp3_ = array;
		json_array_foreach_element (_tmp3_, ____lambda204__json_array_foreach, _data52_);
		tuba_instance_account_set_unread_announcements (self, _data52_->t_unread_announcements);
		block52_data_unref (_data52_);
		_data52_ = NULL;
	}
	_json_array_unref0 (array);
	_g_object_unref0 (parser);
}

static void
___lambda203__tuba_network_success_callback (GInputStream* in_stream,
                                             SoupMessageHeaders* response_headers,
                                             gpointer self,
                                             GError** error)
{
	__lambda203_ ((TubaInstanceAccount*) self, in_stream, error);
}

void
tuba_instance_account_check_announcements (TubaInstanceAccount* self)
{
	TubaRequest* _tmp0_;
	TubaRequest* _tmp1_;
	TubaRequest* _tmp2_;
	TubaRequest* _tmp3_;
	TubaRequest* _tmp4_;
	TubaRequest* _tmp5_;
	TubaRequest* _tmp6_;
	TubaRequest* _tmp7_;
	g_return_if_fail (self != NULL);
	_tmp0_ = tuba_request_new_GET ("/api/v1/announcements");
	_tmp1_ = _tmp0_;
	_tmp2_ = tuba_request_with_account (_tmp1_, self);
	_tmp3_ = _tmp2_;
	_tmp4_ = tuba_request_then (_tmp3_, ___lambda203__tuba_network_success_callback, g_object_ref (self), g_object_unref);
	_tmp5_ = _tmp4_;
	_tmp6_ = tuba_request_exec (_tmp5_);
	_tmp7_ = _tmp6_;
	_g_object_unref0 (_tmp7_);
	_g_object_unref0 (_tmp5_);
	_g_object_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
}

void
tuba_instance_account_read_notifications (TubaInstanceAccount* self,
                                          gint up_to_id)
{
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gint _tmp4_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_strdup_printf ("%i", up_to_id);
	_tmp1_ = _tmp0_;
	_tmp2_ = g_strconcat ("Reading notifications up to id ", _tmp1_, NULL);
	_tmp3_ = _tmp2_;
	g_debug ("InstanceAccount.vala:873: %s", _tmp3_);
	_g_free0 (_tmp3_);
	_g_free0 (_tmp1_);
	_tmp4_ = self->priv->_last_read_id;
	if (up_to_id > _tmp4_) {
		gint _tmp5_;
		tuba_instance_account_set_last_read_id (self, up_to_id);
		_tmp5_ = self->priv->_last_read_id;
		if (_tmp5_ != -1) {
			TubaRequest* _tmp6_;
			TubaRequest* _tmp7_;
			TubaRequest* _tmp8_;
			TubaRequest* _tmp9_;
			gchar* _tmp10_;
			gchar* _tmp11_;
			TubaRequest* _tmp12_;
			TubaRequest* _tmp13_;
			TubaRequest* _tmp14_;
			TubaRequest* _tmp15_;
			gboolean _tmp16_ = FALSE;
			TubaAPIInstance* _tmp17_;
			GeeHashMap* _tmp42_;
			_tmp6_ = tuba_request_new_POST ("/api/v1/markers");
			_tmp7_ = _tmp6_;
			_tmp8_ = tuba_request_with_account (_tmp7_, self);
			_tmp9_ = _tmp8_;
			_tmp10_ = g_strdup_printf ("%i", up_to_id);
			_tmp11_ = _tmp10_;
			_tmp12_ = tuba_request_with_form_data (_tmp9_, "notifications[last_read_id]", _tmp11_);
			_tmp13_ = _tmp12_;
			_tmp14_ = tuba_request_exec (_tmp13_);
			_tmp15_ = _tmp14_;
			_g_object_unref0 (_tmp15_);
			_g_object_unref0 (_tmp13_);
			_g_free0 (_tmp11_);
			_g_object_unref0 (_tmp9_);
			_g_object_unref0 (_tmp7_);
			_tmp17_ = self->priv->_instance_info;
			if (_tmp17_ != NULL) {
				TubaAPIInstance* _tmp18_;
				TubaAPIPleromaInstance* _tmp19_;
				TubaAPIPleromaInstance* _tmp20_;
				_tmp18_ = self->priv->_instance_info;
				_tmp19_ = tuba_api_instance_get_pleroma (_tmp18_);
				_tmp20_ = _tmp19_;
				_tmp16_ = _tmp20_ != NULL;
			} else {
				_tmp16_ = FALSE;
			}
			if (_tmp16_) {
				TubaRequest* _tmp21_;
				TubaRequest* _tmp22_;
				TubaRequest* _tmp23_;
				TubaRequest* _tmp24_;
				gchar* _tmp25_;
				gchar* _tmp26_;
				TubaRequest* _tmp27_;
				TubaRequest* _tmp28_;
				TubaRequest* _tmp29_;
				TubaRequest* _tmp30_;
				_tmp21_ = tuba_request_new_POST ("/api/v1/pleroma/notifications/read");
				_tmp22_ = _tmp21_;
				_tmp23_ = tuba_request_with_account (_tmp22_, self);
				_tmp24_ = _tmp23_;
				_tmp25_ = g_strdup_printf ("%i", up_to_id);
				_tmp26_ = _tmp25_;
				_tmp27_ = tuba_request_with_form_data (_tmp24_, "max_id", _tmp26_);
				_tmp28_ = _tmp27_;
				_tmp29_ = tuba_request_exec (_tmp28_);
				_tmp30_ = _tmp29_;
				_g_object_unref0 (_tmp30_);
				_g_object_unref0 (_tmp28_);
				_g_free0 (_tmp26_);
				_g_object_unref0 (_tmp24_);
				_g_object_unref0 (_tmp22_);
			}
			{
				GeeIterator* _notification_id_it = NULL;
				GeeHashMap* _tmp31_;
				GeeSet* _tmp32_;
				GeeSet* _tmp33_;
				GeeSet* _tmp34_;
				GeeIterator* _tmp35_;
				GeeIterator* _tmp36_;
				_tmp31_ = self->priv->sent_notifications;
				_tmp32_ = gee_abstract_map_get_keys ((GeeAbstractMap*) _tmp31_);
				_tmp33_ = _tmp32_;
				_tmp34_ = _tmp33_;
				_tmp35_ = gee_iterable_iterator ((GeeIterable*) _tmp34_);
				_tmp36_ = _tmp35_;
				_g_object_unref0 (_tmp34_);
				_notification_id_it = _tmp36_;
				while (TRUE) {
					GeeIterator* _tmp37_;
					gchar* notification_id = NULL;
					GeeIterator* _tmp38_;
					gpointer _tmp39_;
					TubaApplication* _tmp40_;
					const gchar* _tmp41_;
					_tmp37_ = _notification_id_it;
					if (!gee_iterator_next (_tmp37_)) {
						break;
					}
					_tmp38_ = _notification_id_it;
					_tmp39_ = gee_iterator_get (_tmp38_);
					notification_id = (gchar*) _tmp39_;
					_tmp40_ = tuba_app;
					_tmp41_ = notification_id;
					g_application_withdraw_notification ((GApplication*) _tmp40_, _tmp41_);
					_g_free0 (notification_id);
				}
				_g_object_unref0 (_notification_id_it);
			}
			_tmp42_ = self->priv->sent_notifications;
			gee_abstract_map_clear ((GeeAbstractMap*) _tmp42_);
		}
	}
	tuba_instance_account_set_unread_count (self, 0);
}

static Block53Data*
block53_data_ref (Block53Data* _data53_)
{
	g_atomic_int_inc (&_data53_->_ref_count_);
	return _data53_;
}

static void
block53_data_unref (void * _userdata_)
{
	Block53Data* _data53_;
	_data53_ = (Block53Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data53_->_ref_count_)) {
		TubaInstanceAccount* self;
		self = _data53_->self;
		_g_free0 (_data53_->id);
		_g_object_unref0 (_data53_->obj);
		_g_object_unref0 (self);
		g_slice_free (Block53Data, _data53_);
	}
}

static void
__lambda314_ (Block53Data* _data53_,
              GObject* _obj,
              GAsyncResult* res)
{
	TubaInstanceAccount* self;
	TubaApplication* _tmp0_;
	const gchar* _tmp1_;
	GNotification* _tmp2_;
	GNotification* _tmp3_;
	self = _data53_->self;
	g_return_if_fail (res != NULL);
	_tmp0_ = tuba_app;
	_tmp1_ = _data53_->id;
	_tmp2_ = tuba_api_notification_to_toast_finish (_data53_->obj, res);
	_tmp3_ = _tmp2_;
	g_application_send_notification ((GApplication*) _tmp0_, _tmp1_, _tmp3_);
	_g_object_unref0 (_tmp3_);
}

static void
___lambda314__gasync_ready_callback (GObject* source_object,
                                     GAsyncResult* res,
                                     gpointer self)
{
	__lambda314_ (self, source_object, res);
	block53_data_unref (self);
}

void
tuba_instance_account_send_toast (TubaInstanceAccount* self,
                                  TubaAPINotification* obj)
{
	Block53Data* _data53_;
	TubaAPINotification* _tmp0_;
	gboolean _tmp1_ = FALSE;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	const gchar* _tmp10_;
	const gchar* _tmp11_;
	gchar* _tmp12_;
	gint others = 0;
	gboolean _tmp13_ = FALSE;
	gboolean _tmp14_ = FALSE;
	TubaSettings* _tmp15_;
	gboolean _tmp16_;
	gboolean _tmp17_;
	GeeHashMap* _tmp44_;
	const gchar* _tmp45_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (obj != NULL);
	_data53_ = g_slice_new0 (Block53Data);
	_data53_->_ref_count_ = 1;
	_data53_->self = g_object_ref (self);
	_tmp0_ = _g_object_ref0 (obj);
	_g_object_unref0 (_data53_->obj);
	_data53_->obj = _tmp0_;
	_tmp2_ = tuba_api_notification_get_kind (_data53_->obj);
	_tmp3_ = _tmp2_;
	if (_tmp3_ != NULL) {
		const gchar* _tmp4_;
		const gchar* _tmp5_;
		TubaSettings* _tmp6_;
		gchar** _tmp7_;
		gint _tmp7__length1;
		gint _tmp8_ = 0;
		gchar** _tmp9_;
		gint _tmp9__length1;
		_tmp4_ = tuba_api_notification_get_kind (_data53_->obj);
		_tmp5_ = _tmp4_;
		_tmp6_ = tuba_settings;
		_tmp7_ = tuba_settings_get_muted_notification_types (_tmp6_, &_tmp8_);
		_tmp7__length1 = _tmp8_;
		_tmp9_ = _tmp7_;
		_tmp9__length1 = _tmp7__length1;
		_tmp1_ = _vala_string_array_contains (_tmp9_, _tmp9__length1, _tmp5_);
	} else {
		_tmp1_ = FALSE;
	}
	if (_tmp1_) {
		block53_data_unref (_data53_);
		_data53_ = NULL;
		return;
	}
	_tmp10_ = tuba_api_account_get_id ((TubaAPIAccount*) self);
	_tmp11_ = _tmp10_;
	_tmp12_ = g_strdup (_tmp11_);
	_data53_->id = _tmp12_;
	others = 0;
	_tmp15_ = tuba_settings;
	_tmp16_ = tuba_settings_get_group_push_notifications (_tmp15_);
	_tmp17_ = _tmp16_;
	if (_tmp17_) {
		TubaAPIStatus* _tmp18_;
		TubaAPIStatus* _tmp19_;
		_tmp18_ = tuba_api_notification_get_status (_data53_->obj);
		_tmp19_ = _tmp18_;
		_tmp14_ = _tmp19_ != NULL;
	} else {
		_tmp14_ = FALSE;
	}
	if (_tmp14_) {
		const gchar* _tmp20_;
		const gchar* _tmp21_;
		_tmp20_ = tuba_api_notification_get_kind (_data53_->obj);
		_tmp21_ = _tmp20_;
		_tmp13_ = _vala_string_array_contains (TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS, G_N_ELEMENTS (TUBA_INSTANCE_ACCOUNT_GROUPED_KINDS), _tmp21_);
	} else {
		_tmp13_ = FALSE;
	}
	if (_tmp13_) {
		const gchar* _tmp22_;
		const gchar* _tmp23_;
		TubaAPIStatus* _tmp24_;
		TubaAPIStatus* _tmp25_;
		const gchar* _tmp26_;
		const gchar* _tmp27_;
		const gchar* _tmp28_;
		const gchar* _tmp29_;
		const gchar* _tmp30_;
		const gchar* _tmp31_;
		gchar* _tmp32_;
		GeeHashMap* _tmp33_;
		const gchar* _tmp34_;
		_tmp22_ = _data53_->id;
		_tmp23_ = string_to_string (_tmp22_);
		_tmp24_ = tuba_api_notification_get_status (_data53_->obj);
		_tmp25_ = _tmp24_;
		_tmp26_ = tuba_api_status_get_id (_tmp25_);
		_tmp27_ = _tmp26_;
		_tmp28_ = string_to_string (_tmp27_);
		_tmp29_ = tuba_api_notification_get_kind (_data53_->obj);
		_tmp30_ = _tmp29_;
		_tmp31_ = string_to_string (_tmp30_);
		_tmp32_ = g_strconcat (_tmp23_, "-", _tmp28_, "-", _tmp31_, NULL);
		_g_free0 (_data53_->id);
		_data53_->id = _tmp32_;
		_tmp33_ = self->priv->sent_notifications;
		_tmp34_ = _data53_->id;
		if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp33_, _tmp34_)) {
			GeeHashMap* _tmp35_;
			const gchar* _tmp36_;
			gpointer _tmp37_;
			_tmp35_ = self->priv->sent_notifications;
			_tmp36_ = _data53_->id;
			_tmp37_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp35_, _tmp36_);
			others = ((gint) ((gintptr) _tmp37_)) + 1;
		}
	} else {
		const gchar* _tmp38_;
		const gchar* _tmp39_;
		const gchar* _tmp40_;
		const gchar* _tmp41_;
		const gchar* _tmp42_;
		gchar* _tmp43_;
		_tmp38_ = _data53_->id;
		_tmp39_ = string_to_string (_tmp38_);
		_tmp40_ = tuba_api_notification_get_id (_data53_->obj);
		_tmp41_ = _tmp40_;
		_tmp42_ = string_to_string (_tmp41_);
		_tmp43_ = g_strconcat (_tmp39_, "-", _tmp42_, NULL);
		_g_free0 (_data53_->id);
		_data53_->id = _tmp43_;
	}
	_tmp44_ = self->priv->sent_notifications;
	_tmp45_ = _data53_->id;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp44_, _tmp45_, (gpointer) ((gintptr) others));
	tuba_api_notification_to_toast (_data53_->obj, self, others, ___lambda314__gasync_ready_callback, block53_data_ref (_data53_));
	block53_data_unref (_data53_);
	_data53_ = NULL;
}

static gchar*
tuba_instance_account_real_get_stream_url (TubaInstanceAccount* self)
{
	gboolean _tmp0_ = FALSE;
	const gchar* _tmp1_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp5_;
	const gchar* _tmp6_;
	gchar* _tmp7_;
	gchar* result;
	_tmp1_ = self->priv->_instance;
	if (_tmp1_ == NULL) {
		_tmp0_ = TRUE;
	} else {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_access_token;
		_tmp0_ = _tmp2_ == NULL;
	}
	if (_tmp0_) {
		result = NULL;
		return result;
	}
	_tmp3_ = self->priv->_instance;
	_tmp4_ = string_to_string (_tmp3_);
	_tmp5_ = self->priv->_access_token;
	_tmp6_ = string_to_string (_tmp5_);
	_tmp7_ = g_strconcat (_tmp4_, "/api/v1/streaming?stream=user:notification&access_token=", _tmp6_, NULL);
	result = _tmp7_;
	return result;
}

gchar*
tuba_instance_account_get_stream_url (TubaInstanceAccount* self)
{
	TubaInstanceAccountClass* _klass_;
	g_return_val_if_fail (self != NULL, NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->get_stream_url) {
		return _klass_->get_stream_url (self);
	}
	return NULL;
}

static void
tuba_instance_account_real_on_notification_event (TubaInstanceAccount* self,
                                                  TubaStreamableEvent* ev)
{
	GError* _inner_error0_ = NULL;
	g_return_if_fail (ev != NULL);
	{
		JsonNode* _tmp0_ = NULL;
		JsonNode* _tmp1_;
		TubaAPINotification* entity = NULL;
		gpointer _tmp2_;
		gboolean _tmp3_ = FALSE;
		TubaAPINotification* _tmp4_;
		TubaAPIStatus* _tmp5_;
		TubaAPIStatus* _tmp6_;
		TubaAPINotification* _tmp14_;
		const gchar* _tmp15_;
		const gchar* _tmp16_;
		gint id = 0;
		TubaAPINotification* _tmp18_;
		const gchar* _tmp19_;
		const gchar* _tmp20_;
		gint _tmp21_;
		_tmp1_ = tuba_streamable_event_get_node (ev, &_inner_error0_);
		_tmp0_ = _tmp1_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			goto __catch0_g_error;
		}
		_tmp2_ = tuba_instance_account_create_entity (self, TUBA_API_TYPE_NOTIFICATION, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp0_, &_inner_error0_);
		entity = (TubaAPINotification*) _tmp2_;
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			__vala_JsonNode_free0 (_tmp0_);
			goto __catch0_g_error;
		}
		_tmp4_ = entity;
		_tmp5_ = tuba_api_notification_get_status (_tmp4_);
		_tmp6_ = _tmp5_;
		if (_tmp6_ != NULL) {
			TubaAPINotification* _tmp7_;
			TubaAPIStatus* _tmp8_;
			TubaAPIStatus* _tmp9_;
			TubaAPIStatus* _tmp10_;
			TubaAPIStatus* _tmp11_;
			gboolean _tmp12_;
			gboolean _tmp13_;
			_tmp7_ = entity;
			_tmp8_ = tuba_api_notification_get_status (_tmp7_);
			_tmp9_ = _tmp8_;
			_tmp10_ = tuba_api_status_get_formal (_tmp9_);
			_tmp11_ = _tmp10_;
			_tmp12_ = tuba_api_status_get_tuba_filter_hidden (_tmp11_);
			_tmp13_ = _tmp12_;
			_tmp3_ = _tmp13_;
		} else {
			_tmp3_ = FALSE;
		}
		if (_tmp3_) {
			_g_object_unref0 (entity);
			__vala_JsonNode_free0 (_tmp0_);
			return;
		}
		_tmp14_ = entity;
		_tmp15_ = tuba_api_notification_get_kind (_tmp14_);
		_tmp16_ = _tmp15_;
		if (g_strcmp0 (_tmp16_, TUBA_INSTANCE_ACCOUNT_KIND_FOLLOW_REQUEST) == 0) {
			gint _tmp17_;
			_tmp17_ = self->priv->_unreviewed_follow_requests;
			tuba_instance_account_set_unreviewed_follow_requests (self, _tmp17_ + 1);
		}
		_tmp18_ = entity;
		_tmp19_ = tuba_api_notification_get_id (_tmp18_);
		_tmp20_ = _tmp19_;
		id = atoi (_tmp20_);
		_tmp21_ = self->priv->_last_received_id;
		if (id > _tmp21_) {
			TubaAPINotification* _tmp22_;
			const gchar* _tmp23_;
			const gchar* _tmp24_;
			gint _tmp25_ = 0;
			gchar** _tmp26_;
			gchar** _tmp27_;
			gint _tmp27__length1;
			gboolean _tmp28_;
			TubaAPINotification* _tmp30_;
			tuba_instance_account_set_last_received_id (self, id);
			_tmp22_ = entity;
			_tmp23_ = tuba_api_notification_get_kind (_tmp22_);
			_tmp24_ = _tmp23_;
			_tmp26_ = tuba_instance_account_account_settings_notification_filters (self, &_tmp25_);
			_tmp27_ = _tmp26_;
			_tmp27__length1 = _tmp25_;
			_tmp28_ = !_vala_string_array_contains (_tmp27_, _tmp25_, _tmp24_);
			_tmp27_ = (_vala_array_free (_tmp27_, _tmp27__length1, (GDestroyNotify) g_free), NULL);
			if (_tmp28_) {
				gint _tmp29_;
				_tmp29_ = self->priv->_unread_count;
				tuba_instance_account_set_unread_count (self, _tmp29_ + 1);
			}
			_tmp30_ = entity;
			tuba_instance_account_send_toast (self, _tmp30_);
		}
		_g_object_unref0 (entity);
		__vala_JsonNode_free0 (_tmp0_);
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		GError* _tmp31_;
		const gchar* _tmp32_;
		const gchar* _tmp33_;
		gchar* _tmp34_;
		gchar* _tmp35_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp31_ = e;
		_tmp32_ = _tmp31_->message;
		_tmp33_ = string_to_string (_tmp32_);
		_tmp34_ = g_strconcat ("on_notification_event: ", _tmp33_, NULL);
		_tmp35_ = _tmp34_;
		g_warning ("InstanceAccount.vala:979: %s", _tmp35_);
		_g_free0 (_tmp35_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

void
tuba_instance_account_on_notification_event (TubaInstanceAccount* self,
                                             TubaStreamableEvent* ev)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->on_notification_event) {
		_klass_->on_notification_event (self, ev);
	}
}

static void
tuba_instance_account_real_open_status_url (TubaInstanceAccount* self,
                                            const gchar* url)
{
	g_return_if_fail (url != NULL);
}

void
tuba_instance_account_open_status_url (TubaInstanceAccount* self,
                                       const gchar* url)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->open_status_url) {
		_klass_->open_status_url (self, url);
	}
}

static void
tuba_instance_account_real_answer_follow_request (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* fr_id,
                                                  gboolean accept)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (fr_id != NULL);
}

void
tuba_instance_account_answer_follow_request (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* fr_id,
                                             gboolean accept)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->answer_follow_request) {
		_klass_->answer_follow_request (self, issuer_id, fr_id, accept);
	}
}

static void
tuba_instance_account_real_follow_back (TubaInstanceAccount* self,
                                        const gchar* issuer_id,
                                        const gchar* acc_id)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (acc_id != NULL);
}

void
tuba_instance_account_follow_back (TubaInstanceAccount* self,
                                   const gchar* issuer_id,
                                   const gchar* acc_id)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->follow_back) {
		_klass_->follow_back (self, issuer_id, acc_id);
	}
}

static void
tuba_instance_account_real_reply_to_status_uri (TubaInstanceAccount* self,
                                                const gchar* issuer_id,
                                                const gchar* uri)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (uri != NULL);
}

void
tuba_instance_account_reply_to_status_uri (TubaInstanceAccount* self,
                                           const gchar* issuer_id,
                                           const gchar* uri)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->reply_to_status_uri) {
		_klass_->reply_to_status_uri (self, issuer_id, uri);
	}
}

static void
tuba_instance_account_real_remove_from_followers (TubaInstanceAccount* self,
                                                  const gchar* issuer_id,
                                                  const gchar* acc_id)
{
	g_return_if_fail (issuer_id != NULL);
	g_return_if_fail (acc_id != NULL);
}

void
tuba_instance_account_remove_from_followers (TubaInstanceAccount* self,
                                             const gchar* issuer_id,
                                             const gchar* acc_id)
{
	TubaInstanceAccountClass* _klass_;
	g_return_if_fail (self != NULL);
	_klass_ = TUBA_INSTANCE_ACCOUNT_GET_CLASS (self);
	if (_klass_->remove_from_followers) {
		_klass_->remove_from_followers (self, issuer_id, acc_id);
	}
}

static GSettings*
tuba_instance_account_account_settings (TubaInstanceAccount* self)
{
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	GSettings* _tmp5_;
	GSettings* _tmp8_;
	GSettings* _tmp9_;
	GSettings* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == self) {
		TubaSettings* _tmp3_;
		GSettings* _tmp4_;
		_tmp3_ = tuba_settings;
		_tmp4_ = _g_object_ref0 ((GSettings*) _tmp3_);
		result = _tmp4_;
		return result;
	}
	_tmp5_ = self->priv->_account_settings;
	if (_tmp5_ == NULL) {
		const gchar* _tmp6_;
		TubaSettingsAccount* _tmp7_;
		_tmp6_ = self->priv->_uuid;
		_tmp7_ = tuba_settings_account_new (_tmp6_);
		_g_object_unref0 (self->priv->_account_settings);
		self->priv->_account_settings = (GSettings*) _tmp7_;
	}
	_tmp8_ = self->priv->_account_settings;
	_tmp9_ = _g_object_ref0 (_tmp8_);
	result = _tmp9_;
	return result;
}

static gchar**
_vala_array_dup28 (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;
}

static gchar**
_vala_array_dup29 (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;
}

static gchar**
tuba_instance_account_account_settings_notification_filters (TubaInstanceAccount* self,
                                                             gint* result_length1)
{
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	gchar** result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == self) {
		GSettings* _tmp3_;
		TubaSettings* _tmp4_;
		gchar** _tmp5_;
		gint _tmp5__length1;
		gint _tmp6_ = 0;
		gchar** _tmp7_;
		gint _tmp7__length1;
		gchar** _tmp8_;
		gint _tmp8__length1;
		gchar** _tmp9_;
		gint _tmp9__length1;
		gchar** _tmp10_;
		gint _tmp10__length1;
		_tmp3_ = tuba_instance_account_account_settings (self);
		_tmp4_ = G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, TUBA_TYPE_SETTINGS, TubaSettings);
		_tmp5_ = tuba_settings_get_notification_filters (_tmp4_, &_tmp6_);
		_tmp5__length1 = _tmp6_;
		_tmp7_ = _tmp5_;
		_tmp7__length1 = _tmp5__length1;
		_tmp8_ = (_tmp7_ != NULL) ? _vala_array_dup28 (_tmp7_, _tmp7__length1) : _tmp7_;
		_tmp8__length1 = _tmp7__length1;
		_tmp9_ = _tmp8_;
		_tmp9__length1 = _tmp8__length1;
		_g_object_unref0 (_tmp4_);
		_tmp10_ = _tmp9_;
		_tmp10__length1 = _tmp9__length1;
		if (result_length1) {
			*result_length1 = _tmp10__length1;
		}
		result = _tmp10_;
		return result;
	} else {
		GSettings* _tmp11_;
		TubaSettingsAccount* _tmp12_;
		gchar** _tmp13_;
		gint _tmp13__length1;
		gint _tmp14_ = 0;
		gchar** _tmp15_;
		gint _tmp15__length1;
		gchar** _tmp16_;
		gint _tmp16__length1;
		gchar** _tmp17_;
		gint _tmp17__length1;
		gchar** _tmp18_;
		gint _tmp18__length1;
		_tmp11_ = tuba_instance_account_account_settings (self);
		_tmp12_ = G_TYPE_CHECK_INSTANCE_CAST (_tmp11_, TUBA_SETTINGS_TYPE_ACCOUNT, TubaSettingsAccount);
		_tmp13_ = tuba_settings_account_get_notification_filters (_tmp12_, &_tmp14_);
		_tmp13__length1 = _tmp14_;
		_tmp15_ = _tmp13_;
		_tmp15__length1 = _tmp13__length1;
		_tmp16_ = (_tmp15_ != NULL) ? _vala_array_dup29 (_tmp15_, _tmp15__length1) : _tmp15_;
		_tmp16__length1 = _tmp15__length1;
		_tmp17_ = _tmp16_;
		_tmp17__length1 = _tmp16__length1;
		_g_object_unref0 (_tmp12_);
		_tmp18_ = _tmp17_;
		_tmp18__length1 = _tmp17__length1;
		if (result_length1) {
			*result_length1 = _tmp18__length1;
		}
		result = _tmp18_;
		return result;
	}
}

TubaInstanceAccount*
tuba_instance_account_construct (GType object_type)
{
	TubaInstanceAccount * self = NULL;
	self = (TubaInstanceAccount*) tuba_api_account_construct (object_type);
	return self;
}

TubaInstanceAccount*
tuba_instance_account_new (void)
{
	return tuba_instance_account_construct (TUBA_TYPE_INSTANCE_ACCOUNT);
}

TubaInstanceAccountInstanceFeatures
tuba_instance_account_get_tuba_instance_features (TubaInstanceAccount* self)
{
	TubaInstanceAccountInstanceFeatures result;
	g_return_val_if_fail (self != NULL, 0U);
	result = self->priv->_tuba_instance_features;
	return result;
}

void
tuba_instance_account_set_tuba_instance_features (TubaInstanceAccount* self,
                                                  TubaInstanceAccountInstanceFeatures value)
{
	TubaInstanceAccountInstanceFeatures old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_instance_features (self);
	if (old_value != value) {
		self->priv->_tuba_instance_features = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_tuba_iceshrimp_api_key (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_tuba_iceshrimp_api_key;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_iceshrimp_api_key (TubaInstanceAccount* self,
                                                  const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_iceshrimp_api_key (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_tuba_iceshrimp_api_key);
		self->priv->_tuba_iceshrimp_api_key = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_tuba_streaming_url (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp1_ = self->priv->_tuba_streaming_url;
	if (_tmp1_ == NULL) {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_instance;
		_tmp0_ = _tmp2_;
	} else {
		const gchar* _tmp3_;
		_tmp3_ = self->priv->_tuba_streaming_url;
		_tmp0_ = _tmp3_;
	}
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_streaming_url (TubaInstanceAccount* self,
                                              const gchar* value)
{
	gchar* _tmp0_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_strdup (value);
	_g_free0 (self->priv->_tuba_streaming_url);
	self->priv->_tuba_streaming_url = _tmp0_;
	g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY]);
}

const gchar*
tuba_instance_account_get_uuid (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_uuid;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_uuid (TubaInstanceAccount* self,
                                const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_uuid (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_uuid);
		self->priv->_uuid = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_admin_mode (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_admin_mode;
	return result;
}

void
tuba_instance_account_set_admin_mode (TubaInstanceAccount* self,
                                      gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_admin_mode (self);
	if (old_value != value) {
		self->priv->_admin_mode = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_backend (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_backend;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_backend (TubaInstanceAccount* self,
                                   const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_backend (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_backend);
		self->priv->_backend = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY]);
	}
}

TubaAPIInstance*
tuba_instance_account_get_instance_info (TubaInstanceAccount* self)
{
	TubaAPIInstance* result;
	TubaAPIInstance* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance_info;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance_info (TubaInstanceAccount* self,
                                         TubaAPIInstance* value)
{
	TubaAPIInstance* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance_info (self);
	if (old_value != value) {
		TubaAPIInstance* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_instance_info);
		self->priv->_instance_info = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY]);
	}
}

GeeArrayList*
tuba_instance_account_get_instance_emojis (TubaInstanceAccount* self)
{
	GeeArrayList* result;
	GeeArrayList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance_emojis;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance_emojis (TubaInstanceAccount* self,
                                           GeeArrayList* value)
{
	GeeArrayList* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance_emojis (self);
	if (old_value != value) {
		GeeArrayList* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_instance_emojis);
		self->priv->_instance_emojis = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_instance (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_instance;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_instance (TubaInstanceAccount* self,
                                    const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_instance (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_instance);
		self->priv->_instance = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_client_id (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_client_id;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_client_id (TubaInstanceAccount* self,
                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_client_id (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_client_id);
		self->priv->_client_id = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_client_secret (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_client_secret;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_client_secret (TubaInstanceAccount* self,
                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_client_secret (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_client_secret);
		self->priv->_client_secret = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_get_access_token (TubaInstanceAccount* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_access_token;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_access_token (TubaInstanceAccount* self,
                                        const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_access_token (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_access_token);
		self->priv->_access_token = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_needs_update (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_needs_update;
	return result;
}

void
tuba_instance_account_set_needs_update (TubaInstanceAccount* self,
                                        gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_needs_update (self);
	if (old_value != value) {
		self->priv->_needs_update = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY]);
	}
}

GError*
tuba_instance_account_get_error (TubaInstanceAccount* self)
{
	GError* result;
	GError* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_error;
	result = _tmp0_;
	return result;
}

static gpointer
_g_error_copy0 (gpointer self)
{
	return self ? g_error_copy (self) : NULL;
}

void
tuba_instance_account_set_error (TubaInstanceAccount* self,
                                 GError* value)
{
	GError* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_error (self);
	if (old_value != value) {
		GError* _tmp0_;
		_tmp0_ = _g_error_copy0 (value);
		_g_error_free0 (self->priv->_error);
		self->priv->_error = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY]);
	}
}

gboolean
tuba_instance_account_get_tuba_probably_has_notification_filters (TubaInstanceAccount* self)
{
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	result = self->priv->_tuba_probably_has_notification_filters;
	return result;
}

void
tuba_instance_account_set_tuba_probably_has_notification_filters (TubaInstanceAccount* self,
                                                                  gboolean value)
{
	gboolean old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_probably_has_notification_filters (self);
	if (old_value != value) {
		self->priv->_tuba_probably_has_notification_filters = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY]);
	}
}

TubaAPIInstanceV2APIVersions*
tuba_instance_account_get_tuba_api_versions (TubaInstanceAccount* self)
{
	TubaAPIInstanceV2APIVersions* result;
	TubaAPIInstanceV2APIVersions* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_tuba_api_versions;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_set_tuba_api_versions (TubaInstanceAccount* self,
                                             TubaAPIInstanceV2APIVersions* value)
{
	TubaAPIInstanceV2APIVersions* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_api_versions (self);
	if (old_value != value) {
		TubaAPIInstanceV2APIVersions* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_tuba_api_versions);
		self->priv->_tuba_api_versions = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY]);
	}
}

gchar*
tuba_instance_account_get_handle_short (TubaInstanceAccount* self)
{
	gchar* result;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_api_account_get_username ((TubaAPIAccount*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = string_to_string (_tmp1_);
	_tmp3_ = g_strconcat ("@", _tmp2_, NULL);
	result = _tmp3_;
	return result;
}

gchar*
tuba_instance_account_get_handle (TubaInstanceAccount* self)
{
	gchar* result;
	gchar* _tmp0_;
	gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = tuba_api_account_get_full_handle ((TubaAPIAccount*) self);
	_tmp1_ = _tmp0_;
	result = _tmp1_;
	return result;
}

gboolean
tuba_instance_account_get_is_active (TubaInstanceAccount* self)
{
	gboolean result;
	TubaAccountStore* _tmp0_;
	TubaInstanceAccount* _tmp1_;
	TubaInstanceAccount* _tmp2_;
	TubaAccountStore* _tmp3_;
	TubaInstanceAccount* _tmp4_;
	TubaInstanceAccount* _tmp5_;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = tuba_accounts;
	_tmp1_ = tuba_account_store_get_active (_tmp0_);
	_tmp2_ = _tmp1_;
	if (_tmp2_ == NULL) {
		result = FALSE;
		return result;
	}
	_tmp3_ = tuba_accounts;
	_tmp4_ = tuba_account_store_get_active (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = _tmp5_->priv->_access_token;
	_tmp7_ = self->priv->_access_token;
	result = g_strcmp0 (_tmp6_, _tmp7_) == 0;
	return result;
}

gint
tuba_instance_account_get_unreviewed_follow_requests (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_unreviewed_follow_requests;
	return result;
}

void
tuba_instance_account_set_unreviewed_follow_requests (TubaInstanceAccount* self,
                                                      gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unreviewed_follow_requests (self);
	if (old_value != value) {
		self->priv->_unreviewed_follow_requests = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY]);
	}
}

gint
tuba_instance_account_get_unread_announcements (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_unread_announcements;
	return result;
}

void
tuba_instance_account_set_unread_announcements (TubaInstanceAccount* self,
                                                gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unread_announcements (self);
	if (old_value != value) {
		self->priv->_unread_announcements = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY]);
	}
}

gint
tuba_instance_account_get_filtered_notifications_count (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_filtered_notifications_count;
	return result;
}

void
tuba_instance_account_set_filtered_notifications_count (TubaInstanceAccount* self,
                                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_filtered_notifications_count (self);
	if (old_value != value) {
		self->priv->_filtered_notifications_count = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY]);
	}
}

gint
tuba_instance_account_get_unread_count (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_unread_count;
	return result;
}

void
tuba_instance_account_set_unread_count (TubaInstanceAccount* self,
                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_unread_count (self);
	if (old_value != value) {
		self->priv->_unread_count = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY]);
	}
}

gint
tuba_instance_account_get_last_read_id (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_last_read_id;
	return result;
}

void
tuba_instance_account_set_last_read_id (TubaInstanceAccount* self,
                                        gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_last_read_id (self);
	if (old_value != value) {
		self->priv->_last_read_id = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY]);
	}
}

gint
tuba_instance_account_get_last_received_id (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_last_received_id;
	return result;
}

void
tuba_instance_account_set_last_received_id (TubaInstanceAccount* self,
                                            gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_last_received_id (self);
	if (old_value != value) {
		self->priv->_last_received_id = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY]);
	}
}

gint
tuba_instance_account_get_tuba_last_fediwrapped_year (TubaInstanceAccount* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	result = self->priv->_tuba_last_fediwrapped_year;
	return result;
}

void
tuba_instance_account_set_tuba_last_fediwrapped_year (TubaInstanceAccount* self,
                                                      gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_get_tuba_last_fediwrapped_year (self);
	if (old_value != value) {
		self->priv->_tuba_last_fediwrapped_year = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY]);
	}
}

static const gchar*
tuba_instance_account_real_get_t_connection_url (TubaStreamable* base)
{
	const gchar* result;
	TubaInstanceAccount* self;
	const gchar* _tmp0_;
	self = (TubaInstanceAccount*) base;
	_tmp0_ = self->priv->_t_connection_url;
	result = _tmp0_;
	return result;
}

static void
tuba_instance_account_real_set_t_connection_url (TubaStreamable* base,
                                                 const gchar* value)
{
	TubaInstanceAccount* self;
	gchar* old_value;
	self = (TubaInstanceAccount*) base;
	old_value = tuba_instance_account_real_get_t_connection_url (base);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_t_connection_url);
		self->priv->_t_connection_url = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY]);
	}
}

static gboolean
tuba_instance_account_real_get_subscribed (TubaStreamable* base)
{
	gboolean result;
	TubaInstanceAccount* self;
	self = (TubaInstanceAccount*) base;
	result = self->priv->_subscribed;
	return result;
}

static void
tuba_instance_account_real_set_subscribed (TubaStreamable* base,
                                           gboolean value)
{
	TubaInstanceAccount* self;
	gboolean old_value;
	self = (TubaInstanceAccount*) base;
	old_value = tuba_instance_account_real_get_subscribed (base);
	if (old_value != value) {
		self->priv->_subscribed = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY]);
	}
}

static void
tuba_instance_account_real_activated (TubaInstanceAccount* self)
{
	GSettings* _tmp0_;
	tuba_instance_account_bump_sidebar_items (self);
	tuba_instance_account_gather_instance_info (self);
	tuba_instance_account_gather_instance_custom_emojis (self);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_lists_gsource_func, g_object_ref (self), g_object_unref);
	g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _tuba_instance_account_gather_fav_tags_gsource_func, g_object_ref (self), g_object_unref);
	tuba_instance_account_check_announcements (self);
	_tmp0_ = self->priv->_account_settings;
	if (_tmp0_ != NULL) {
		_g_object_unref0 (self->priv->_account_settings);
		self->priv->_account_settings = NULL;
	}
}

static void
tuba_instance_account_real_deactivated (TubaInstanceAccount* self)
{
}

static void
tuba_instance_account_real_added (TubaInstanceAccount* self)
{
	tuba_streamable_set_subscribed ((TubaStreamable*) self, TRUE);
	tuba_instance_account_check_notifications (self);
}

static void
tuba_instance_account_real_removed (TubaInstanceAccount* self)
{
	tuba_streamable_set_subscribed ((TubaStreamable*) self, FALSE);
}

static inline gpointer
tuba_instance_account_visibility_get_instance_private (TubaInstanceAccountVisibility* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccountVisibility_private_offset);
}

TubaInstanceAccountVisibility*
tuba_instance_account_visibility_construct (GType object_type)
{
	TubaInstanceAccountVisibility * self = NULL;
	self = (TubaInstanceAccountVisibility*) g_object_new (object_type, NULL);
	return self;
}

TubaInstanceAccountVisibility*
tuba_instance_account_visibility_new (void)
{
	return tuba_instance_account_visibility_construct (TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY);
}

const gchar*
tuba_instance_account_visibility_get_id (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_id;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_id (TubaInstanceAccountVisibility* self,
                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_id (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_id);
		self->priv->_id = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_name (TubaInstanceAccountVisibility* self,
                                           const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_name);
		self->priv->_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_icon_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_icon_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_icon_name (TubaInstanceAccountVisibility* self,
                                                const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_icon_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_icon_name);
		self->priv->_icon_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_description (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_description;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_description (TubaInstanceAccountVisibility* self,
                                                  const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_visibility_get_description (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_description);
		self->priv->_description = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_visibility_get_small_icon_name (TubaInstanceAccountVisibility* self)
{
	const gchar* result;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp1_ = self->priv->_small_icon_name;
	_tmp0_ = _tmp1_;
	if (_tmp0_ == NULL) {
		const gchar* _tmp2_;
		_tmp2_ = self->priv->_icon_name;
		_tmp0_ = _tmp2_;
	}
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_visibility_set_small_icon_name (TubaInstanceAccountVisibility* self,
                                                      const gchar* value)
{
	gchar* _tmp0_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_strdup (value);
	_g_free0 (self->priv->_small_icon_name);
	self->priv->_small_icon_name = _tmp0_;
	g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY]);
}

static void
tuba_instance_account_visibility_class_init (TubaInstanceAccountVisibilityClass * klass,
                                             gpointer klass_data)
{
	tuba_instance_account_visibility_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccountVisibility_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_visibility_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_visibility_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_visibility_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY] = g_param_spec_string ("id", "id", "id", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY] = g_param_spec_string ("name", "name", "name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY] = g_param_spec_string ("icon-name", "icon-name", "icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY] = g_param_spec_string ("description", "description", "description", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY, tuba_instance_account_visibility_properties[TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY] = g_param_spec_string ("small-icon-name", "small-icon-name", "small-icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
tuba_instance_account_visibility_instance_init (TubaInstanceAccountVisibility * self,
                                                gpointer klass)
{
	self->priv = tuba_instance_account_visibility_get_instance_private (self);
	self->priv->_small_icon_name = NULL;
}

static void
tuba_instance_account_visibility_finalize (GObject * obj)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	_g_free0 (self->priv->_id);
	_g_free0 (self->priv->_name);
	_g_free0 (self->priv->_icon_name);
	_g_free0 (self->priv->_description);
	_g_free0 (self->priv->_small_icon_name);
	G_OBJECT_CLASS (tuba_instance_account_visibility_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_visibility_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountVisibilityClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_visibility_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccountVisibility), 0, (GInstanceInitFunc) tuba_instance_account_visibility_instance_init, NULL };
	GType tuba_instance_account_visibility_type_id;
	tuba_instance_account_visibility_type_id = g_type_register_static (G_TYPE_OBJECT, "TubaInstanceAccountVisibility", &g_define_type_info, 0);
	TubaInstanceAccountVisibility_private_offset = g_type_add_instance_private (tuba_instance_account_visibility_type_id, sizeof (TubaInstanceAccountVisibilityPrivate));
	return tuba_instance_account_visibility_type_id;
}

GType
tuba_instance_account_visibility_get_type (void)
{
	static gsize tuba_instance_account_visibility_type_id__once = 0;
	if (g_once_init_enter (&tuba_instance_account_visibility_type_id__once)) {
		GType tuba_instance_account_visibility_type_id;
		tuba_instance_account_visibility_type_id = tuba_instance_account_visibility_get_type_once ();
		g_once_init_leave (&tuba_instance_account_visibility_type_id__once, tuba_instance_account_visibility_type_id);
	}
	return tuba_instance_account_visibility_type_id__once;
}

static void
_vala_tuba_instance_account_visibility_get_property (GObject * object,
                                                     guint property_id,
                                                     GValue * value,
                                                     GParamSpec * pspec)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_icon_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_description (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_visibility_get_small_icon_name (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_visibility_set_property (GObject * object,
                                                     guint property_id,
                                                     const GValue * value,
                                                     GParamSpec * pspec)
{
	TubaInstanceAccountVisibility * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, TubaInstanceAccountVisibility);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ID_PROPERTY:
		tuba_instance_account_visibility_set_id (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_NAME_PROPERTY:
		tuba_instance_account_visibility_set_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_ICON_NAME_PROPERTY:
		tuba_instance_account_visibility_set_icon_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_DESCRIPTION_PROPERTY:
		tuba_instance_account_visibility_set_description (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_VISIBILITY_SMALL_ICON_NAME_PROPERTY:
		tuba_instance_account_visibility_set_small_icon_name (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static inline gpointer
tuba_instance_account_status_content_type_get_instance_private (TubaInstanceAccountStatusContentType* self)
{
	return G_STRUCT_MEMBER_P (self, TubaInstanceAccountStatusContentType_private_offset);
}

static gboolean
_tuba_instance_account_status_content_type_compare_lambda84_ (const gchar* a,
                                                              const gchar* b)
{
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gboolean result;
	g_return_val_if_fail (a != NULL, FALSE);
	g_return_val_if_fail (b != NULL, FALSE);
	_tmp0_ = G_TYPE_CHECK_INSTANCE_CAST (a, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType)->priv->_mime;
	_tmp1_ = G_TYPE_CHECK_INSTANCE_CAST (b, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType)->priv->_mime;
	result = g_strcmp0 (_tmp0_, _tmp1_) == 0;
	return result;
}

static gboolean
__tuba_instance_account_status_content_type_compare_lambda84__gequal_func (gconstpointer a,
                                                                           gconstpointer b)
{
	gboolean result;
	result = _tuba_instance_account_status_content_type_compare_lambda84_ ((const gchar*) a, (const gchar*) b);
	return result;
}

static gint
string_index_of_char (const gchar* self,
                      gunichar c,
                      gint start_index)
{
	gchar* _result_ = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	gint result;
	g_return_val_if_fail (self != NULL, 0);
	_tmp0_ = g_utf8_strchr (((gchar*) self) + start_index, (gssize) -1, c);
	_result_ = _tmp0_;
	_tmp1_ = _result_;
	if (_tmp1_ != NULL) {
		gchar* _tmp2_;
		_tmp2_ = _result_;
		result = (gint) (_tmp2_ - ((gchar*) self));
		return result;
	} else {
		result = -1;
		return result;
	}
}

static gchar*
string_slice (const gchar* self,
              glong start,
              glong end)
{
	glong string_length = 0L;
	gint _tmp0_;
	gint _tmp1_;
	gboolean _tmp2_ = FALSE;
	gboolean _tmp3_ = FALSE;
	gchar* _tmp4_;
	gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = strlen (self);
	_tmp1_ = _tmp0_;
	string_length = (glong) _tmp1_;
	if (start < ((glong) 0)) {
		start = string_length + start;
	}
	if (end < ((glong) 0)) {
		end = string_length + end;
	}
	if (start >= ((glong) 0)) {
		_tmp2_ = start <= string_length;
	} else {
		_tmp2_ = FALSE;
	}
	g_return_val_if_fail (_tmp2_, NULL);
	if (end >= ((glong) 0)) {
		_tmp3_ = end <= string_length;
	} else {
		_tmp3_ = FALSE;
	}
	g_return_val_if_fail (_tmp3_, NULL);
	g_return_val_if_fail (start <= end, NULL);
	_tmp4_ = g_strndup (((gchar*) self) + start, (gsize) (end - start));
	result = _tmp4_;
	return result;
}

TubaInstanceAccountStatusContentType*
tuba_instance_account_status_content_type_construct (GType object_type,
                                                     const gchar* content_type)
{
	TubaInstanceAccountStatusContentType * self = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	GQuark _tmp3_ = 0U;
	static GQuark _tmp2_label0 = 0;
	static GQuark _tmp2_label1 = 0;
	static GQuark _tmp2_label2 = 0;
	static GQuark _tmp2_label3 = 0;
	static GQuark _tmp2_label4 = 0;
	g_return_val_if_fail (content_type != NULL, NULL);
	self = (TubaInstanceAccountStatusContentType*) g_object_new (object_type, NULL);
	tuba_instance_account_status_content_type_set_mime (self, content_type);
	_tmp0_ = g_utf8_strdown (content_type, (gssize) -1);
	_tmp1_ = _tmp0_;
	_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
	g_free (_tmp1_);
	if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("text/plain")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-paper-symbolic");
				tuba_instance_account_status_content_type_set_title (self, _ ("Plain Text"));
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("text/html")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-code-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "HTML");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-html");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("text/markdown")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-markdown-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "Markdown");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-markdown");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("text/bbcode")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "BBCode");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("text/x.misskeymarkdown")))) {
		switch (0) {
			default:
			{
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_title (self, "MFM");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				break;
			}
		}
	} else {
		switch (0) {
			default:
			{
				gint slash = 0;
				gint ct_l = 0;
				gint _tmp4_;
				gint _tmp5_;
				gboolean _tmp6_ = FALSE;
				tuba_instance_account_status_content_type_set_icon_name (self, "tuba-rich-text-symbolic");
				tuba_instance_account_status_content_type_set_syntax (self, "fedi-basic");
				slash = string_index_of_char (content_type, (gunichar) '/', 0);
				_tmp4_ = strlen (content_type);
				_tmp5_ = _tmp4_;
				ct_l = _tmp5_;
				if (slash == -1) {
					_tmp6_ = TRUE;
				} else {
					_tmp6_ = slash == ct_l;
				}
				if (_tmp6_) {
					gchar* _tmp7_;
					gchar* _tmp8_;
					_tmp7_ = g_utf8_strup (content_type, (gssize) -1);
					_tmp8_ = _tmp7_;
					tuba_instance_account_status_content_type_set_title (self, _tmp8_);
					_g_free0 (_tmp8_);
				} else {
					gchar* _tmp9_;
					gchar* _tmp10_;
					gchar* _tmp11_;
					gchar* _tmp12_;
					_tmp9_ = string_slice (content_type, (glong) (slash + 1), (glong) ct_l);
					_tmp10_ = _tmp9_;
					_tmp11_ = g_utf8_strup (_tmp10_, (gssize) -1);
					_tmp12_ = _tmp11_;
					tuba_instance_account_status_content_type_set_title (self, _tmp12_);
					_g_free0 (_tmp12_);
					_g_free0 (_tmp10_);
				}
				break;
			}
		}
	}
	return self;
}

TubaInstanceAccountStatusContentType*
tuba_instance_account_status_content_type_new (const gchar* content_type)
{
	return tuba_instance_account_status_content_type_construct (TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, content_type);
}

const gchar*
tuba_instance_account_status_content_type_get_mime (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_mime;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_mime (TubaInstanceAccountStatusContentType* self,
                                                    const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_mime (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_mime);
		self->priv->_mime = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_icon_name (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_icon_name;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_icon_name (TubaInstanceAccountStatusContentType* self,
                                                         const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_icon_name (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_icon_name);
		self->priv->_icon_name = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_title (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_title;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_title (TubaInstanceAccountStatusContentType* self,
                                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_title (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_title);
		self->priv->_title = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY]);
	}
}

const gchar*
tuba_instance_account_status_content_type_get_syntax (TubaInstanceAccountStatusContentType* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_syntax;
	result = _tmp0_;
	return result;
}

void
tuba_instance_account_status_content_type_set_syntax (TubaInstanceAccountStatusContentType* self,
                                                      const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_instance_account_status_content_type_get_syntax (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_syntax);
		self->priv->_syntax = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY]);
	}
}

static void
tuba_instance_account_status_content_type_class_init (TubaInstanceAccountStatusContentTypeClass * klass,
                                                      gpointer klass_data)
{
	tuba_instance_account_status_content_type_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccountStatusContentType_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_status_content_type_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_status_content_type_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_status_content_type_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY] = g_param_spec_string ("mime", "mime", "mime", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY] = g_param_spec_string ("icon-name", "icon-name", "icon-name", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY] = g_param_spec_string ("title", "title", "title", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY, tuba_instance_account_status_content_type_properties[TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY] = g_param_spec_string ("syntax", "syntax", "syntax", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	tuba_instance_account_status_content_type_compare = __tuba_instance_account_status_content_type_compare_lambda84__gequal_func;
}

static void
tuba_instance_account_status_content_type_instance_init (TubaInstanceAccountStatusContentType * self,
                                                         gpointer klass)
{
	self->priv = tuba_instance_account_status_content_type_get_instance_private (self);
}

static void
tuba_instance_account_status_content_type_finalize (GObject * obj)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	_g_free0 (self->priv->_mime);
	_g_free0 (self->priv->_icon_name);
	_g_free0 (self->priv->_title);
	_g_free0 (self->priv->_syntax);
	G_OBJECT_CLASS (tuba_instance_account_status_content_type_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_status_content_type_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountStatusContentTypeClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_status_content_type_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccountStatusContentType), 0, (GInstanceInitFunc) tuba_instance_account_status_content_type_instance_init, NULL };
	GType tuba_instance_account_status_content_type_type_id;
	tuba_instance_account_status_content_type_type_id = g_type_register_static (G_TYPE_OBJECT, "TubaInstanceAccountStatusContentType", &g_define_type_info, 0);
	TubaInstanceAccountStatusContentType_private_offset = g_type_add_instance_private (tuba_instance_account_status_content_type_type_id, sizeof (TubaInstanceAccountStatusContentTypePrivate));
	return tuba_instance_account_status_content_type_type_id;
}

GType
tuba_instance_account_status_content_type_get_type (void)
{
	static gsize tuba_instance_account_status_content_type_type_id__once = 0;
	if (g_once_init_enter (&tuba_instance_account_status_content_type_type_id__once)) {
		GType tuba_instance_account_status_content_type_type_id;
		tuba_instance_account_status_content_type_type_id = tuba_instance_account_status_content_type_get_type_once ();
		g_once_init_leave (&tuba_instance_account_status_content_type_type_id__once, tuba_instance_account_status_content_type_type_id);
	}
	return tuba_instance_account_status_content_type_type_id__once;
}

static void
_vala_tuba_instance_account_status_content_type_get_property (GObject * object,
                                                              guint property_id,
                                                              GValue * value,
                                                              GParamSpec * pspec)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_mime (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_icon_name (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_title (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY:
		g_value_set_string (value, tuba_instance_account_status_content_type_get_syntax (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_status_content_type_set_property (GObject * object,
                                                              guint property_id,
                                                              const GValue * value,
                                                              GParamSpec * pspec)
{
	TubaInstanceAccountStatusContentType * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE, TubaInstanceAccountStatusContentType);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_MIME_PROPERTY:
		tuba_instance_account_status_content_type_set_mime (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_ICON_NAME_PROPERTY:
		tuba_instance_account_status_content_type_set_icon_name (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_TITLE_PROPERTY:
		tuba_instance_account_status_content_type_set_title (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_STATUS_CONTENT_TYPE_SYNTAX_PROPERTY:
		tuba_instance_account_status_content_type_set_syntax (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

void
tuba_instance_account_kind_copy (const TubaInstanceAccountKind* self,
                                 TubaInstanceAccountKind* dest)
{
	const gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
	_tmp0_ = (*self).icon;
	_tmp1_ = g_strdup (_tmp0_);
	_g_free0 ((*dest).icon);
	(*dest).icon = _tmp1_;
	_tmp2_ = (*self).description;
	_tmp3_ = g_strdup (_tmp2_);
	_g_free0 ((*dest).description);
	(*dest).description = _tmp3_;
	_tmp4_ = (*self).url;
	_tmp5_ = g_strdup (_tmp4_);
	_g_free0 ((*dest).url);
	(*dest).url = _tmp5_;
}

void
tuba_instance_account_kind_destroy (TubaInstanceAccountKind* self)
{
	_g_free0 ((*self).icon);
	_g_free0 ((*self).description);
	_g_free0 ((*self).url);
}

TubaInstanceAccountKind*
tuba_instance_account_kind_dup (const TubaInstanceAccountKind* self)
{
	TubaInstanceAccountKind* dup;
	dup = g_new0 (TubaInstanceAccountKind, 1);
	tuba_instance_account_kind_copy (self, dup);
	return dup;
}

void
tuba_instance_account_kind_free (TubaInstanceAccountKind* self)
{
	tuba_instance_account_kind_destroy (self);
	g_free (self);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_kind_get_type_once (void)
{
	GType tuba_instance_account_kind_type_id;
	tuba_instance_account_kind_type_id = g_boxed_type_register_static ("TubaInstanceAccountKind", (GBoxedCopyFunc) tuba_instance_account_kind_dup, (GBoxedFreeFunc) tuba_instance_account_kind_free);
	return tuba_instance_account_kind_type_id;
}

GType
tuba_instance_account_kind_get_type (void)
{
	static gsize tuba_instance_account_kind_type_id__once = 0;
	if (g_once_init_enter (&tuba_instance_account_kind_type_id__once)) {
		GType tuba_instance_account_kind_type_id;
		tuba_instance_account_kind_type_id = tuba_instance_account_kind_get_type_once ();
		g_once_init_leave (&tuba_instance_account_kind_type_id__once, tuba_instance_account_kind_type_id);
	}
	return tuba_instance_account_kind_type_id__once;
}

static void
_tuba_instance_account_on_notification_event_tuba_streamable_stream_event (TubaStreamable* _sender,
                                                                           TubaStreamableEvent* ev,
                                                                           gpointer self)
{
	tuba_instance_account_on_notification_event ((TubaInstanceAccount*) self, ev);
}

static void
_tuba_instance_account_on_network_change_g_object_notify (GObject* _sender,
                                                          GParamSpec* pspec,
                                                          gpointer self)
{
	tuba_instance_account_on_network_change ((TubaInstanceAccount*) self);
}

static GObject *
tuba_instance_account_constructor (GType type,
                                   guint n_construct_properties,
                                   GObjectConstructParam * construct_properties)
{
	GObject * obj;
	GObjectClass * parent_class;
	TubaInstanceAccount * self;
	gchar* _tmp0_;
	GListStore* _tmp1_;
	GListStore* _tmp2_;
	GListStore* _tmp3_;
	TubaApplication* _tmp4_;
	parent_class = G_OBJECT_CLASS (tuba_instance_account_parent_class);
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	tuba_streamable_construct_streamable ((TubaStreamable*) self);
	_tmp0_ = g_strconcat ("stream-event::", TUBA_INSTANCE_ACCOUNT_EVENT_NOTIFICATION, NULL);
	g_signal_connect_object ((TubaStreamable*) self, _tmp0_, (GCallback) _tuba_instance_account_on_notification_event_tuba_streamable_stream_event, self, 0);
	_g_free0 (_tmp0_);
	_tmp1_ = self->known_places;
	tuba_instance_account_register_known_places (self, _tmp1_);
	_tmp2_ = self->list_places;
	tuba_instance_account_register_extra (self, _tmp2_, NULL, (gint) 0);
	_tmp3_ = self->tags_places;
	tuba_instance_account_register_extra (self, _tmp3_, NULL, (gint) 0);
	_tmp4_ = tuba_app;
	g_signal_connect_object ((GObject*) _tmp4_, "notify::is-online", (GCallback) _tuba_instance_account_on_network_change_g_object_notify, self, 0);
	return obj;
}

static void
tuba_instance_account_class_init (TubaInstanceAccountClass * klass,
                                  gpointer klass_data)
{
	tuba_instance_account_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaInstanceAccount_private_offset);
	((TubaInstanceAccountClass *) klass)->describe_kind = (void (*) (TubaInstanceAccount*, const gchar*, TubaInstanceAccountKind*, const gchar*, const gchar*, const gchar*)) tuba_instance_account_real_describe_kind;
	((TubaInstanceAccountClass *) klass)->register_known_places = (void (*) (TubaInstanceAccount*, GListStore*)) tuba_instance_account_real_register_known_places;
	((TubaInstanceAccountClass *) klass)->register_extra = (void (*) (TubaInstanceAccount*, GListStore*, TubaPlace**, gint)) tuba_instance_account_real_register_extra;
	((TubaInstanceAccountClass *) klass)->bump_sidebar_items = (void (*) (TubaInstanceAccount*)) tuba_instance_account_real_bump_sidebar_items;
	((TubaInstanceAccountClass *) klass)->check_notifications = (void (*) (TubaInstanceAccount*)) tuba_instance_account_real_check_notifications;
	((TubaInstanceAccountClass *) klass)->get_stream_url = (gchar* (*) (TubaInstanceAccount*)) tuba_instance_account_real_get_stream_url;
	((TubaInstanceAccountClass *) klass)->on_notification_event = (void (*) (TubaInstanceAccount*, TubaStreamableEvent*)) tuba_instance_account_real_on_notification_event;
	((TubaInstanceAccountClass *) klass)->open_status_url = (void (*) (TubaInstanceAccount*, const gchar*)) tuba_instance_account_real_open_status_url;
	((TubaInstanceAccountClass *) klass)->answer_follow_request = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*, gboolean)) tuba_instance_account_real_answer_follow_request;
	((TubaInstanceAccountClass *) klass)->follow_back = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_follow_back;
	((TubaInstanceAccountClass *) klass)->reply_to_status_uri = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_reply_to_status_uri;
	((TubaInstanceAccountClass *) klass)->remove_from_followers = (void (*) (TubaInstanceAccount*, const gchar*, const gchar*)) tuba_instance_account_real_remove_from_followers;
	((TubaInstanceAccountClass *) klass)->activated = tuba_instance_account_real_activated;
	((TubaInstanceAccountClass *) klass)->deactivated = tuba_instance_account_real_deactivated;
	((TubaInstanceAccountClass *) klass)->added = tuba_instance_account_real_added;
	((TubaInstanceAccountClass *) klass)->removed = tuba_instance_account_real_removed;
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_instance_account_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_instance_account_set_property;
	G_OBJECT_CLASS (klass)->constructor = tuba_instance_account_constructor;
	G_OBJECT_CLASS (klass)->finalize = tuba_instance_account_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY] = g_param_spec_flags ("tuba-instance-features", "tuba-instance-features", "tuba-instance-features", TUBA_INSTANCE_ACCOUNT_TYPE_INSTANCE_FEATURES, TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY] = g_param_spec_string ("tuba-iceshrimp-api-key", "tuba-iceshrimp-api-key", "tuba-iceshrimp-api-key", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY] = g_param_spec_string ("tuba-streaming-url", "tuba-streaming-url", "tuba-streaming-url", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY] = g_param_spec_string ("uuid", "uuid", "uuid", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY] = g_param_spec_boolean ("admin-mode", "admin-mode", "admin-mode", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY] = g_param_spec_string ("backend", "backend", "backend", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY] = g_param_spec_object ("instance-info", "instance-info", "instance-info", TUBA_API_TYPE_INSTANCE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY] = g_param_spec_object ("instance-emojis", "instance-emojis", "instance-emojis", GEE_TYPE_ARRAY_LIST, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY] = g_param_spec_string ("instance", "instance", "instance", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY] = g_param_spec_string ("client-id", "client-id", "client-id", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY] = g_param_spec_string ("client-secret", "client-secret", "client-secret", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY] = g_param_spec_string ("access-token", "access-token", "access-token", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY] = g_param_spec_boolean ("needs-update", "needs-update", "needs-update", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY] = g_param_spec_boxed ("error", "error", "error", G_TYPE_ERROR, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY] = g_param_spec_boolean ("tuba-probably-has-notification-filters", "tuba-probably-has-notification-filters", "tuba-probably-has-notification-filters", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY] = g_param_spec_object ("tuba-api-versions", "tuba-api-versions", "tuba-api-versions", TUBA_API_INSTANCE_V2_TYPE_API_VERSIONS, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY] = g_param_spec_string ("handle-short", "handle-short", "handle-short", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY] = g_param_spec_string ("handle", "handle", "handle", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY] = g_param_spec_boolean ("is-active", "is-active", "is-active", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY] = g_param_spec_int ("unreviewed-follow-requests", "unreviewed-follow-requests", "unreviewed-follow-requests", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY] = g_param_spec_int ("unread-announcements", "unread-announcements", "unread-announcements", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY] = g_param_spec_int ("filtered-notifications-count", "filtered-notifications-count", "filtered-notifications-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY] = g_param_spec_int ("unread-count", "unread-count", "unread-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY] = g_param_spec_int ("last-read-id", "last-read-id", "last-read-id", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY] = g_param_spec_int ("last-received-id", "last-received-id", "last-received-id", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY] = g_param_spec_int ("tuba-last-fediwrapped-year", "tuba-last-fediwrapped-year", "tuba-last-fediwrapped-year", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY] = g_param_spec_string ("t-connection-url", "t-connection-url", "t-connection-url", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY, tuba_instance_account_properties[TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY] = g_param_spec_boolean ("subscribed", "subscribed", "subscribed", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_ACTIVATED_SIGNAL] = g_signal_new ("activated", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, activated), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_DEACTIVATED_SIGNAL] = g_signal_new ("deactivated", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, deactivated), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_ADDED_SIGNAL] = g_signal_new ("added", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, added), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
	tuba_instance_account_signals[TUBA_INSTANCE_ACCOUNT_REMOVED_SIGNAL] = g_signal_new ("removed", TUBA_TYPE_INSTANCE_ACCOUNT, G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (TubaInstanceAccountClass, removed), NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
}

static void
tuba_instance_account_tuba_streamable_interface_init (TubaStreamableIface * iface,
                                                      gpointer iface_data)
{
	tuba_instance_account_tuba_streamable_parent_iface = g_type_interface_peek_parent (iface);
	iface->get_stream_url = (gchar* (*) (TubaStreamable*)) tuba_instance_account_get_stream_url;
	iface->get_t_connection_url = tuba_instance_account_real_get_t_connection_url;
	iface->set_t_connection_url = tuba_instance_account_real_set_t_connection_url;
	iface->get_subscribed = tuba_instance_account_real_get_subscribed;
	iface->set_subscribed = tuba_instance_account_real_set_subscribed;
}

static void
tuba_instance_account_instance_init (TubaInstanceAccount * self,
                                     gpointer klass)
{
	TubaAPIInstanceV2APIVersions* _tmp0_;
	GListStore* _tmp1_;
	GListStore* _tmp2_;
	GListStore* _tmp3_;
	GeeHashMap* _tmp4_;
	GeeHashMap* _tmp5_;
	GListStore* _tmp6_;
	GListStore* _tmp7_;
	GeeHashMap* _tmp8_;
	self->priv = tuba_instance_account_get_instance_private (self);
	self->priv->_tuba_instance_features = TUBA_INSTANCE_ACCOUNT_INSTANCE_FEATURES_NONE;
	self->priv->_tuba_iceshrimp_api_key = NULL;
	self->priv->_tuba_streaming_url = NULL;
	self->priv->_admin_mode = FALSE;
	self->priv->_needs_update = FALSE;
	self->priv->_tuba_probably_has_notification_filters = FALSE;
	_tmp0_ = tuba_api_instance_v2_api_versions_new ();
	self->priv->_tuba_api_versions = _tmp0_;
	_tmp1_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->known_places = _tmp1_;
	_tmp2_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->list_places = _tmp2_;
	_tmp3_ = g_list_store_new (TUBA_TYPE_PLACE);
	self->tags_places = _tmp3_;
	_tmp4_ = gee_hash_map_new (G_TYPE_GTYPE, NULL, NULL, G_TYPE_GTYPE, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->type_overrides = _tmp4_;
	_tmp5_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->visibility = _tmp5_;
	_tmp6_ = g_list_store_new (TUBA_INSTANCE_ACCOUNT_TYPE_VISIBILITY);
	self->visibility_list = _tmp6_;
	self->priv->_unreviewed_follow_requests = 0;
	self->priv->_unread_announcements = 0;
	self->priv->_filtered_notifications_count = 0;
	self->priv->_unread_count = 0;
	self->priv->_last_read_id = 0;
	self->priv->_last_received_id = 0;
	_tmp7_ = g_list_store_new (TUBA_INSTANCE_ACCOUNT_TYPE_STATUS_CONTENT_TYPE);
	self->supported_mime_types = _tmp7_;
	self->priv->_tuba_last_fediwrapped_year = 0;
	_tmp8_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, G_TYPE_INT, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->priv->sent_notifications = _tmp8_;
	self->priv->_account_settings = NULL;
}

static void
tuba_instance_account_finalize (GObject * obj)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	tuba_streamable_destruct_streamable ((TubaStreamable*) self);
	_g_free0 (self->priv->_tuba_iceshrimp_api_key);
	_g_free0 (self->priv->_tuba_streaming_url);
	_g_free0 (self->priv->_uuid);
	_g_free0 (self->priv->_backend);
	_g_object_unref0 (self->priv->_instance_info);
	_g_object_unref0 (self->priv->_instance_emojis);
	_g_free0 (self->priv->_instance);
	_g_free0 (self->priv->_client_id);
	_g_free0 (self->priv->_client_secret);
	_g_free0 (self->priv->_access_token);
	_g_error_free0 (self->priv->_error);
	_g_object_unref0 (self->priv->_tuba_api_versions);
	_g_object_unref0 (self->known_places);
	_g_object_unref0 (self->list_places);
	_g_object_unref0 (self->tags_places);
	_g_object_unref0 (self->type_overrides);
	_g_object_unref0 (self->visibility);
	_g_object_unref0 (self->visibility_list);
	_g_object_unref0 (self->supported_mime_types);
	_g_object_unref0 (self->priv->annual_report);
	_g_object_unref0 (self->priv->sent_notifications);
	_g_free0 (self->priv->_t_connection_url);
	_g_object_unref0 (self->priv->_account_settings);
	G_OBJECT_CLASS (tuba_instance_account_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_instance_account_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaInstanceAccountClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_instance_account_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaInstanceAccount), 0, (GInstanceInitFunc) tuba_instance_account_instance_init, NULL };
	static const GInterfaceInfo tuba_streamable_info = { (GInterfaceInitFunc) tuba_instance_account_tuba_streamable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
	GType tuba_instance_account_type_id;
	tuba_instance_account_type_id = g_type_register_static (TUBA_API_TYPE_ACCOUNT, "TubaInstanceAccount", &g_define_type_info, 0);
	g_type_add_interface_static (tuba_instance_account_type_id, TUBA_TYPE_STREAMABLE, &tuba_streamable_info);
	TubaInstanceAccount_private_offset = g_type_add_instance_private (tuba_instance_account_type_id, sizeof (TubaInstanceAccountPrivate));
	return tuba_instance_account_type_id;
}

GType
tuba_instance_account_get_type (void)
{
	static gsize tuba_instance_account_type_id__once = 0;
	if (g_once_init_enter (&tuba_instance_account_type_id__once)) {
		GType tuba_instance_account_type_id;
		tuba_instance_account_type_id = tuba_instance_account_get_type_once ();
		g_once_init_leave (&tuba_instance_account_type_id__once, tuba_instance_account_type_id);
	}
	return tuba_instance_account_type_id__once;
}

static void
_vala_tuba_instance_account_get_property (GObject * object,
                                          guint property_id,
                                          GValue * value,
                                          GParamSpec * pspec)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY:
		g_value_set_flags (value, tuba_instance_account_get_tuba_instance_features (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_tuba_iceshrimp_api_key (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_tuba_streaming_url (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_uuid (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_admin_mode (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_backend (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_instance_info (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_instance_emojis (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_instance (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_client_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_client_secret (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY:
		g_value_set_string (value, tuba_instance_account_get_access_token (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_needs_update (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY:
		g_value_set_boxed (value, tuba_instance_account_get_error (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_tuba_probably_has_notification_filters (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY:
		g_value_set_object (value, tuba_instance_account_get_tuba_api_versions (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_HANDLE_SHORT_PROPERTY:
		g_value_take_string (value, tuba_instance_account_get_handle_short (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_HANDLE_PROPERTY:
		g_value_take_string (value, tuba_instance_account_get_handle (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_IS_ACTIVE_PROPERTY:
		g_value_set_boolean (value, tuba_instance_account_get_is_active (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unreviewed_follow_requests (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unread_announcements (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_filtered_notifications_count (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_unread_count (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_last_read_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_last_received_id (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY:
		g_value_set_int (value, tuba_instance_account_get_tuba_last_fediwrapped_year (self));
		break;
		case TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY:
		g_value_set_string (value, tuba_streamable_get_t_connection_url ((TubaStreamable*) self));
		break;
		case TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY:
		g_value_set_boolean (value, tuba_streamable_get_subscribed ((TubaStreamable*) self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_instance_account_set_property (GObject * object,
                                          guint property_id,
                                          const GValue * value,
                                          GParamSpec * pspec)
{
	TubaInstanceAccount * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount);
	switch (property_id) {
		case TUBA_INSTANCE_ACCOUNT_TUBA_INSTANCE_FEATURES_PROPERTY:
		tuba_instance_account_set_tuba_instance_features (self, g_value_get_flags (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_ICESHRIMP_API_KEY_PROPERTY:
		tuba_instance_account_set_tuba_iceshrimp_api_key (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_STREAMING_URL_PROPERTY:
		tuba_instance_account_set_tuba_streaming_url (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UUID_PROPERTY:
		tuba_instance_account_set_uuid (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_ADMIN_MODE_PROPERTY:
		tuba_instance_account_set_admin_mode (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_BACKEND_PROPERTY:
		tuba_instance_account_set_backend (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_INFO_PROPERTY:
		tuba_instance_account_set_instance_info (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_EMOJIS_PROPERTY:
		tuba_instance_account_set_instance_emojis (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_INSTANCE_PROPERTY:
		tuba_instance_account_set_instance (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_ID_PROPERTY:
		tuba_instance_account_set_client_id (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_CLIENT_SECRET_PROPERTY:
		tuba_instance_account_set_client_secret (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_ACCESS_TOKEN_PROPERTY:
		tuba_instance_account_set_access_token (self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_NEEDS_UPDATE_PROPERTY:
		tuba_instance_account_set_needs_update (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_ERROR_PROPERTY:
		tuba_instance_account_set_error (self, g_value_get_boxed (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_PROBABLY_HAS_NOTIFICATION_FILTERS_PROPERTY:
		tuba_instance_account_set_tuba_probably_has_notification_filters (self, g_value_get_boolean (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_API_VERSIONS_PROPERTY:
		tuba_instance_account_set_tuba_api_versions (self, g_value_get_object (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREVIEWED_FOLLOW_REQUESTS_PROPERTY:
		tuba_instance_account_set_unreviewed_follow_requests (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_ANNOUNCEMENTS_PROPERTY:
		tuba_instance_account_set_unread_announcements (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_FILTERED_NOTIFICATIONS_COUNT_PROPERTY:
		tuba_instance_account_set_filtered_notifications_count (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_UNREAD_COUNT_PROPERTY:
		tuba_instance_account_set_unread_count (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_READ_ID_PROPERTY:
		tuba_instance_account_set_last_read_id (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_LAST_RECEIVED_ID_PROPERTY:
		tuba_instance_account_set_last_received_id (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_TUBA_LAST_FEDIWRAPPED_YEAR_PROPERTY:
		tuba_instance_account_set_tuba_last_fediwrapped_year (self, g_value_get_int (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_T_CONNECTION_URL_PROPERTY:
		tuba_streamable_set_t_connection_url ((TubaStreamable*) self, g_value_get_string (value));
		break;
		case TUBA_INSTANCE_ACCOUNT_SUBSCRIBED_PROPERTY:
		tuba_streamable_set_subscribed ((TubaStreamable*) self, g_value_get_boolean (value));
		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);
}

