summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorentin Noël <corentin@elementary.io>2019-01-11 08:31:46 +0100
committerMilan Crha <mcrha@redhat.com>2019-01-11 08:31:46 +0100
commitd9dfdedfcbdf493c04e169a2569aeeca3556708e (patch)
treec4431472939c495ac86eb0c00d7a7ba3336d1724
parent155e1356f37f3cd0478480cdaf52943380b4891f (diff)
downloadevolution-data-server-d9dfdedfcbdf493c04e169a2569aeeca3556708e.tar.gz
I#73 - Add e-dataserver-autocleanups header
Closes https://gitlab.gnome.org/GNOME/evolution-data-server/issues/73
-rw-r--r--src/libedataserver/CMakeLists.txt1
-rw-r--r--src/libedataserver/e-dataserver-autocleanups.h106
-rw-r--r--src/libedataserver/libedataserver.h2
3 files changed, 109 insertions, 0 deletions
diff --git a/src/libedataserver/CMakeLists.txt b/src/libedataserver/CMakeLists.txt
index 4393579c8..17be15469 100644
--- a/src/libedataserver/CMakeLists.txt
+++ b/src/libedataserver/CMakeLists.txt
@@ -141,6 +141,7 @@ set(HEADERS
e-client.h
e-collator.h
e-credentials.h
+ e-dataserver-autocleanups.h
e-extensible.h
e-extension.h
e-flag.h
diff --git a/src/libedataserver/e-dataserver-autocleanups.h b/src/libedataserver/e-dataserver-autocleanups.h
new file mode 100644
index 000000000..a836fe918
--- /dev/null
+++ b/src/libedataserver/e-dataserver-autocleanups.h
@@ -0,0 +1,106 @@
+/*
+ * e-dataserver-autocleanups.h
+ *
+ * This library is free software: you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ * for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+#if !defined (__LIBEDATASERVER_H_INSIDE__) && !defined (LIBEDATASERVER_COMPILATION)
+#error "Only <libedataserver/libedataserver.h> should be included directly."
+#endif
+
+#ifndef __E_DATASERVER_AUTOCLEANUPS_H__
+#define __E_DATASERVER_AUTOCLEANUPS_H__
+
+#ifndef __GI_SCANNER__
+#ifdef G_DEFINE_AUTOPTR_CLEANUP_FUNC
+
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EClient, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ECollator, e_collator_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ECredentials, e_credentials_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EAsyncClosure, e_async_closure_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ENamedParameters, e_named_parameters_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(GWeakRef, e_weak_ref_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EExtensible, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EExtension, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EFlag, e_flag_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EGDataOAuth2Authorizer, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EIterator, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EList, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EListIterator, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EMemChunk, e_memchunk_destroy)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EModule, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ENetworkMonitor, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOAuth2Service, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOAuth2ServiceBase, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOAuth2ServiceGoogle, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOAuth2ServiceOutlook, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOAuth2Services, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EOperationPool, e_operation_pool_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EProxy, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESExp, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESoupAuthBearer, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESoupSession, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESource, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceAddressBook, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceAlarms, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceAuthentication, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceAutocomplete, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceAutoconfig, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceBackend, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCalendar, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCamel, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCollection, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceContacts, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCredentialsProvider, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCredentialsProviderImpl, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCredentialsProviderImplOAuth2, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceCredentialsProviderImplPassword, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceExtension, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceGoa, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceLDAP, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceLocal, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailAccount, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailComposition, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailIdentity, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailSignature, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailSubmission, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMailTransport, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMDN, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceMemoList, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceOffline, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceOpenPGP, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceProxy, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceRefresh, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceRegistry, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceRegistryWatcher, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceResource, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceRevisionGuards, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceSecurity, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceSelectable, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceSMIME, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceTaskList, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceUoa, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceWeather, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(ESourceWebdav, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EUri, e_uri_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EWebDAVSession, g_object_unref)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EWebDAVResource, e_webdav_resource_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EWebDAVPropertyChange, e_webdav_property_change_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EWebDAVPrivilege, e_webdav_privilege_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EWebDAVAccessControlEntry, e_webdav_access_control_entry_free)
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(EXmlDocument, g_object_unref)
+
+#endif /* G_DEFINE_AUTOPTR_CLEANUP_FUNC */
+#endif /* !__GI_SCANNER__ */
+#endif /* __E_DATASERVER_AUTOCLEANUPS_H__ */
diff --git a/src/libedataserver/libedataserver.h b/src/libedataserver/libedataserver.h
index 8b19ef572..6f872098a 100644
--- a/src/libedataserver/libedataserver.h
+++ b/src/libedataserver/libedataserver.h
@@ -104,6 +104,8 @@
#include <libedataserver/e-xml-utils.h>
#include <libedataserver/eds-version.h>
+#include <libedataserver/e-dataserver-autocleanups.h>
+
#undef __LIBEDATASERVER_H_INSIDE__
#endif /* LIBEDATASERVER_H */