summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfigure2
-rw-r--r--src/mail/Makefile2
-rw-r--r--src/mail/mail.vala48
-rw-r--r--src/mail/mailer-interface.vala2
-rw-r--r--src/mail/mailer.vala2
-rw-r--r--vapi/Makefile2
-rw-r--r--vapi/gmime-2.6.vapi1446
-rw-r--r--vapi/gmime-3.0.deps (renamed from vapi/gmime-2.6.deps)0
-rw-r--r--vapi/gmime-3.0.vapi1775
9 files changed, 1808 insertions, 1471 deletions
diff --git a/configure b/configure
index 9438569..4fde129 100755
--- a/configure
+++ b/configure
@@ -18,7 +18,7 @@ check_dependencies() {
check_pkg_version gdk-2.0 2.24 "force"
check_pkg_version gee-0.8 0.6 "force"
check_pkg_version gio-2.0 2.36 "force"
- check_pkg_version gmime-2.6 2.6.10 "force"
+ check_pkg_version gmime-3.0 3.0 "force"
check_prg_version gpgme 1.2 $GPGME_VERSION "force"
check_pkg_version gstreamer-1.0 1.0 "force"
check_pkg_version libarchive 3.0 "force"
diff --git a/src/mail/Makefile b/src/mail/Makefile
index 6ec153c..47819dd 100644
--- a/src/mail/Makefile
+++ b/src/mail/Makefile
@@ -2,7 +2,7 @@ all: mailer
@echo > /dev/null
mailer: main.vala mailer.vala mail.vala mailer-interface.vala ../config/config-interface.vala
- valac -X -w -o $@ --vapidir=../../vapi --pkg posix --pkg libesmtp --pkg gio-2.0 --pkg gmime-2.6 -X -D_GNU_SOURCE -X -lesmtp -X -lssl -X -lcrypto -X -ldl -X -pthread $^
+ valac -X -w -o $@ --vapidir=../../vapi --pkg posix --pkg libesmtp --pkg gio-2.0 --pkg gmime-3.0 -X -D_GNU_SOURCE -X -lesmtp -X -lssl -X -lcrypto -X -ldl -X -pthread $^
clean:
rm -f mailer
diff --git a/src/mail/mail.vala b/src/mail/mail.vala
index 41153f8..63e9362 100644
--- a/src/mail/mail.vala
+++ b/src/mail/mail.vala
@@ -20,15 +20,16 @@ public class MailImplementation {
private GMime.Part? main_html = null;
private GMime.Part[] attachments;
- private GMime.FilterCRLF filter;
+ private GMime.FilterUnix2Dos filter_unix2dos;
+ private GMime.FilterSmtpData filter_smtp;
private string[] recipients;
private string? reversepath;
public MailContact from { set {
- string sender = value.name + " " + "<" + value.email + ">";
reversepath = value.email;
- m.set_sender(sender);
+ m.add_mailbox(GMime.AddressType.SENDER, value.name, value.email);
+ m.add_mailbox(GMime.AddressType.FROM, value.name, value.email);
}}
public string subject {
@@ -37,7 +38,7 @@ public class MailImplementation {
return (result == null) ? "" : result;
}
set {
- m.set_subject(value);
+ m.set_subject(value, "utf-8");
}
}
@@ -53,30 +54,35 @@ public class MailImplementation {
public string reply_to {
owned get {
- var result = m.get_reply_to();
+ var result = m.get_reply_to().to_string(new GMime.FormatOptions(), true);
return (result == null) ? "" : result;
}
set {
- m.set_reply_to(value);
+ m.add_mailbox(GMime.AddressType.REPLY_TO, "", value);
}
}
public MailDate date {
owned get {
MailDate result = {};
- m.get_date(out result.date, out result.tz_offset);
+ var tmp = m.get_date();
+ result.timezone = tmp.get_timezone_abbreviation();
+ result.date = tmp.to_unix();
return result;
}
set {
- m.set_date((ulong) value.date, value.tz_offset);
+ var timezone = new TimeZone(value.timezone);
+ var date = new DateTime.from_unix_utc((int64) value.date).to_timezone(timezone);
+ m.set_date(date);
}
}
public MailImplementation() {
m = new GMime.Message(true);
- m.set_header("X-Mailer", "KtT Shopsystem");
+ m.set_header("X-Mailer", "KtT Shopsystem", "utf-8");
attachments = new GMime.Part[0];
- filter = new GMime.FilterCRLF(true, true);
+ filter_smtp = new GMime.FilterSmtpData();
+ filter_unix2dos = new GMime.FilterUnix2Dos(true);
recipients = new string[0];
}
@@ -95,8 +101,8 @@ public class MailImplementation {
}
#endif
- public void add_recipient(MailContact contact, GMime.RecipientType type) {
- m.add_recipient(type, contact.name, contact.email);
+ public void add_recipient(MailContact contact, GMime.AddressType type) {
+ m.add_mailbox(type, contact.name, contact.email);
recipients += contact.email;
}
@@ -106,17 +112,17 @@ public class MailImplementation {
GMime.ContentEncoding.DEFAULT);
GMime.Part? part = new GMime.Part();
- part.set_content_object(content);
+ part.set_content(content);
switch(type) {
case MessageType.HTML:
- part.set_content_type(new GMime.ContentType.from_string("text/html; charset=utf-8"));
+ part.set_content_type(GMime.ContentType.parse(new GMime.ParserOptions(), "text/html; charset=utf-8"));
part.set_content_encoding(part.get_best_content_encoding(GMime.EncodingConstraint.7BIT));
main_html = part;
break;
case MessageType.PLAIN:
default:
- part.set_content_type(new GMime.ContentType.from_string("text/plain; charset=utf-8; format=flowed"));
+ part.set_content_type(GMime.ContentType.parse(new GMime.ParserOptions(), "text/plain; charset=utf-8; format=flowed"));
part.set_content_encoding(part.get_best_content_encoding(GMime.EncodingConstraint.7BIT));
main_text = part;
break;
@@ -133,8 +139,8 @@ public class MailImplementation {
/* configure part */
part.set_disposition("attachment");
part.set_filename(filename);
- part.set_content_type(new GMime.ContentType.from_string(content_type));
- part.set_content_object(content);
+ part.set_content_type(GMime.ContentType.parse(new GMime.ParserOptions(), content_type));
+ part.set_content(content);
part.set_content_encoding(part.get_best_content_encoding(GMime.EncodingConstraint.7BIT));
attachments += part;
@@ -190,11 +196,13 @@ public class MailImplementation {
[DBus (visible = false)]
public string generate() {
update_mime_part();
- string result = m.to_string();
+ string result = m.to_string(new GMime.FormatOptions());
uint8[] crlfdata;
+ uint8[] smtpdata;
size_t prespace;
- filter.filter(result.data, 0, out crlfdata, out prespace);
- return (string) crlfdata;
+ filter_unix2dos.filter(result.data, 0, out crlfdata, out prespace);
+ filter_smtp.filter(crlfdata, 0, out smtpdata, out prespace);
+ return (string) smtpdata;
}
[DBus (visible = false)]
diff --git a/src/mail/mailer-interface.vala b/src/mail/mailer-interface.vala
index 54b4865..1b819d5 100644
--- a/src/mail/mailer-interface.vala
+++ b/src/mail/mailer-interface.vala
@@ -51,7 +51,7 @@ public struct MailContact {
public struct MailDate {
uint64 date;
- int tz_offset;
+ string timezone;
}
public enum MessageType {
diff --git a/src/mail/mailer.vala b/src/mail/mailer.vala
index 3ec9381..d83e4b0 100644
--- a/src/mail/mailer.vala
+++ b/src/mail/mailer.vala
@@ -59,7 +59,7 @@ public class MailerImplementation {
public MailerImplementation() throws IOError {
int result;
- GMime.init(0);
+ GMime.init();
Smtp.auth_client_init();
session = Smtp.Session();
diff --git a/vapi/Makefile b/vapi/Makefile
index 93c8d79..4fe253f 100644
--- a/vapi/Makefile
+++ b/vapi/Makefile
@@ -1,5 +1,5 @@
doc:
rm -rf doc
- valadoc -o doc --deps --vapidir=. --pkg gmime-2.6 --pkg libesmtp --pkg gpgme
+ valadoc -o doc --deps --vapidir=. --pkg gmime-3.0 --pkg libesmtp --pkg gpgme
.PHONY: doc
diff --git a/vapi/gmime-2.6.vapi b/vapi/gmime-2.6.vapi
deleted file mode 100644
index eaf3468..0000000
--- a/vapi/gmime-2.6.vapi
+++ /dev/null
@@ -1,1446 +0,0 @@
-/* gmime-2.6.vapi generated by vapigen, do not modify. */
-
-[CCode (lower_case_cprefix = "gmime_")]
-namespace GMime {
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Certificate : GLib.Object {
- public ulong created;
- public GMime.DigestAlgo digest_algo;
- public weak string email;
- public ulong expires;
- public weak string fingerprint;
- public weak string issuer_name;
- public weak string issuer_serial;
- public weak string keyid;
- public weak string name;
- public GMime.PubKeyAlgo pubkey_algo;
- public GMime.CertificateTrust trust;
- [CCode (cname = "g_mime_certificate_new", has_construct_function = false)]
- public Certificate ();
- [CCode (cname = "g_mime_certificate_get_created")]
- public ulong get_created ();
- [CCode (cname = "g_mime_certificate_get_digest_algo")]
- public GMime.DigestAlgo get_digest_algo ();
- [CCode (cname = "g_mime_certificate_get_email")]
- public unowned string get_email ();
- [CCode (cname = "g_mime_certificate_get_expires")]
- public ulong get_expires ();
- [CCode (cname = "g_mime_certificate_get_fingerprint")]
- public unowned string get_fingerprint ();
- [CCode (cname = "g_mime_certificate_get_issuer_name")]
- public unowned string get_issuer_name ();
- [CCode (cname = "g_mime_certificate_get_issuer_serial")]
- public unowned string get_issuer_serial ();
- [CCode (cname = "g_mime_certificate_get_key_id")]
- public unowned string get_key_id ();
- [CCode (cname = "g_mime_certificate_get_name")]
- public unowned string get_name ();
- [CCode (cname = "g_mime_certificate_get_pubkey_algo")]
- public GMime.PubKeyAlgo get_pubkey_algo ();
- [CCode (cname = "g_mime_certificate_get_trust")]
- public GMime.CertificateTrust get_trust ();
- [CCode (cname = "g_mime_certificate_set_created")]
- public void set_created (ulong created);
- [CCode (cname = "g_mime_certificate_set_digest_algo")]
- public void set_digest_algo (GMime.DigestAlgo algo);
- [CCode (cname = "g_mime_certificate_set_email")]
- public void set_email (string email);
- [CCode (cname = "g_mime_certificate_set_expires")]
- public void set_expires (ulong expires);
- [CCode (cname = "g_mime_certificate_set_fingerprint")]
- public void set_fingerprint (string fingerprint);
- [CCode (cname = "g_mime_certificate_set_issuer_name")]
- public void set_issuer_name (string issuer_name);
- [CCode (cname = "g_mime_certificate_set_issuer_serial")]
- public void set_issuer_serial (string issuer_serial);
- [CCode (cname = "g_mime_certificate_set_key_id")]
- public void set_key_id (string key_id);
- [CCode (cname = "g_mime_certificate_set_name")]
- public void set_name (string name);
- [CCode (cname = "g_mime_certificate_set_pubkey_algo")]
- public void set_pubkey_algo (GMime.PubKeyAlgo algo);
- [CCode (cname = "g_mime_certificate_set_trust")]
- public void set_trust (GMime.CertificateTrust trust);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class CertificateList : GLib.Object {
- public weak GLib.PtrArray array;
- [CCode (cname = "g_mime_certificate_list_new", has_construct_function = false)]
- public CertificateList ();
- [CCode (cname = "g_mime_certificate_list_add")]
- public int add (GMime.Certificate cert);
- [CCode (cname = "g_mime_certificate_list_clear")]
- public void clear ();
- [CCode (cname = "g_mime_certificate_list_contains")]
- public bool contains (GMime.Certificate cert);
- [CCode (cname = "g_mime_certificate_list_get_certificate")]
- public unowned GMime.Certificate get_certificate (int index);
- [CCode (cname = "g_mime_certificate_list_index_of")]
- public int index_of (GMime.Certificate cert);
- [CCode (cname = "g_mime_certificate_list_insert")]
- public void insert (int index, GMime.Certificate cert);
- [CCode (cname = "g_mime_certificate_list_length")]
- public int length ();
- [CCode (cname = "g_mime_certificate_list_remove")]
- public bool remove (GMime.Certificate cert);
- [CCode (cname = "g_mime_certificate_list_remove_at")]
- public bool remove_at (int index);
- [CCode (cname = "g_mime_certificate_list_set_certificate")]
- public void set_certificate (int index, GMime.Certificate cert);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- [Compact]
- public class Charset {
- public uint level;
- public uint mask;
- [CCode (cname = "g_mime_charset_best")]
- public static unowned string best (string inbuf, size_t inlen);
- [CCode (cname = "g_mime_charset_best_name")]
- public unowned string best_name ();
- [CCode (cname = "g_mime_charset_can_encode")]
- public bool can_encode (string charset, string text, size_t len);
- [CCode (cname = "g_mime_charset_canon_name")]
- public static unowned string canon_name (string charset);
- [CCode (cname = "g_mime_charset_iconv_name")]
- public static unowned string iconv_name (string charset);
- [CCode (cname = "g_mime_charset_init")]
- public void init ();
- [CCode (cname = "g_mime_charset_iso_to_windows")]
- public static unowned string iso_to_windows (string isocharset);
- [CCode (cname = "g_mime_charset_language")]
- public static unowned string language (string charset);
- [CCode (cname = "g_mime_charset_locale_name")]
- public static unowned string locale_name ();
- [CCode (cname = "g_mime_charset_map_init")]
- public static void map_init ();
- [CCode (cname = "g_mime_charset_map_shutdown")]
- public static void map_shutdown ();
- [CCode (cname = "g_mime_charset_name")]
- public static unowned string name (string charset);
- [CCode (cname = "g_mime_charset_step")]
- public void step (string inbuf, size_t inlen);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class ContentDisposition : GLib.Object {
- public weak string disposition;
- public weak GLib.HashTable param_hash;
- public weak GMime.Param @params;
- [CCode (cname = "g_mime_content_disposition_new", has_construct_function = false)]
- public ContentDisposition ();
- [CCode (cname = "g_mime_content_disposition_new_from_string", has_construct_function = false)]
- public ContentDisposition.from_string (string str);
- [CCode (cname = "g_mime_content_disposition_get_disposition")]
- public unowned string get_disposition ();
- [CCode (cname = "g_mime_content_disposition_get_parameter")]
- public unowned string get_parameter (string attribute);
- [CCode (cname = "g_mime_content_disposition_get_params")]
- public unowned GMime.Param get_params ();
- [CCode (cname = "g_mime_content_disposition_set_disposition")]
- public void set_disposition (string value);
- [CCode (cname = "g_mime_content_disposition_set_parameter")]
- public void set_parameter (string attribute, string value);
- [CCode (cname = "g_mime_content_disposition_set_params")]
- public void set_params (GMime.Param @params);
- [CCode (cname = "g_mime_content_disposition_to_string")]
- public unowned string to_string (bool fold);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class ContentType : GLib.Object {
- public weak GLib.HashTable param_hash;
- public weak GMime.Param @params;
- public weak string subtype;
- public weak string type;
- [CCode (cname = "g_mime_content_type_new", has_construct_function = false)]
- public ContentType (string type, string subtype);
- [CCode (cname = "g_mime_content_type_new_from_string", has_construct_function = false)]
- public ContentType.from_string (string str);
- [CCode (cname = "g_mime_content_type_get_media_subtype")]
- public unowned string get_media_subtype ();
- [CCode (cname = "g_mime_content_type_get_media_type")]
- public unowned string get_media_type ();
- [CCode (cname = "g_mime_content_type_get_parameter")]
- public unowned string get_parameter (string attribute);
- [CCode (cname = "g_mime_content_type_get_params")]
- public unowned GMime.Param get_params ();
- [CCode (cname = "g_mime_content_type_is_type")]
- public bool is_type (string type, string subtype);
- [CCode (cname = "g_mime_content_type_set_media_subtype")]
- public void set_media_subtype (string subtype);
- [CCode (cname = "g_mime_content_type_set_media_type")]
- public void set_media_type (string type);
- [CCode (cname = "g_mime_content_type_set_parameter")]
- public void set_parameter (string attribute, string value);
- [CCode (cname = "g_mime_content_type_set_params")]
- public void set_params (GMime.Param @params);
- [CCode (cname = "g_mime_content_type_to_string")]
- public unowned string to_string ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class CryptoContext : GLib.Object {
- public weak GMime.PasswordRequestFunc request_passwd;
- [CCode (has_construct_function = false)]
- protected CryptoContext ();
- [CCode (cname = "g_mime_crypto_context_decrypt")]
- public virtual unowned GMime.DecryptResult decrypt (GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
- [CCode (cname = "g_mime_crypto_context_digest_id")]
- public virtual GMime.DigestAlgo digest_id (string name);
- [CCode (cname = "g_mime_crypto_context_digest_name")]
- public virtual unowned string digest_name (GMime.DigestAlgo digest);
- [CCode (cname = "g_mime_crypto_context_encrypt")]
- public virtual int encrypt (bool sign, string userid, GMime.DigestAlgo digest, GLib.PtrArray recipients, GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
- [CCode (cname = "g_mime_crypto_context_export_keys")]
- public virtual int export_keys (GLib.PtrArray keys, GMime.Stream ostream) throws GLib.Error;
- [CCode (cname = "g_mime_crypto_context_get_encryption_protocol")]
- public virtual unowned string get_encryption_protocol ();
- [CCode (cname = "g_mime_crypto_context_get_key_exchange_protocol")]
- public virtual unowned string get_key_exchange_protocol ();
- [CCode (cname = "g_mime_crypto_context_get_signature_protocol")]
- public virtual unowned string get_signature_protocol ();
- [CCode (cname = "g_mime_crypto_context_import_keys")]
- public virtual int import_keys (GMime.Stream istream) throws GLib.Error;
- [CCode (cname = "g_mime_crypto_context_set_request_password")]
- public void set_request_password (GMime.PasswordRequestFunc request_passwd);
- [CCode (cname = "g_mime_crypto_context_sign")]
- public virtual int sign (string userid, GMime.DigestAlgo digest, GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
- [CCode (cname = "g_mime_crypto_context_verify")]
- public virtual unowned GMime.SignatureList verify (GMime.DigestAlgo digest, GMime.Stream istream, GMime.Stream sigstream) throws GLib.Error;
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class DataWrapper : GLib.Object {
- public GMime.ContentEncoding encoding;
- public weak GMime.Stream stream;
- [CCode (cname = "g_mime_data_wrapper_new", has_construct_function = false)]
- public DataWrapper ();
- [CCode (cname = "g_mime_data_wrapper_get_encoding")]
- public GMime.ContentEncoding get_encoding ();
- [CCode (cname = "g_mime_data_wrapper_get_stream")]
- public unowned GMime.Stream get_stream ();
- [CCode (cname = "g_mime_data_wrapper_set_encoding")]
- public void set_encoding (GMime.ContentEncoding encoding);
- [CCode (cname = "g_mime_data_wrapper_set_stream")]
- public void set_stream (GMime.Stream stream);
- [CCode (cname = "g_mime_data_wrapper_new_with_stream", has_construct_function = false)]
- public DataWrapper.with_stream (GMime.Stream stream, GMime.ContentEncoding encoding);
- [CCode (cname = "g_mime_data_wrapper_write_to_stream")]
- public virtual ssize_t write_to_stream (GMime.Stream stream);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class DecryptResult : GLib.Object {
- public GMime.CipherAlgo cipher;
- public GMime.DigestAlgo mdc;
- public weak GMime.CertificateList recipients;
- public weak GMime.SignatureList signatures;
- [CCode (cname = "g_mime_decrypt_result_new", has_construct_function = false)]
- public DecryptResult ();
- [CCode (cname = "g_mime_decrypt_result_get_cipher")]
- public GMime.CipherAlgo get_cipher ();
- [CCode (cname = "g_mime_decrypt_result_get_mdc")]
- public GMime.DigestAlgo get_mdc ();
- [CCode (cname = "g_mime_decrypt_result_get_recipients")]
- public unowned GMime.CertificateList get_recipients ();
- [CCode (cname = "g_mime_decrypt_result_get_signatures")]
- public unowned GMime.SignatureList get_signatures ();
- [CCode (cname = "g_mime_decrypt_result_set_cipher")]
- public void set_cipher (GMime.CipherAlgo cipher);
- [CCode (cname = "g_mime_decrypt_result_set_mdc")]
- public void set_mdc (GMime.DigestAlgo mdc);
- [CCode (cname = "g_mime_decrypt_result_set_recipients")]
- public void set_recipients (GMime.CertificateList recipients);
- [CCode (cname = "g_mime_decrypt_result_set_signatures")]
- public void set_signatures (GMime.SignatureList signatures);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- [Compact]
- public class Encoding {
- public bool encode;
- public GMime.ContentEncoding encoding;
- public uint32 save;
- public int state;
- [CCode (array_length = false)]
- public weak uint[] uubuf;
- [CCode (cname = "g_mime_encoding_base64_decode_step")]
- public static size_t base64_decode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_base64_encode_close")]
- public static size_t base64_encode_close (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_base64_encode_step")]
- public static size_t base64_encode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_flush")]
- public size_t flush (string inbuf, size_t inlen, string outbuf);
- [CCode (cname = "g_mime_encoding_init_decode")]
- public void init_decode (GMime.ContentEncoding encoding);
- [CCode (cname = "g_mime_encoding_init_encode")]
- public void init_encode (GMime.ContentEncoding encoding);
- [CCode (cname = "g_mime_encoding_outlen")]
- public size_t outlen (size_t inlen);
- [CCode (cname = "g_mime_encoding_quoted_decode_step")]
- public static size_t quoted_decode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_quoted_encode_close")]
- public static size_t quoted_encode_close (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_quoted_encode_step")]
- public static size_t quoted_encode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_reset")]
- public void reset ();
- [CCode (cname = "g_mime_encoding_step")]
- public size_t step (string inbuf, size_t inlen, string outbuf);
- [CCode (cname = "g_mime_encoding_uudecode_step")]
- public static size_t uudecode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_uuencode_close")]
- public static size_t uuencode_close (uint inbuf, size_t inlen, uint outbuf, uint uubuf, int state, uint32 save);
- [CCode (cname = "g_mime_encoding_uuencode_step")]
- public static size_t uuencode_step (uint inbuf, size_t inlen, uint outbuf, uint uubuf, int state, uint32 save);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Filter : GLib.Object {
- public char* backbuf;
- public size_t backlen;
- public size_t backsize;
- [CCode (array_length_cname = "outsize", array_length_type = "size_t")]
- public uint8[] outbuf;
- public size_t outpre;
- public char* outptr;
- public char* outreal;
- [CCode (has_construct_function = false)]
- protected Filter ();
- [CCode (cname = "g_mime_filter_backup")]
- public void backup ([CCode (array_length_pos = 1.1, array_length_type = "size_t")] uint8[] data);
- [CCode (cname = "g_mime_filter_complete")]
- public virtual void complete ([CCode (array_length_pos = 1.1, array_length_type = "size_t")] uint8[] inbuf, size_t prespace, [CCode (array_length_pos = 3.1, array_length_type = "size_t")] out unowned uint8[] outbuf, out size_t outprespace);
- [CCode (cname = "g_mime_filter_copy")]
- public virtual GMime.Filter copy ();
- [CCode (cname = "g_mime_filter_filter")]
- public virtual void filter ([CCode (array_length_pos = 1.1, array_length_type = "size_t")] uint8[] inbuf, size_t prespace, [CCode (array_length_pos = 3.1, array_length_type = "size_t", type = "char **")] out unowned uint8[] outbuf, out size_t outprespace);
- [CCode (cname = "g_mime_filter_reset")]
- public virtual void reset ();
- [CCode (cname = "g_mime_filter_set_size")]
- public void set_size (size_t size, bool keep);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterBasic : GMime.Filter {
- public weak GMime.Encoding encoder;
- [CCode (cname = "g_mime_filter_basic_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterBasic (GMime.ContentEncoding encoding, bool encode);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterBest : GMime.Filter {
- public uint count0;
- public uint count8;
- public GMime.FilterBestFlags flags;
- [CCode (array_length = false)]
- public weak uint[] frombuf;
- public uint fromlen;
- public uint hadfrom;
- public uint linelen;
- public uint maxline;
- public uint midline;
- public uint startline;
- public uint total;
- [CCode (cname = "g_mime_filter_best_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterBest (GMime.FilterBestFlags flags);
- [CCode (cname = "g_mime_filter_best_charset")]
- public unowned string charset ();
- [CCode (cname = "g_mime_filter_best_encoding")]
- public GMime.ContentEncoding encoding (GMime.EncodingConstraint constraint);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterCRLF : GMime.Filter {
- public bool dots;
- public bool encode;
- public bool saw_cr;
- public bool saw_dot;
- public bool saw_lf;
- [CCode (cname = "g_mime_filter_crlf_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterCRLF (bool encode, bool dots);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterCharset : GMime.Filter {
- public void* cd;
- public weak string from_charset;
- public weak string to_charset;
- [CCode (cname = "g_mime_filter_charset_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterCharset (string from_charset, string to_charset);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterEnriched : GMime.Filter {
- public uint32 flags;
- public int nofill;
- [CCode (cname = "g_mime_filter_enriched_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterEnriched (uint32 flags);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterFrom : GMime.Filter {
- public bool midline;
- public GMime.FilterFromMode mode;
- [CCode (cname = "g_mime_filter_from_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterFrom (GMime.FilterFromMode mode);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterGZip : GMime.Filter {
- public int level;
- public GMime.FilterGZipMode mode;
- [CCode (cname = "g_mime_filter_gzip_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterGZip (GMime.FilterGZipMode mode, int level);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterHTML : GMime.Filter {
- public uint32 colour;
- public uint32 column;
- public uint32 flags;
- public uint32 pre_open;
- public void* scanner;
- [CCode (cname = "g_mime_filter_html_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterHTML (uint32 flags, uint32 colour);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterMd5 : GMime.Filter {
- [CCode (cname = "g_mime_filter_md5_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterMd5 ();
- [CCode (cname = "g_mime_filter_md5_get_digest")]
- public void get_digest (uint[] digest);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterStrip : GMime.Filter {
- [CCode (cname = "g_mime_filter_strip_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterStrip ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterWindows : GMime.Filter {
- public weak string claimed_charset;
- public bool is_windows;
- [CCode (cname = "g_mime_filter_windows_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterWindows (string claimed_charset);
- [CCode (cname = "g_mime_filter_windows_is_windows_charset")]
- public bool is_windows_charset ();
- [CCode (cname = "g_mime_filter_windows_real_charset")]
- public unowned string real_charset ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class FilterYenc : GMime.Filter {
- public uint32 crc;
- public bool encode;
- public int part;
- public uint32 pcrc;
- public int state;
- [CCode (cname = "g_mime_filter_yenc_new", has_construct_function = false, type = "GMimeFilter*")]
- public FilterYenc (bool encode);
- [CCode (cname = "g_mime_filter_yenc_get_crc")]
- public uint32 get_crc ();
- [CCode (cname = "g_mime_filter_yenc_get_pcrc")]
- public uint32 get_pcrc ();
- [CCode (cname = "g_mime_filter_yenc_set_crc")]
- public void set_crc (uint32 crc);
- [CCode (cname = "g_mime_filter_yenc_set_state")]
- public void set_state (int state);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class GpgContext : GMime.CryptoContext {
- public bool always_trust;
- public bool auto_key_retrieve;
- public weak string path;
- public bool use_agent;
- [CCode (cname = "g_mime_gpg_context_new", has_construct_function = false, type = "GMimeCryptoContext*")]
- public GpgContext (GMime.PasswordRequestFunc request_passwd, string path);
- [CCode (cname = "g_mime_gpg_context_get_always_trust")]
- public bool get_always_trust ();
- [CCode (cname = "g_mime_gpg_context_get_auto_key_retrieve")]
- public bool get_auto_key_retrieve ();
- [CCode (cname = "g_mime_gpg_context_get_use_agent")]
- public bool get_use_agent ();
- [CCode (cname = "g_mime_gpg_context_set_always_trust")]
- public void set_always_trust (bool always_trust);
- [CCode (cname = "g_mime_gpg_context_set_auto_key_retrieve")]
- public void set_auto_key_retrieve (bool auto_key_retrieve);
- [CCode (cname = "g_mime_gpg_context_set_use_agent")]
- public void set_use_agent (bool use_agent);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- [Compact]
- public class Header {
- }
- [CCode (cheader_filename = "gmime/gmime.h", copy_function = "g_mime_header_iter_copy", free_function = "g_mime_header_iter_free")]
- [Compact]
- public class HeaderIter {
- public weak GMime.Header cursor;
- public weak GMime.HeaderList hdrlist;
- public uint32 version;
- [CCode (cname = "g_mime_header_iter_new", has_construct_function = false)]
- public HeaderIter ();
- [CCode (cname = "g_mime_header_iter_copy")]
- public unowned GMime.HeaderIter copy ();
- [CCode (cname = "g_mime_header_iter_copy_to")]
- public void copy_to (GMime.HeaderIter dest);
- [CCode (cname = "g_mime_header_iter_equal")]
- public bool equal (GMime.HeaderIter iter2);
- [CCode (cname = "g_mime_header_iter_first")]
- public bool first ();
- [CCode (cname = "g_mime_header_iter_get_name")]
- public unowned string get_name ();
- [CCode (cname = "g_mime_header_iter_get_value")]
- public unowned string get_value ();
- [CCode (cname = "g_mime_header_iter_is_valid")]
- public bool is_valid ();
- [CCode (cname = "g_mime_header_iter_last")]
- public bool last ();
- [CCode (cname = "g_mime_header_iter_next")]
- public bool next ();
- [CCode (cname = "g_mime_header_iter_prev")]
- public bool prev ();
- [CCode (cname = "g_mime_header_iter_remove")]
- public bool remove ();
- [CCode (cname = "g_mime_header_iter_set_value")]
- public bool set_value (string value);
- }
- [CCode (cheader_filename = "gmime/gmime.h", free_function = "g_mime_header_list_destroy")]
- [Compact]
- public class HeaderList {
- [CCode (cname = "g_mime_header_list_new", has_construct_function = false)]
- public HeaderList ();
- [CCode (cname = "g_mime_header_list_append")]
- public void append (string name, string value);
- [CCode (cname = "g_mime_header_list_clear")]
- public void clear ();
- [CCode (cname = "g_mime_header_list_contains")]
- public bool contains (string name);
- [CCode (cname = "g_mime_header_list_foreach")]
- public void @foreach (GMime.HeaderForeachFunc func);
- [CCode (cname = "g_mime_header_list_get")]
- public unowned string @get (string name);
- [CCode (cname = "g_mime_header_list_get_iter")]
- public bool get_iter (out unowned GMime.HeaderIter iter);
- [CCode (cname = "g_mime_header_list_get_stream")]
- public unowned GMime.Stream get_stream ();
- [CCode (cname = "g_mime_header_list_prepend")]
- public void prepend (string name, string value);
- [CCode (cname = "g_mime_header_list_register_writer")]
- public void register_writer (string name, GMime.HeaderWriter writer);
- [CCode (cname = "g_mime_header_list_remove")]
- public bool remove (string name);
- [CCode (cname = "g_mime_header_list_set")]
- public void @set (string name, string value);
- [CCode (cname = "g_mime_header_list_set_stream")]
- public void set_stream (GMime.Stream stream);
- [CCode (cname = "g_mime_header_list_to_string")]
- public unowned string to_string ();
- [CCode (cname = "g_mime_header_list_write_to_stream")]
- public ssize_t write_to_stream (GMime.Stream stream);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Message : GMime.Object {
- public ulong date;
- public weak string from;
- public weak string message_id;
- public weak GMime.Object mime_part;
- public weak InternetAddressList recipients;
- public weak string reply_to;
- public weak string subject;
- public int tz_offset;
- [CCode (cname = "g_mime_message_new", has_construct_function = false)]
- public Message (bool pretty_headers);
- [CCode (cname = "g_mime_message_add_recipient")]
- public void add_recipient (GMime.RecipientType type, string name, string addr);
- [CCode (cname = "g_mime_message_foreach")]
- public void @foreach (GMime.ObjectForeachFunc callback);
- [CCode (cname = "g_mime_message_get_all_recipients")]
- public unowned InternetAddressList get_all_recipients ();
- [CCode (cname = "g_mime_message_get_body")]
- public unowned GMime.Object get_body ();
- [CCode (cname = "g_mime_message_get_date")]
- public void get_date (out ulong date, out int tz_offset);
- [CCode (cname = "g_mime_message_get_date_as_string")]
- public unowned string get_date_as_string ();
- [CCode (cname = "g_mime_message_get_message_id")]
- public unowned string get_message_id ();
- [CCode (cname = "g_mime_message_get_mime_part")]
- public unowned GMime.Object get_mime_part ();
- [CCode (cname = "g_mime_message_get_recipients")]
- public unowned InternetAddressList get_recipients (GMime.RecipientType type);
- [CCode (cname = "g_mime_message_get_reply_to")]
- public unowned string get_reply_to ();
- [CCode (cname = "g_mime_message_get_sender")]
- public unowned string get_sender ();
- [CCode (cname = "g_mime_message_get_subject")]
- public unowned string get_subject ();
- [CCode (cname = "g_mime_message_set_date")]
- public void set_date (ulong date, int tz_offset);
- [CCode (cname = "g_mime_message_set_date_as_string")]
- public void set_date_as_string (string str);
- [CCode (cname = "g_mime_message_set_message_id")]
- public void set_message_id (string message_id);
- [CCode (cname = "g_mime_message_set_mime_part")]
- public void set_mime_part (GMime.Object mime_part);
- [CCode (cname = "g_mime_message_set_reply_to")]
- public void set_reply_to (string reply_to);
- [CCode (cname = "g_mime_message_set_sender")]
- public void set_sender (string sender);
- [CCode (cname = "g_mime_message_set_subject")]
- public void set_subject (string subject);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class MessagePart : GMime.Object {
- public weak GMime.Message message;
- [CCode (cname = "g_mime_message_part_new", has_construct_function = false)]
- public MessagePart (string subtype);
- [CCode (cname = "g_mime_message_part_get_message")]
- public unowned GMime.Message get_message ();
- [CCode (cname = "g_mime_message_part_set_message")]
- public void set_message (GMime.Message message);
- [CCode (cname = "g_mime_message_part_new_with_message", has_construct_function = false)]
- public MessagePart.with_message (string subtype, GMime.Message message);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class MessagePartial : GMime.Part {
- public weak string id;
- public int number;
- public int total;
- [CCode (cname = "g_mime_message_partial_new", has_construct_function = false)]
- public MessagePartial (string id, int number, int total);
- [CCode (cname = "g_mime_message_partial_get_id")]
- public unowned string get_id ();
- [CCode (cname = "g_mime_message_partial_get_number")]
- public int get_number ();
- [CCode (cname = "g_mime_message_partial_get_total")]
- public int get_total ();
- [CCode (cname = "g_mime_message_partial_reconstruct_message")]
- public unowned GMime.Message reconstruct_message (size_t num);
- [CCode (cname = "g_mime_message_partial_split_message")]
- public static unowned GMime.Message split_message (GMime.Message message, size_t max_size, size_t nparts);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Multipart : GMime.Object {
- public weak string boundary;
- public weak GLib.PtrArray children;
- public weak string postface;
- public weak string preface;
- [CCode (cname = "g_mime_multipart_new", has_construct_function = false)]
- public Multipart ();
- [CCode (cname = "g_mime_multipart_add")]
- public virtual void add (GMime.Object part);
- [CCode (cname = "g_mime_multipart_clear")]
- public virtual void clear ();
- [CCode (cname = "g_mime_multipart_contains")]
- public virtual bool contains (GMime.Object part);
- [CCode (cname = "g_mime_multipart_foreach")]
- public void @foreach (GMime.ObjectForeachFunc callback);
- [CCode (cname = "g_mime_multipart_get_boundary")]
- public virtual unowned string get_boundary ();
- [CCode (cname = "g_mime_multipart_get_count")]
- public virtual int get_count ();
- [CCode (cname = "g_mime_multipart_get_part")]
- public virtual unowned GMime.Object get_part (int index);
- [CCode (cname = "g_mime_multipart_get_postface")]
- public unowned string get_postface ();
- [CCode (cname = "g_mime_multipart_get_preface")]
- public unowned string get_preface ();
- [CCode (cname = "g_mime_multipart_get_subpart_from_content_id")]
- public unowned GMime.Object get_subpart_from_content_id (string content_id);
- [CCode (cname = "g_mime_multipart_index_of")]
- public virtual int index_of (GMime.Object part);
- [CCode (cname = "g_mime_multipart_insert")]
- public virtual void insert (int index, GMime.Object part);
- [CCode (cname = "g_mime_multipart_remove")]
- public virtual bool remove (GMime.Object part);
- [CCode (cname = "g_mime_multipart_remove_at")]
- public virtual unowned GMime.Object remove_at (int index);
- [CCode (cname = "g_mime_multipart_replace")]
- public unowned GMime.Object replace (int index, GMime.Object replacement);
- [CCode (cname = "g_mime_multipart_set_boundary")]
- public virtual void set_boundary (string boundary);
- [CCode (cname = "g_mime_multipart_set_postface")]
- public void set_postface (string postface);
- [CCode (cname = "g_mime_multipart_set_preface")]
- public void set_preface (string preface);
- [CCode (cname = "g_mime_multipart_new_with_subtype", has_construct_function = false)]
- public Multipart.with_subtype (string subtype);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class MultipartEncrypted : GMime.Multipart {
- [CCode (cname = "g_mime_multipart_encrypted_new", has_construct_function = false)]
- public MultipartEncrypted ();
- [CCode (cname = "g_mime_multipart_encrypted_decrypt")]
- public unowned GMime.Object decrypt (GMime.CryptoContext ctx, out unowned GMime.DecryptResult _result) throws GLib.Error;
- [CCode (cname = "g_mime_multipart_encrypted_encrypt")]
- public int encrypt (GMime.Object content, GMime.CryptoContext ctx, bool sign, string userid, GMime.DigestAlgo digest, GLib.PtrArray recipients) throws GLib.Error;
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class MultipartSigned : GMime.Multipart {
- [CCode (cname = "g_mime_multipart_signed_new", has_construct_function = false)]
- public MultipartSigned ();
- [CCode (cname = "g_mime_multipart_signed_sign")]
- public int sign (GMime.Object content, GMime.CryptoContext ctx, string userid, GMime.DigestAlgo digest) throws GLib.Error;
- [CCode (cname = "g_mime_multipart_signed_verify")]
- public unowned GMime.SignatureList verify (GMime.CryptoContext ctx) throws GLib.Error;
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public abstract class Object : GLib.Object {
- public weak string content_id;
- public weak GMime.ContentType content_type;
- public weak GMime.ContentDisposition disposition;
- public weak GMime.HeaderList headers;
- [CCode (cname = "g_mime_object_new", has_construct_function = false)]
- public Object (GMime.ContentType content_type);
- [CCode (cname = "g_mime_object_append_header")]
- public virtual void append_header (string header, string value);
- [CCode (cname = "g_mime_object_encode")]
- public virtual void encode (GMime.EncodingConstraint constraint);
- [CCode (cname = "g_mime_object_get_content_disposition")]
- public unowned GMime.ContentDisposition get_content_disposition ();
- [CCode (cname = "g_mime_object_get_content_disposition_parameter")]
- public unowned string get_content_disposition_parameter (string attribute);
- [CCode (cname = "g_mime_object_get_content_id")]
- public unowned string get_content_id ();
- [CCode (cname = "g_mime_object_get_content_type")]
- public unowned GMime.ContentType get_content_type ();
- [CCode (cname = "g_mime_object_get_content_type_parameter")]
- public unowned string? get_content_type_parameter (string name);
- [CCode (cname = "g_mime_object_get_disposition")]
- public unowned string get_disposition ();
- [CCode (cname = "g_mime_object_get_header")]
- public virtual unowned string get_header (string header);
- [CCode (cname = "g_mime_object_get_header_list")]
- public unowned GMime.HeaderList get_header_list ();
- [CCode (cname = "g_mime_object_get_headers")]
- public virtual unowned string get_headers ();
- [CCode (cname = "g_mime_object_prepend_header")]
- public virtual void prepend_header (string header, string value);
- [CCode (cname = "g_mime_object_register_type")]
- public static void register_type (string type, string subtype, GLib.Type object_type);
- [CCode (cname = "g_mime_object_remove_header")]
- public virtual bool remove_header (string header);
- [CCode (cname = "g_mime_object_set_content_disposition")]
- public void set_content_disposition (GMime.ContentDisposition disposition);
- [CCode (cname = "g_mime_object_set_content_disposition_parameter")]
- public void set_content_disposition_parameter (string attribute, string value);
- [CCode (cname = "g_mime_object_set_content_id")]
- public void set_content_id (string content_id);
- [CCode (cname = "g_mime_object_set_content_type")]
- public virtual void set_content_type (GMime.ContentType content_type);
- [CCode (cname = "g_mime_object_set_content_type_parameter")]
- public void set_content_type_parameter (string name, string value);
- [CCode (cname = "g_mime_object_set_disposition")]
- public void set_disposition (string disposition);
- [CCode (cname = "g_mime_object_set_header")]
- public virtual void set_header (string header, string value);
- [CCode (cname = "g_mime_object_to_string")]
- public string to_string ();
- [CCode (cname = "g_mime_object_new_type", has_construct_function = false)]
- public Object.type (string type, string subtype);
- [CCode (cname = "g_mime_object_type_registry_init")]
- public static void type_registry_init ();
- [CCode (cname = "g_mime_object_type_registry_shutdown")]
- public static void type_registry_shutdown ();
- [CCode (cname = "g_mime_object_write_to_stream")]
- public virtual ssize_t write_to_stream (GMime.Stream stream);
- }
- [CCode (cheader_filename = "gmime/gmime.h", free_function = "g_mime_param_destroy")]
- [Compact]
- public class Param {
- public weak string name;
- public weak GMime.Param next;
- public weak string value;
- [CCode (cname = "g_mime_param_new", has_construct_function = false)]
- public Param (string name, string value);
- [CCode (cname = "g_mime_param_append")]
- public unowned GMime.Param append (string name, string value);
- [CCode (cname = "g_mime_param_append_param")]
- public unowned GMime.Param append_param (GMime.Param param);
- [CCode (cname = "g_mime_param_new_from_string", has_construct_function = false)]
- public Param.from_string (string str);
- [CCode (cname = "g_mime_param_get_name")]
- public unowned string get_name ();
- [CCode (cname = "g_mime_param_next")]
- public unowned GMime.Param get_next ();
- [CCode (cname = "g_mime_param_get_value")]
- public unowned string get_value ();
- [CCode (cname = "g_mime_param_write_to_string")]
- public void write_to_string (bool fold, GLib.StringBuilder str);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Parser : GLib.Object {
- [CCode (cname = "g_mime_parser_new", has_construct_function = false)]
- public Parser ();
- [CCode (cname = "g_mime_parser_construct_message")]
- public unowned GMime.Message? construct_message ();
- [CCode (cname = "g_mime_parser_construct_part")]
- public unowned GMime.Object construct_part ();
- [CCode (cname = "g_mime_parser_eos")]
- public bool eos ();
- [CCode (cname = "g_mime_parser_get_from")]
- public unowned string get_from ();
- [CCode (cname = "g_mime_parser_get_from_offset")]
- public int64 get_from_offset ();
- [CCode (cname = "g_mime_parser_get_headers_begin")]
- public int64 get_headers_begin ();
- [CCode (cname = "g_mime_parser_get_headers_end")]
- public int64 get_headers_end ();
- [CCode (cname = "g_mime_parser_get_persist_stream")]
- public bool get_persist_stream ();
- [CCode (cname = "g_mime_parser_get_respect_content_length")]
- public bool get_respect_content_length ();
- [CCode (cname = "g_mime_parser_get_scan_from")]
- public bool get_scan_from ();
- [CCode (cname = "g_mime_parser_init_with_stream")]
- public void init_with_stream (GMime.Stream stream);
- [CCode (cname = "g_mime_parser_set_header_regex")]
- public void set_header_regex (string regex, GMime.ParserHeaderRegexFunc header_cb);
- [CCode (cname = "g_mime_parser_set_persist_stream")]
- public void set_persist_stream (bool persist);
- [CCode (cname = "g_mime_parser_set_respect_content_length")]
- public void set_respect_content_length (bool respect_content_length);
- [CCode (cname = "g_mime_parser_set_scan_from")]
- public void set_scan_from (bool scan_from);
- [CCode (cname = "g_mime_parser_tell")]
- public int64 tell ();
- [CCode (cname = "g_mime_parser_new_with_stream", has_construct_function = false)]
- public Parser.with_stream (GMime.Stream stream);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Part : GMime.Object {
- public weak GMime.DataWrapper content;
- public weak string content_description;
- public weak string content_location;
- public weak string content_md5;
- public GMime.ContentEncoding encoding;
- [CCode (cname = "g_mime_part_new", has_construct_function = false)]
- public Part ();
- [CCode (cname = "g_mime_part_get_best_content_encoding")]
- public GMime.ContentEncoding get_best_content_encoding (GMime.EncodingConstraint constraint);
- [CCode (cname = "g_mime_part_get_content_description")]
- public unowned string get_content_description ();
- [CCode (cname = "g_mime_part_get_content_encoding")]
- public GMime.ContentEncoding get_content_encoding ();
- [CCode (cname = "g_mime_part_get_content_id")]
- public unowned string get_content_id ();
- [CCode (cname = "g_mime_part_get_content_location")]
- public unowned string get_content_location ();
- [CCode (cname = "g_mime_part_get_content_md5")]
- public unowned string get_content_md5 ();
- [CCode (cname = "g_mime_part_get_content_object")]
- public unowned GMime.DataWrapper get_content_object ();
- [CCode (cname = "g_mime_part_get_filename")]
- public unowned string get_filename ();
- [CCode (cname = "g_mime_part_set_content_description")]
- public void set_content_description (string description);
- [CCode (cname = "g_mime_part_set_content_encoding")]
- public void set_content_encoding (GMime.ContentEncoding encoding);
- [CCode (cname = "g_mime_part_set_content_id")]
- public void set_content_id (string content_id);
- [CCode (cname = "g_mime_part_set_content_location")]
- public void set_content_location (string content_location);
- [CCode (cname = "g_mime_part_set_content_md5")]
- public void set_content_md5 (string content_md5);
- [CCode (cname = "g_mime_part_set_content_object")]
- public virtual void set_content_object (GMime.DataWrapper content);
- [CCode (cname = "g_mime_part_set_filename")]
- public void set_filename (string filename);
- [CCode (cname = "g_mime_part_verify_content_md5")]
- public bool verify_content_md5 ();
- [CCode (cname = "g_mime_part_new_with_type", has_construct_function = false)]
- public Part.with_type (string type, string subtype);
- }
- [CCode (cheader_filename = "gmime/gmime.h", free_function = "g_mime_part_iter_free")]
- [Compact]
- public class PartIter {
- [CCode (cname = "g_mime_part_iter_new", has_construct_function = false)]
- public PartIter (GMime.Object toplevel);
- [CCode (cname = "g_mime_part_iter_get_current")]
- public unowned GMime.Object get_current ();
- [CCode (cname = "g_mime_part_iter_get_parent")]
- public unowned GMime.Object get_parent ();
- [CCode (cname = "g_mime_part_iter_get_path")]
- public unowned string get_path ();
- [CCode (cname = "g_mime_part_iter_get_toplevel")]
- public unowned GMime.Object get_toplevel ();
- [CCode (cname = "g_mime_part_iter_is_valid")]
- public bool is_valid ();
- [CCode (cname = "g_mime_part_iter_jump_to")]
- public bool jump_to (string path);
- [CCode (cname = "g_mime_part_iter_next")]
- public bool next ();
- [CCode (cname = "g_mime_part_iter_prev")]
- public bool prev ();
- [CCode (cname = "g_mime_part_iter_remove")]
- public bool remove ();
- [CCode (cname = "g_mime_part_iter_replace")]
- public bool replace (GMime.Object replacement);
- [CCode (cname = "g_mime_part_iter_reset")]
- public void reset ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Pkcs7Context : GMime.CryptoContext {
- [CCode (cname = "g_mime_pkcs7_context_new", has_construct_function = false, type = "GMimeCryptoContext*")]
- public Pkcs7Context (GMime.PasswordRequestFunc request_passwd);
- [CCode (cname = "g_mime_pkcs7_context_get_always_trust")]
- public bool get_always_trust ();
- [CCode (cname = "g_mime_pkcs7_context_set_always_trust")]
- public void set_always_trust (bool always_trust);
- }
- [CCode (cheader_filename = "gmime/gmime.h", free_function = "g_mime_references_free")]
- [Compact]
- public class References {
- public weak string msgid;
- public weak GMime.References next;
- [CCode (cname = "g_mime_references_append")]
- public void append (string msgid);
- [CCode (cname = "g_mime_references_clear")]
- public void clear ();
- [CCode (cname = "g_mime_references_decode")]
- public static unowned GMime.References decode (string text);
- [CCode (cname = "g_mime_references_get_message_id")]
- public unowned string get_message_id ();
- [CCode (cname = "g_mime_references_get_next")]
- public unowned GMime.References get_next ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class Signature : GLib.Object {
- public weak GMime.Certificate cert;
- public ulong created;
- public GMime.SignatureError errors;
- public ulong expires;
- public GMime.SignatureStatus status;
- [CCode (cname = "g_mime_signature_new", has_construct_function = false)]
- public Signature ();
- [CCode (cname = "g_mime_signature_get_certificate")]
- public unowned GMime.Certificate get_certificate ();
- [CCode (cname = "g_mime_signature_get_created")]
- public ulong get_created ();
- [CCode (cname = "g_mime_signature_get_errors")]
- public GMime.SignatureError get_errors ();
- [CCode (cname = "g_mime_signature_get_expires")]
- public ulong get_expires ();
- [CCode (cname = "g_mime_signature_get_status")]
- public GMime.SignatureStatus get_status ();
- [CCode (cname = "g_mime_signature_set_certificate")]
- public void set_certificate (GMime.Certificate cert);
- [CCode (cname = "g_mime_signature_set_created")]
- public void set_created (ulong created);
- [CCode (cname = "g_mime_signature_set_errors")]
- public void set_errors (GMime.SignatureError errors);
- [CCode (cname = "g_mime_signature_set_expires")]
- public void set_expires (ulong expires);
- [CCode (cname = "g_mime_signature_set_status")]
- public void set_status (GMime.SignatureStatus status);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class SignatureList : GLib.Object {
- public weak GLib.PtrArray array;
- [CCode (cname = "g_mime_signature_list_new", has_construct_function = false)]
- public SignatureList ();
- [CCode (cname = "g_mime_signature_list_add")]
- public int add (GMime.Signature sig);
- [CCode (cname = "g_mime_signature_list_clear")]
- public void clear ();
- [CCode (cname = "g_mime_signature_list_contains")]
- public bool contains (GMime.Signature sig);
- [CCode (cname = "g_mime_signature_list_get_signature")]
- public unowned GMime.Signature get_signature (int index);
- [CCode (cname = "g_mime_signature_list_index_of")]
- public int index_of (GMime.Signature sig);
- [CCode (cname = "g_mime_signature_list_insert")]
- public void insert (int index, GMime.Signature sig);
- [CCode (cname = "g_mime_signature_list_length")]
- public int length ();
- [CCode (cname = "g_mime_signature_list_remove")]
- public bool remove (GMime.Signature sig);
- [CCode (cname = "g_mime_signature_list_remove_at")]
- public bool remove_at (int index);
- [CCode (cname = "g_mime_signature_list_set_signature")]
- public void set_signature (int index, GMime.Signature sig);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public abstract class Stream : GLib.Object {
- public int64 bound_end;
- public int64 bound_start;
- public int64 position;
- public weak GMime.Stream super_stream;
- [CCode (has_construct_function = false)]
- protected Stream ();
- [CCode (cname = "g_mime_stream_close")]
- public virtual int close ();
- [CCode (cname = "g_mime_stream_construct")]
- public void @construct (int64 start, int64 end);
- [CCode (cname = "g_mime_stream_eos")]
- public virtual bool eos ();
- [CCode (cname = "g_mime_stream_flush")]
- public virtual int flush ();
- [CCode (cname = "g_mime_stream_length")]
- public virtual int64 length ();
- [CCode (cname = "g_mime_stream_printf")]
- public ssize_t printf (string fmt);
- [CCode (cname = "g_mime_stream_read")]
- public virtual ssize_t read (string buf, size_t len);
- [CCode (cname = "g_mime_stream_reset")]
- public virtual int reset ();
- [CCode (cname = "g_mime_stream_seek")]
- public virtual int64 seek (int64 offset, GMime.SeekWhence whence);
- [CCode (cname = "g_mime_stream_set_bounds")]
- public void set_bounds (int64 start, int64 end);
- [CCode (cname = "g_mime_stream_substream")]
- public virtual unowned GMime.Stream substream (int64 start, int64 end);
- [CCode (cname = "g_mime_stream_tell")]
- public virtual int64 tell ();
- [CCode (cname = "g_mime_stream_write")]
- public virtual ssize_t write (string buf, size_t len);
- [CCode (cname = "g_mime_stream_write_string")]
- public ssize_t write_string (string str);
- [CCode (cname = "g_mime_stream_write_to_stream")]
- public ssize_t write_to_stream (GMime.Stream dest);
- [CCode (cname = "g_mime_stream_writev")]
- public ssize_t writev (GMime.StreamIOVector vector, size_t count);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamBuffer : GMime.Stream {
- public weak string bufend;
- public weak string buffer;
- public size_t buflen;
- public weak string bufptr;
- public GMime.StreamBufferMode mode;
- public weak GMime.Stream source;
- [CCode (cname = "g_mime_stream_buffer_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamBuffer (GMime.Stream source, GMime.StreamBufferMode mode);
- [CCode (cname = "g_mime_stream_buffer_gets")]
- public static ssize_t gets (GMime.Stream stream, string buf, size_t max);
- [CCode (cname = "g_mime_stream_buffer_readln")]
- public static void readln (GMime.Stream stream, GLib.ByteArray buffer);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamCat : GMime.Stream {
- public void* current;
- public void* sources;
- [CCode (cname = "g_mime_stream_cat_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamCat ();
- [CCode (cname = "g_mime_stream_cat_add_source")]
- public int add_source (GMime.Stream source);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamFile : GMime.Stream {
- public weak GLib.FileStream fp;
- public bool owner;
- [CCode (cname = "g_mime_stream_file_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamFile (GLib.FileStream fp);
- [CCode (cname = "g_mime_stream_file_get_owner")]
- public bool get_owner ();
- [CCode (cname = "g_mime_stream_file_set_owner")]
- public void set_owner (bool owner);
- [CCode (cname = "g_mime_stream_file_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
- public StreamFile.with_bounds (GLib.FileStream fp, int64 start, int64 end);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamFilter : GMime.Stream {
- public weak GMime.Stream source;
- [CCode (cname = "g_mime_stream_filter_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamFilter (GMime.Stream stream);
- [CCode (cname = "g_mime_stream_filter_add")]
- public int add (GMime.Filter filter);
- [CCode (cname = "g_mime_stream_filter_remove")]
- public void remove (int id);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamFs : GMime.Stream {
- public bool eos;
- public int fd;
- public bool owner;
- [CCode (cname = "g_mime_stream_fs_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamFs (int fd);
- [CCode (cname = "g_mime_stream_fs_get_owner")]
- public bool get_owner ();
- [CCode (cname = "g_mime_stream_fs_set_owner")]
- public void set_owner (bool owner);
- [CCode (cname = "g_mime_stream_fs_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
- public StreamFs.with_bounds (int fd, int64 start, int64 end);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamGIO : GMime.Stream {
- public bool eos;
- public weak GLib.File file;
- public weak GLib.InputStream istream;
- public weak GLib.OutputStream ostream;
- public bool owner;
- [CCode (cname = "g_mime_stream_gio_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamGIO (GLib.File file);
- [CCode (cname = "g_mime_stream_gio_get_owner")]
- public bool get_owner ();
- [CCode (cname = "g_mime_stream_gio_set_owner")]
- public void set_owner (bool owner);
- [CCode (cname = "g_mime_stream_gio_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
- public StreamGIO.with_bounds (GLib.File file, int64 start, int64 end);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- [Compact]
- public class StreamIOVector {
- public void* data;
- public size_t len;
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamMem : GMime.Stream {
- public weak GLib.ByteArray buffer;
- public bool owner;
- [CCode (cname = "g_mime_stream_mem_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamMem ();
- [CCode (cname = "g_mime_stream_mem_get_byte_array")]
- public unowned GLib.ByteArray get_byte_array ();
- [CCode (cname = "g_mime_stream_mem_get_owner")]
- public bool get_owner ();
- [CCode (cname = "g_mime_stream_mem_set_byte_array")]
- public void set_byte_array (GLib.ByteArray array);
- [CCode (cname = "g_mime_stream_mem_set_owner")]
- public void set_owner (bool owner);
- [CCode (cname = "g_mime_stream_mem_new_with_buffer", has_construct_function = false, type = "GMimeStream*")]
- public StreamMem.with_buffer ([CCode (array_length_pos = 1)] uint8[] buffer);
- [CCode (cname = "g_mime_stream_mem_new_with_byte_array", has_construct_function = false, type = "GMimeStream*")]
- public StreamMem.with_byte_array (GLib.ByteArray array);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamMmap : GMime.Stream {
- public bool eos;
- public int fd;
- public weak string map;
- public size_t maplen;
- public bool owner;
- [CCode (cname = "g_mime_stream_mmap_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamMmap (int fd, int prot, int flags);
- [CCode (cname = "g_mime_stream_mmap_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
- public StreamMmap.with_bounds (int fd, int prot, int flags, int64 start, int64 end);
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamNull : GMime.Stream {
- public size_t newlines;
- public size_t written;
- [CCode (cname = "g_mime_stream_null_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamNull ();
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public class StreamPipe : GMime.Stream {
- public bool eos;
- public int fd;
- public bool owner;
- [CCode (cname = "g_mime_stream_pipe_new", has_construct_function = false, type = "GMimeStream*")]
- public StreamPipe (int fd);
- [CCode (cname = "g_mime_stream_pipe_get_owner")]
- public bool get_owner ();
- [CCode (cname = "g_mime_stream_pipe_set_owner")]
- public void set_owner (bool owner);
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_CERTIFICATE_TRUST_", has_type_id = false)]
- public enum CertificateTrust {
- NONE,
- NEVER,
- UNDEFINED,
- MARGINAL,
- FULLY,
- ULTIMATE
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_CIPHER_ALGO_", has_type_id = false)]
- public enum CipherAlgo {
- DEFAULT,
- IDEA,
- @3DES,
- CAST5,
- BLOWFISH,
- AES,
- AES192,
- AES256,
- TWOFISH,
- CAMELLIA128,
- CAMELLIA192,
- CAMELLIA256
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_CONTENT_ENCODING_", has_type_id = false)]
- public enum ContentEncoding {
- DEFAULT,
- @7BIT,
- @8BIT,
- BINARY,
- BASE64,
- QUOTEDPRINTABLE,
- UUENCODE
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_DIGEST_ALGO_", has_type_id = false)]
- public enum DigestAlgo {
- DEFAULT,
- MD5,
- SHA1,
- RIPEMD160,
- MD2,
- TIGER192,
- HAVAL5160,
- SHA256,
- SHA384,
- SHA512,
- SHA224,
- MD4
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_ENCODING_CONSTRAINT_", has_type_id = false)]
- public enum EncodingConstraint {
- @7BIT,
- @8BIT,
- BINARY
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_BEST_", has_type_id = false)]
- public enum FilterBestFlags {
- CHARSET,
- ENCODING
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_FROM_MODE_", has_type_id = false)]
- public enum FilterFromMode {
- DEFAULT,
- ESCAPE,
- ARMOR
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_GZIP_MODE_", has_type_id = false)]
- public enum FilterGZipMode {
- ZIP,
- UNZIP
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_PUBKEY_ALGO_", has_type_id = false)]
- public enum PubKeyAlgo {
- DEFAULT,
- RSA,
- RSA_E,
- RSA_S,
- ELG_E,
- DSA,
- ELG
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_RECIPIENT_TYPE_", has_type_id = false)]
- public enum RecipientType {
- TO,
- CC,
- BCC
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_STREAM_SEEK_", has_type_id = false)]
- public enum SeekWhence {
- SET,
- CUR,
- END
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_SIGNATURE_ERROR_", has_type_id = false)]
- public enum SignatureError {
- NONE,
- EXPSIG,
- NO_PUBKEY,
- EXPKEYSIG,
- REVKEYSIG,
- UNSUPP_ALGO
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_SIGNATURE_STATUS_", has_type_id = false)]
- public enum SignatureStatus {
- GOOD,
- ERROR,
- BAD
- }
- [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_STREAM_BUFFER_", has_type_id = false)]
- public enum StreamBufferMode {
- CACHE_READ,
- BLOCK_READ,
- BLOCK_WRITE
- }
- [CCode (cheader_filename = "gmime/gmime.h")]
- public delegate void HeaderForeachFunc (string name, string value);
- [CCode (cheader_filename = "gmime/gmime.h", has_target = false)]
- public delegate ssize_t HeaderWriter (GMime.Stream stream, string name, string value);
- [CCode (cheader_filename = "gmime/gmime.h")]
- public delegate void ObjectForeachFunc (GMime.Object parent, GMime.Object part);
- [CCode (cheader_filename = "gmime/gmime.h")]
- public delegate void ParserHeaderRegexFunc (GMime.Parser parser, string header, string value, int64 offset);
- [CCode (cheader_filename = "gmime/gmime.h", has_target = false)]
- public delegate bool PasswordRequestFunc (GMime.CryptoContext ctx, string user_id, string prompt_ctx, bool reprompt, GMime.Stream response) throws GLib.Error;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int BINARY_AGE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const string DISPOSITION_ATTACHMENT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const string DISPOSITION_INLINE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int ENABLE_RFC2047_WORKAROUNDS;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_ENRICHED_IS_RICHTEXT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_CITE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_CONVERT_ADDRESSES;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_CONVERT_NL;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_CONVERT_SPACES;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_CONVERT_URLS;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_ESCAPE_8BIT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_MARK_CITATION;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int FILTER_HTML_PRE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int INTERFACE_AGE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int MAJOR_VERSION;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int MICRO_VERSION;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int MINOR_VERSION;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int UUDECODE_STATE_BEGIN;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int UUDECODE_STATE_END;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int UUDECODE_STATE_INIT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int UUDECODE_STATE_MASK;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_BEGIN;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_DECODE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_END;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_EOLN;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_ESCAPE;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_INIT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YDECODE_STATE_PART;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YENCODE_CRC_INIT;
- [CCode (cheader_filename = "gmime/gmime.h")]
- public const int YENCODE_STATE_INIT;
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_check_version")]
- public static bool check_version (uint major, uint minor, uint micro);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_content_encoding_from_string")]
- public static GMime.ContentEncoding content_encoding_from_string (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_content_encoding_to_string")]
- public static unowned string content_encoding_to_string (GMime.ContentEncoding encoding);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_close")]
- public static int iconv_close (void* cd);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_init")]
- public static void iconv_init ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_locale_to_utf8")]
- public static unowned string iconv_locale_to_utf8 (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_locale_to_utf8_length")]
- public static unowned string iconv_locale_to_utf8_length (string str, size_t n);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_open")]
- public static void* iconv_open (string to, string from);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_shutdown")]
- public static void iconv_shutdown ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_strdup")]
- public static unowned string iconv_strdup (void* cd, string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_strndup")]
- public static unowned string iconv_strndup (void* cd, string str, size_t n);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_utf8_to_locale")]
- public static unowned string iconv_utf8_to_locale (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_utf8_to_locale_length")]
- public static unowned string iconv_utf8_to_locale_length (string str, size_t n);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_init")]
- public static void init (uint32 flags);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_locale_charset")]
- public static unowned string locale_charset ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_locale_language")]
- public static unowned string locale_language ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_set_user_charsets")]
- public static void set_user_charsets (out unowned string charsets);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_shutdown")]
- public static void shutdown ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_user_charsets")]
- public static unowned string user_charsets ();
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_best_encoding")]
- public static GMime.ContentEncoding utils_best_encoding (uint text, size_t len);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_decode_8bit")]
- public static string utils_decode_8bit (string text, size_t len);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_decode_message_id")]
- public static unowned string utils_decode_message_id (string message_id);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_generate_message_id")]
- public static unowned string utils_generate_message_id (string fqdn);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_date")]
- public static time_t utils_header_decode_date (string str, out unowned int? tz_offset);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_phrase")]
- public static string utils_header_decode_phrase (string phrase);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_text")]
- public static string utils_header_decode_text (string text);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_encode_phrase")]
- public static unowned string utils_header_encode_phrase (string phrase);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_encode_text")]
- public static unowned string utils_header_encode_text (string text);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_fold")]
- public static unowned string utils_header_fold (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_format_date")]
- public static unowned string utils_header_format_date (ulong date, int tz_offset);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_printf")]
- public static unowned string utils_header_printf (string format);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_quote_string")]
- public static unowned string utils_quote_string (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_structured_header_fold")]
- public static unowned string utils_structured_header_fold (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_text_is_8bit")]
- public static bool utils_text_is_8bit (uint text, size_t len);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_unquote_string")]
- public static void utils_unquote_string (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_unstructured_header_fold")]
- public static unowned string utils_unstructured_header_fold (string str);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_ydecode_step")]
- public static size_t ydecode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 pcrc, uint32 crc);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_yencode_close")]
- public static size_t yencode_close (uint inbuf, size_t inlen, uint outbuf, int state, uint32 pcrc, uint32 crc);
- [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_yencode_step")]
- public static size_t yencode_step (uint inbuf, size_t inlen, uint outbuf, int state, uint32 pcrc, uint32 crc);
-}
-[CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddress", type_check_function = "IS_INTERNET_ADDRESS", type_id = "INTERNET_ADDRESS_TYPE")]
-public class InternetAddress : GLib.Object {
- [CCode (cname = "internet_address_get_name")]
- public unowned string? get_name ();
- [CCode (cname = "internet_address_set_name")]
- public void set_name (string? name);
- [CCode (cname = "internet_address_to_string")]
- public virtual string to_string (bool encoded);
-}
-[CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressGroup", type_check_function = "INTERNET_ADDRESS_IS_GROUP", type_id = "INTERNET_ADDRESS_TYPE_GROUP")]
-public class InternetAddressGroup : InternetAddress {
- [CCode (cname = "internet_address_group_new")]
- public InternetAddressGroup (string name);
- [CCode (cname = "internet_address_group_add_member")]
- public int add_member (InternetAddress member);
- [CCode (cname = "internet_address_group_get_members")]
- public unowned InternetAddressList get_members ();
- [CCode (cname = "internet_address_group_set_members")]
- public void set_members (InternetAddressList members);
-}
-[CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressMailbox", type_check_function = "INTERNET_ADDRESS_IS_MAILBOX", type_id = "INTERNET_ADDRESS_TYPE_MAILBOX")]
-public class InternetAddressMailbox : InternetAddress {
- [CCode (cname = "internet_address_mailbox_new")]
- public InternetAddressMailbox (string? name, string addr);
- [CCode (cname = "internet_address_mailbox_get_addr")]
- public unowned string get_addr ();
- [CCode (cname = "internet_address_mailbox_set_addr")]
- public void set_addr (string addr);
-}
-[CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressList", type_check_function = "IS_INTERNET_ADDRESS_LIST", type_id = "INTERNET_ADDRESS_LIST_TYPE")]
-public class InternetAddressList : GLib.Object {
- [CCode (cname = "internet_address_list_new")]
- public InternetAddressList ();
- [CCode (cname = "internet_address_list_add")]
- public int add (InternetAddress addr);
- [CCode (cname = "internet_address_list_append")]
- public void append (InternetAddressList append);
- [CCode (cname = "internet_address_list_clear")]
- public void clear ();
- [CCode (cname = "internet_address_list_contains")]
- public bool contains (InternetAddress addr);
- [CCode (cname = "internet_address_list_get_address")]
- public unowned InternetAddress get_address (int index);
- [CCode (cname = "internet_address_list_index_of")]
- public int index_of (InternetAddress addr);
- [CCode (cname = "internet_address_list_insert")]
- public void insert (int index, InternetAddress addr);
- [CCode (cname = "internet_address_list_length")]
- public int length ();
- [CCode (cname = "internet_address_list_parse_string")]
- public static InternetAddressList? parse_string (string str);
- [CCode (cname = "internet_address_list_prepend")]
- public void prepend (InternetAddressList prepend);
- [CCode (cname = "internet_address_list_remove")]
- public bool remove (InternetAddress addr);
- [CCode (cname = "internet_address_list_remove_at")]
- public bool remove_at (int index);
- [CCode (cname = "internet_address_list_set_address")]
- public void set_address (int index, InternetAddress addr);
- [CCode (cname = "internet_address_list_to_string")]
- public string? to_string (bool encode);
-}
diff --git a/vapi/gmime-2.6.deps b/vapi/gmime-3.0.deps
index cd10dfd..cd10dfd 100644
--- a/vapi/gmime-2.6.deps
+++ b/vapi/gmime-3.0.deps
diff --git a/vapi/gmime-3.0.vapi b/vapi/gmime-3.0.vapi
new file mode 100644
index 0000000..243c605
--- /dev/null
+++ b/vapi/gmime-3.0.vapi
@@ -0,0 +1,1775 @@
+/* gmime-3.0.vapi generated by vapigen-0.42, do not modify. */
+
+[CCode (cprefix = "GMime", gir_namespace = "GMime", gir_version = "3.0", lower_case_cprefix = "gmime__")]
+namespace GMime {
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_application_pkcs7_mime_get_type ()")]
+ public class ApplicationPkcs7Mime : GMime.Part {
+ public GMime.SecureMimeType smime_type;
+ [CCode (cname = "g_mime_application_pkcs7_mime_new", has_construct_function = false)]
+ public ApplicationPkcs7Mime (GMime.SecureMimeType type);
+ [CCode (cname = "g_mime_application_pkcs7_mime_decrypt")]
+ public GMime.Object? decrypt (GMime.DecryptFlags flags, string session_key, GMime.DecryptResult result) throws GLib.Error;
+ [CCode (cname = "g_mime_application_pkcs7_mime_encrypt")]
+ public static GMime.ApplicationPkcs7Mime? encrypt (GMime.Object entity, GMime.EncryptFlags flags, GLib.GenericArray<string> recipients) throws GLib.Error;
+ [CCode (cname = "g_mime_application_pkcs7_mime_get_smime_type")]
+ public GMime.SecureMimeType get_smime_type ();
+ [CCode (cname = "g_mime_application_pkcs7_mime_sign")]
+ public static GMime.ApplicationPkcs7Mime? sign (GMime.Object entity, string userid) throws GLib.Error;
+ [CCode (cname = "g_mime_application_pkcs7_mime_verify")]
+ public GMime.SignatureList? verify (GMime.VerifyFlags flags, out GMime.Object entity) throws GLib.Error;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_autocrypt_header_get_type ()")]
+ public class AutocryptHeader : GLib.Object {
+ public weak GMime.InternetAddressMailbox address;
+ public weak GLib.DateTime effective_date;
+ public weak GLib.Bytes keydata;
+ public GMime.AutocryptPreferEncrypt prefer_encrypt;
+ [CCode (cname = "g_mime_autocrypt_header_new", has_construct_function = false)]
+ public AutocryptHeader ();
+ [CCode (cname = "g_mime_autocrypt_header_clone")]
+ public void clone (GMime.AutocryptHeader src);
+ [CCode (cname = "g_mime_autocrypt_header_compare")]
+ public int compare (GMime.AutocryptHeader ah2);
+ [CCode (cname = "g_mime_autocrypt_header_new_from_string", has_construct_function = false)]
+ public AutocryptHeader.from_string (string string);
+ [CCode (cname = "g_mime_autocrypt_header_get_address")]
+ public unowned GMime.InternetAddressMailbox get_address ();
+ [CCode (cname = "g_mime_autocrypt_header_get_address_as_string")]
+ public unowned string get_address_as_string ();
+ [CCode (cname = "g_mime_autocrypt_header_get_effective_date")]
+ public unowned GLib.DateTime get_effective_date ();
+ [CCode (cname = "g_mime_autocrypt_header_get_keydata")]
+ public unowned GLib.Bytes get_keydata ();
+ [CCode (cname = "g_mime_autocrypt_header_get_prefer_encrypt")]
+ public GMime.AutocryptPreferEncrypt get_prefer_encrypt ();
+ [CCode (cname = "g_mime_autocrypt_header_is_complete")]
+ public bool is_complete ();
+ [CCode (cname = "g_mime_autocrypt_header_set_address")]
+ public void set_address (GMime.InternetAddressMailbox address);
+ [CCode (cname = "g_mime_autocrypt_header_set_address_from_string")]
+ public void set_address_from_string (string address);
+ [CCode (cname = "g_mime_autocrypt_header_set_effective_date")]
+ public void set_effective_date (GLib.DateTime effective_date);
+ [CCode (cname = "g_mime_autocrypt_header_set_keydata")]
+ public void set_keydata (GLib.Bytes data);
+ [CCode (cname = "g_mime_autocrypt_header_set_prefer_encrypt")]
+ public void set_prefer_encrypt (GMime.AutocryptPreferEncrypt pref);
+ [CCode (cname = "g_mime_autocrypt_header_to_string")]
+ public string to_string (bool gossip);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_autocrypt_header_list_get_type ()")]
+ public class AutocryptHeaderList : GLib.Object {
+ [CCode (cname = "g_mime_autocrypt_header_list_new", has_construct_function = false)]
+ public AutocryptHeaderList ();
+ [CCode (cname = "g_mime_autocrypt_header_list_add")]
+ public void add (GMime.AutocryptHeader header);
+ [CCode (cname = "g_mime_autocrypt_header_list_add_missing_addresses")]
+ public uint add_missing_addresses (GMime.InternetAddressList addresses);
+ [CCode (cname = "g_mime_autocrypt_header_list_get_count")]
+ public uint get_count ();
+ [CCode (cname = "g_mime_autocrypt_header_list_get_header_at")]
+ public unowned GMime.AutocryptHeader get_header_at (uint index);
+ [CCode (cname = "g_mime_autocrypt_header_list_get_header_for_address")]
+ public unowned GMime.AutocryptHeader get_header_for_address (GMime.InternetAddressMailbox mailbox);
+ [CCode (cname = "g_mime_autocrypt_header_list_remove_incomplete")]
+ public void remove_incomplete ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_certificate_get_type ()")]
+ public class Certificate : GLib.Object {
+ public long created;
+ public GMime.DigestAlgo digest_algo;
+ public weak string email;
+ public long expires;
+ public weak string fingerprint;
+ public GMime.Validity id_validity;
+ public weak string issuer_name;
+ public weak string issuer_serial;
+ public weak string keyid;
+ public weak string name;
+ public GMime.PubKeyAlgo pubkey_algo;
+ public GMime.Trust trust;
+ public weak string user_id;
+ [CCode (cname = "g_mime_certificate_new", has_construct_function = false)]
+ public Certificate ();
+ [CCode (cname = "g_mime_certificate_get_created")]
+ public long get_created ();
+ [CCode (cname = "g_mime_certificate_get_digest_algo")]
+ public GMime.DigestAlgo get_digest_algo ();
+ [CCode (cname = "g_mime_certificate_get_email")]
+ public unowned string get_email ();
+ [CCode (cname = "g_mime_certificate_get_expires")]
+ public long get_expires ();
+ [CCode (cname = "g_mime_certificate_get_fingerprint")]
+ public unowned string get_fingerprint ();
+ [CCode (cname = "g_mime_certificate_get_id_validity")]
+ public GMime.Validity get_id_validity ();
+ [CCode (cname = "g_mime_certificate_get_issuer_name")]
+ public unowned string get_issuer_name ();
+ [CCode (cname = "g_mime_certificate_get_issuer_serial")]
+ public unowned string get_issuer_serial ();
+ [CCode (cname = "g_mime_certificate_get_key_id")]
+ public unowned string get_key_id ();
+ [CCode (cname = "g_mime_certificate_get_name")]
+ public unowned string get_name ();
+ [CCode (cname = "g_mime_certificate_get_pubkey_algo")]
+ public GMime.PubKeyAlgo get_pubkey_algo ();
+ [CCode (cname = "g_mime_certificate_get_trust")]
+ public GMime.Trust get_trust ();
+ [CCode (cname = "g_mime_certificate_get_user_id")]
+ public unowned string get_user_id ();
+ [CCode (cname = "g_mime_certificate_set_created")]
+ public void set_created (long created);
+ [CCode (cname = "g_mime_certificate_set_digest_algo")]
+ public void set_digest_algo (GMime.DigestAlgo algo);
+ [CCode (cname = "g_mime_certificate_set_email")]
+ public void set_email (string email);
+ [CCode (cname = "g_mime_certificate_set_expires")]
+ public void set_expires (long expires);
+ [CCode (cname = "g_mime_certificate_set_fingerprint")]
+ public void set_fingerprint (string fingerprint);
+ [CCode (cname = "g_mime_certificate_set_id_validity")]
+ public void set_id_validity (GMime.Validity validity);
+ [CCode (cname = "g_mime_certificate_set_issuer_name")]
+ public void set_issuer_name (string issuer_name);
+ [CCode (cname = "g_mime_certificate_set_issuer_serial")]
+ public void set_issuer_serial (string issuer_serial);
+ [CCode (cname = "g_mime_certificate_set_key_id")]
+ public void set_key_id (string key_id);
+ [CCode (cname = "g_mime_certificate_set_name")]
+ public void set_name (string name);
+ [CCode (cname = "g_mime_certificate_set_pubkey_algo")]
+ public void set_pubkey_algo (GMime.PubKeyAlgo algo);
+ [CCode (cname = "g_mime_certificate_set_trust")]
+ public void set_trust (GMime.Trust trust);
+ [CCode (cname = "g_mime_certificate_set_user_id")]
+ public void set_user_id (string user_id);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_certificate_list_get_type ()")]
+ public class CertificateList : GLib.Object {
+ public weak GLib.GenericArray<void*> array;
+ [CCode (cname = "g_mime_certificate_list_new", has_construct_function = false)]
+ public CertificateList ();
+ [CCode (cname = "g_mime_certificate_list_add")]
+ public int add (GMime.Certificate cert);
+ [CCode (cname = "g_mime_certificate_list_clear")]
+ public void clear ();
+ [CCode (cname = "g_mime_certificate_list_contains")]
+ public bool contains (GMime.Certificate cert);
+ [CCode (cname = "g_mime_certificate_list_get_certificate")]
+ public GMime.Certificate get_certificate (int index);
+ [CCode (cname = "g_mime_certificate_list_index_of")]
+ public int index_of (GMime.Certificate cert);
+ [CCode (cname = "g_mime_certificate_list_insert")]
+ public void insert (int index, GMime.Certificate cert);
+ [CCode (cname = "g_mime_certificate_list_length")]
+ public int length ();
+ [CCode (cname = "g_mime_certificate_list_remove")]
+ public bool remove (GMime.Certificate cert);
+ [CCode (cname = "g_mime_certificate_list_remove_at")]
+ public bool remove_at (int index);
+ [CCode (cname = "g_mime_certificate_list_set_certificate")]
+ public void set_certificate (int index, GMime.Certificate cert);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_content_disposition_get_type ()")]
+ public class ContentDisposition : GLib.Object {
+ public weak string disposition;
+ public weak GMime.ParamList @params;
+ [CCode (cname = "g_mime_content_disposition_new", has_construct_function = false)]
+ public ContentDisposition ();
+ [CCode (cname = "g_mime_content_disposition_encode")]
+ public string encode (GMime.FormatOptions? options);
+ [CCode (cname = "g_mime_content_disposition_get_disposition")]
+ public unowned string get_disposition ();
+ [CCode (cname = "g_mime_content_disposition_get_parameter")]
+ public unowned string get_parameter (string name);
+ [CCode (cname = "g_mime_content_disposition_get_parameters")]
+ public unowned GMime.ParamList get_parameters ();
+ [CCode (cname = "g_mime_content_disposition_is_attachment")]
+ public bool is_attachment ();
+ [CCode (cname = "g_mime_content_disposition_parse")]
+ public static GMime.ContentDisposition parse (GMime.ParserOptions? options, string str);
+ [CCode (cname = "g_mime_content_disposition_set_disposition")]
+ public void set_disposition (string value);
+ [CCode (cname = "g_mime_content_disposition_set_parameter")]
+ public void set_parameter (string name, string value);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_content_type_get_type ()")]
+ public class ContentType : GLib.Object {
+ public weak GMime.ParamList @params;
+ public weak string subtype;
+ public weak string type;
+ [CCode (cname = "g_mime_content_type_new", has_construct_function = false)]
+ public ContentType (string type, string subtype);
+ [CCode (cname = "g_mime_content_type_encode")]
+ public string encode (GMime.FormatOptions? options);
+ [CCode (cname = "g_mime_content_type_get_media_subtype")]
+ public unowned string get_media_subtype ();
+ [CCode (cname = "g_mime_content_type_get_media_type")]
+ public unowned string get_media_type ();
+ [CCode (cname = "g_mime_content_type_get_mime_type")]
+ public string get_mime_type ();
+ [CCode (cname = "g_mime_content_type_get_parameter")]
+ public unowned string get_parameter (string name);
+ [CCode (cname = "g_mime_content_type_get_parameters")]
+ public unowned GMime.ParamList get_parameters ();
+ [CCode (cname = "g_mime_content_type_is_type")]
+ public bool is_type (string type, string subtype);
+ [CCode (cname = "g_mime_content_type_parse")]
+ public static GMime.ContentType parse (GMime.ParserOptions? options, string str);
+ [CCode (cname = "g_mime_content_type_set_media_subtype")]
+ public void set_media_subtype (string subtype);
+ [CCode (cname = "g_mime_content_type_set_media_type")]
+ public void set_media_type (string type);
+ [CCode (cname = "g_mime_content_type_set_parameter")]
+ public void set_parameter (string name, string value);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_crypto_context_get_type ()")]
+ public class CryptoContext : GLib.Object {
+ public weak GMime.PasswordRequestFunc request_passwd;
+ [CCode (cname = "g_mime_crypto_context_new", has_construct_function = false)]
+ public CryptoContext (string protocol);
+ public virtual GMime.DecryptResult decrypt (GMime.DecryptFlags flags, string? session_key, GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
+ public virtual GMime.DigestAlgo digest_id (string name);
+ public virtual unowned string? digest_name (GMime.DigestAlgo digest);
+ public virtual int encrypt (bool sign, string? userid, GMime.EncryptFlags flags, GLib.GenericArray<string> recipients, GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
+ public virtual int export_keys (string keys, GMime.Stream ostream) throws GLib.Error;
+ public virtual unowned string? get_encryption_protocol ();
+ public virtual unowned string? get_key_exchange_protocol ();
+ public virtual unowned string? get_signature_protocol ();
+ public virtual int import_keys (GMime.Stream istream) throws GLib.Error;
+ public virtual int sign (bool detach, string userid, GMime.Stream istream, GMime.Stream ostream) throws GLib.Error;
+ public virtual GMime.SignatureList? verify (GMime.VerifyFlags flags, GMime.Stream istream, GMime.Stream? sigstream, GMime.Stream? ostream) throws GLib.Error;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_data_wrapper_get_type ()")]
+ public class DataWrapper : GLib.Object {
+ public GMime.ContentEncoding encoding;
+ public weak GMime.Stream stream;
+ [CCode (cname = "g_mime_data_wrapper_new", has_construct_function = false)]
+ public DataWrapper ();
+ [CCode (cname = "g_mime_data_wrapper_get_encoding")]
+ public GMime.ContentEncoding get_encoding ();
+ [CCode (cname = "g_mime_data_wrapper_get_stream")]
+ public unowned GMime.Stream get_stream ();
+ [CCode (cname = "g_mime_data_wrapper_set_encoding")]
+ public void set_encoding (GMime.ContentEncoding encoding);
+ [CCode (cname = "g_mime_data_wrapper_set_stream")]
+ public void set_stream (GMime.Stream stream);
+ [CCode (cname = "g_mime_data_wrapper_new_with_stream", has_construct_function = false)]
+ public DataWrapper.with_stream (GMime.Stream stream, GMime.ContentEncoding encoding);
+ public virtual ssize_t write_to_stream (GMime.Stream stream);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_decrypt_result_get_type ()")]
+ public class DecryptResult : GLib.Object {
+ public GMime.CipherAlgo cipher;
+ public GMime.DigestAlgo mdc;
+ public weak GMime.CertificateList recipients;
+ public weak string session_key;
+ public weak GMime.SignatureList signatures;
+ [CCode (cname = "g_mime_decrypt_result_new", has_construct_function = false)]
+ public DecryptResult ();
+ [CCode (cname = "g_mime_decrypt_result_get_cipher")]
+ public GMime.CipherAlgo get_cipher ();
+ [CCode (cname = "g_mime_decrypt_result_get_mdc")]
+ public GMime.DigestAlgo get_mdc ();
+ [CCode (cname = "g_mime_decrypt_result_get_recipients")]
+ public unowned GMime.CertificateList get_recipients ();
+ [CCode (cname = "g_mime_decrypt_result_get_session_key")]
+ public unowned string? get_session_key ();
+ [CCode (cname = "g_mime_decrypt_result_get_signatures")]
+ public unowned GMime.SignatureList? get_signatures ();
+ [CCode (cname = "g_mime_decrypt_result_set_cipher")]
+ public void set_cipher (GMime.CipherAlgo cipher);
+ [CCode (cname = "g_mime_decrypt_result_set_mdc")]
+ public void set_mdc (GMime.DigestAlgo mdc);
+ [CCode (cname = "g_mime_decrypt_result_set_recipients")]
+ public void set_recipients (GMime.CertificateList recipients);
+ [CCode (cname = "g_mime_decrypt_result_set_session_key")]
+ public void set_session_key (string? session_key);
+ [CCode (cname = "g_mime_decrypt_result_set_signatures")]
+ public void set_signatures (GMime.SignatureList signatures);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_get_type ()")]
+ public abstract class Filter : GLib.Object {
+ [CCode (array_length_cname = "backsize", array_length_type = "gsize")]
+ public uint8[] backbuf;
+ public size_t backlen;
+ public size_t backsize;
+ [CCode (array_length_cname = "outsize", array_length_type = "gsize")]
+ public weak uint8[] outbuf;
+ public size_t outpre;
+ [CCode (array_length = false)]
+ public weak uint8[] outptr;
+ [CCode (array_length = false)]
+ public uint8[] outreal;
+ public size_t outsize;
+ [CCode (has_construct_function = false)]
+ protected Filter ();
+ [CCode (cname = "g_mime_filter_backup")]
+ public void backup ([CCode (array_length_cname = "length", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] data);
+ public virtual void complete ([CCode (array_length_cname = "inlen", array_length_pos = 1.5, array_length_type = "gsize")] uint8[] inbuf, size_t prespace, [CCode (array_length_cname = "outlen", array_length_pos = 3.5, array_length_type = "gsize")] out unowned uint8[] outbuf, out size_t outprespace);
+ public virtual GMime.Filter copy ();
+ [CCode (cname = "g_mime_filter_filter")]
+ public virtual void filter ([CCode (array_length_cname = "inlen", array_length_pos = 1.5, array_length_type = "gsize")] uint8[] inbuf, size_t prespace, [CCode (array_length_cname = "outlen", array_length_pos = 3.5, array_length_type = "gsize")] out unowned uint8[] outbuf, out size_t outprespace);
+ public virtual void reset ();
+ [CCode (cname = "g_mime_filter_set_size")]
+ public void set_size (size_t size, bool keep);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_basic_get_type ()")]
+ public class FilterBasic : GMime.Filter {
+ public GMime.Encoding encoder;
+ [CCode (cname = "g_mime_filter_basic_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterBasic (GMime.ContentEncoding encoding, bool encode);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_best_get_type ()")]
+ public class FilterBest : GMime.Filter {
+ public uint count0;
+ public uint count8;
+ public GMime.FilterBestFlags flags;
+ [CCode (array_length = false)]
+ public weak uint frombuf[6];
+ public uint fromlen;
+ public uint hadfrom;
+ public uint linelen;
+ public uint maxline;
+ public uint midline;
+ public uint startline;
+ public uint total;
+ [CCode (cname = "g_mime_filter_best_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterBest (GMime.FilterBestFlags flags);
+ [CCode (cname = "g_mime_filter_best_encoding")]
+ public GMime.ContentEncoding encoding (GMime.EncodingConstraint constraint);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_charset_get_type ()")]
+ public class FilterCharset : GMime.Filter {
+ public weak string from_charset;
+ public weak string to_charset;
+ [CCode (cname = "g_mime_filter_charset_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterCharset (string from_charset, string to_charset);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_checksum_get_type ()")]
+ public class FilterChecksum : GMime.Filter {
+ public weak GLib.Checksum checksum;
+ [CCode (cname = "g_mime_filter_checksum_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterChecksum (GLib.ChecksumType type);
+ [CCode (cname = "g_mime_filter_checksum_get_digest")]
+ public size_t get_digest (uint8 digest, size_t len);
+ [CCode (cname = "g_mime_filter_checksum_get_string")]
+ public string get_string ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", lower_case_csuffix = "filter_dos2unix", type_id = "g_mime_filter_dos2unix_get_type ()")]
+ public class FilterDos2Unix : GMime.Filter {
+ public bool ensure_newline;
+ public char pc;
+ [CCode (cname = "g_mime_filter_dos2unix_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterDos2Unix (bool ensure_newline);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_enriched_get_type ()")]
+ public class FilterEnriched : GMime.Filter {
+ public uint32 flags;
+ public int nofill;
+ [CCode (cname = "g_mime_filter_enriched_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterEnriched (uint32 flags);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_from_get_type ()")]
+ public class FilterFrom : GMime.Filter {
+ public bool midline;
+ public GMime.FilterFromMode mode;
+ [CCode (cname = "g_mime_filter_from_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterFrom (GMime.FilterFromMode mode);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_gzip_get_type ()")]
+ public class FilterGZip : GMime.Filter {
+ public int level;
+ public GMime.FilterGZipMode mode;
+ [CCode (cname = "g_mime_filter_gzip_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterGZip (GMime.FilterGZipMode mode, int level);
+ [CCode (cname = "g_mime_filter_gzip_get_comment")]
+ [Version (since = "3.2")]
+ public unowned string get_comment ();
+ [CCode (cname = "g_mime_filter_gzip_get_filename")]
+ [Version (since = "3.2")]
+ public unowned string get_filename ();
+ [CCode (cname = "g_mime_filter_gzip_set_comment")]
+ [Version (since = "3.2")]
+ public void set_comment (string comment);
+ [CCode (cname = "g_mime_filter_gzip_set_filename")]
+ [Version (since = "3.2")]
+ public void set_filename (string filename);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_html_get_type ()")]
+ public class FilterHTML : GMime.Filter {
+ public uint32 citation_depth;
+ public uint32 colour;
+ public uint32 column;
+ public uint32 flags;
+ public uint32 pre_open;
+ public void* scanner;
+ [CCode (cname = "g_mime_filter_html_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterHTML (uint32 flags, uint32 colour);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", lower_case_csuffix = "filter_openpgp", type_id = "g_mime_filter_openpgp_get_type ()")]
+ [Version (since = "3.2")]
+ public class FilterOpenPGP : GMime.Filter {
+ [CCode (cname = "g_mime_filter_openpgp_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterOpenPGP ();
+ [CCode (cname = "g_mime_filter_openpgp_get_begin_offset")]
+ public int64 get_begin_offset ();
+ [CCode (cname = "g_mime_filter_openpgp_get_data_type")]
+ public GMime.OpenPGPData get_data_type ();
+ [CCode (cname = "g_mime_filter_openpgp_get_end_offset")]
+ public int64 get_end_offset ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_smtp_data_get_type ()")]
+ public class FilterSmtpData : GMime.Filter {
+ public bool bol;
+ [CCode (cname = "g_mime_filter_smtp_data_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterSmtpData ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_strip_get_type ()")]
+ public class FilterStrip : GMime.Filter {
+ [CCode (cname = "g_mime_filter_strip_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterStrip ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", lower_case_csuffix = "filter_unix2dos", type_id = "g_mime_filter_unix2dos_get_type ()")]
+ public class FilterUnix2Dos : GMime.Filter {
+ public bool ensure_newline;
+ public char pc;
+ [CCode (cname = "g_mime_filter_unix2dos_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterUnix2Dos (bool ensure_newline);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_windows_get_type ()")]
+ public class FilterWindows : GMime.Filter {
+ public weak string claimed_charset;
+ public bool is_windows;
+ [CCode (cname = "g_mime_filter_windows_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterWindows (string claimed_charset);
+ [CCode (cname = "g_mime_filter_windows_is_windows_charset")]
+ public bool is_windows_charset ();
+ [CCode (cname = "g_mime_filter_windows_real_charset")]
+ public unowned string real_charset ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_filter_yenc_get_type ()")]
+ public class FilterYenc : GMime.Filter {
+ public uint32 crc;
+ public bool encode;
+ public int part;
+ public uint32 pcrc;
+ public int state;
+ [CCode (cname = "g_mime_filter_yenc_new", has_construct_function = false, type = "GMimeFilter*")]
+ public FilterYenc (bool encode);
+ [CCode (cname = "g_mime_filter_yenc_get_crc")]
+ public uint32 get_crc ();
+ [CCode (cname = "g_mime_filter_yenc_get_pcrc")]
+ public uint32 get_pcrc ();
+ [CCode (cname = "g_mime_filter_yenc_set_crc")]
+ public void set_crc (uint32 crc);
+ [CCode (cname = "g_mime_filter_yenc_set_state")]
+ public void set_state (int state);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "g_mime_format_options_get_type ()")]
+ [Compact]
+ public class FormatOptions {
+ [CCode (cname = "g_mime_format_options_new", has_construct_function = false)]
+ public FormatOptions ();
+ [CCode (cname = "g_mime_format_options_add_hidden_header")]
+ public void add_hidden_header (string header);
+ [CCode (cname = "g_mime_format_options_clear_hidden_headers")]
+ public void clear_hidden_headers ();
+ [CCode (cname = "g_mime_format_options_clone")]
+ public GMime.FormatOptions clone ();
+ [CCode (cname = "g_mime_format_options_create_newline_filter")]
+ public GMime.Filter create_newline_filter (bool ensure_newline);
+ [CCode (cname = "g_mime_format_options_free")]
+ public void free ();
+ [CCode (cname = "g_mime_format_options_get_newline")]
+ public unowned string get_newline ();
+ [CCode (cname = "g_mime_format_options_get_newline_format")]
+ public GMime.NewLineFormat get_newline_format ();
+ [CCode (cname = "g_mime_format_options_get_param_encoding_method")]
+ public GMime.ParamEncodingMethod get_param_encoding_method ();
+ [CCode (cname = "g_mime_format_options_is_hidden_header")]
+ public bool is_hidden_header (string header);
+ [CCode (cname = "g_mime_format_options_remove_hidden_header")]
+ public void remove_hidden_header (string header);
+ [CCode (cname = "g_mime_format_options_set_newline_format")]
+ public void set_newline_format (GMime.NewLineFormat newline);
+ [CCode (cname = "g_mime_format_options_set_param_encoding_method")]
+ public void set_param_encoding_method (GMime.ParamEncodingMethod method);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_gpg_context_get_type ()")]
+ public class GpgContext : GMime.CryptoContext {
+ [CCode (cname = "g_mime_gpg_context_new", has_construct_function = false, type = "GMimeCryptoContext*")]
+ public GpgContext ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_header_get_type ()")]
+ public class Header : GLib.Object {
+ [CCode (has_construct_function = false)]
+ protected Header ();
+ [CCode (cname = "g_mime_header_format_addrlist")]
+ public string format_addrlist (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_content_disposition")]
+ public string format_content_disposition (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_content_type")]
+ public string format_content_type (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_default")]
+ public string format_default (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_message_id")]
+ public string format_message_id (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_received")]
+ public string format_received (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_format_references")]
+ public string format_references (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_get_name")]
+ public unowned string get_name ();
+ [CCode (cname = "g_mime_header_get_offset")]
+ public int64 get_offset ();
+ [CCode (cname = "g_mime_header_get_raw_name")]
+ public unowned string get_raw_name ();
+ [CCode (cname = "g_mime_header_get_raw_value")]
+ public unowned string get_raw_value ();
+ [CCode (cname = "g_mime_header_get_value")]
+ public unowned string get_value ();
+ [CCode (cname = "g_mime_header_set_raw_value")]
+ public void set_raw_value (string raw_value);
+ [CCode (cname = "g_mime_header_set_value")]
+ public void set_value (GMime.FormatOptions? options, string value, string charset);
+ [CCode (cname = "g_mime_header_write_to_stream")]
+ public ssize_t write_to_stream (GMime.FormatOptions? options, GMime.Stream stream);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_header_list_get_type ()")]
+ public class HeaderList : GLib.Object {
+ [CCode (cname = "g_mime_header_list_new", has_construct_function = false)]
+ public HeaderList (GMime.ParserOptions? options);
+ [CCode (cname = "g_mime_header_list_append")]
+ public void append (string name, string value, string charset);
+ [CCode (cname = "g_mime_header_list_clear")]
+ public void clear ();
+ [CCode (cname = "g_mime_header_list_contains")]
+ public bool contains (string name);
+ [CCode (cname = "g_mime_header_list_get_count")]
+ public int get_count ();
+ [CCode (cname = "g_mime_header_list_get_header")]
+ public unowned GMime.Header get_header (string name);
+ [CCode (cname = "g_mime_header_list_get_header_at")]
+ public unowned GMime.Header get_header_at (int index);
+ [CCode (cname = "g_mime_header_list_prepend")]
+ public void prepend (string name, string value, string charset);
+ [CCode (cname = "g_mime_header_list_remove")]
+ public bool remove (string name);
+ [CCode (cname = "g_mime_header_list_remove_at")]
+ public void remove_at (int index);
+ [CCode (cname = "g_mime_header_list_set")]
+ public void @set (string name, string value, string charset);
+ [CCode (cname = "g_mime_header_list_to_string")]
+ public string to_string (GMime.FormatOptions? options);
+ [CCode (cname = "g_mime_header_list_write_to_stream")]
+ public ssize_t write_to_stream (GMime.FormatOptions? options, GMime.Stream stream);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddress", type_id = "internet_address_get_type ()")]
+ public abstract class InternetAddress : GLib.Object {
+ public weak string charset;
+ public weak string name;
+ [CCode (has_construct_function = false)]
+ protected InternetAddress ();
+ [CCode (cname = "internet_address_get_charset")]
+ public unowned string? get_charset ();
+ [CCode (cname = "internet_address_get_name")]
+ public unowned string? get_name ();
+ [CCode (cname = "internet_address_set_charset")]
+ public void set_charset (string? charset);
+ [CCode (cname = "internet_address_set_name")]
+ public void set_name (string name);
+ [CCode (cname = "internet_address_to_string")]
+ public string to_new_string (GMime.FormatOptions? options, bool encode);
+ [NoWrapper]
+ public virtual void to_string (GMime.FormatOptions options, uint32 flags, size_t linelen, GLib.StringBuilder str);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressGroup", type_id = "internet_address_group_get_type ()")]
+ public class InternetAddressGroup : GMime.InternetAddress {
+ public weak GMime.InternetAddressList members;
+ [CCode (cname = "internet_address_group_new", has_construct_function = false, type = "InternetAddress*")]
+ public InternetAddressGroup (string name);
+ [CCode (cname = "internet_address_group_add_member")]
+ public int add_member (GMime.InternetAddress member);
+ [CCode (cname = "internet_address_group_get_members")]
+ public unowned GMime.InternetAddressList get_members ();
+ [CCode (cname = "internet_address_group_set_members")]
+ public void set_members (GMime.InternetAddressList members);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressList", type_id = "internet_address_list_get_type ()")]
+ public class InternetAddressList : GLib.Object {
+ public weak GLib.GenericArray<void*> array;
+ [CCode (cname = "internet_address_list_new", has_construct_function = false)]
+ public InternetAddressList ();
+ [CCode (cname = "internet_address_list_add")]
+ public int add (GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_append")]
+ public void append (GMime.InternetAddressList append);
+ [CCode (cname = "internet_address_list_clear")]
+ public void clear ();
+ [CCode (cname = "internet_address_list_contains")]
+ public bool contains (GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_encode")]
+ public void encode (GMime.FormatOptions? options, GLib.StringBuilder str);
+ [CCode (cname = "internet_address_list_get_address")]
+ public unowned GMime.InternetAddress get_address (int index);
+ [CCode (cname = "internet_address_list_index_of")]
+ public int index_of (GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_insert")]
+ public void insert (int index, GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_length")]
+ public int length ();
+ [CCode (cname = "internet_address_list_parse")]
+ public static GMime.InternetAddressList? parse (GMime.ParserOptions? options, string str);
+ [CCode (cname = "internet_address_list_prepend")]
+ public void prepend (GMime.InternetAddressList prepend);
+ [CCode (cname = "internet_address_list_remove")]
+ public bool remove (GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_remove_at")]
+ public bool remove_at (int index);
+ [CCode (cname = "internet_address_list_set_address")]
+ public void set_address (int index, GMime.InternetAddress ia);
+ [CCode (cname = "internet_address_list_to_string")]
+ public string? to_string (GMime.FormatOptions? options, bool encode);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "InternetAddressMailbox", type_id = "internet_address_mailbox_get_type ()")]
+ public class InternetAddressMailbox : GMime.InternetAddress {
+ public weak string addr;
+ public int at;
+ public weak string idn_addr;
+ [CCode (cname = "internet_address_mailbox_new", has_construct_function = false, type = "InternetAddress*")]
+ public InternetAddressMailbox (string name, string addr);
+ [CCode (cname = "internet_address_mailbox_get_addr")]
+ public unowned string get_addr ();
+ [CCode (cname = "internet_address_mailbox_get_idn_addr")]
+ public unowned string get_idn_addr ();
+ [CCode (cname = "internet_address_mailbox_set_addr")]
+ public void set_addr (string addr);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_message_get_type ()")]
+ public class Message : GMime.Object {
+ public weak GMime.InternetAddressList addrlists;
+ public weak GLib.DateTime date;
+ public weak string message_id;
+ public weak GMime.Object mime_part;
+ public weak string subject;
+ [CCode (cname = "g_mime_message_new", has_construct_function = false)]
+ public Message (bool pretty_headers);
+ [CCode (cname = "g_mime_message_add_mailbox")]
+ public void add_mailbox (GMime.AddressType type, string name, string addr);
+ [CCode (cname = "g_mime_message_foreach")]
+ public void @foreach (GMime.ObjectForeachFunc callback);
+ [CCode (cname = "g_mime_message_get_addresses")]
+ public unowned GMime.InternetAddressList get_addresses (GMime.AddressType type);
+ [CCode (cname = "g_mime_message_get_all_recipients")]
+ public GMime.InternetAddressList get_all_recipients ();
+ [CCode (cname = "g_mime_message_get_autocrypt_gossip_headers")]
+ public GMime.AutocryptHeaderList get_autocrypt_gossip_headers (GLib.DateTime now, GMime.DecryptFlags flags, string session_key) throws GLib.Error;
+ [CCode (cname = "g_mime_message_get_autocrypt_gossip_headers_from_inner_part")]
+ public GMime.AutocryptHeaderList get_autocrypt_gossip_headers_from_inner_part (GLib.DateTime now, GMime.Object inner_part);
+ [CCode (cname = "g_mime_message_get_autocrypt_header")]
+ public GMime.AutocryptHeader get_autocrypt_header (GLib.DateTime now);
+ [CCode (cname = "g_mime_message_get_bcc")]
+ public unowned GMime.InternetAddressList get_bcc ();
+ [CCode (cname = "g_mime_message_get_body")]
+ public unowned GMime.Object get_body ();
+ [CCode (cname = "g_mime_message_get_cc")]
+ public unowned GMime.InternetAddressList get_cc ();
+ [CCode (cname = "g_mime_message_get_date")]
+ public GLib.DateTime get_date ();
+ [CCode (cname = "g_mime_message_get_from")]
+ public unowned GMime.InternetAddressList get_from ();
+ [CCode (cname = "g_mime_message_get_message_id")]
+ public unowned string get_message_id ();
+ [CCode (cname = "g_mime_message_get_mime_part")]
+ public unowned GMime.Object? get_mime_part ();
+ [CCode (cname = "g_mime_message_get_reply_to")]
+ public unowned GMime.InternetAddressList get_reply_to ();
+ [CCode (cname = "g_mime_message_get_sender")]
+ public unowned GMime.InternetAddressList get_sender ();
+ [CCode (cname = "g_mime_message_get_subject")]
+ public unowned string get_subject ();
+ [CCode (cname = "g_mime_message_get_to")]
+ public unowned GMime.InternetAddressList get_to ();
+ [CCode (cname = "g_mime_message_partial_split_message")]
+ public GMime.Message? partial_split_message (size_t max_size, out size_t nparts);
+ [CCode (cname = "g_mime_message_set_date")]
+ public void set_date (GLib.DateTime date);
+ [CCode (cname = "g_mime_message_set_message_id")]
+ public void set_message_id (string message_id);
+ [CCode (cname = "g_mime_message_set_mime_part")]
+ public void set_mime_part (GMime.Object mime_part);
+ [CCode (cname = "g_mime_message_set_subject")]
+ public void set_subject (string subject, string charset);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_message_part_get_type ()")]
+ public class MessagePart : GMime.Object {
+ public weak GMime.Message message;
+ [CCode (cname = "g_mime_message_part_new", has_construct_function = false)]
+ public MessagePart (string subtype);
+ [CCode (cname = "g_mime_message_part_get_message")]
+ public unowned GMime.Message get_message ();
+ [CCode (cname = "g_mime_message_part_set_message")]
+ public void set_message (GMime.Message message);
+ [CCode (cname = "g_mime_message_part_new_with_message", has_construct_function = false)]
+ public MessagePart.with_message (string subtype, GMime.Message message);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_message_partial_get_type ()")]
+ public class MessagePartial : GMime.Part {
+ public weak string id;
+ public int number;
+ public int total;
+ [CCode (cname = "g_mime_message_partial_new", has_construct_function = false)]
+ public MessagePartial (string id, int number, int total);
+ [CCode (cname = "g_mime_message_partial_get_id")]
+ public unowned string get_id ();
+ [CCode (cname = "g_mime_message_partial_get_number")]
+ public int get_number ();
+ [CCode (cname = "g_mime_message_partial_get_total")]
+ public int get_total ();
+ [CCode (cname = "g_mime_message_partial_reconstruct_message")]
+ public static GMime.Message reconstruct_message (GMime.MessagePartial partials, size_t num);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_multipart_get_type ()")]
+ public class Multipart : GMime.Object {
+ public weak string boundary;
+ public weak GLib.GenericArray<void*> children;
+ public weak string epilogue;
+ public weak string prologue;
+ [CCode (cname = "g_mime_multipart_new", has_construct_function = false)]
+ public Multipart ();
+ [CCode (cname = "g_mime_multipart_add")]
+ public virtual void add (GMime.Object part);
+ public virtual void clear ();
+ public virtual bool contains (GMime.Object part);
+ [CCode (cname = "g_mime_multipart_foreach")]
+ public void @foreach (GMime.ObjectForeachFunc callback);
+ public virtual unowned string get_boundary ();
+ public virtual int get_count ();
+ [CCode (cname = "g_mime_multipart_get_epilogue")]
+ public unowned string get_epilogue ();
+ public virtual unowned GMime.Object get_part (int index);
+ [CCode (cname = "g_mime_multipart_get_prologue")]
+ public unowned string get_prologue ();
+ [CCode (cname = "g_mime_multipart_get_subpart_from_content_id")]
+ public unowned GMime.Object get_subpart_from_content_id (string content_id);
+ public virtual int index_of (GMime.Object part);
+ public virtual void insert (int index, GMime.Object part);
+ public virtual bool remove (GMime.Object part);
+ public virtual GMime.Object remove_at (int index);
+ [CCode (cname = "g_mime_multipart_replace")]
+ public GMime.Object replace (int index, GMime.Object replacement);
+ public virtual void set_boundary (string boundary);
+ [CCode (cname = "g_mime_multipart_set_epilogue")]
+ public void set_epilogue (string epilogue);
+ [CCode (cname = "g_mime_multipart_set_prologue")]
+ public void set_prologue (string prologue);
+ [CCode (cname = "g_mime_multipart_new_with_subtype", has_construct_function = false)]
+ public Multipart.with_subtype (string subtype);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_multipart_encrypted_get_type ()")]
+ public class MultipartEncrypted : GMime.Multipart {
+ [CCode (cname = "g_mime_multipart_encrypted_new", has_construct_function = false)]
+ public MultipartEncrypted ();
+ [CCode (cname = "g_mime_multipart_encrypted_decrypt")]
+ public GMime.Object? decrypt (GMime.DecryptFlags flags, string session_key, out GMime.DecryptResult result) throws GLib.Error;
+ [CCode (cname = "g_mime_multipart_encrypted_encrypt")]
+ public static GMime.MultipartEncrypted? encrypt (GMime.CryptoContext ctx, GMime.Object entity, bool sign, string? userid, GMime.EncryptFlags flags, GLib.GenericArray<string> recipients) throws GLib.Error;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_multipart_signed_get_type ()")]
+ public class MultipartSigned : GMime.Multipart {
+ [CCode (cname = "g_mime_multipart_signed_new", has_construct_function = false)]
+ public MultipartSigned ();
+ [CCode (cname = "g_mime_multipart_signed_sign")]
+ public static GMime.MultipartSigned? sign (GMime.CryptoContext ctx, GMime.Object entity, string userid) throws GLib.Error;
+ [CCode (cname = "g_mime_multipart_signed_verify")]
+ public GMime.SignatureList? verify (GMime.VerifyFlags flags) throws GLib.Error;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_object_get_type ()")]
+ public abstract class Object : GLib.Object {
+ public weak string content_id;
+ public weak GMime.ContentType content_type;
+ public weak GMime.ContentDisposition disposition;
+ public weak GMime.HeaderList headers;
+ [CCode (cname = "g_mime_object_new", has_construct_function = false)]
+ public Object (GMime.ParserOptions? options, GMime.ContentType content_type);
+ [CCode (cname = "g_mime_object_append_header")]
+ public void append_header (string header, string value, string charset);
+ public virtual void encode (GMime.EncodingConstraint constraint);
+ [CCode (cname = "g_mime_object_get_content_disposition")]
+ public unowned GMime.ContentDisposition get_content_disposition ();
+ [CCode (cname = "g_mime_object_get_content_disposition_parameter")]
+ public unowned string get_content_disposition_parameter (string name);
+ [CCode (cname = "g_mime_object_get_content_id")]
+ public unowned string get_content_id ();
+ [CCode (cname = "g_mime_object_get_content_type")]
+ public unowned GMime.ContentType get_content_type ();
+ [CCode (cname = "g_mime_object_get_content_type_parameter")]
+ public unowned string? get_content_type_parameter (string name);
+ [CCode (cname = "g_mime_object_get_disposition")]
+ public unowned string get_disposition ();
+ [CCode (cname = "g_mime_object_get_header")]
+ public unowned string get_header (string header);
+ [CCode (cname = "g_mime_object_get_header_list")]
+ public unowned GMime.HeaderList get_header_list ();
+ public virtual string get_headers (GMime.FormatOptions? options);
+ [NoWrapper]
+ public virtual void header_added (GMime.Header header);
+ [NoWrapper]
+ public virtual void header_changed (GMime.Header header);
+ [NoWrapper]
+ public virtual void header_removed (GMime.Header header);
+ [NoWrapper]
+ public virtual void headers_cleared ();
+ [CCode (cname = "g_mime_object_prepend_header")]
+ public void prepend_header (string header, string value, string charset);
+ [CCode (cname = "g_mime_object_register_type")]
+ public static void register_type (string type, string subtype, GLib.Type object_type);
+ [CCode (cname = "g_mime_object_remove_header")]
+ public bool remove_header (string header);
+ [CCode (cname = "g_mime_object_set_content_disposition")]
+ public void set_content_disposition (GMime.ContentDisposition disposition);
+ [CCode (cname = "g_mime_object_set_content_disposition_parameter")]
+ public void set_content_disposition_parameter (string name, string value);
+ [CCode (cname = "g_mime_object_set_content_id")]
+ public void set_content_id (string content_id);
+ [CCode (cname = "g_mime_object_set_content_type")]
+ public virtual void set_content_type (GMime.ContentType content_type);
+ [CCode (cname = "g_mime_object_set_content_type_parameter")]
+ public void set_content_type_parameter (string name, string value);
+ [CCode (cname = "g_mime_object_set_disposition")]
+ public void set_disposition (string disposition);
+ [CCode (cname = "g_mime_object_set_header")]
+ public void set_header (string header, string value, string charset);
+ [CCode (cname = "g_mime_object_to_string")]
+ public string to_string (GMime.FormatOptions? options);
+ [CCode (cname = "g_mime_object_new_type", has_construct_function = false)]
+ public Object.type (GMime.ParserOptions? options, string type, string subtype);
+ [CCode (cname = "g_mime_object_type_registry_init")]
+ public static void type_registry_init ();
+ [CCode (cname = "g_mime_object_type_registry_shutdown")]
+ public static void type_registry_shutdown ();
+ [NoWrapper]
+ public virtual ssize_t write_to_stream (GMime.FormatOptions options, bool content_only, GMime.Stream stream);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_param_get_type ()")]
+ public class Param : GLib.Object {
+ public weak string charset;
+ public weak string lang;
+ public GMime.ParamEncodingMethod method;
+ public weak string name;
+ public weak string value;
+ [CCode (has_construct_function = false)]
+ protected Param ();
+ [CCode (cname = "g_mime_param_get_charset")]
+ public unowned string get_charset ();
+ [CCode (cname = "g_mime_param_get_encoding_method")]
+ public GMime.ParamEncodingMethod get_encoding_method ();
+ [CCode (cname = "g_mime_param_get_lang")]
+ public unowned string get_lang ();
+ [CCode (cname = "g_mime_param_get_name")]
+ public unowned string get_name ();
+ [CCode (cname = "g_mime_param_get_value")]
+ public unowned string get_value ();
+ [CCode (cname = "g_mime_param_set_charset")]
+ public void set_charset (string charset);
+ [CCode (cname = "g_mime_param_set_encoding_method")]
+ public void set_encoding_method (GMime.ParamEncodingMethod method);
+ [CCode (cname = "g_mime_param_set_lang")]
+ public void set_lang (string lang);
+ [CCode (cname = "g_mime_param_set_value")]
+ public void set_value (string value);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_param_list_get_type ()")]
+ public class ParamList : GLib.Object {
+ [CCode (cname = "g_mime_param_list_new", has_construct_function = false)]
+ public ParamList ();
+ [CCode (cname = "g_mime_param_list_clear")]
+ public void clear ();
+ [CCode (cname = "g_mime_param_list_encode")]
+ public void encode (GMime.FormatOptions options, bool fold, GLib.StringBuilder str);
+ [CCode (cname = "g_mime_param_list_get_parameter")]
+ public unowned GMime.Param get_parameter (string name);
+ [CCode (cname = "g_mime_param_list_get_parameter_at")]
+ public unowned GMime.Param get_parameter_at (int index);
+ [CCode (cname = "g_mime_param_list_length")]
+ public int length ();
+ [CCode (cname = "g_mime_param_list_parse")]
+ public static GMime.ParamList parse (GMime.ParserOptions options, string str);
+ [CCode (cname = "g_mime_param_list_remove")]
+ public bool remove (string name);
+ [CCode (cname = "g_mime_param_list_remove_at")]
+ public bool remove_at (int index);
+ [CCode (cname = "g_mime_param_list_set_parameter")]
+ public void set_parameter (string name, string value);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_parser_get_type ()")]
+ public class Parser : GLib.Object {
+ [CCode (cname = "g_mime_parser_new", has_construct_function = false)]
+ public Parser ();
+ [CCode (cname = "g_mime_parser_construct_message")]
+ public GMime.Message? construct_message (GMime.ParserOptions? options);
+ [CCode (cname = "g_mime_parser_construct_part")]
+ public GMime.Object? construct_part (GMime.ParserOptions? options);
+ [CCode (cname = "g_mime_parser_eos")]
+ public bool eos ();
+ [CCode (cname = "g_mime_parser_get_format")]
+ public GMime.Format get_format ();
+ [CCode (cname = "g_mime_parser_get_headers_begin")]
+ public int64 get_headers_begin ();
+ [CCode (cname = "g_mime_parser_get_headers_end")]
+ public int64 get_headers_end ();
+ [CCode (cname = "g_mime_parser_get_mbox_marker")]
+ public string? get_mbox_marker ();
+ [CCode (cname = "g_mime_parser_get_mbox_marker_offset")]
+ public int64 get_mbox_marker_offset ();
+ [CCode (cname = "g_mime_parser_get_persist_stream")]
+ public bool get_persist_stream ();
+ [CCode (cname = "g_mime_parser_get_respect_content_length")]
+ public bool get_respect_content_length ();
+ [CCode (cname = "g_mime_parser_init_with_stream")]
+ public void init_with_stream (GMime.Stream stream);
+ [CCode (cname = "g_mime_parser_set_format")]
+ public void set_format (GMime.Format format);
+ [CCode (cname = "g_mime_parser_set_persist_stream")]
+ public void set_persist_stream (bool persist);
+ [CCode (cname = "g_mime_parser_set_respect_content_length")]
+ public void set_respect_content_length (bool respect_content_length);
+ [CCode (cname = "g_mime_parser_tell")]
+ public int64 tell ();
+ [CCode (cname = "g_mime_parser_new_with_stream", has_construct_function = false)]
+ public Parser.with_stream (GMime.Stream stream);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "g_mime_parser_options_get_type ()")]
+ [Compact]
+ public class ParserOptions {
+ [CCode (cname = "g_mime_parser_options_new", has_construct_function = false)]
+ public ParserOptions ();
+ [CCode (cname = "g_mime_parser_options_clone")]
+ public GMime.ParserOptions clone ();
+ [CCode (cname = "g_mime_parser_options_free")]
+ public void free ();
+ [CCode (cname = "g_mime_parser_options_get_address_compliance_mode")]
+ public GMime.RfcComplianceMode get_address_compliance_mode ();
+ [CCode (cname = "g_mime_parser_options_get_allow_addresses_without_domain")]
+ public bool get_allow_addresses_without_domain ();
+ [CCode (array_length = false, array_null_terminated = true, cname = "g_mime_parser_options_get_fallback_charsets")]
+ public unowned string[] get_fallback_charsets ();
+ [CCode (cname = "g_mime_parser_options_get_parameter_compliance_mode")]
+ public GMime.RfcComplianceMode get_parameter_compliance_mode ();
+ [CCode (cname = "g_mime_parser_options_get_rfc2047_compliance_mode")]
+ public GMime.RfcComplianceMode get_rfc2047_compliance_mode ();
+ [CCode (cname = "g_mime_parser_options_set_address_compliance_mode")]
+ public void set_address_compliance_mode (GMime.RfcComplianceMode mode);
+ [CCode (cname = "g_mime_parser_options_set_allow_addresses_without_domain")]
+ public void set_allow_addresses_without_domain (bool allow);
+ [CCode (cname = "g_mime_parser_options_set_fallback_charsets")]
+ public void set_fallback_charsets (string charsets);
+ [CCode (cname = "g_mime_parser_options_set_parameter_compliance_mode")]
+ public void set_parameter_compliance_mode (GMime.RfcComplianceMode mode);
+ [CCode (cname = "g_mime_parser_options_set_rfc2047_compliance_mode")]
+ public void set_rfc2047_compliance_mode (GMime.RfcComplianceMode mode);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_part_get_type ()")]
+ public class Part : GMime.Object {
+ public weak GMime.DataWrapper content;
+ public weak string content_description;
+ public weak string content_location;
+ public weak string content_md5;
+ public GMime.ContentEncoding encoding;
+ public GMime.OpenPGPData openpgp;
+ [CCode (cname = "g_mime_part_new", has_construct_function = false)]
+ public Part ();
+ [CCode (cname = "g_mime_part_get_best_content_encoding")]
+ public GMime.ContentEncoding get_best_content_encoding (GMime.EncodingConstraint constraint);
+ [CCode (cname = "g_mime_part_get_content")]
+ public unowned GMime.DataWrapper get_content ();
+ [CCode (cname = "g_mime_part_get_content_description")]
+ public unowned string get_content_description ();
+ [CCode (cname = "g_mime_part_get_content_encoding")]
+ public GMime.ContentEncoding get_content_encoding ();
+ [CCode (cname = "g_mime_part_get_content_id")]
+ public unowned string get_content_id ();
+ [CCode (cname = "g_mime_part_get_content_location")]
+ public unowned string get_content_location ();
+ [CCode (cname = "g_mime_part_get_content_md5")]
+ public unowned string get_content_md5 ();
+ [CCode (cname = "g_mime_part_get_filename")]
+ public unowned string get_filename ();
+ [CCode (cname = "g_mime_part_get_openpgp_data")]
+ public GMime.OpenPGPData get_openpgp_data ();
+ [CCode (cname = "g_mime_part_is_attachment")]
+ public bool is_attachment ();
+ [CCode (cname = "g_mime_part_openpgp_decrypt")]
+ public GMime.DecryptResult? openpgp_decrypt (GMime.DecryptFlags flags, string? session_key) throws GLib.Error;
+ [CCode (cname = "g_mime_part_openpgp_encrypt")]
+ public bool openpgp_encrypt (bool sign, string? userid, GMime.EncryptFlags flags, GLib.GenericArray<string> recipients) throws GLib.Error;
+ [CCode (cname = "g_mime_part_openpgp_sign")]
+ public bool openpgp_sign (string userid) throws GLib.Error;
+ [CCode (cname = "g_mime_part_openpgp_verify")]
+ public GMime.SignatureList? openpgp_verify (GMime.VerifyFlags flags) throws GLib.Error;
+ [CCode (cname = "g_mime_part_set_content")]
+ public virtual void set_content (GMime.DataWrapper content);
+ [CCode (cname = "g_mime_part_set_content_description")]
+ public void set_content_description (string description);
+ [CCode (cname = "g_mime_part_set_content_encoding")]
+ public void set_content_encoding (GMime.ContentEncoding encoding);
+ [CCode (cname = "g_mime_part_set_content_id")]
+ public void set_content_id (string content_id);
+ [CCode (cname = "g_mime_part_set_content_location")]
+ public void set_content_location (string content_location);
+ [CCode (cname = "g_mime_part_set_content_md5")]
+ public void set_content_md5 (string content_md5);
+ [CCode (cname = "g_mime_part_set_filename")]
+ public void set_filename (string filename);
+ [CCode (cname = "g_mime_part_set_openpgp_data")]
+ public void set_openpgp_data (GMime.OpenPGPData data);
+ [CCode (cname = "g_mime_part_verify_content_md5")]
+ public bool verify_content_md5 ();
+ [CCode (cname = "g_mime_part_new_with_type", has_construct_function = false)]
+ public Part.with_type (string type, string subtype);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "g_mime_part_iter_get_type ()")]
+ [Compact]
+ public class PartIter {
+ [CCode (cname = "g_mime_part_iter_new", has_construct_function = false)]
+ public PartIter (GMime.Object toplevel);
+ [CCode (cname = "g_mime_part_iter_clone")]
+ public GMime.PartIter clone ();
+ [CCode (cname = "g_mime_part_iter_free")]
+ public void free ();
+ [CCode (cname = "g_mime_part_iter_get_current")]
+ public unowned GMime.Object get_current ();
+ [CCode (cname = "g_mime_part_iter_get_parent")]
+ public unowned GMime.Object get_parent ();
+ [CCode (cname = "g_mime_part_iter_get_path")]
+ public string get_path ();
+ [CCode (cname = "g_mime_part_iter_get_toplevel")]
+ public unowned GMime.Object get_toplevel ();
+ [CCode (cname = "g_mime_part_iter_is_valid")]
+ public bool is_valid ();
+ [CCode (cname = "g_mime_part_iter_jump_to")]
+ public bool jump_to (string path);
+ [CCode (cname = "g_mime_part_iter_next")]
+ public bool next ();
+ [CCode (cname = "g_mime_part_iter_prev")]
+ public bool prev ();
+ [CCode (cname = "g_mime_part_iter_remove")]
+ public bool remove ();
+ [CCode (cname = "g_mime_part_iter_replace")]
+ public bool replace (GMime.Object replacement);
+ [CCode (cname = "g_mime_part_iter_reset")]
+ public void reset ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_pkcs7_context_get_type ()")]
+ public class Pkcs7Context : GMime.CryptoContext {
+ [CCode (cname = "g_mime_pkcs7_context_new", has_construct_function = false, type = "GMimeCryptoContext*")]
+ public Pkcs7Context ();
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", copy_function = "g_boxed_copy", free_function = "g_boxed_free", type_id = "g_mime_references_get_type ()")]
+ [Compact]
+ public class References {
+ public weak GLib.GenericArray<void*> array;
+ [CCode (cname = "g_mime_references_new", has_construct_function = false)]
+ public References ();
+ [CCode (cname = "g_mime_references_append")]
+ public void append (string msgid);
+ [CCode (cname = "g_mime_references_clear")]
+ public void clear ();
+ [CCode (cname = "g_mime_references_copy")]
+ public GMime.References copy ();
+ [CCode (cname = "g_mime_references_free")]
+ public void free ();
+ [CCode (cname = "g_mime_references_get_message_id")]
+ public unowned string get_message_id (int index);
+ [CCode (cname = "g_mime_references_length")]
+ public int length ();
+ [CCode (cname = "g_mime_references_set_message_id")]
+ public void set_message_id (int index, string msgid);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_signature_get_type ()")]
+ public class Signature : GLib.Object {
+ public weak GMime.Certificate cert;
+ public long created;
+ public long expires;
+ public GMime.SignatureStatus status;
+ [CCode (cname = "g_mime_signature_new", has_construct_function = false)]
+ public Signature ();
+ [CCode (cname = "g_mime_signature_get_certificate")]
+ public unowned GMime.Certificate get_certificate ();
+ [CCode (cname = "g_mime_signature_get_created")]
+ public long get_created ();
+ [CCode (cname = "g_mime_signature_get_expires")]
+ public long get_expires ();
+ [CCode (cname = "g_mime_signature_get_status")]
+ public GMime.SignatureStatus get_status ();
+ [CCode (cname = "g_mime_signature_set_certificate")]
+ public void set_certificate (GMime.Certificate cert);
+ [CCode (cname = "g_mime_signature_set_created")]
+ public void set_created (long created);
+ [CCode (cname = "g_mime_signature_set_expires")]
+ public void set_expires (long expires);
+ [CCode (cname = "g_mime_signature_set_status")]
+ public void set_status (GMime.SignatureStatus status);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_signature_list_get_type ()")]
+ public class SignatureList : GLib.Object {
+ [CCode (cname = "g_mime_signature_list_new", has_construct_function = false)]
+ public SignatureList ();
+ [CCode (cname = "g_mime_signature_list_add")]
+ public int add (GMime.Signature sig);
+ [CCode (cname = "g_mime_signature_list_clear")]
+ public void clear ();
+ [CCode (cname = "g_mime_signature_list_contains")]
+ public bool contains (GMime.Signature sig);
+ [CCode (cname = "g_mime_signature_list_get_signature")]
+ public unowned GMime.Signature get_signature (int index);
+ [CCode (cname = "g_mime_signature_list_index_of")]
+ public int index_of (GMime.Signature sig);
+ [CCode (cname = "g_mime_signature_list_insert")]
+ public void insert (int index, GMime.Signature sig);
+ [CCode (cname = "g_mime_signature_list_length")]
+ public int length ();
+ [CCode (cname = "g_mime_signature_list_remove")]
+ public bool remove (GMime.Signature sig);
+ [CCode (cname = "g_mime_signature_list_remove_at")]
+ public bool remove_at (int index);
+ [CCode (cname = "g_mime_signature_list_set_signature")]
+ public void set_signature (int index, GMime.Signature sig);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_get_type ()")]
+ public abstract class Stream : GLib.Object {
+ [CCode (has_construct_function = false)]
+ protected Stream ();
+ [CCode (cname = "g_mime_stream_buffer_gets")]
+ public ssize_t buffer_gets (string buf, size_t max);
+ [CCode (cname = "g_mime_stream_buffer_readln")]
+ public void buffer_readln (GLib.ByteArray buffer);
+ public virtual int close ();
+ [CCode (cname = "g_mime_stream_construct")]
+ public void @construct (int64 start, int64 end);
+ public virtual bool eos ();
+ public virtual int flush ();
+ public virtual int64 length ();
+ public virtual ssize_t read ([CCode (array_length_cname = "len", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] buf);
+ public virtual int reset ();
+ public virtual int64 seek (int64 offset, GMime.SeekWhence whence);
+ [CCode (cname = "g_mime_stream_set_bounds")]
+ public void set_bounds (int64 start, int64 end);
+ public virtual GMime.Stream substream (int64 start, int64 end);
+ public virtual int64 tell ();
+ public virtual ssize_t write (string buf, size_t len);
+ [CCode (cname = "g_mime_stream_write_string")]
+ public ssize_t write_string (string str);
+ [CCode (cname = "g_mime_stream_write_to_stream")]
+ public int64 write_to_stream (GMime.Stream dest);
+ [CCode (cname = "g_mime_stream_writev")]
+ public int64 writev (GMime.StreamIOVector vector, size_t count);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_buffer_get_type ()")]
+ public class StreamBuffer : GMime.Stream {
+ public weak string bufend;
+ public weak string buffer;
+ public size_t buflen;
+ public weak string bufptr;
+ public GMime.StreamBufferMode mode;
+ public weak GMime.Stream source;
+ [CCode (cname = "g_mime_stream_buffer_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamBuffer (GMime.Stream source, GMime.StreamBufferMode mode);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_cat_get_type ()")]
+ public class StreamCat : GMime.Stream {
+ public void* current;
+ public void* sources;
+ [CCode (cname = "g_mime_stream_cat_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamCat ();
+ [CCode (cname = "g_mime_stream_cat_add_source")]
+ public int add_source (GMime.Stream source);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_file_get_type ()")]
+ public class StreamFile : GMime.Stream {
+ public void* fp;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_file_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamFile (void* fp);
+ [CCode (cname = "g_mime_stream_file_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_file_open")]
+ public static GMime.Stream open (string path, string mode) throws GLib.Error;
+ [CCode (cname = "g_mime_stream_file_set_owner")]
+ public void set_owner (bool owner);
+ [CCode (cname = "g_mime_stream_file_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
+ public StreamFile.with_bounds (void* fp, int64 start, int64 end);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_filter_get_type ()")]
+ public class StreamFilter : GMime.Stream {
+ public bool owner;
+ public weak GMime.Stream source;
+ [CCode (cname = "g_mime_stream_filter_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamFilter (GMime.Stream stream);
+ [CCode (cname = "g_mime_stream_filter_add")]
+ public int add (GMime.Filter filter);
+ [CCode (cname = "g_mime_stream_filter_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_filter_remove")]
+ public void remove (int id);
+ [CCode (cname = "g_mime_stream_filter_set_owner")]
+ public void set_owner (bool owner);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_fs_get_type ()")]
+ public class StreamFs : GMime.Stream {
+ public bool eos;
+ public int fd;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_fs_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamFs (int fd);
+ [CCode (cname = "g_mime_stream_fs_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_fs_open")]
+ public static GMime.Stream open (string path, int flags, int mode) throws GLib.Error;
+ [CCode (cname = "g_mime_stream_fs_set_owner")]
+ public void set_owner (bool owner);
+ [CCode (cname = "g_mime_stream_fs_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
+ public StreamFs.with_bounds (int fd, int64 start, int64 end);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_gio_get_type ()")]
+ public class StreamGIO : GMime.Stream {
+ public bool eos;
+ public weak GLib.File file;
+ public weak GLib.InputStream istream;
+ public weak GLib.OutputStream ostream;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_gio_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamGIO (GLib.File file);
+ [CCode (cname = "g_mime_stream_gio_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_gio_set_owner")]
+ public void set_owner (bool owner);
+ [CCode (cname = "g_mime_stream_gio_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
+ public StreamGIO.with_bounds (GLib.File file, int64 start, int64 end);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_mem_get_type ()")]
+ public class StreamMem : GMime.Stream {
+ public weak GLib.ByteArray buffer;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_mem_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamMem ();
+ [CCode (cname = "g_mime_stream_mem_get_byte_array")]
+ public unowned GLib.ByteArray get_byte_array ();
+ [CCode (cname = "g_mime_stream_mem_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_mem_set_byte_array")]
+ public void set_byte_array (GLib.ByteArray array);
+ [CCode (cname = "g_mime_stream_mem_set_owner")]
+ public void set_owner (bool owner);
+ [CCode (cname = "g_mime_stream_mem_new_with_buffer", has_construct_function = false, type = "GMimeStream*")]
+ public StreamMem.with_buffer ([CCode (array_length_cname = "len", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] buffer);
+ [CCode (cname = "g_mime_stream_mem_new_with_byte_array", has_construct_function = false, type = "GMimeStream*")]
+ public StreamMem.with_byte_array (GLib.ByteArray array);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_mmap_get_type ()")]
+ public class StreamMmap : GMime.Stream {
+ public bool eos;
+ public int fd;
+ public weak string map;
+ public size_t maplen;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_mmap_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamMmap (int fd, int prot, int flags);
+ [CCode (cname = "g_mime_stream_mmap_get_owner")]
+ [Version (since = "3.2")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_mmap_set_owner")]
+ [Version (since = "3.2")]
+ public void set_owner (bool owner);
+ [CCode (cname = "g_mime_stream_mmap_new_with_bounds", has_construct_function = false, type = "GMimeStream*")]
+ public StreamMmap.with_bounds (int fd, int prot, int flags, int64 start, int64 end);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_null_get_type ()")]
+ public class StreamNull : GMime.Stream {
+ public bool count_newlines;
+ public size_t newlines;
+ public size_t written;
+ [CCode (cname = "g_mime_stream_null_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamNull ();
+ [CCode (cname = "g_mime_stream_null_get_count_newlines")]
+ public bool get_count_newlines ();
+ [CCode (cname = "g_mime_stream_null_set_count_newlines")]
+ public void set_count_newlines (bool count);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_stream_pipe_get_type ()")]
+ public class StreamPipe : GMime.Stream {
+ public bool eos;
+ public int fd;
+ public bool owner;
+ [CCode (cname = "g_mime_stream_pipe_new", has_construct_function = false, type = "GMimeStream*")]
+ public StreamPipe (int fd);
+ [CCode (cname = "g_mime_stream_pipe_get_owner")]
+ public bool get_owner ();
+ [CCode (cname = "g_mime_stream_pipe_set_owner")]
+ public void set_owner (bool owner);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", type_id = "g_mime_text_part_get_type ()")]
+ public class TextPart : GMime.Part {
+ [CCode (cname = "g_mime_text_part_new", has_construct_function = false)]
+ public TextPart ();
+ [CCode (cname = "g_mime_text_part_get_charset")]
+ public unowned string get_charset ();
+ [CCode (cname = "g_mime_text_part_get_text")]
+ public string get_text ();
+ [CCode (cname = "g_mime_text_part_set_charset")]
+ public void set_charset (string charset);
+ [CCode (cname = "g_mime_text_part_set_text")]
+ public void set_text (string text);
+ [CCode (cname = "g_mime_text_part_new_with_subtype", has_construct_function = false)]
+ public TextPart.with_subtype (string subtype);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", has_type_id = false)]
+ public struct Charset {
+ public uint mask;
+ public uint level;
+ [CCode (cname = "g_mime_charset_best_name")]
+ public unowned string? best_name ();
+ [CCode (cname = "g_mime_charset_can_encode")]
+ public bool can_encode (string charset, string text, size_t len);
+ [CCode (cname = "g_mime_charset_init")]
+ public void init ();
+ [CCode (cname = "g_mime_charset_step")]
+ public void step (string inbuf, size_t inlen);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", has_type_id = false)]
+ public struct Encoding {
+ public GMime.ContentEncoding encoding;
+ [CCode (array_length = false)]
+ public weak uint uubuf[60];
+ public bool encode;
+ public uint32 save;
+ public int state;
+ [CCode (cname = "g_mime_encoding_flush")]
+ public size_t flush (string inbuf, size_t inlen, string outbuf);
+ [CCode (cname = "g_mime_encoding_init_decode")]
+ public void init_decode (GMime.ContentEncoding encoding);
+ [CCode (cname = "g_mime_encoding_init_encode")]
+ public void init_encode (GMime.ContentEncoding encoding);
+ [CCode (cname = "g_mime_encoding_outlen")]
+ public size_t outlen (size_t inlen);
+ [CCode (cname = "g_mime_encoding_reset")]
+ public void reset ();
+ [CCode (cname = "g_mime_encoding_step")]
+ public size_t step (string inbuf, size_t inlen, string outbuf);
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", has_type_id = false)]
+ [Version (since = "3.2")]
+ public struct OpenPGPMarker {
+ public weak string marker;
+ public size_t len;
+ public GMime.OpenPGPState before;
+ public GMime.OpenPGPState after;
+ public bool is_end_marker;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", has_type_id = false)]
+ public struct StreamIOVector {
+ public void* data;
+ public size_t len;
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_ADDRESS_TYPE_", has_type_id = false)]
+ public enum AddressType {
+ SENDER,
+ FROM,
+ REPLY_TO,
+ TO,
+ CC,
+ BCC
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_AUTOCRYPT_PREFER_ENCRYPT_", has_type_id = false)]
+ public enum AutocryptPreferEncrypt {
+ NONE,
+ MUTUAL
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_CIPHER_ALGO_", has_type_id = false)]
+ public enum CipherAlgo {
+ DEFAULT,
+ IDEA,
+ @3DES,
+ CAST5,
+ BLOWFISH,
+ AES,
+ AES192,
+ AES256,
+ TWOFISH,
+ CAMELLIA128,
+ CAMELLIA192,
+ CAMELLIA256
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_CONTENT_ENCODING_", has_type_id = false)]
+ public enum ContentEncoding {
+ DEFAULT,
+ @7BIT,
+ @8BIT,
+ BINARY,
+ BASE64,
+ QUOTEDPRINTABLE,
+ UUENCODE
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_DECRYPT_", has_type_id = false)]
+ [Flags]
+ public enum DecryptFlags {
+ NONE,
+ EXPORT_SESSION_KEY
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_DIGEST_ALGO_", has_type_id = false)]
+ public enum DigestAlgo {
+ DEFAULT,
+ MD5,
+ SHA1,
+ RIPEMD160,
+ MD2,
+ TIGER192,
+ HAVAL5160,
+ SHA256,
+ SHA384,
+ SHA512,
+ SHA224,
+ MD4,
+ CRC32,
+ CRC32_RFC1510,
+ CRC32_RFC2440
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_ENCODING_CONSTRAINT_", has_type_id = false)]
+ public enum EncodingConstraint {
+ @7BIT,
+ @8BIT,
+ BINARY
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_ENCRYPT_", has_type_id = false)]
+ public enum EncryptFlags {
+ NONE,
+ ALWAYS_TRUST,
+ NO_COMPRESS,
+ SYMMETRIC,
+ THROW_KEYIDS
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_BEST_", has_type_id = false)]
+ [Flags]
+ public enum FilterBestFlags {
+ CHARSET,
+ ENCODING
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_FROM_MODE_", has_type_id = false)]
+ public enum FilterFromMode {
+ DEFAULT,
+ ESCAPE,
+ ARMOR
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FILTER_GZIP_MODE_", has_type_id = false)]
+ public enum FilterGZipMode {
+ ZIP,
+ UNZIP
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_FORMAT_", has_type_id = false)]
+ public enum Format {
+ MESSAGE,
+ MBOX,
+ MMDF
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_NEWLINE_FORMAT_", has_type_id = false)]
+ public enum NewLineFormat {
+ UNIX,
+ DOS
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_OPENPGP_DATA_", has_type_id = false)]
+ public enum OpenPGPData {
+ NONE,
+ ENCRYPTED,
+ SIGNED,
+ PUBLIC_KEY,
+ PRIVATE_KEY
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_OPENPGP_", has_type_id = false)]
+ [Flags]
+ [Version (since = "3.2")]
+ public enum OpenPGPState {
+ NONE,
+ BEGIN_PGP_MESSAGE,
+ END_PGP_MESSAGE,
+ BEGIN_PGP_SIGNED_MESSAGE,
+ BEGIN_PGP_SIGNATURE,
+ END_PGP_SIGNATURE,
+ BEGIN_PGP_PUBLIC_KEY_BLOCK,
+ END_PGP_PUBLIC_KEY_BLOCK,
+ BEGIN_PGP_PRIVATE_KEY_BLOCK,
+ END_PGP_PRIVATE_KEY_BLOCK
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_PARAM_ENCODING_METHOD_", has_type_id = false)]
+ public enum ParamEncodingMethod {
+ DEFAULT,
+ RFC2231,
+ RFC2047
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_", has_type_id = false)]
+ public enum ParserWarning {
+ WARN_DUPLICATED_HEADER,
+ WARN_DUPLICATED_PARAMETER,
+ WARN_UNENCODED_8BIT_HEADER,
+ WARN_INVALID_CONTENT_TYPE,
+ WARN_INVALID_RFC2047_HEADER_VALUE,
+ WARN_INVALID_PARAMETER,
+ WARN_MALFORMED_MULTIPART,
+ WARN_TRUNCATED_MESSAGE,
+ WARN_MALFORMED_MESSAGE,
+ CRIT_INVALID_HEADER_NAME,
+ CRIT_CONFLICTING_HEADER,
+ CRIT_CONFLICTING_PARAMETER,
+ CRIT_MULTIPART_WITHOUT_BOUNDARY
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_PUBKEY_ALGO_", has_type_id = false)]
+ public enum PubKeyAlgo {
+ DEFAULT,
+ RSA,
+ RSA_E,
+ RSA_S,
+ ELG_E,
+ DSA,
+ ECC,
+ ELG,
+ ECDSA,
+ ECDH,
+ EDDSA
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_RFC_COMPLIANCE_", has_type_id = false)]
+ public enum RfcComplianceMode {
+ LOOSE,
+ STRICT
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_SECURE_MIME_TYPE_", has_type_id = false)]
+ public enum SecureMimeType {
+ COMPRESSED_DATA,
+ ENVELOPED_DATA,
+ SIGNED_DATA,
+ CERTS_ONLY,
+ UNKNOWN
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_STREAM_SEEK_", has_type_id = false)]
+ public enum SeekWhence {
+ SET,
+ CUR,
+ END
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_SIGNATURE_STATUS_", has_type_id = false)]
+ public enum SignatureStatus {
+ VALID,
+ GREEN,
+ RED,
+ KEY_REVOKED,
+ KEY_EXPIRED,
+ SIG_EXPIRED,
+ KEY_MISSING,
+ CRL_MISSING,
+ CRL_TOO_OLD,
+ BAD_POLICY,
+ SYS_ERROR,
+ TOFU_CONFLICT
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_STREAM_BUFFER_BLOCK_", has_type_id = false)]
+ public enum StreamBufferMode {
+ READ,
+ WRITE
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_TRUST_", has_type_id = false)]
+ public enum Trust {
+ UNKNOWN,
+ UNDEFINED,
+ NEVER,
+ MARGINAL,
+ FULL,
+ ULTIMATE
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_VALIDITY_", has_type_id = false)]
+ public enum Validity {
+ UNKNOWN,
+ UNDEFINED,
+ NEVER,
+ MARGINAL,
+ FULL,
+ ULTIMATE
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", cprefix = "GMIME_VERIFY_", has_type_id = false)]
+ public enum VerifyFlags {
+ [CCode (cname = "GMIME_VERIFY_NONE")]
+ VERIFY_NONE
+ }
+ [CCode (cheader_filename = "gmime/gmime.h", has_target = false)]
+ public delegate string HeaderRawValueFormatter (GMime.Header header, GMime.FormatOptions options, string value, string charset);
+ [CCode (cheader_filename = "gmime/gmime.h", instance_pos = 2.9)]
+ public delegate void ObjectForeachFunc (GMime.Object parent, GMime.Object part);
+ [CCode (cheader_filename = "gmime/gmime.h", instance_pos = 4.9)]
+ public delegate void ParserHeaderRegexFunc (GMime.Parser parser, string header, string value, int64 offset);
+ [CCode (cheader_filename = "gmime/gmime.h", instance_pos = 3.9)]
+ public delegate void ParserWarningFunc (int64 offset, GMime.ParserWarning errcode, string item);
+ [CCode (cheader_filename = "gmime/gmime.h", has_target = false)]
+ public delegate bool PasswordRequestFunc (GMime.CryptoContext ctx, string user_id, string prompt, bool reprompt, GMime.Stream response) throws GLib.Error;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_BINARY_AGE")]
+ public const int BINARY_AGE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_DISPOSITION_ATTACHMENT")]
+ public const string DISPOSITION_ATTACHMENT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_DISPOSITION_INLINE")]
+ public const string DISPOSITION_INLINE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_ENRICHED_IS_RICHTEXT")]
+ public const int FILTER_ENRICHED_IS_RICHTEXT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_BLOCKQUOTE_CITATION")]
+ public const int FILTER_HTML_BLOCKQUOTE_CITATION;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_CITE")]
+ public const int FILTER_HTML_CITE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_CONVERT_ADDRESSES")]
+ public const int FILTER_HTML_CONVERT_ADDRESSES;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_CONVERT_NL")]
+ public const int FILTER_HTML_CONVERT_NL;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_CONVERT_SPACES")]
+ public const int FILTER_HTML_CONVERT_SPACES;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_CONVERT_URLS")]
+ public const int FILTER_HTML_CONVERT_URLS;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_ESCAPE_8BIT")]
+ public const int FILTER_HTML_ESCAPE_8BIT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_MARK_CITATION")]
+ public const int FILTER_HTML_MARK_CITATION;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_FILTER_HTML_PRE")]
+ public const int FILTER_HTML_PRE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_INTERFACE_AGE")]
+ public const int INTERFACE_AGE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_MAJOR_VERSION")]
+ public const int MAJOR_VERSION;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_MICRO_VERSION")]
+ public const int MICRO_VERSION;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_MINOR_VERSION")]
+ public const int MINOR_VERSION;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_SIGNATURE_STATUS_ERROR_MASK")]
+ public const int SIGNATURE_STATUS_ERROR_MASK;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_UUDECODE_STATE_BEGIN")]
+ public const int UUDECODE_STATE_BEGIN;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_UUDECODE_STATE_END")]
+ public const int UUDECODE_STATE_END;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_UUDECODE_STATE_INIT")]
+ public const int UUDECODE_STATE_INIT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_UUDECODE_STATE_MASK")]
+ public const int UUDECODE_STATE_MASK;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_BEGIN")]
+ public const int YDECODE_STATE_BEGIN;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_DECODE")]
+ public const int YDECODE_STATE_DECODE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_END")]
+ public const int YDECODE_STATE_END;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_EOLN")]
+ public const int YDECODE_STATE_EOLN;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_ESCAPE")]
+ public const int YDECODE_STATE_ESCAPE;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_INIT")]
+ public const int YDECODE_STATE_INIT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YDECODE_STATE_PART")]
+ public const int YDECODE_STATE_PART;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YENCODE_CRC_INIT")]
+ public const int YENCODE_CRC_INIT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "GMIME_YENCODE_STATE_INIT")]
+ public const int YENCODE_STATE_INIT;
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_best")]
+ public static unowned string? charset_best (string inbuf, size_t inlen);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_canon_name")]
+ public static unowned string charset_canon_name (string charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_iconv_name")]
+ public static unowned string charset_iconv_name (string charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_iso_to_windows")]
+ public static unowned string charset_iso_to_windows (string isocharset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_language")]
+ public static unowned string? charset_language (string charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_locale_name")]
+ public static unowned string charset_locale_name ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_map_init")]
+ public static void charset_map_init ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_map_shutdown")]
+ public static void charset_map_shutdown ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_charset_name")]
+ public static unowned string charset_name (string charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_check_version")]
+ public static bool check_version (uint major, uint minor, uint micro);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_content_encoding_from_string")]
+ public static GMime.ContentEncoding content_encoding_from_string (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_content_encoding_to_string")]
+ public static unowned string content_encoding_to_string (GMime.ContentEncoding encoding);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_base64_decode_step")]
+ public static size_t encoding_base64_decode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_base64_encode_close")]
+ public static size_t encoding_base64_encode_close (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_base64_encode_step")]
+ public static size_t encoding_base64_encode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_quoted_decode_step")]
+ public static size_t encoding_quoted_decode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_quoted_encode_close")]
+ public static size_t encoding_quoted_encode_close (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_quoted_encode_step")]
+ public static size_t encoding_quoted_encode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_uudecode_step")]
+ public static size_t encoding_uudecode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_uuencode_close")]
+ public static size_t encoding_uuencode_close (uint8 inbuf, size_t inlen, uint8 outbuf, uint8 uubuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_encoding_uuencode_step")]
+ public static size_t encoding_uuencode_step (uint8 inbuf, size_t inlen, uint8 outbuf, uint8 uubuf, int state, uint32 save);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_format_options_get_default")]
+ public static GMime.FormatOptions format_options_get_default ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_locale_to_utf8")]
+ public static string iconv_locale_to_utf8 (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_locale_to_utf8_length")]
+ public static string iconv_locale_to_utf8_length (string str, size_t n);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_utf8_to_locale")]
+ public static string iconv_utf8_to_locale (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_iconv_utf8_to_locale_length")]
+ public static string iconv_utf8_to_locale_length (string str, size_t n);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_init")]
+ public static void init ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_locale_charset")]
+ public static unowned string locale_charset ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_locale_language")]
+ public static unowned string? locale_language ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_parser_options_get_default")]
+ public static GMime.ParserOptions parser_options_get_default ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_references_parse")]
+ public static GMime.References references_parse (GMime.ParserOptions? options, string text);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_shutdown")]
+ public static void shutdown ();
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_best_encoding")]
+ public static GMime.ContentEncoding utils_best_encoding ([CCode (array_length_cname = "len", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] text);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_decode_8bit")]
+ public static string utils_decode_8bit (GMime.ParserOptions? options, [CCode (array_length_cname = "len", array_length_pos = 2.1, array_length_type = "gsize")] uint8[] text);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_decode_message_id")]
+ public static string utils_decode_message_id (string message_id);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_generate_message_id")]
+ public static string utils_generate_message_id (string fqdn);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_date")]
+ public static GLib.DateTime? utils_header_decode_date (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_phrase")]
+ public static string utils_header_decode_phrase (GMime.ParserOptions? options, string phrase);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_decode_text")]
+ public static string utils_header_decode_text (GMime.ParserOptions? options, string text);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_encode_phrase")]
+ public static string utils_header_encode_phrase (GMime.FormatOptions? options, string phrase, string? charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_encode_text")]
+ public static string utils_header_encode_text (GMime.FormatOptions? options, string text, string? charset);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_format_date")]
+ public static string utils_header_format_date (GLib.DateTime date);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_header_unfold")]
+ public static string utils_header_unfold (string value);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_quote_string")]
+ public static string utils_quote_string (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_structured_header_fold")]
+ public static string utils_structured_header_fold (GMime.ParserOptions? options, GMime.FormatOptions? format, string header);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_text_is_8bit")]
+ public static bool utils_text_is_8bit ([CCode (array_length_cname = "len", array_length_pos = 1.1, array_length_type = "gsize")] uint8[] text);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_unquote_string")]
+ public static void utils_unquote_string (string str);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_utils_unstructured_header_fold")]
+ public static string utils_unstructured_header_fold (GMime.ParserOptions? options, GMime.FormatOptions? format, string header);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_ydecode_step")]
+ public static size_t ydecode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 pcrc, uint32 crc);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_yencode_close")]
+ public static size_t yencode_close (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 pcrc, uint32 crc);
+ [CCode (cheader_filename = "gmime/gmime.h", cname = "g_mime_yencode_step")]
+ public static size_t yencode_step (uint8 inbuf, size_t inlen, uint8 outbuf, int state, uint32 pcrc, uint32 crc);
+}