Commit 0955f6f8 authored by Patrick Griffis's avatar Patrick Griffis
Browse files

Use G_DECLARE_FINAL_TYPE when applicable

parent 379d1d1b
Pipeline #301225 failed with stages
in 54 seconds
......@@ -32,7 +32,7 @@ typedef struct {
*
*/
G_DEFINE_TYPE_WITH_PRIVATE (SoupAuthBasic, soup_auth_basic, SOUP_TYPE_AUTH)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupAuthBasic, soup_auth_basic, SOUP_TYPE_AUTH)
static void
soup_auth_basic_init (SoupAuthBasic *basic)
......
......@@ -55,7 +55,7 @@ static void recompute_hex_a1 (SoupAuthDigestPrivate *priv);
*
*/
G_DEFINE_TYPE_WITH_PRIVATE (SoupAuthDigest, soup_auth_digest, SOUP_TYPE_AUTH)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupAuthDigest, soup_auth_digest, SOUP_TYPE_AUTH)
static void
soup_auth_digest_init (SoupAuthDigest *digest)
......
......@@ -84,10 +84,10 @@ typedef struct {
GHashTable *auths; /* scheme:realm -> SoupAuth */
} SoupAuthHost;
G_DEFINE_TYPE_WITH_CODE (SoupAuthManager, soup_auth_manager, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupAuthManager)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_auth_manager_session_feature_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupAuthManager, soup_auth_manager, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupAuthManager)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_auth_manager_session_feature_init))
static void soup_auth_host_free (SoupAuthHost *host);
static SoupAuth *record_auth_for_uri (SoupAuthManagerPrivate *priv,
......
......@@ -88,7 +88,7 @@ typedef struct {
* was.
*
*/
G_DEFINE_TYPE_WITH_PRIVATE (SoupAuthNegotiate, soup_auth_negotiate, SOUP_TYPE_CONNECTION_AUTH)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupAuthNegotiate, soup_auth_negotiate, SOUP_TYPE_CONNECTION_AUTH)
#ifdef LIBSOUP_HAVE_GSSAPI
static gboolean check_auth_trusted_uri (SoupConnectionAuth *auth,
......
......@@ -108,7 +108,7 @@ static void sso_ntlm_close (SoupAuthNTLMPrivate *priv);
*
*/
G_DEFINE_TYPE_WITH_PRIVATE (SoupAuthNTLM, soup_auth_ntlm, SOUP_TYPE_CONNECTION_AUTH)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupAuthNTLM, soup_auth_ntlm, SOUP_TYPE_CONNECTION_AUTH)
static void
soup_auth_ntlm_init (SoupAuthNTLM *ntlm)
......
......@@ -19,7 +19,7 @@ typedef struct {
SoupConnection *conn;
} SoupTlsInteractionPrivate;
G_DEFINE_TYPE_WITH_PRIVATE (SoupTlsInteraction, soup_tls_interaction, G_TYPE_TLS_INTERACTION)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupTlsInteraction, soup_tls_interaction, G_TYPE_TLS_INTERACTION)
static void
soup_tls_interaction_request_certificate_async (GTlsInteraction *tls_interaction,
......
......@@ -25,7 +25,7 @@ struct _SoupCacheClientInputStream {
GFilterInputStream parent_instance;
};
G_DEFINE_TYPE (SoupCacheClientInputStream, soup_cache_client_input_stream, G_TYPE_FILTER_INPUT_STREAM)
G_DEFINE_FINAL_TYPE (SoupCacheClientInputStream, soup_cache_client_input_stream, G_TYPE_FILTER_INPUT_STREAM)
static void
soup_cache_client_input_stream_init (SoupCacheClientInputStream *stream)
......
......@@ -35,10 +35,10 @@ typedef struct {
static void soup_cache_input_stream_pollable_init (GPollableInputStreamInterface *pollable_interface, gpointer interface_data);
G_DEFINE_TYPE_WITH_CODE (SoupCacheInputStream, soup_cache_input_stream, SOUP_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupCacheInputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_cache_input_stream_pollable_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupCacheInputStream, soup_cache_input_stream, SOUP_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupCacheInputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_cache_input_stream_pollable_init))
static void soup_cache_input_stream_write_next_buffer (SoupCacheInputStream *istream);
......
......@@ -36,8 +36,8 @@ struct _SoupBrotliDecompressor
static void soup_brotli_decompressor_iface_init (GConverterIface *iface);
G_DEFINE_TYPE_EXTENDED (SoupBrotliDecompressor, soup_brotli_decompressor, G_TYPE_OBJECT, 0,
G_IMPLEMENT_INTERFACE (G_TYPE_CONVERTER, soup_brotli_decompressor_iface_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupBrotliDecompressor, soup_brotli_decompressor, G_TYPE_OBJECT,
G_IMPLEMENT_INTERFACE (G_TYPE_CONVERTER, soup_brotli_decompressor_iface_init))
SoupBrotliDecompressor *
soup_brotli_decompressor_new (void)
......
......@@ -71,12 +71,12 @@ static SoupContentProcessorInterface *soup_content_decoder_default_content_proce
static void soup_content_decoder_content_processor_init (SoupContentProcessorInterface *interface, gpointer interface_data);
G_DEFINE_TYPE_WITH_CODE (SoupContentDecoder, soup_content_decoder, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupContentDecoder)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_content_decoder_session_feature_init)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_CONTENT_PROCESSOR,
soup_content_decoder_content_processor_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupContentDecoder, soup_content_decoder, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupContentDecoder)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_content_decoder_session_feature_init)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_CONTENT_PROCESSOR,
soup_content_decoder_content_processor_init))
static GSList *
soup_content_decoder_get_decoders_for_msg (SoupContentDecoder *decoder, SoupMessage *msg)
......
......@@ -51,10 +51,10 @@ typedef struct {
static void soup_converter_wrapper_iface_init (GConverterIface *iface);
G_DEFINE_TYPE_WITH_CODE (SoupConverterWrapper, soup_converter_wrapper, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupConverterWrapper)
G_IMPLEMENT_INTERFACE (G_TYPE_CONVERTER,
soup_converter_wrapper_iface_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupConverterWrapper, soup_converter_wrapper, G_TYPE_OBJECT,
G_ADD_PRIVATE (SoupConverterWrapper)
G_IMPLEMENT_INTERFACE (G_TYPE_CONVERTER,
soup_converter_wrapper_iface_init))
static void
soup_converter_wrapper_init (SoupConverterWrapper *converter)
......
......@@ -46,10 +46,10 @@ typedef struct {
static void soup_content_sniffer_stream_pollable_init (GPollableInputStreamInterface *pollable_interface, gpointer interface_data);
G_DEFINE_TYPE_WITH_CODE (SoupContentSnifferStream, soup_content_sniffer_stream, G_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupContentSnifferStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_content_sniffer_stream_pollable_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupContentSnifferStream, soup_content_sniffer_stream, G_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupContentSnifferStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_content_sniffer_stream_pollable_init))
static void
soup_content_sniffer_stream_finalize (GObject *object)
......
......@@ -51,11 +51,11 @@ struct _SoupContentSniffer {
GObject parent_instance;
};
G_DEFINE_TYPE_WITH_CODE (SoupContentSniffer, soup_content_sniffer, G_TYPE_OBJECT,
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_content_sniffer_session_feature_init)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_CONTENT_PROCESSOR,
soup_content_sniffer_content_processor_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupContentSniffer, soup_content_sniffer, G_TYPE_OBJECT,
G_IMPLEMENT_INTERFACE (SOUP_TYPE_SESSION_FEATURE,
soup_content_sniffer_session_feature_init)
G_IMPLEMENT_INTERFACE (SOUP_TYPE_CONTENT_PROCESSOR,
soup_content_sniffer_content_processor_init))
static GInputStream *
......
......@@ -56,7 +56,7 @@ typedef struct {
sqlite3 *db;
} SoupCookieJarDBPrivate;
G_DEFINE_TYPE_WITH_PRIVATE (SoupCookieJarDB, soup_cookie_jar_db, SOUP_TYPE_COOKIE_JAR)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupCookieJarDB, soup_cookie_jar_db, SOUP_TYPE_COOKIE_JAR)
static void load (SoupCookieJar *jar);
......
......@@ -51,7 +51,7 @@ typedef struct {
} SoupCookieJarTextPrivate;
G_DEFINE_TYPE_WITH_PRIVATE (SoupCookieJarText, soup_cookie_jar_text, SOUP_TYPE_COOKIE_JAR)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupCookieJarText, soup_cookie_jar_text, SOUP_TYPE_COOKIE_JAR)
static void load (SoupCookieJar *jar);
......
......@@ -51,8 +51,8 @@ typedef struct {
sqlite3 *db;
} SoupHSTSEnforcerDBPrivate;
G_DEFINE_TYPE_WITH_CODE (SoupHSTSEnforcerDB, soup_hsts_enforcer_db, SOUP_TYPE_HSTS_ENFORCER,
G_ADD_PRIVATE(SoupHSTSEnforcerDB))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupHSTSEnforcerDB, soup_hsts_enforcer_db, SOUP_TYPE_HSTS_ENFORCER,
G_ADD_PRIVATE(SoupHSTSEnforcerDB))
static void load (SoupHSTSEnforcer *hsts_enforcer);
......
......@@ -61,12 +61,12 @@ static GParamSpec *properties[LAST_PROPERTY] = { NULL, };
static void soup_body_input_stream_pollable_init (GPollableInputStreamInterface *pollable_interface, gpointer interface_data);
static void soup_body_input_stream_seekable_init (GSeekableIface *seekable_interface);
G_DEFINE_TYPE_WITH_CODE (SoupBodyInputStream, soup_body_input_stream, G_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupBodyInputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_body_input_stream_pollable_init)
G_IMPLEMENT_INTERFACE (G_TYPE_SEEKABLE,
soup_body_input_stream_seekable_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupBodyInputStream, soup_body_input_stream, G_TYPE_FILTER_INPUT_STREAM,
G_ADD_PRIVATE (SoupBodyInputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_body_input_stream_pollable_init)
G_IMPLEMENT_INTERFACE (G_TYPE_SEEKABLE,
soup_body_input_stream_seekable_init))
static void
soup_body_input_stream_init (SoupBodyInputStream *bistream)
......
......@@ -58,10 +58,10 @@ static guint signals[LAST_SIGNAL] = { 0 };
static void soup_body_output_stream_pollable_init (GPollableOutputStreamInterface *pollable_interface, gpointer interface_data);
G_DEFINE_TYPE_WITH_CODE (SoupBodyOutputStream, soup_body_output_stream, G_TYPE_FILTER_OUTPUT_STREAM,
G_ADD_PRIVATE (SoupBodyOutputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_OUTPUT_STREAM,
soup_body_output_stream_pollable_init))
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupBodyOutputStream, soup_body_output_stream, G_TYPE_FILTER_OUTPUT_STREAM,
G_ADD_PRIVATE (SoupBodyOutputStream)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_OUTPUT_STREAM,
soup_body_output_stream_pollable_init))
static void
......
......@@ -52,10 +52,10 @@ typedef struct {
static void soup_body_input_stream_http2_pollable_iface_init (GPollableInputStreamInterface *iface);
G_DEFINE_TYPE_WITH_CODE (SoupBodyInputStreamHttp2, soup_body_input_stream_http2, G_TYPE_INPUT_STREAM,
G_ADD_PRIVATE (SoupBodyInputStreamHttp2)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_body_input_stream_http2_pollable_iface_init);)
G_DEFINE_FINAL_TYPE_WITH_CODE (SoupBodyInputStreamHttp2, soup_body_input_stream_http2, G_TYPE_INPUT_STREAM,
G_ADD_PRIVATE (SoupBodyInputStreamHttp2)
G_IMPLEMENT_INTERFACE (G_TYPE_POLLABLE_INPUT_STREAM,
soup_body_input_stream_http2_pollable_iface_init);)
enum {
NEED_MORE_DATA,
......
......@@ -50,7 +50,7 @@ typedef struct {
GDestroyNotify auth_dnotify;
} SoupAuthDomainBasicPrivate;
G_DEFINE_TYPE_WITH_PRIVATE (SoupAuthDomainBasic, soup_auth_domain_basic, SOUP_TYPE_AUTH_DOMAIN)
G_DEFINE_FINAL_TYPE_WITH_PRIVATE (SoupAuthDomainBasic, soup_auth_domain_basic, SOUP_TYPE_AUTH_DOMAIN)
static void
soup_auth_domain_basic_init (SoupAuthDomainBasic *basic)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment