diff options
Diffstat (limited to 'mono')
-rw-r--r-- | mono/AssemblyInfo.cs.in | 4 | ||||
-rw-r--r-- | mono/CertificateCollection.custom | 243 | ||||
-rw-r--r-- | mono/DataWrapper.custom | 25 | ||||
-rw-r--r-- | mono/GMime.metadata | 367 | ||||
-rw-r--r-- | mono/Global.custom | 25 | ||||
-rw-r--r-- | mono/Header.cs | 21 | ||||
-rw-r--r-- | mono/HeaderEnumerator.cs | 113 | ||||
-rw-r--r-- | mono/HeaderList.custom | 56 | ||||
-rw-r--r-- | mono/InternetAddress.custom | 4 | ||||
-rw-r--r-- | mono/InternetAddressList.custom | 281 | ||||
-rw-r--r-- | mono/Makefile.am | 120 | ||||
-rw-r--r-- | mono/Makefile.in | 618 | ||||
-rw-r--r-- | mono/Message.custom | 87 | ||||
-rw-r--r-- | mono/Multipart.custom | 248 | ||||
-rw-r--r-- | mono/Object.custom | 8 | ||||
-rw-r--r-- | mono/SignatureCollection.custom | 243 | ||||
-rw-r--r-- | mono/Stream.custom | 4 | ||||
-rw-r--r-- | mono/StreamWrapper.cs | 187 | ||||
-rw-r--r-- | mono/gmime-api.raw | 3267 | ||||
-rw-r--r-- | mono/gmime-sharp.dll.config.in | 3 | ||||
-rw-r--r-- | mono/gmime-sharp.pc.in | 11 | ||||
-rw-r--r-- | mono/gmime-sharp.snk | bin | 0 -> 596 bytes | |||
-rw-r--r-- | mono/sources.xml | 9 |
23 files changed, 5944 insertions, 0 deletions
diff --git a/mono/AssemblyInfo.cs.in b/mono/AssemblyInfo.cs.in new file mode 100644 index 0000000..54d23f9 --- /dev/null +++ b/mono/AssemblyInfo.cs.in @@ -0,0 +1,4 @@ +using System.Reflection; +using System.Runtime.CompilerServices; + +[assembly:AssemblyVersion("@API_VERSION@")] diff --git a/mono/CertificateCollection.custom b/mono/CertificateCollection.custom new file mode 100644 index 0000000..518e512 --- /dev/null +++ b/mono/CertificateCollection.custom @@ -0,0 +1,243 @@ +#region Native Methods + [DllImport("gmime")] + static extern int g_mime_certificate_list_length (IntPtr list); + + [DllImport("gmime")] + static extern void g_mime_certificate_list_clear (IntPtr list); + + [DllImport("gmime")] + static extern int g_mime_certificate_list_add (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern void g_mime_certificate_list_insert (IntPtr list, int index, IntPtr ia); + + [DllImport("gmime")] + static extern bool g_mime_certificate_list_remove (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern bool g_mime_certificate_list_remove_at (IntPtr list, int index); + + [DllImport("gmime")] + static extern bool g_mime_certificate_list_contains (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern int g_mime_certificate_list_index_of (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern IntPtr g_mime_certificate_list_get_certificate (IntPtr list, int index); + + [DllImport("gmime")] + static extern void g_mime_certificate_list_set_certificate (IntPtr list, int index, IntPtr ia); +#endregion + + Exception CannotAdd (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot add objects of type '{0}' to a CertificateCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotInsert (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot insert objects of type '{0}' into a CertificateCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotRemove (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot remove objects of type '{0}' from a CertificateCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotSet (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot set objects of type '{0}' on an CertificateCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + public int Count { + get { return g_mime_certificate_list_length (Handle); } + } + + public bool IsFixedSize { + get { return false; } + } + + public bool IsReadOnly { + get { return false; } + } + + public bool IsSynchronized { + get { return false; } + } + + public object SyncRoot { + get { return this; } + } + + public int Add (Certificate cert) + { + if (cert == null) + throw CannotAdd (cert); + + return g_mime_certificate_list_add (Handle, cert.Handle); + } + + int IList.Add (object value) + { + Certificate cert = value as Certificate; + + if (cert == null) + throw CannotAdd (value); + + return Add (cert); + } + + public void Clear () + { + g_mime_certificate_list_clear (Handle); + } + + public bool Contains (Certificate cert) + { + if (cert == null) + return false; + + return g_mime_certificate_list_contains (Handle, cert.Handle); + } + + bool IList.Contains (object value) + { + return Contains (value as Certificate); + } + + public void CopyTo (Array array, int index) + { + if (array == null) + throw new ArgumentNullException ("array"); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + int n = Count; + + for (int i = 0; i < n; i++) + array.SetValue (((IList) this)[i], index + i); + } + + public IEnumerator GetEnumerator () + { + int n = Count; + + for (int i = 0; i < n; i++) + yield return this[i]; + + yield break; + } + + public int IndexOf (Certificate cert) + { + if (cert == null) + return -1; + + return g_mime_certificate_list_index_of (Handle, cert.Handle); + } + + int IList.IndexOf (object value) + { + return IndexOf (value as Certificate); + } + + public void Insert (int index, Certificate cert) + { + if (cert == null) + throw CannotInsert (cert); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_certificate_list_insert (Handle, index, cert.Handle); + } + + void IList.Insert (int index, object value) + { + Certificate cert = value as Certificate; + + if (cert == null) + throw CannotInsert (value); + + Insert (index, cert); + } + + public void Remove (Certificate cert) + { + if (cert == null) + throw CannotRemove (cert); + + g_mime_certificate_list_remove (Handle, cert.Handle); + } + + void IList.Remove (object value) + { + Certificate cert = value as Certificate; + + if (cert == null) + throw CannotRemove (value); + + Remove (cert); + } + + public void RemoveAt (int index) + { + if (index < 0 || index >= Count) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_certificate_list_remove_at (Handle, index); + } + + public Certificate this[int index] { + get { + IntPtr raw = g_mime_certificate_list_get_certificate (Handle, index); + + if (raw == IntPtr.Zero) + return null; + + return GLib.Object.GetObject (raw) as Certificate; + } + + set { + if (value == null) + throw CannotSet (value); + + g_mime_certificate_list_set_certificate (Handle, index, value.Handle); + } + } + + object IList.this[int index] { + get { + return this[index]; + } + + set { + this[index] = value as Certificate; + } + } diff --git a/mono/DataWrapper.custom b/mono/DataWrapper.custom new file mode 100644 index 0000000..6365f3d --- /dev/null +++ b/mono/DataWrapper.custom @@ -0,0 +1,25 @@ +public StreamWrapper Stream { + get { + GMime.Stream gmime_stream = GMimeStream; + GMime.StreamFilter filtered_stream; + FilterBasic filter; + + switch (Encoding) { + case ContentEncoding.QuotedPrintable: + case ContentEncoding.UuEncode: + case ContentEncoding.Base64: + filtered_stream = new GMime.StreamFilter (gmime_stream); + filter = new FilterBasic (Encoding, false); + filtered_stream.Add (filter); + gmime_stream.Dispose (); + filter.Dispose (); + + gmime_stream = filtered_stream; + break; + default: + break; + } + + return new StreamWrapper (gmime_stream); + } +} diff --git a/mono/GMime.metadata b/mono/GMime.metadata new file mode 100644 index 0000000..3002c45 --- /dev/null +++ b/mono/GMime.metadata @@ -0,0 +1,367 @@ +<?xml version="1.0"?> +<metadata> + <!-- We need to remap size_t and ssize_t --> + <attr path="/api/namespace/*/field[@type='size_t']" name="type">guint32</attr> + <attr path="/api/namespace/*/*/return-type[@type='size_t']" name="type">guint32</attr> + <attr path="/api/namespace/*/*/*/parameter[@type='size_t']" name="type">guint32</attr> + <attr path="/api/namespace/*/*/*/parameter[@type='size_t*']" name="type">guint32*</attr> + + <!--<attr path="/api/namespace/*/field[@type='ssize_t']" name="type">gint32</attr>--> + <attr path="/api/namespace/*/*/return-type[@type='ssize_t']" name="type">gint32</attr> + <!--<attr path="/api/namespace/*/*/*/parameter[@type='ssize_t']" name="type">gint32</attr>--> + <!--<attr path="/api/namespace/*/*/*/parameter[@type='ssize_t*']" name="type">gint32*</attr>--> + + <!-- Global / Locale --> + <attr path="/api/namespace/class[@name='Global']/method[@name='UserCharsets']" name="name">GetUserCharsets</attr> + <attr path="/api/namespace/class[@name='Locale']/method[@name='Charset']" name="name">GetCharset</attr> + <attr path="/api/namespace/class[@name='Locale']/method[@name='Language']" name="name">GetLanguage</attr> + + <!-- Callback Functions --> + <remove-node path="/api/namespace/callback[@name='HeaderForeachFunc']"/> + + <!-- Charset --> + + <!-- Common --> + <!-- Remove the g_mime_strcase_hash/equal functions - they don't need to be public --> + <!--<remove-node path="/api/namespace/class[@name='Strcase']"/>--> + + <!-- Events --> + <!-- Remove the g_mime_event* functions - they don't need to be public --> + <remove-node path="/api/namespace/struct[@name='Event']"/> + <remove-node path="/api/namespace/callback[@name='EventCallback']"/> + + <!-- ContentDisposition --> + <remove-node path="/api/namespace/object[@cname='GMimeContentDisposition']/field[@cname='param_hash']"/> + <remove-node path="/api/namespace/object[@cname='GMimeContentDisposition']/field[@cname='params']"/> + + <!-- ContentEncoding --> + <!--<attr path="/api/namespace/class[@name='Content']/method[@name='EncodingFromString']" name="name">ContentEncodingFromString</attr> + <attr path="/api/namespace/class[@name='Content']/method[@name='EncodingToString']" name="name">ContentEncodingToString</attr> + <move-node path="/api/namespace/class[@name='Content']/method[@name='ContentEncodingFromString']">/api/namespace/class[@name='Utils']</move-node> + <move-node path="/api/namespace/class[@name='Content']/method[@name='ContentEncodingToString']">/api/namespace/class[@name='Utils']</move-node>--> + <remove-node path="/api/namespace/class[@name='Content']"/> + + <!-- ContentType --> + <remove-node path="/api/namespace/object[@cname='GMimeContentType']/field[@cname='param_hash']"/> + <remove-node path="/api/namespace/object[@cname='GMimeContentType']/field[@cname='params']"/> + <remove-node path="/api/namespace/object[@cname='GMimeContentType']/field[@cname='subtype']"/> + <remove-node path="/api/namespace/object[@cname='GMimeContentType']/field[@cname='type']"/> + + <!-- Certificate --> + <attr path="/api/namespace/object[@cname='GMimeCertificate']/method[@name='GetCreated']" name="name">GetCreationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeCertificate']/method[@name='SetCreated']" name="name">SetCreationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeCertificate']/method[@name='GetExpires']" name="name">GetExpirationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeCertificate']/method[@name='SetExpires']" name="name">SetExpirationDate</attr> + + <!-- CertificateList --> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/field[@cname='array']"/> + <attr path="/api/namespace/object[@name='CertificateList']" name="name">CertificateCollection</attr> + <!-- We're going to implement the IList interface --> + <add-node path="/api/namespace/object[@cname='GMimeCertificateList']"> + <implements> + <interface name="IList"/> + </implements> + </add-node> + <!-- Remove methods we're going to implement manually in GMimeCertificateList.custom --> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Add']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Clear']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Contains']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='IndexOf']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Insert']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Length']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='Remove']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='RemoveAt']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='GetCertificate']"/> + <remove-node path="/api/namespace/object[@cname='GMimeCertificateList']/method[@name='SetCertificate']"/> + + <!-- Signature --> + <attr path="/api/namespace/object[@cname='GMimeSignature']/method[@name='GetCreated']" name="name">GetCreationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeSignature']/method[@name='SetCreated']" name="name">SetCreationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeSignature']/method[@name='GetExpires']" name="name">GetExpirationDate</attr> + <attr path="/api/namespace/object[@cname='GMimeSignature']/method[@name='SetExpires']" name="name">SetExpirationDate</attr> + + <!-- SignatureList --> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/field[@cname='array']"/> + <attr path="/api/namespace/object[@name='SignatureList']" name="name">SignatureCollection</attr> + <!-- We're going to implement the IList interface --> + <add-node path="/api/namespace/object[@cname='GMimeSignatureList']"> + <implements> + <interface name="IList"/> + </implements> + </add-node> + <!-- Remove methods we're going to implement manually in GMimeSignatureList.custom --> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Add']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Clear']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Contains']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='IndexOf']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Insert']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Length']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='Remove']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='RemoveAt']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='GetSignature']"/> + <remove-node path="/api/namespace/object[@cname='GMimeSignatureList']/method[@name='SetSignature']"/> + + <!-- CryptoContext --> + + <!-- DataWrapper --> + <attr path="/api/namespace/object[@cname='GMimeDataWrapper']/method[@name='GetStream']" name="name">GetGMimeStream</attr> + <attr path="/api/namespace/object[@cname='GMimeDataWrapper']/method[@name='SetStream']" name="name">SetGMimeStream</attr> + + <!-- Encoding --> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='inbuf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='inbuf']" name="array">true</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='inlen']" name="name">n_inbuf</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='uubuf']" name="type">guint8*</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='uubuf']" name="array">true</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='outbuf']" name="type">guint8*</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='outbuf']" name="array">true</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='state']" name="pass_as">ref</attr> + <attr path="/api/namespace/struct[@name='Encoding']/*/*/parameter[@name='save']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Yencode']/method[@cname='g_mime_yencode_close']" name="name">yEncodeClose</attr> + <attr path="/api/namespace/class[@name='Yencode']/method[@cname='g_mime_yencode_step']" name="name">yEncodeStep</attr> + <attr path="/api/namespace/class[@name='Global']/method[@cname='g_mime_ydecode_step']" name="name">yDecodeStep</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='inbuf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='inbuf']" name="array">true</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='inlen']" name="name">n_inbuf</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='outbuf']" name="type">guint8*</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='outbuf']" name="array">true</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='state']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='pcrc']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Yencode']/*/*/parameter[@name='crc']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='inbuf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='inbuf']" name="array">true</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='inlen']" name="name">n_inbuf</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='outbuf']" name="type">guint8*</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='outbuf']" name="array">true</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='state']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='pcrc']" name="pass_as">ref</attr> + <attr path="/api/namespace/class[@name='Global']/*/*/parameter[@name='crc']" name="pass_as">ref</attr> + <move-node path="/api/namespace/class[@name='Yencode']/method[@name='yEncodeClose']">/api/namespace/struct[@name='Encoding']</move-node> + <move-node path="/api/namespace/class[@name='Yencode']/method[@name='yEncodeStep']">/api/namespace/struct[@name='Encoding']</move-node> + <move-node path="/api/namespace/class[@name='Global']/method[@name='yDecodeStep']">/api/namespace/struct[@name='Encoding']</move-node> + + <!-- Enumerations --> + <attr path="/api/namespace/enum/member[@cname='GMIME_ENCODING_CONSTRAINT_7BIT']" name="name">SevenBit</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_ENCODING_CONSTRAINT_8BIT']" name="name">EightBit</attr> + + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_DEFAULT']" name="name">Default</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_7BIT']" name="name">SevenBit</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_8BIT']" name="name">EightBit</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_BINARY']" name="name">Binary</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_BASE64']" name="name">Base64</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_QUOTEDPRINTABLE']" name="name">QuotedPrintable</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_CONTENT_ENCODING_UUENCODE']" name="name">UuEncode</attr> + + <attr path="/api/namespace/enum/member[@cname='GMIME_STREAM_SEEK_SET']" name="value">0</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_STREAM_SEEK_CUR']" name="value">1</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_STREAM_SEEK_END']" name="value">2</attr> + + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_NONE']" name="name">None</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_EXPSIG']" name="name">ExpiredSignature</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_NO_PUBKEY']" name="name">NoPublicKey</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_EXPKEYSIG']" name="name">ExpiredSignatureKey</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_REVKEYSIG']" name="name">RevokedSignatureKey</attr> + <attr path="/api/namespace/enum/member[@cname='GMIME_SIGNATURE_ERROR_UNSUPP_ALGO']" name="name">UnsupportedAlgorithm</attr> + + <!-- Filter --> + <attr path="/api/namespace/object[@cname='GMimeFilter']" name="abstract">1</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/method[@cname='g_mime_filter_filter']" name="name">ApplyFilter</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/*/*/parameter[@name='inbuf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/*/*/parameter[@name='inbuf']" name="array">true</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/*/*/parameter[@name='inlen']" name="name">n_inbuf</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/*/*/parameter[@name='outbuf']" name="type">guint8**</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/*/*/parameter[@name='outbuf']" name="array">true</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/method[@name='Backup']/*/parameter[@name='data']" name="name">buf</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/method[@name='Backup']/*/parameter[@name='buf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/method[@name='Backup']/*/parameter[@name='buf']" name="array">true</attr> + <attr path="/api/namespace/object[@cname='GMimeFilter']/method[@name='Backup']/*/parameter[@name='length']" name="name">n_buf</attr> + + <!-- FilterBest --> + <attr path="/api/namespace/object[@cname='GMimeFilterBest']/method[@cname='g_mime_filter_best_charset']" name="name">GetBestCharset</attr> + <attr path="/api/namespace/object[@cname='GMimeFilterBest']/method[@cname='g_mime_filter_best_encoding']" name="name">GetBestEncoding</attr> + + <!-- GpgContext --> + + <!-- Header --> + <remove-node path="/api/namespace/struct[@cname='GMimeHeader']"/> + + <!-- HeaderList --> + <!-- We're going to implement the IEnumerable interface --> + <add-node path="/api/namespace/object[@cname='GMimeHeaderList']"> + <implements> + <interface name="IEnumerable"/> + </implements> + </add-node> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@cname='g_mime_header_list_foreach']"/> + <attr path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@name='SetStream']" name="hidden">true</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@name='GetStream']" name="hidden">true</attr> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@name='Get']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@name='Set']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderList']/method[@name='GetIter']"/> + + <!-- HeaderIter --> + <!-- This should really be made to be internal, but I don't know how to do that... --> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']/method[@name='SetValue']/return-type" name="type">void</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']/method[@name='First']" name="name">MoveFirst</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']/method[@name='Last']" name="name">MoveLast</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']/method[@name='Next']" name="name">MoveNext</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']/method[@name='Prev']" name="name">MovePrev</attr> + <attr path="/api/namespace/struct[@cname='GMimeHeaderIter']" name="opaque">true</attr> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderIter']/field[@cname='hdrlist']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderIter']/field[@cname='version']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeHeaderIter']/field[@cname='cursor']"/> + + <!-- iconv --> + + <!-- iconv-utils --> + + <!-- InternetAddress --> + <attr path="/api/namespace/object[@cname='InternetAddress']" name="abstract">1</attr> + <remove-node path="/api/namespace/object[@cname='InternetAddress']/field[@cname='priv']"/> + + <!-- InternetAddressGroup --> + <remove-node path="/api/namespace/object[@cname='InternetAddressGroup']/method[@name='AddMember']"/> + + <!-- InternetAddressMailbox --> + <attr path="/api/namespace/object[@cname='InternetAddressMailbox']/method[@name='GetAddr']" name="name">GetAddress</attr> + <attr path="/api/namespace/object[@cname='InternetAddressMailbox']/method[@name='SetAddr']" name="name">SetAddress</attr> + + <!-- InternetAddressList --> + <!-- Remove internal methods/fields/signals --> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/field[@cname='array']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/field[@cname='priv']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Writer']"/> + <!-- We're going to implement the IList interface --> + <add-node path="/api/namespace/object[@cname='InternetAddressList']"> + <implements> + <interface name="IList"/> + </implements> + </add-node> + <!-- Remove methods we're going to implement manually in InternetAddressList.custom --> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Add']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Clear']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Contains']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='IndexOf']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Insert']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Length']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='ParseString']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Remove']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='RemoveAt']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='GetAddress']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='SetAddress']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='ToString']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Prepend']"/> + <remove-node path="/api/namespace/object[@cname='InternetAddressList']/method[@name='Append']"/> + + <!-- Message --> + <attr path="/api/namespace/object[@cname='GMimeMessage']/method[@name='GetAllRecipients']/return-type" name="owned">true</attr> + <!-- We implement these properties by hand, hide them. --> + <remove-node path="/api/namespace/object[@cname='GMimeMessage']/method[@cname='g_mime_message_get_recipients']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMessage']/method[@cname='g_mime_message_get_date']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMessage']/method[@cname='g_mime_message_set_date']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMessage']/method[@cname='g_mime_message_foreach']"/> + + <!-- MessagePart --> + + <!-- MessagePartial --> + <add-node path="/api/namespace/object[@cname='GMimeMessagePartial']/method[@name='ReconstructMessage']/parameters"><parameter name="partials" type="GMimeMessagePartial**" array="true"/></add-node> + <attr path="/api/namespace/object[@cname='GMimeMessagePartial']/method[@name='ReconstructMessage']" name="shared">true</attr> + <attr path="/api/namespace/object[@cname='GMimeMessagePartial']/method[@name='ReconstructMessage']/*/parameter[@name='num']" name="name">n_partials</attr> + + <!-- Multipart --> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Foreach']"/> + <!-- We're going to implement the IList interface --> + <add-node path="/api/namespace/object[@cname='GMimeMultipart']"> + <implements> + <interface name="IList"/> + </implements> + </add-node> + <!-- Remove methods we're going to implement manually in GMimeMultipart.custom --> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Add']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Clear']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='GetCount']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Contains']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='IndexOf']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Insert']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Remove']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='RemoveAt']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='Replace']"/> + <remove-node path="/api/namespace/object[@cname='GMimeMultipart']/method[@name='GetPart']"/> + + <!-- MultipartEncrypted --> + <attr path="/api/namespace/object[@cname='GMimeMultipartEncrypted']/method[@name='Decrypt']/*/parameter[@name='result']" name="pass_as">out</attr> + + <!-- MultipartSigned --> + + <!-- Object --> + <attr path="/api/namespace/object[@cname='GMimeObject']" name="name">Entity</attr> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/constructor[@cname='g_mime_object_new']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/constructor[@cname='g_mime_object_new_type']"/> + <!-- Clean up some unnecessary helper methods from GMimeObject --> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_get_disposition']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_set_disposition']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_get_content_type_parameter']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_set_content_type_parameter']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_get_content_disposition_parameter']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_set_content_disposition_parameter']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_prepend_header']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_append_header']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_remove_header']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_get_header']"/> + <remove-node path="/api/namespace/object[@cname='GMimeObject']/method[@cname='g_mime_object_set_header']"/> + + <!-- Param --> + <remove-node path="/api/namespace/struct[@cname='GMimeParam']/field[@cname='value']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeParam']/field[@cname='name']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeParam']/field[@cname='next']"/> + + <!-- Parser --> + <attr path="/api/namespace/object[@cname='GMimeParser']/method[@name='ConstructPart']/return-type" name="owned">true</attr> + <attr path="/api/namespace/object[@cname='GMimeParser']/method[@name='ConstructMessage']/return-type" name="owned">true</attr> + + <!-- Parse Utils --> + <!-- Remove some utility parser functions: decode_word, decode_lwsp, etc --> + <!--<remove-node path="/api/namespace/class[@name='Global']/method[@name='ParseContentType']"/>--> + <!--<remove-node path="/api/namespace/class[@name='Decode']"/>--> + + <!-- Part --> + + <!-- PartIter --> + <remove-node path="/api/namespace/struct[@name='PartIter']"/> + + <!-- References --> + <attr path="/api/namespace/struct[@name='References']" name="opaque">true</attr> + <attr path="/api/namespace/struct[@name='References']/method[@name='Decode']" name="name">Parse</attr> + <remove-node path="/api/namespace/struct[@name='References']/method[@name='Clear']"/> + + <!-- Stream IOVectors --> + <remove-node path="/api/namespace/object[@cname='GMimeStream']/method[@cname='g_mime_stream_writev']"/> + <remove-node path="/api/namespace/struct[@cname='GMimeStreamIOVector']"/> + + <!-- Stream --> + <attr path="/api/namespace/object[@cname='GMimeStream']" name="abstract">1</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='Length']" name="name">GetLength</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='Read']/*/parameter[@name='buf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='Read']/*/parameter[@name='buf']" name="array">true</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='Write']/*/parameter[@name='buf']" name="type">const-guint8*</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='Write']/*/parameter[@name='buf']" name="array">true</attr> + <attr path="/api/namespace/object[@cname='GMimeStream']/method[@name='WriteString']" name="name">Write</attr> + + <!-- StreamFile --> + <attr path="/api/namespace/object[@cname='GMimeStreamFile']" name="hidden">true</attr> + + <!-- StreamMem --> + <attr path="/api/namespace/object[@cname='GMimeStreamMem']/constructor[@cname='g_mime_stream_mem_new_with_byte_array']" name="hidden">true</attr> + + <!-- Utils --> + <remove-node path="/api/namespace/class[@name='Utils']/method[@cname='g_mime_utils_decode_8bit']"/> + <remove-node path="/api/namespace/class[@name='Utils']/method[@cname='g_mime_utils_text_is_8bit']"/> + <attr path="/api/namespace/class[@name='Utils']/method[@cname='g_mime_utils_best_encoding']/*/parameter[@name='text']" name="type">const-guint8*</attr> + <attr path="/api/namespace/class[@name='Utils']/method[@cname='g_mime_utils_best_encoding']/*/parameter[@name='text']" name="array">true</attr> + <attr path="/api/namespace/class[@name='Utils']/method[@cname='g_mime_utils_best_encoding']/*/parameter[@name='len']" name="name">n_text</attr> + + <!-- Yencode --> + <!-- We've already moved the encoder/decoder functions into Encoding... --> + <attr path="/api/namespace/class[@name='Yencode']" name="hidden">true</attr> + +</metadata> diff --git a/mono/Global.custom b/mono/Global.custom new file mode 100644 index 0000000..0ef8f6c --- /dev/null +++ b/mono/Global.custom @@ -0,0 +1,25 @@ + public enum InitFlags { + None = 0, + EnableRfc2047Workarounds = (1 << 0), + } + + [DllImport("gmime")] + static extern void g_mime_init (int flags); + + public static void Init () + { + g_mime_init (0); + } + + public static void Init (InitFlags flags) + { + g_mime_init ((int) flags); + } + + [DllImport("gmime")] + static extern void g_mime_shutdown (); + + public static void Shutdown () + { + g_mime_shutdown (); + } diff --git a/mono/Header.cs b/mono/Header.cs new file mode 100644 index 0000000..702e603 --- /dev/null +++ b/mono/Header.cs @@ -0,0 +1,21 @@ +using System; + +namespace GMime { + public class Header { + public Header () { } + + public Header (string name, string value) + { + Value = value; + Name = name; + } + + public string Name { + get; set; + } + + public string Value { + get; set; + } + } +} diff --git a/mono/HeaderEnumerator.cs b/mono/HeaderEnumerator.cs new file mode 100644 index 0000000..11431a6 --- /dev/null +++ b/mono/HeaderEnumerator.cs @@ -0,0 +1,113 @@ +using System; +using System.Collections; + +namespace GMime { + public class HeaderEnumerator : IEnumerator, IDisposable { + bool premove = true; + HeaderList headers; + HeaderIter iter; + + public HeaderEnumerator (HeaderList headers) + { + if (headers == null) + throw new ArgumentNullException ("headers"); + + iter = headers.GetIter (); + this.headers = headers; + } + + public Header Current { + get { + CheckDisposed (); + return new Header (iter.Name, iter.Value); + } + } + + object IEnumerator.Current { + get { return Current; } + } + + public string Name { + get { + CheckDisposed (); + return iter.Name; + } + } + + public string Value { + set { + CheckDisposed (); + iter.Value = value; + } + + get { + CheckDisposed (); + return iter.Value; + } + } + + public bool MoveFirst () + { + CheckDisposed (); + + premove = false; + return iter.MoveFirst (); + } + + public bool MoveLast () + { + CheckDisposed (); + + premove = false; + return iter.MoveLast (); + } + + public bool MoveNext () + { + CheckDisposed (); + + if (premove) { + premove = false; + return iter.MoveFirst (); + } + + return iter.MoveNext (); + } + + public bool MovePrev () + { + CheckDisposed (); + + if (premove) + return false; + + premove = false; + return iter.MovePrev (); + } + + public bool Remove () + { + CheckDisposed (); + return iter.Remove (); + } + + public void Reset () + { + CheckDisposed (); + iter.MoveFirst (); + premove = true; + } + + void CheckDisposed () + { + if (headers == null) + throw new ObjectDisposedException ("The HeaderEnumerator has been disposed."); + } + + public void Dispose () + { + headers = null; + iter = null; + } + } +} diff --git a/mono/HeaderList.custom b/mono/HeaderList.custom new file mode 100644 index 0000000..9cea737 --- /dev/null +++ b/mono/HeaderList.custom @@ -0,0 +1,56 @@ + [DllImport ("gmime")] + static extern IntPtr g_mime_header_list_set (IntPtr raw, IntPtr name, IntPtr value); + + [DllImport ("gmime")] + static extern IntPtr g_mime_header_list_get (IntPtr raw, IntPtr name); + + public string this[string name] { + get { + if (name == null) + throw new ArgumentNullException ("name"); + + IntPtr native_name = GLib.Marshaller.StringToPtrGStrdup (name); + IntPtr raw_ret = g_mime_header_list_get (Handle, native_name); + string ret = GLib.Marshaller.Utf8PtrToString (raw_ret); + GLib.Marshaller.Free (native_name); + + return ret; + } + + set { + if (name == null) + throw new ArgumentNullException ("name"); + + IntPtr native_name = GLib.Marshaller.StringToPtrGStrdup (name); + IntPtr native_value = GLib.Marshaller.StringToPtrGStrdup (value); + g_mime_header_list_set (Handle, native_name, native_value); + GLib.Marshaller.Free (native_value); + GLib.Marshaller.Free (native_name); + } + } + + [DllImport ("gmime")] + static extern bool g_mime_header_list_get_iter (IntPtr raw, IntPtr iter); + + internal HeaderIter GetIter () + { + HeaderIter iter = new HeaderIter (); + + g_mime_header_list_get_iter (Handle, iter.Handle); + + return iter; + } + + public IEnumerator GetEnumerator () + { + return new HeaderEnumerator (this); + } + + public StreamWrapper Stream { + get { + GMime.StreamMem mem_stream = new GMime.StreamMem (); + this.WriteToStream (mem_stream); + mem_stream.Seek (0); + return new StreamWrapper (mem_stream); + } + } diff --git a/mono/InternetAddress.custom b/mono/InternetAddress.custom new file mode 100644 index 0000000..7edc1c1 --- /dev/null +++ b/mono/InternetAddress.custom @@ -0,0 +1,4 @@ + public override string ToString () + { + return ToString (false); + } diff --git a/mono/InternetAddressList.custom b/mono/InternetAddressList.custom new file mode 100644 index 0000000..29d5ad9 --- /dev/null +++ b/mono/InternetAddressList.custom @@ -0,0 +1,281 @@ +#region Native Methods + [DllImport("gmime")] + static extern int internet_address_list_length (IntPtr list); + + [DllImport("gmime")] + static extern void internet_address_list_clear (IntPtr list); + + [DllImport("gmime")] + static extern int internet_address_list_add (IntPtr list, IntPtr ia); + + //[DllImport("gmime")] + //static extern void internet_address_list_concat (IntPtr list, IntPtr concat); + + [DllImport("gmime")] + static extern void internet_address_list_insert (IntPtr list, int index, IntPtr ia); + + [DllImport("gmime")] + static extern bool internet_address_list_remove (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern bool internet_address_list_remove_at (IntPtr list, int index); + + [DllImport("gmime")] + static extern bool internet_address_list_contains (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern int internet_address_list_index_of (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern IntPtr internet_address_list_get_address (IntPtr list, int index); + + [DllImport("gmime")] + static extern void internet_address_list_set_address (IntPtr list, int index, IntPtr ia); + + [DllImport("gmime")] + static extern IntPtr internet_address_list_to_string (IntPtr list, bool encode); + + [DllImport("gmime")] + static extern IntPtr internet_address_list_parse_string (IntPtr str); +#endregion + + Exception CannotAdd (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot add objects of type '{0}' to an InternetAddressList.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotInsert (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot insert objects of type '{0}' into an InternetAddressList.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotRemove (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot remove objects of type '{0}' from an InternetAddressList.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotSet (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot set objects of type '{0}' on an InternetAddressList.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + public int Count { + get { return internet_address_list_length (Handle); } + } + + public bool IsFixedSize { + get { return false; } + } + + public bool IsReadOnly { + get { return false; } + } + + public bool IsSynchronized { + get { return false; } + } + + public object SyncRoot { + get { return this; } + } + + public int Add (InternetAddress addr) + { + if (addr == null) + throw CannotAdd (addr); + + return internet_address_list_add (Handle, addr.Handle); + } + + int IList.Add (object value) + { + InternetAddress addr = value as InternetAddress; + + if (addr == null) + throw CannotAdd (value); + + return Add (addr); + } + + public void Clear () + { + internet_address_list_clear (Handle); + } + + public bool Contains (InternetAddress addr) + { + if (addr == null) + return false; + + return internet_address_list_contains (Handle, addr.Handle); + } + + bool IList.Contains (object value) + { + return Contains (value as InternetAddress); + } + + public void CopyTo (Array array, int index) + { + if (array == null) + throw new ArgumentNullException ("array"); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + int n = Count; + + for (int i = 0; i < n; i++) + array.SetValue (((IList) this)[i], index + i); + } + + public IEnumerator GetEnumerator () + { + int n = Count; + + for (int i = 0; i < n; i++) + yield return this[i]; + + yield break; + } + + public int IndexOf (InternetAddress addr) + { + if (addr == null) + return -1; + + return internet_address_list_index_of (Handle, addr.Handle); + } + + int IList.IndexOf (object value) + { + return IndexOf (value as InternetAddress); + } + + public void Insert (int index, InternetAddress addr) + { + if (addr == null) + throw CannotInsert (addr); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + internet_address_list_insert (Handle, index, addr.Handle); + } + + void IList.Insert (int index, object value) + { + InternetAddress addr = value as InternetAddress; + + if (addr == null) + throw CannotInsert (value); + + Insert (index, addr); + } + + public void Remove (InternetAddress addr) + { + if (addr == null) + throw CannotRemove (addr); + + internet_address_list_remove (Handle, addr.Handle); + } + + void IList.Remove (object value) + { + InternetAddress addr = value as InternetAddress; + + if (addr == null) + throw CannotRemove (value); + + Remove (addr); + } + + public void RemoveAt (int index) + { + if (index < 0 || index >= Count) + throw new ArgumentOutOfRangeException ("index"); + + internet_address_list_remove_at (Handle, index); + } + + public InternetAddress this[int index] { + get { + IntPtr raw = internet_address_list_get_address (Handle, index); + + if (raw == IntPtr.Zero) + return null; + + return GLib.Object.GetObject (raw) as InternetAddress; + } + + set { + if (value == null) + throw CannotSet (value); + + internet_address_list_set_address (Handle, index, value.Handle); + } + } + + object IList.this[int index] { + get { + return this[index]; + } + + set { + this[index] = value as InternetAddress; + } + } + + public static InternetAddressList Parse (string str) + { + IntPtr native_str = GLib.Marshaller.StringToPtrGStrdup (str); + IntPtr raw = internet_address_list_parse_string (native_str); + InternetAddressList list = null; + + if (raw != IntPtr.Zero) + list = new InternetAddressList (raw); + + GLib.Marshaller.Free (native_str); + + return list; + } + + public string ToString (bool encode) + { + IntPtr raw = internet_address_list_to_string (Handle, encode); + + if (raw == IntPtr.Zero) + return String.Empty; + + return GLib.Marshaller.PtrToStringGFree (raw); + } + + public override string ToString () + { + return ToString (false); + } diff --git a/mono/Makefile.am b/mono/Makefile.am new file mode 100644 index 0000000..05c912b --- /dev/null +++ b/mono/Makefile.am @@ -0,0 +1,120 @@ +API = gmime-api.xml +SNK = gmime-sharp.snk +RAW_API = gmime-api.raw +METADATA = GMime.metadata +ASSEMBLY_NAME = gmime-sharp +references = $(GLIB_SHARP_LIBS) +SOURCES_XML = sources.xml + +PACKAGE_SHARP = $(PACKAGE)-sharp-$(GMIME_API_VERSION) +ASSEMBLY = $(ASSEMBLY_NAME).dll +TARGET = $(ASSEMBLY) $(ASSEMBLY).config +TARGET_API = $(API) +noinst_DATA = $(API) $(ASSEMBLY) $(ASSEMBLY).config +CLEANFILES = $(ASSEMBLY) generated-stamp generated/*.cs $(API) +DISTCLEANFILES = $(ASSEMBLY).config AssemblyInfo.cs gmime-sharp-$(GMIME_API_VERSION).pc +GACUTIL_DESTDIR_FLAGS = -package $(PACKAGE_SHARP) -root $(DESTDIR)$(gacdir) +GACUTIL_FLAGS = -package $(PACKAGE_SHARP) -gacdir $(gacdir) + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = $(PACKAGE_SHARP).pc +gapidir = $(datadir)/gapi-2.0 +gapi_DATA = $(TARGET_API) + +sources = \ + StreamWrapper.cs \ + HeaderEnumerator.cs \ + Header.cs + +build_sources = \ + $(srcdir)/StreamWrapper.cs \ + $(srcdir)/HeaderEnumerator.cs \ + $(srcdir)/Header.cs \ + AssemblyInfo.cs + +customs = \ + CertificateCollection.custom \ + DataWrapper.custom \ + Global.custom \ + HeaderList.custom \ + InternetAddress.custom \ + InternetAddressList.custom \ + Message.custom \ + Multipart.custom \ + Object.custom \ + SignatureCollection.custom \ + Stream.custom + +build_customs = \ + $(srcdir)/CertificateCollection.custom \ + $(srcdir)/DataWrapper.custom \ + $(srcdir)/Global.custom \ + $(srcdir)/HeaderList.custom \ + $(srcdir)/InternetAddress.custom \ + $(srcdir)/InternetAddressList.custom \ + $(srcdir)/Message.custom \ + $(srcdir)/Multipart.custom \ + $(srcdir)/Object.custom \ + $(srcdir)/SignatureCollection.custom \ + $(srcdir)/Stream.custom + +EXTRA_DIST = \ + $(ASSEMBLY).config.in \ + AssemblyInfo.cs.in \ + $(SNK) \ + $(METADATA) \ + $(RAW_API) \ + $(customs) \ + $(sources) \ + $(SOURCES_XML) \ + gmime-sharp.pc.in + +$(PACKAGE_SHARP).pc: gmime-sharp.pc + -cp gmime-sharp.pc $(PACKAGE_SHARP).pc + +$(API): $(srcdir)/$(RAW_API) $(srcdir)/$(METADATA) + cp $(srcdir)/$(RAW_API) $(API) + chmod u+w $(API) + $(GAPI_FIXUP) --api=$(API) --metadata=$(srcdir)/$(METADATA) + +generated-stamp: $(API) $(build_customs) + rm -f generated/* && \ + $(GAPI_CODEGEN) --generate $(API) --outdir=generated --customdir=$(srcdir) --assembly-name=$(ASSEMBLY_NAME) \ + && touch generated-stamp + +if PLATFORM_WIN32 +GAPI_CDECL_INSERT=$(top_srcdir)/gapi-cdecl-insert --keyfile=$(SNK) $(ASSEMBLY) +else +GAPI_CDECL_INSERT= +endif + +$(ASSEMBLY): $(build_sources) generated-stamp $(srcdir)/$(ASSEMBLY_NAME).snk + $(CSC) -unsafe /out:$(ASSEMBLY) /target:library $(references) \ + -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk $(build_sources) generated/*.cs + $(GAPI_CDECL_INSERT) + sn -q -R $(ASSEMBLY) $(srcdir)/$(SNK) + +install-data-local: + @if test -n '$(TARGET)'; then \ + if test -n '$(DESTDIR)'; then \ + echo "$(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_DESTDIR_FLAGS)"; \ + $(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_DESTDIR_FLAGS) || exit 1; \ + else \ + echo "$(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_FLAGS)"; \ + $(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_FLAGS) || exit 1; \ + fi; \ + fi + +uninstall-local: + @if test -n '$(TARGET)'; then \ + if test -n '$(DESTDIR)'; then \ + echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_DESTDIR_FLAGS)"; \ + $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_DESTDIR_FLAGS) || exit 1; \ + else \ + echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS)"; \ + $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS) || exit 1; \ + fi; \ + fi + +parse: + $(GAPI_PARSER) $(SOURCES_XML) diff --git a/mono/Makefile.in b/mono/Makefile.in new file mode 100644 index 0000000..4329e20 --- /dev/null +++ b/mono/Makefile.in @@ -0,0 +1,618 @@ +# Makefile.in generated by automake 1.11.3 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software +# Foundation, Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +target_triplet = @target@ +subdir = mono +DIST_COMMON = $(srcdir)/AssemblyInfo.cs.in $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(srcdir)/gmime-sharp.dll.config.in \ + $(srcdir)/gmime-sharp.pc.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = AssemblyInfo.cs gmime-sharp.dll.config \ + gmime-sharp.pc +CONFIG_CLEAN_VPATH_FILES = +SOURCES = +DIST_SOURCES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(gapidir)" "$(DESTDIR)$(pkgconfigdir)" +DATA = $(gapi_DATA) $(noinst_DATA) $(pkgconfig_DATA) +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ACLOCAL_AMFLAGS = @ACLOCAL_AMFLAGS@ +AMTAR = @AMTAR@ +API_VERSION = @API_VERSION@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CSC = @CSC@ +CYGPATH_W = @CYGPATH_W@ +DB2HTML = @DB2HTML@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOLT_BASH = @DOLT_BASH@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GACUTIL = @GACUTIL@ +GAPI_CODEGEN = @GAPI_CODEGEN@ +GAPI_FIXUP = @GAPI_FIXUP@ +GAPI_PARSER = @GAPI_PARSER@ +GAPI_TOOLS_CFLAGS = @GAPI_TOOLS_CFLAGS@ +GAPI_TOOLS_LIBS = @GAPI_TOOLS_LIBS@ +GLIB_CFLAGS = @GLIB_CFLAGS@ +GLIB_COMPILE_RESOURCES = @GLIB_COMPILE_RESOURCES@ +GLIB_GENMARSHAL = @GLIB_GENMARSHAL@ +GLIB_LIBS = @GLIB_LIBS@ +GLIB_MKENUMS = @GLIB_MKENUMS@ +GLIB_SHARP_CFLAGS = @GLIB_SHARP_CFLAGS@ +GLIB_SHARP_LIBS = @GLIB_SHARP_LIBS@ +GMIME_API_VERSION = @GMIME_API_VERSION@ +GMIME_BINARY_AGE = @GMIME_BINARY_AGE@ +GMIME_CFLAGS = @GMIME_CFLAGS@ +GMIME_INCLUDEDIR = @GMIME_INCLUDEDIR@ +GMIME_INTERFACE_AGE = @GMIME_INTERFACE_AGE@ +GMIME_LIBDIR = @GMIME_LIBDIR@ +GMIME_LIBS = @GMIME_LIBS@ +GMIME_LIBS_PRIVATE = @GMIME_LIBS_PRIVATE@ +GMIME_MAJOR_VERSION = @GMIME_MAJOR_VERSION@ +GMIME_MICRO_VERSION = @GMIME_MICRO_VERSION@ +GMIME_MINOR_VERSION = @GMIME_MINOR_VERSION@ +GMIME_VERSION = @GMIME_VERSION@ +GOBJECT_QUERY = @GOBJECT_QUERY@ +GPGME_CONFIG = @GPGME_CONFIG@ +GPGME_PTHREAD_CFLAGS = @GPGME_PTHREAD_CFLAGS@ +GPGME_PTHREAD_LIBS = @GPGME_PTHREAD_LIBS@ +GREP = @GREP@ +GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ +HTML_DIR = @HTML_DIR@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBICONV = @LIBICONV@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIB_EXE_MACHINE_FLAG = @LIB_EXE_MACHINE_FLAG@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTCOMPILE = @LTCOMPILE@ +LTCXXCOMPILE = @LTCXXCOMPILE@ +LTLIBICONV = @LTLIBICONV@ +LTLIBOBJS = @LTLIBOBJS@ +LT_AGE = @LT_AGE@ +LT_CURRENT = @LT_CURRENT@ +LT_CURRENT_MINUS_AGE = @LT_CURRENT_MINUS_AGE@ +LT_RELEASE = @LT_RELEASE@ +LT_REVISION = @LT_REVISION@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +MV = @MV@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +RM = @RM@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +TAR = @TAR@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +gacdir = @gacdir@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +ms_librarian = @ms_librarian@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target = @target@ +target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +API = gmime-api.xml +SNK = gmime-sharp.snk +RAW_API = gmime-api.raw +METADATA = GMime.metadata +ASSEMBLY_NAME = gmime-sharp +references = $(GLIB_SHARP_LIBS) +SOURCES_XML = sources.xml +PACKAGE_SHARP = $(PACKAGE)-sharp-$(GMIME_API_VERSION) +ASSEMBLY = $(ASSEMBLY_NAME).dll +TARGET = $(ASSEMBLY) $(ASSEMBLY).config +TARGET_API = $(API) +noinst_DATA = $(API) $(ASSEMBLY) $(ASSEMBLY).config +CLEANFILES = $(ASSEMBLY) generated-stamp generated/*.cs $(API) +DISTCLEANFILES = $(ASSEMBLY).config AssemblyInfo.cs gmime-sharp-$(GMIME_API_VERSION).pc +GACUTIL_DESTDIR_FLAGS = -package $(PACKAGE_SHARP) -root $(DESTDIR)$(gacdir) +GACUTIL_FLAGS = -package $(PACKAGE_SHARP) -gacdir $(gacdir) +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = $(PACKAGE_SHARP).pc +gapidir = $(datadir)/gapi-2.0 +gapi_DATA = $(TARGET_API) +sources = \ + StreamWrapper.cs \ + HeaderEnumerator.cs \ + Header.cs + +build_sources = \ + $(srcdir)/StreamWrapper.cs \ + $(srcdir)/HeaderEnumerator.cs \ + $(srcdir)/Header.cs \ + AssemblyInfo.cs + +customs = \ + CertificateCollection.custom \ + DataWrapper.custom \ + Global.custom \ + HeaderList.custom \ + InternetAddress.custom \ + InternetAddressList.custom \ + Message.custom \ + Multipart.custom \ + Object.custom \ + SignatureCollection.custom \ + Stream.custom + +build_customs = \ + $(srcdir)/CertificateCollection.custom \ + $(srcdir)/DataWrapper.custom \ + $(srcdir)/Global.custom \ + $(srcdir)/HeaderList.custom \ + $(srcdir)/InternetAddress.custom \ + $(srcdir)/InternetAddressList.custom \ + $(srcdir)/Message.custom \ + $(srcdir)/Multipart.custom \ + $(srcdir)/Object.custom \ + $(srcdir)/SignatureCollection.custom \ + $(srcdir)/Stream.custom + +EXTRA_DIST = \ + $(ASSEMBLY).config.in \ + AssemblyInfo.cs.in \ + $(SNK) \ + $(METADATA) \ + $(RAW_API) \ + $(customs) \ + $(sources) \ + $(SOURCES_XML) \ + gmime-sharp.pc.in + +@PLATFORM_WIN32_FALSE@GAPI_CDECL_INSERT = +@PLATFORM_WIN32_TRUE@GAPI_CDECL_INSERT = $(top_srcdir)/gapi-cdecl-insert --keyfile=$(SNK) $(ASSEMBLY) +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign mono/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign mono/Makefile +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +AssemblyInfo.cs: $(top_builddir)/config.status $(srcdir)/AssemblyInfo.cs.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +gmime-sharp.dll.config: $(top_builddir)/config.status $(srcdir)/gmime-sharp.dll.config.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +gmime-sharp.pc: $(top_builddir)/config.status $(srcdir)/gmime-sharp.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-gapiDATA: $(gapi_DATA) + @$(NORMAL_INSTALL) + test -z "$(gapidir)" || $(MKDIR_P) "$(DESTDIR)$(gapidir)" + @list='$(gapi_DATA)'; test -n "$(gapidir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(gapidir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(gapidir)" || exit $$?; \ + done + +uninstall-gapiDATA: + @$(NORMAL_UNINSTALL) + @list='$(gapi_DATA)'; test -n "$(gapidir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(gapidir)'; $(am__uninstall_files_from_dir) +install-pkgconfigDATA: $(pkgconfig_DATA) + @$(NORMAL_INSTALL) + test -z "$(pkgconfigdir)" || $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \ + done + +uninstall-pkgconfigDATA: + @$(NORMAL_UNINSTALL) + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(DATA) +installdirs: + for dir in "$(DESTDIR)$(gapidir)" "$(DESTDIR)$(pkgconfigdir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-data-local install-gapiDATA \ + install-pkgconfigDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-gapiDATA uninstall-local \ + uninstall-pkgconfigDATA + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + distclean distclean-generic distclean-libtool distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-data-local install-dvi \ + install-dvi-am install-exec install-exec-am install-gapiDATA \ + install-html install-html-am install-info install-info-am \ + install-man install-pdf install-pdf-am install-pkgconfigDATA \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am \ + uninstall-gapiDATA uninstall-local uninstall-pkgconfigDATA + + +$(PACKAGE_SHARP).pc: gmime-sharp.pc + -cp gmime-sharp.pc $(PACKAGE_SHARP).pc + +$(API): $(srcdir)/$(RAW_API) $(srcdir)/$(METADATA) + cp $(srcdir)/$(RAW_API) $(API) + chmod u+w $(API) + $(GAPI_FIXUP) --api=$(API) --metadata=$(srcdir)/$(METADATA) + +generated-stamp: $(API) $(build_customs) + rm -f generated/* && \ + $(GAPI_CODEGEN) --generate $(API) --outdir=generated --customdir=$(srcdir) --assembly-name=$(ASSEMBLY_NAME) \ + && touch generated-stamp + +$(ASSEMBLY): $(build_sources) generated-stamp $(srcdir)/$(ASSEMBLY_NAME).snk + $(CSC) -unsafe /out:$(ASSEMBLY) /target:library $(references) \ + -keyfile:$(srcdir)/$(ASSEMBLY_NAME).snk $(build_sources) generated/*.cs + $(GAPI_CDECL_INSERT) + sn -q -R $(ASSEMBLY) $(srcdir)/$(SNK) + +install-data-local: + @if test -n '$(TARGET)'; then \ + if test -n '$(DESTDIR)'; then \ + echo "$(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_DESTDIR_FLAGS)"; \ + $(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_DESTDIR_FLAGS) || exit 1; \ + else \ + echo "$(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_FLAGS)"; \ + $(GACUTIL) -i $(ASSEMBLY) -f $(GACUTIL_FLAGS) || exit 1; \ + fi; \ + fi + +uninstall-local: + @if test -n '$(TARGET)'; then \ + if test -n '$(DESTDIR)'; then \ + echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_DESTDIR_FLAGS)"; \ + $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_DESTDIR_FLAGS) || exit 1; \ + else \ + echo "$(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS)"; \ + $(GACUTIL) -u $(ASSEMBLY_NAME) $(GACUTIL_FLAGS) || exit 1; \ + fi; \ + fi + +parse: + $(GAPI_PARSER) $(SOURCES_XML) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/mono/Message.custom b/mono/Message.custom new file mode 100644 index 0000000..573f38f --- /dev/null +++ b/mono/Message.custom @@ -0,0 +1,87 @@ + [DllImport ("gmime")] + static extern IntPtr g_mime_message_get_recipients (IntPtr message, int type); + + public InternetAddressList GetRecipients (GMime.RecipientType type) + { + IntPtr list = g_mime_message_get_recipients (Handle, (int) type); + + return new InternetAddressList (list); + } + + public InternetAddressList To { + get { return GetRecipients (RecipientType.To); } + } + + public InternetAddressList Cc { + get { return GetRecipients (RecipientType.Cc); } + } + + public InternetAddressList Bcc { + get { return GetRecipients (RecipientType.Bcc); } + } + + public System.Collections.IEnumerable References { + get { + GMime.HeaderList headers = HeaderList; + + if (headers == null) + yield break; + + string references = headers["References"]; + + if (references == null) + yield break; + + GMime.References refs = GMime.References.Parse (references); + GMime.References iter = refs; + + while (iter != null) { + yield return iter; + iter = iter.Next; + } + + yield break; + } + } + + [DllImport("gmime")] + static extern IntPtr internet_address_list_to_string (IntPtr list, bool encode); + + public string GetRecipientsAsString (GMime.RecipientType type, bool encode) + { + IntPtr list = g_mime_message_get_recipients (Handle, (int) type); + IntPtr str; + + if (list == IntPtr.Zero) + return null; + + str = internet_address_list_to_string (list, encode); + + return GLib.Marshaller.PtrToStringGFree (str); + } + + public string GetRecipientsAsString (GMime.RecipientType type) + { + return GetRecipientsAsString (type, false); + } + + [DllImport("gmime")] + static extern void g_mime_message_get_date (IntPtr message, out IntPtr date, out int gmt_offset); + + [DllImport("gmime")] + static extern void g_mime_message_set_date (IntPtr message, IntPtr date, int gmt_offset); + + public DateTime Date { + get { + int tz_offset; + IntPtr date; + + g_mime_message_get_date (Handle, out date, out tz_offset); + + return GLib.Marshaller.time_tToDateTime (date); + } + + set { + g_mime_message_set_date (Handle, GLib.Marshaller.DateTimeTotime_t (value), 0); + } + } diff --git a/mono/Multipart.custom b/mono/Multipart.custom new file mode 100644 index 0000000..aef29ec --- /dev/null +++ b/mono/Multipart.custom @@ -0,0 +1,248 @@ +#region Native Methods + [DllImport("gmime")] + static extern int g_mime_multipart_get_count (IntPtr multipart); + + [DllImport("gmime")] + static extern void g_mime_multipart_clear (IntPtr multipart); + + [DllImport("gmime")] + static extern int g_mime_multipart_add (IntPtr multipart, IntPtr part); + + [DllImport("gmime")] + static extern void g_mime_multipart_insert (IntPtr multipart, int index, IntPtr part); + + [DllImport("gmime")] + static extern bool g_mime_multipart_remove (IntPtr multipart, IntPtr part); + + [DllImport("gmime")] + static extern bool g_mime_multipart_remove_at (IntPtr multipart, int index); + + [DllImport("gmime")] + static extern bool g_mime_multipart_contains (IntPtr multipart, IntPtr part); + + [DllImport("gmime")] + static extern int g_mime_multipart_index_of (IntPtr multipart, IntPtr part); + + [DllImport("gmime")] + static extern IntPtr g_mime_multipart_get_part (IntPtr multipart, int index); +#endregion + + Exception CannotAdd (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot add objects of type '{0}' to a GMime.Multipart.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotInsert (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot insert objects of type '{0}' into a GMime.Multipart.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotRemove (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot remove objects of type '{0}' from a GMime.Multipart.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotSet (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot set objects of type '{0}' on a GMime.Multipart.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + public int Count { + get { return g_mime_multipart_get_count (Handle); } + } + + public bool IsFixedSize { + get { return false; } + } + + public bool IsReadOnly { + get { return false; } + } + + public bool IsSynchronized { + get { return false; } + } + + public object SyncRoot { + get { return this; } + } + + public int Add (GMime.Entity part) + { + if (part == null) + throw CannotAdd (part); + + return g_mime_multipart_add (Handle, part.Handle); + } + + int IList.Add (object value) + { + GMime.Entity part = value as GMime.Entity; + + if (part == null) + throw CannotAdd (value); + + return Add (part); + } + + public void Clear () + { + g_mime_multipart_clear (Handle); + } + + public bool Contains (GMime.Entity part) + { + if (part == null) + return false; + + return g_mime_multipart_contains (Handle, part.Handle); + } + + bool IList.Contains (object value) + { + return Contains (value as GMime.Entity); + } + + public void CopyTo (Array array, int index) + { + if (array == null) + throw new ArgumentNullException ("array"); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + int n = Count; + + for (int i = 0; i < n; i++) + array.SetValue (((IList) this)[i], index + i); + } + + public IEnumerator GetEnumerator () + { + int n = Count; + + for (int i = 0; i < n; i++) + yield return this[i]; + + yield break; + } + + public int IndexOf (GMime.Entity part) + { + if (part == null) + return -1; + + return g_mime_multipart_index_of (Handle, part.Handle); + } + + int IList.IndexOf (object value) + { + return IndexOf (value as GMime.Entity); + } + + public void Insert (int index, GMime.Entity part) + { + if (part == null) + throw CannotInsert (part); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_multipart_insert (Handle, index, part.Handle); + } + + void IList.Insert (int index, object value) + { + GMime.Entity part = value as GMime.Entity; + + if (part == null) + throw CannotInsert (value); + + Insert (index, part); + } + + public void Remove (GMime.Entity part) + { + if (part == null) + throw CannotRemove (part); + + g_mime_multipart_remove (Handle, part.Handle); + } + + void IList.Remove (object value) + { + GMime.Entity part = value as GMime.Entity; + + if (part == null) + throw CannotRemove (value); + + Remove (part); + } + + public void RemoveAt (int index) + { + if (index < 0 || index >= Count) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_multipart_remove_at (Handle, index); + } + + public GMime.Entity this[int index] { + get { + IntPtr raw = g_mime_multipart_get_part (Handle, index); + + if (raw == IntPtr.Zero) + return null; + + return GLib.Object.GetObject (raw) as GMime.Entity; + } + + set { + if (value == null) + throw CannotSet (value); + + if (index > Count || index < Count) + throw new ArgumentOutOfRangeException ("index"); + + if (index < Count) { + RemoveAt (index); + Insert (index, value); + } else { + Add (value); + } + } + } + + object IList.this[int index] { + get { + return this[index]; + } + + set { + this[index] = value as GMime.Entity; + } + } diff --git a/mono/Object.custom b/mono/Object.custom new file mode 100644 index 0000000..259b6ff --- /dev/null +++ b/mono/Object.custom @@ -0,0 +1,8 @@ +public StreamWrapper Stream { + get { + GMime.StreamMem mem_stream = new GMime.StreamMem (); + this.WriteToStream (mem_stream); + mem_stream.Seek (0); + return new StreamWrapper (mem_stream); + } +} diff --git a/mono/SignatureCollection.custom b/mono/SignatureCollection.custom new file mode 100644 index 0000000..332cadc --- /dev/null +++ b/mono/SignatureCollection.custom @@ -0,0 +1,243 @@ +#region Native Methods + [DllImport("gmime")] + static extern int g_mime_signature_list_length (IntPtr list); + + [DllImport("gmime")] + static extern void g_mime_signature_list_clear (IntPtr list); + + [DllImport("gmime")] + static extern int g_mime_signature_list_add (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern void g_mime_signature_list_insert (IntPtr list, int index, IntPtr ia); + + [DllImport("gmime")] + static extern bool g_mime_signature_list_remove (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern bool g_mime_signature_list_remove_at (IntPtr list, int index); + + [DllImport("gmime")] + static extern bool g_mime_signature_list_contains (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern int g_mime_signature_list_index_of (IntPtr list, IntPtr ia); + + [DllImport("gmime")] + static extern IntPtr g_mime_signature_list_get_signature (IntPtr list, int index); + + [DllImport("gmime")] + static extern void g_mime_signature_list_set_signature (IntPtr list, int index, IntPtr ia); +#endregion + + Exception CannotAdd (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot add objects of type '{0}' to a SignatureCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotInsert (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot insert objects of type '{0}' into a SignatureCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotRemove (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot remove objects of type '{0}' from a SignatureCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + Exception CannotSet (object value) + { + if (value == null) + return new ArgumentNullException ("value"); + + string message = String.Format ("Cannot set objects of type '{0}' on an SignatureCollection.", + value.GetType ().ToString ()); + + return new InvalidOperationException (message); + } + + public int Count { + get { return g_mime_signature_list_length (Handle); } + } + + public bool IsFixedSize { + get { return false; } + } + + public bool IsReadOnly { + get { return false; } + } + + public bool IsSynchronized { + get { return false; } + } + + public object SyncRoot { + get { return this; } + } + + public int Add (Signature signature) + { + if (signature == null) + throw CannotAdd (signature); + + return g_mime_signature_list_add (Handle, signature.Handle); + } + + int IList.Add (object value) + { + Signature signature = value as Signature; + + if (signature == null) + throw CannotAdd (value); + + return Add (signature); + } + + public void Clear () + { + g_mime_signature_list_clear (Handle); + } + + public bool Contains (Signature signature) + { + if (signature == null) + return false; + + return g_mime_signature_list_contains (Handle, signature.Handle); + } + + bool IList.Contains (object value) + { + return Contains (value as Signature); + } + + public void CopyTo (Array array, int index) + { + if (array == null) + throw new ArgumentNullException ("array"); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + int n = Count; + + for (int i = 0; i < n; i++) + array.SetValue (((IList) this)[i], index + i); + } + + public IEnumerator GetEnumerator () + { + int n = Count; + + for (int i = 0; i < n; i++) + yield return this[i]; + + yield break; + } + + public int IndexOf (Signature signature) + { + if (signature == null) + return -1; + + return g_mime_signature_list_index_of (Handle, signature.Handle); + } + + int IList.IndexOf (object value) + { + return IndexOf (value as Signature); + } + + public void Insert (int index, Signature signature) + { + if (signature == null) + throw CannotInsert (signature); + + if (index < 0) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_signature_list_insert (Handle, index, signature.Handle); + } + + void IList.Insert (int index, object value) + { + Signature signature = value as Signature; + + if (signature == null) + throw CannotInsert (value); + + Insert (index, signature); + } + + public void Remove (Signature signature) + { + if (signature == null) + throw CannotRemove (signature); + + g_mime_signature_list_remove (Handle, signature.Handle); + } + + void IList.Remove (object value) + { + Signature signature = value as Signature; + + if (signature == null) + throw CannotRemove (value); + + Remove (signature); + } + + public void RemoveAt (int index) + { + if (index < 0 || index >= Count) + throw new ArgumentOutOfRangeException ("index"); + + g_mime_signature_list_remove_at (Handle, index); + } + + public Signature this[int index] { + get { + IntPtr raw = g_mime_signature_list_get_signature (Handle, index); + + if (raw == IntPtr.Zero) + return null; + + return GLib.Object.GetObject (raw) as Signature; + } + + set { + if (value == null) + throw CannotSet (value); + + g_mime_signature_list_set_signature (Handle, index, value.Handle); + } + } + + object IList.this[int index] { + get { + return this[index]; + } + + set { + this[index] = value as Signature; + } + } diff --git a/mono/Stream.custom b/mono/Stream.custom new file mode 100644 index 0000000..0ab4173 --- /dev/null +++ b/mono/Stream.custom @@ -0,0 +1,4 @@ +public long Seek (long offset) +{ + return this.Seek (offset, GMime.SeekWhence.Set); +} diff --git a/mono/StreamWrapper.cs b/mono/StreamWrapper.cs new file mode 100644 index 0000000..e393a2d --- /dev/null +++ b/mono/StreamWrapper.cs @@ -0,0 +1,187 @@ +using System; +using System.IO; + +namespace GMime { + public class StreamWrapper : System.IO.Stream, IDisposable { + GMime.Stream stream; + + public StreamWrapper (GMime.Stream stream) + { + if (stream == null) + throw new ArgumentNullException (); + + this.stream = stream; + } + + ~StreamWrapper () + { + Close (); + } + + public new void Dispose () + { + Close (); + } + + public GMime.Stream GMimeStream { + get { return stream; } + set { + if (value == null) + throw new ArgumentNullException (); + + stream = value; + } + } + + public override bool CanRead { + get { return stream == null ? false : true; } + } + + public override bool CanSeek { + get { return stream == null || stream is StreamFilter ? false : true; } + } + + public override bool CanWrite { + get { return stream == null ? false : true; } + } + + public override long Length { + get { + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The stream has been closed"); + + return stream.Length; + } + } + + public override long Position { + get { + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The stream has been closed"); + + return stream.Tell (); + } + + set { + if (Seek (value, SeekOrigin.Begin) == -1) + throw new IOException (); + } + } + + public override void Close () + { + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The stream has been closed"); + + stream.Dispose (); + stream = null; + } + + public override void Flush () + { + stream.Flush (); + } + + public override int Read (byte[] buffer, int offset, int count) + { + byte[] buf; + int nread; + + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The backing stream has been closed."); + + if (offset > buffer.Length) + throw new ArgumentOutOfRangeException ("offset"); + + if (offset + count > buffer.Length) + throw new ArgumentOutOfRangeException ("count"); + + if (offset != 0) + buf = new byte [count]; + else + buf = buffer; + + nread = (int) stream.Read (buf, (uint) count); + + if (nread < 0) + throw new IOException (); + + if (buf != buffer && nread > 0) + Array.Copy (buf, 0, buffer, offset, nread); + + return nread; + } + + public override void Write (byte[] buffer, int offset, int count) + { + int nwritten; + byte[] buf; + + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The backing stream has been closed."); + + if (offset > buffer.Length) + throw new ArgumentOutOfRangeException ("offset"); + + if (offset + count > buffer.Length) + throw new ArgumentOutOfRangeException ("count"); + + if (offset != 0) { + buf = new byte [count]; + Array.Copy (buffer, offset, buf, 0, count); + } else { + buf = buffer; + } + + nwritten = (int) stream.Write (buf, (uint) count); + + if (nwritten < 0) + throw new IOException (); + } + + public override long Seek (long offset, SeekOrigin origin) + { + if (stream == null) + throw new ObjectDisposedException ("GMimeStream", "The backing stream has been closed."); + + if (stream is StreamFilter) { + if (offset != 0 || origin != SeekOrigin.Begin) + throw new NotSupportedException (); + + // offset = 0 is a special case and means reset the streamfilter + ((StreamFilter) stream).Reset (); + return 0; + } + + long ret = -1; + + switch (origin) { + case SeekOrigin.Begin: + if (offset < 0) + throw new ArgumentOutOfRangeException (); + + ret = stream.Seek (offset, GMime.SeekWhence.Set); + break; + case SeekOrigin.Current: + ret = stream.Seek (offset, GMime.SeekWhence.Cur); + break; + case SeekOrigin.End: + if (offset > 0) + throw new ArgumentOutOfRangeException (); + + ret = stream.Seek (offset, GMime.SeekWhence.End); + break; + } + + if (ret == -1) + throw new IOException (); + + return ret; + } + + public override void SetLength (long value) + { + throw new NotSupportedException (); + } + } +} diff --git a/mono/gmime-api.raw b/mono/gmime-api.raw new file mode 100644 index 0000000..a906d8b --- /dev/null +++ b/mono/gmime-api.raw @@ -0,0 +1,3267 @@ +<?xml version="1.0"?> +<api> + <!-- + + This file was automatically generated. + Please DO NOT MODIFY THIS FILE, modify .metadata files instead. + +--> + <namespace name="GMime" library="gmime"> + <enum name="CertificateTrust" cname="GMimeCertificateTrust" type="enum"> + <member cname="GMIME_CERTIFICATE_TRUST_NONE" name="None" /> + <member cname="GMIME_CERTIFICATE_TRUST_NEVER" name="Never" /> + <member cname="GMIME_CERTIFICATE_TRUST_UNDEFINED" name="Undefined" /> + <member cname="GMIME_CERTIFICATE_TRUST_MARGINAL" name="Marginal" /> + <member cname="GMIME_CERTIFICATE_TRUST_FULLY" name="Fully" /> + <member cname="GMIME_CERTIFICATE_TRUST_ULTIMATE" name="Ultimate" /> + </enum> + <enum name="CipherAlgo" cname="GMimeCipherAlgo" type="enum"> + <member cname="GMIME_CIPHER_ALGO_DEFAULT" name="Default" /> + <member cname="GMIME_CIPHER_ALGO_IDEA" name="Idea" value="1" /> + <member cname="GMIME_CIPHER_ALGO_3DES" name="ThreeDes" value="2" /> + <member cname="GMIME_CIPHER_ALGO_CAST5" name="Cast5" value="3" /> + <member cname="GMIME_CIPHER_ALGO_BLOWFISH" name="Blowfish" value="4" /> + <member cname="GMIME_CIPHER_ALGO_AES" name="Aes" value="7" /> + <member cname="GMIME_CIPHER_ALGO_AES192" name="Aes192" value="8" /> + <member cname="GMIME_CIPHER_ALGO_AES256" name="Aes256" value="9" /> + <member cname="GMIME_CIPHER_ALGO_TWOFISH" name="Twofish" value="10" /> + <member cname="GMIME_CIPHER_ALGO_CAMELLIA128" name="Camellia128" value="11" /> + <member cname="GMIME_CIPHER_ALGO_CAMELLIA192" name="Camellia192" value="12" /> + <member cname="GMIME_CIPHER_ALGO_CAMELLIA256" name="Camellia256" value="13" /> + </enum> + <enum name="ContentEncoding" cname="GMimeContentEncoding" type="enum"> + <member cname="GMIME_CONTENT_ENCODING_DEFAULT" name="Default" /> + <member cname="GMIME_CONTENT_ENCODING_7BIT" name="7Bit" /> + <member cname="GMIME_CONTENT_ENCODING_8BIT" name="8Bit" /> + <member cname="GMIME_CONTENT_ENCODING_BINARY" name="Binary" /> + <member cname="GMIME_CONTENT_ENCODING_BASE64" name="Base64" /> + <member cname="GMIME_CONTENT_ENCODING_QUOTEDPRINTABLE" name="Quotedprintable" /> + <member cname="GMIME_CONTENT_ENCODING_UUENCODE" name="Uuencode" /> + </enum> + <enum name="DigestAlgo" cname="GMimeDigestAlgo" type="enum"> + <member cname="GMIME_DIGEST_ALGO_DEFAULT" name="Default" /> + <member cname="GMIME_DIGEST_ALGO_MD5" name="Md5" value="1" /> + <member cname="GMIME_DIGEST_ALGO_SHA1" name="Sha1" value="2" /> + <member cname="GMIME_DIGEST_ALGO_RIPEMD160" name="Ripemd160" value="3" /> + <member cname="GMIME_DIGEST_ALGO_MD2" name="Md2" value="5" /> + <member cname="GMIME_DIGEST_ALGO_TIGER192" name="Tiger192" value="6" /> + <member cname="GMIME_DIGEST_ALGO_HAVAL5160" name="Haval5160" value="7" /> + <member cname="GMIME_DIGEST_ALGO_SHA256" name="Sha256" value="8" /> + <member cname="GMIME_DIGEST_ALGO_SHA384" name="Sha384" value="9" /> + <member cname="GMIME_DIGEST_ALGO_SHA512" name="Sha512" value="10" /> + <member cname="GMIME_DIGEST_ALGO_SHA224" name="Sha224" value="11" /> + <member cname="GMIME_DIGEST_ALGO_MD4" name="Md4" value="301" /> + </enum> + <enum name="EncodingConstraint" cname="GMimeEncodingConstraint" type="enum"> + <member cname="GMIME_ENCODING_CONSTRAINT_7BIT" name="7Bit" /> + <member cname="GMIME_ENCODING_CONSTRAINT_8BIT" name="8Bit" /> + <member cname="GMIME_ENCODING_CONSTRAINT_BINARY" name="Binary" /> + </enum> + <enum name="FilterBestFlags" cname="GMimeFilterBestFlags" type="flags"> + <member cname="GMIME_FILTER_BEST_CHARSET" name="Charset" value="1 << 0" /> + <member cname="GMIME_FILTER_BEST_ENCODING" name="Encoding" value="1 << 1" /> + </enum> + <enum name="FilterFromMode" cname="GMimeFilterFromMode" type="enum"> + <member cname="GMIME_FILTER_FROM_MODE_DEFAULT" name="Default" /> + <member cname="GMIME_FILTER_FROM_MODE_ESCAPE" name="Escape" /> + <member cname="GMIME_FILTER_FROM_MODE_ARMOR" name="Armor" value="1" /> + </enum> + <enum name="FilterGZipMode" cname="GMimeFilterGZipMode" type="enum"> + <member cname="GMIME_FILTER_GZIP_MODE_ZIP" name="Zip" /> + <member cname="GMIME_FILTER_GZIP_MODE_UNZIP" name="Unzip" /> + </enum> + <enum name="PubKeyAlgo" cname="GMimePubKeyAlgo" type="enum"> + <member cname="GMIME_PUBKEY_ALGO_DEFAULT" name="Default" /> + <member cname="GMIME_PUBKEY_ALGO_RSA" name="Rsa" value="1" /> + <member cname="GMIME_PUBKEY_ALGO_RSA_E" name="RsaE" value="2" /> + <member cname="GMIME_PUBKEY_ALGO_RSA_S" name="RsaS" value="3" /> + <member cname="GMIME_PUBKEY_ALGO_ELG_E" name="ElgE" value="16" /> + <member cname="GMIME_PUBKEY_ALGO_DSA" name="Dsa" value="17" /> + <member cname="GMIME_PUBKEY_ALGO_ELG" name="Elg" value="20" /> + </enum> + <enum name="RecipientType" cname="GMimeRecipientType" type="enum"> + <member cname="GMIME_RECIPIENT_TYPE_TO" name="To" /> + <member cname="GMIME_RECIPIENT_TYPE_CC" name="Cc" /> + <member cname="GMIME_RECIPIENT_TYPE_BCC" name="Bcc" /> + </enum> + <enum name="SeekWhence" cname="GMimeSeekWhence" type="enum"> + <member cname="GMIME_STREAM_SEEK_SET" name="Set" value="SEEK_SET" /> + <member cname="GMIME_STREAM_SEEK_CUR" name="Cur" value="SEEK_CUR" /> + <member cname="GMIME_STREAM_SEEK_END" name="End" value="SEEK_END" /> + </enum> + <enum name="SignatureError" cname="GMimeSignatureError" type="flags"> + <member cname="GMIME_SIGNATURE_ERROR_NONE" name="None" /> + <member cname="GMIME_SIGNATURE_ERROR_EXPSIG" name="Expsig" value="1 << 0" /> + <member cname="GMIME_SIGNATURE_ERROR_NO_PUBKEY" name="NoPubkey" value="1 << 1" /> + <member cname="GMIME_SIGNATURE_ERROR_EXPKEYSIG" name="Expkeysig" value="1 << 2" /> + <member cname="GMIME_SIGNATURE_ERROR_REVKEYSIG" name="Revkeysig" value="1 << 3" /> + <member cname="GMIME_SIGNATURE_ERROR_UNSUPP_ALGO" name="UnsuppAlgo" value="1 << 4" /> + </enum> + <enum name="SignatureStatus" cname="GMimeSignatureStatus" type="enum"> + <member cname="GMIME_SIGNATURE_STATUS_GOOD" name="Good" /> + <member cname="GMIME_SIGNATURE_STATUS_ERROR" name="Error" /> + <member cname="GMIME_SIGNATURE_STATUS_BAD" name="Bad" /> + </enum> + <enum name="StreamBufferMode" cname="GMimeStreamBufferMode" type="enum"> + <member cname="GMIME_STREAM_BUFFER_CACHE_READ" name="CacheRead" /> + <member cname="GMIME_STREAM_BUFFER_BLOCK_READ" name="BlockRead" /> + <member cname="GMIME_STREAM_BUFFER_BLOCK_WRITE" name="BlockWrite" /> + </enum> + <callback name="EventCallback" cname="GMimeEventCallback"> + <return-type type="void" /> + <parameters> + <parameter type="gpointer" name="sender" /> + <parameter type="gpointer" name="args" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </callback> + <callback name="HeaderForeachFunc" cname="GMimeHeaderForeachFunc"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </callback> + <callback name="HeaderWriter" cname="GMimeHeaderWriter"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </callback> + <callback name="ObjectForeachFunc" cname="GMimeObjectForeachFunc"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="parent" /> + <parameter type="GMimeObject*" name="part" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </callback> + <callback name="ParserHeaderRegexFunc" cname="GMimeParserHeaderRegexFunc"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeParser*" name="parser" /> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + <parameter type="gint64" name="offset" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </callback> + <callback name="PasswordRequestFunc" cname="GMimePasswordRequestFunc"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="const-char*" name="user_id" /> + <parameter type="const-char*" name="prompt_ctx" /> + <parameter type="gboolean" name="reprompt" /> + <parameter type="GMimeStream*" name="response" /> + <parameter type="GError**" name="err" /> + </parameters> + </callback> + <object name="Certificate" cname="GMimeCertificate" parent="GObject"> + <field name="PubkeyAlgo" cname="pubkey_algo" type="GMimePubKeyAlgo" /> + <field name="DigestAlgo" cname="digest_algo" type="GMimeDigestAlgo" /> + <field name="Trust" cname="trust" type="GMimeCertificateTrust" /> + <field name="IssuerSerial" cname="issuer_serial" type="char*" /> + <field name="IssuerName" cname="issuer_name" type="char*" /> + <field name="Fingerprint" cname="fingerprint" type="char*" /> + <field name="Created" cname="created" type="time_t" /> + <field name="Expires" cname="expires" type="time_t" /> + <field name="Keyid" cname="keyid" type="char*" /> + <field name="Email" cname="email" type="char*" /> + <field name="Name" cname="name" type="char*" /> + <method name="GetCreated" cname="g_mime_certificate_get_created"> + <return-type type="time_t" /> + </method> + <method name="GetDigestAlgo" cname="g_mime_certificate_get_digest_algo"> + <return-type type="GMimeDigestAlgo" /> + </method> + <method name="GetEmail" cname="g_mime_certificate_get_email"> + <return-type type="const-char*" /> + </method> + <method name="GetExpires" cname="g_mime_certificate_get_expires"> + <return-type type="time_t" /> + </method> + <method name="GetFingerprint" cname="g_mime_certificate_get_fingerprint"> + <return-type type="const-char*" /> + </method> + <method name="GetIssuerName" cname="g_mime_certificate_get_issuer_name"> + <return-type type="const-char*" /> + </method> + <method name="GetIssuerSerial" cname="g_mime_certificate_get_issuer_serial"> + <return-type type="const-char*" /> + </method> + <method name="GetKeyId" cname="g_mime_certificate_get_key_id"> + <return-type type="const-char*" /> + </method> + <method name="GetName" cname="g_mime_certificate_get_name"> + <return-type type="const-char*" /> + </method> + <method name="GetPubkeyAlgo" cname="g_mime_certificate_get_pubkey_algo"> + <return-type type="GMimePubKeyAlgo" /> + </method> + <method name="GetTrust" cname="g_mime_certificate_get_trust"> + <return-type type="GMimeCertificateTrust" /> + </method> + <method name="GetType" cname="g_mime_certificate_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_certificate_new" /> + <method name="SetCreated" cname="g_mime_certificate_set_created"> + <return-type type="void" /> + <parameters> + <parameter type="time_t" name="created" /> + </parameters> + </method> + <method name="SetDigestAlgo" cname="g_mime_certificate_set_digest_algo"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeDigestAlgo" name="algo" /> + </parameters> + </method> + <method name="SetEmail" cname="g_mime_certificate_set_email"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="email" /> + </parameters> + </method> + <method name="SetExpires" cname="g_mime_certificate_set_expires"> + <return-type type="void" /> + <parameters> + <parameter type="time_t" name="expires" /> + </parameters> + </method> + <method name="SetFingerprint" cname="g_mime_certificate_set_fingerprint"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="fingerprint" /> + </parameters> + </method> + <method name="SetIssuerName" cname="g_mime_certificate_set_issuer_name"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="issuer_name" /> + </parameters> + </method> + <method name="SetIssuerSerial" cname="g_mime_certificate_set_issuer_serial"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="issuer_serial" /> + </parameters> + </method> + <method name="SetKeyId" cname="g_mime_certificate_set_key_id"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="key_id" /> + </parameters> + </method> + <method name="SetName" cname="g_mime_certificate_set_name"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="SetPubkeyAlgo" cname="g_mime_certificate_set_pubkey_algo"> + <return-type type="void" /> + <parameters> + <parameter type="GMimePubKeyAlgo" name="algo" /> + </parameters> + </method> + <method name="SetTrust" cname="g_mime_certificate_set_trust"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeCertificateTrust" name="trust" /> + </parameters> + </method> + </object> + <object name="CertificateList" cname="GMimeCertificateList" parent="GObject"> + <field name="Array" cname="array" type="GPtrArray*" /> + <method name="Add" cname="g_mime_certificate_list_add"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="Clear" cname="g_mime_certificate_list_clear"> + <return-type type="void" /> + </method> + <method name="Contains" cname="g_mime_certificate_list_contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="GetCertificate" cname="g_mime_certificate_list_get_certificate"> + <return-type type="GMimeCertificate*" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_certificate_list_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IndexOf" cname="g_mime_certificate_list_index_of"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="Insert" cname="g_mime_certificate_list_insert"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="Length" cname="g_mime_certificate_list_length"> + <return-type type="int" /> + </method> + <constructor cname="g_mime_certificate_list_new" /> + <method name="Remove" cname="g_mime_certificate_list_remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="RemoveAt" cname="g_mime_certificate_list_remove_at"> + <return-type type="gboolean" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="SetCertificate" cname="g_mime_certificate_list_set_certificate"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + </object> + <object name="CryptoContext" cname="GMimeCryptoContext" parent="GObject"> + <field name="RequestPasswd" cname="request_passwd" type="GMimePasswordRequestFunc" /> + <virtual_method name="DigestId" cname="digest_id"> + <return-type type="GMimeDigestAlgo" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="const-char*" name="name" /> + </parameters> + </virtual_method> + <virtual_method name="Sign" cname="sign"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <virtual_method name="Verify" cname="verify"> + <return-type type="GMimeSignatureList*" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="sigstream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <virtual_method name="Encrypt" cname="encrypt"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="gboolean" name="sign" /> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GPtrArray*" name="recipients" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <virtual_method name="Decrypt" cname="decrypt"> + <return-type type="GMimeDecryptResult*" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <virtual_method name="ImportKeys" cname="import_keys"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <virtual_method name="ExportKeys" cname="export_keys"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GPtrArray*" name="keys" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </virtual_method> + <method name="Decrypt" cname="g_mime_crypto_context_decrypt"> + <return-type type="GMimeDecryptResult*" /> + <parameters> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="DigestId" cname="g_mime_crypto_context_digest_id"> + <return-type type="GMimeDigestAlgo" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="DigestName" cname="g_mime_crypto_context_digest_name"> + <return-type type="const-char*" /> + <parameters> + <parameter type="GMimeDigestAlgo" name="digest" /> + </parameters> + </method> + <method name="Encrypt" cname="g_mime_crypto_context_encrypt"> + <return-type type="int" /> + <parameters> + <parameter type="gboolean" name="sign" /> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GPtrArray*" name="recipients" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="ExportKeys" cname="g_mime_crypto_context_export_keys"> + <return-type type="int" /> + <parameters> + <parameter type="GPtrArray*" name="keys" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="GetEncryptionProtocol" cname="g_mime_crypto_context_get_encryption_protocol"> + <return-type type="const-char*" /> + </method> + <method name="GetKeyExchangeProtocol" cname="g_mime_crypto_context_get_key_exchange_protocol"> + <return-type type="const-char*" /> + </method> + <method name="GetSignatureProtocol" cname="g_mime_crypto_context_get_signature_protocol"> + <return-type type="const-char*" /> + </method> + <method name="GetType" cname="g_mime_crypto_context_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="ImportKeys" cname="g_mime_crypto_context_import_keys"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="SetRequestPassword" cname="g_mime_crypto_context_set_request_password"> + <return-type type="void" /> + <parameters> + <parameter type="GMimePasswordRequestFunc" name="request_passwd" /> + </parameters> + </method> + <method name="Sign" cname="g_mime_crypto_context_sign"> + <return-type type="int" /> + <parameters> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="ostream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="Verify" cname="g_mime_crypto_context_verify"> + <return-type type="GMimeSignatureList*" /> + <parameters> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GMimeStream*" name="istream" /> + <parameter type="GMimeStream*" name="sigstream" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + </object> + <object name="DataWrapper" cname="GMimeDataWrapper" parent="GObject"> + <field name="Encoding" cname="encoding" type="GMimeContentEncoding" /> + <field name="Stream" cname="stream" type="GMimeStream*" /> + <virtual_method name="WriteToStream" cname="write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeDataWrapper*" name="wrapper" /> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <method name="GetEncoding" cname="g_mime_data_wrapper_get_encoding"> + <return-type type="GMimeContentEncoding" /> + </method> + <method name="GetStream" cname="g_mime_data_wrapper_get_stream"> + <return-type type="GMimeStream*" /> + </method> + <method name="GetType" cname="g_mime_data_wrapper_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_data_wrapper_new" /> + <constructor cname="g_mime_data_wrapper_new_with_stream"> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </constructor> + <method name="SetEncoding" cname="g_mime_data_wrapper_set_encoding"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </method> + <method name="SetStream" cname="g_mime_data_wrapper_set_stream"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + <method name="WriteToStream" cname="g_mime_data_wrapper_write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + </object> + <object name="DecryptResult" cname="GMimeDecryptResult" parent="GObject"> + <field name="Recipients" cname="recipients" type="GMimeCertificateList*" /> + <field name="Signatures" cname="signatures" type="GMimeSignatureList*" /> + <field name="Cipher" cname="cipher" type="GMimeCipherAlgo" /> + <field name="Mdc" cname="mdc" type="GMimeDigestAlgo" /> + <method name="GetCipher" cname="g_mime_decrypt_result_get_cipher"> + <return-type type="GMimeCipherAlgo" /> + </method> + <method name="GetMdc" cname="g_mime_decrypt_result_get_mdc"> + <return-type type="GMimeDigestAlgo" /> + </method> + <method name="GetRecipients" cname="g_mime_decrypt_result_get_recipients"> + <return-type type="GMimeCertificateList*" /> + </method> + <method name="GetSignatures" cname="g_mime_decrypt_result_get_signatures"> + <return-type type="GMimeSignatureList*" /> + </method> + <method name="GetType" cname="g_mime_decrypt_result_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_decrypt_result_new" /> + <method name="SetCipher" cname="g_mime_decrypt_result_set_cipher"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeCipherAlgo" name="cipher" /> + </parameters> + </method> + <method name="SetMdc" cname="g_mime_decrypt_result_set_mdc"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeDigestAlgo" name="mdc" /> + </parameters> + </method> + <method name="SetRecipients" cname="g_mime_decrypt_result_set_recipients"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeCertificateList*" name="recipients" /> + </parameters> + </method> + <method name="SetSignatures" cname="g_mime_decrypt_result_set_signatures"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeSignatureList*" name="signatures" /> + </parameters> + </method> + </object> + <object name="Filter" cname="GMimeFilter" parent="GObject"> + <field name="Priv" cname="priv" type="struct-_GMimeFilterPrivate*" /> + <field name="Outreal" cname="outreal" type="char*" /> + <field name="Outbuf" cname="outbuf" type="char*" /> + <field name="Outptr" cname="outptr" type="char*" /> + <field name="Outsize" cname="outsize" type="size_t" /> + <field name="Outpre" cname="outpre" type="size_t" /> + <field name="Backbuf" cname="backbuf" type="char*" /> + <field name="Backsize" cname="backsize" type="size_t" /> + <field name="Backlen" cname="backlen" type="size_t" /> + <virtual_method name="Copy" cname="copy"> + <return-type type="GMimeFilter*" owned="true" /> + <parameters> + <parameter type="GMimeFilter*" name="filter" /> + </parameters> + </virtual_method> + <virtual_method name="Filter" cname="filter"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeFilter*" name="filter" /> + <parameter type="char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="size_t" name="prespace" /> + <parameter type="char**" name="outbuf" /> + <parameter type="size_t*" name="outlen" /> + <parameter type="size_t*" name="outprespace" /> + </parameters> + </virtual_method> + <virtual_method name="Complete" cname="complete"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeFilter*" name="filter" /> + <parameter type="char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="size_t" name="prespace" /> + <parameter type="char**" name="outbuf" /> + <parameter type="size_t*" name="outlen" /> + <parameter type="size_t*" name="outprespace" /> + </parameters> + </virtual_method> + <virtual_method name="Reset" cname="reset"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeFilter*" name="filter" /> + </parameters> + </virtual_method> + <method name="Backup" cname="g_mime_filter_backup"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="data" /> + <parameter type="size_t" name="length" /> + </parameters> + </method> + <method name="Complete" cname="g_mime_filter_complete"> + <return-type type="void" /> + <parameters> + <parameter type="char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="size_t" name="prespace" /> + <parameter type="char**" name="outbuf" /> + <parameter type="size_t*" name="outlen" /> + <parameter type="size_t*" name="outprespace" /> + </parameters> + </method> + <method name="Copy" cname="g_mime_filter_copy"> + <return-type type="GMimeFilter*" owned="true" /> + </method> + <method name="Filter" cname="g_mime_filter_filter"> + <return-type type="void" /> + <parameters> + <parameter type="char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="size_t" name="prespace" /> + <parameter type="char**" name="outbuf" /> + <parameter type="size_t*" name="outlen" /> + <parameter type="size_t*" name="outprespace" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_filter_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="Reset" cname="g_mime_filter_reset"> + <return-type type="void" /> + </method> + <method name="SetSize" cname="g_mime_filter_set_size"> + <return-type type="void" /> + <parameters> + <parameter type="size_t" name="size" /> + <parameter type="gboolean" name="keep" /> + </parameters> + </method> + </object> + <object name="FilterBasic" cname="GMimeFilterBasic" parent="GMimeFilter"> + <field name="Encoder" cname="encoder" type="GMimeEncoding" /> + <method name="GetType" cname="g_mime_filter_basic_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_basic_new"> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + <parameter type="gboolean" name="encode" /> + </parameters> + </constructor> + </object> + <object name="FilterBest" cname="GMimeFilterBest" parent="GMimeFilter"> + <field name="Flags" cname="flags" type="GMimeFilterBestFlags" /> + <field name="Charset" cname="charset" type="GMimeCharset" /> + <field name="Count0" cname="count0" type="unsigned int" /> + <field name="Count8" cname="count8" type="unsigned int" /> + <field name="Total" cname="total" type="unsigned int" /> + <field name="Maxline" cname="maxline" type="unsigned int" /> + <field name="Linelen" cname="linelen" type="unsigned int" /> + <field name="Frombuf" cname="frombuf" array_len="6" type="unsigned char" /> + <field name="Fromlen" cname="fromlen" bits="4" type="unsigned int" /> + <field name="Hadfrom" cname="hadfrom" bits="1" type="unsigned int" /> + <field name="Startline" cname="startline" bits="1" type="unsigned int" /> + <field name="Midline" cname="midline" bits="1" type="unsigned int" /> + <method name="Charset" cname="g_mime_filter_best_charset"> + <return-type type="const-char*" /> + </method> + <method name="Encoding" cname="g_mime_filter_best_encoding"> + <return-type type="GMimeContentEncoding" /> + <parameters> + <parameter type="GMimeEncodingConstraint" name="constraint" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_filter_best_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_best_new"> + <parameters> + <parameter type="GMimeFilterBestFlags" name="flags" /> + </parameters> + </constructor> + </object> + <object name="FilterCharset" cname="GMimeFilterCharset" parent="GMimeFilter"> + <field name="FromCharset" cname="from_charset" type="char*" /> + <field name="ToCharset" cname="to_charset" type="char*" /> + <field name="Cd" cname="cd" type="iconv_t" /> + <method name="GetType" cname="g_mime_filter_charset_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_charset_new"> + <parameters> + <parameter type="const-char*" name="from_charset" /> + <parameter type="const-char*" name="to_charset" /> + </parameters> + </constructor> + </object> + <object name="FilterCRLF" cname="GMimeFilterCRLF" parent="GMimeFilter"> + <field name="Encode" cname="encode" type="gboolean" /> + <field name="Dots" cname="dots" type="gboolean" /> + <field name="SawCr" cname="saw_cr" type="gboolean" /> + <field name="SawLf" cname="saw_lf" type="gboolean" /> + <field name="SawDot" cname="saw_dot" type="gboolean" /> + <method name="GetType" cname="g_mime_filter_crlf_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_crlf_new"> + <parameters> + <parameter type="gboolean" name="encode" /> + <parameter type="gboolean" name="dots" /> + </parameters> + </constructor> + </object> + <object name="FilterEnriched" cname="GMimeFilterEnriched" parent="GMimeFilter"> + <field name="Flags" cname="flags" type="guint32" /> + <field name="Nofill" cname="nofill" type="int" /> + <method name="GetType" cname="g_mime_filter_enriched_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_enriched_new"> + <parameters> + <parameter type="guint32" name="flags" /> + </parameters> + </constructor> + </object> + <object name="FilterFrom" cname="GMimeFilterFrom" parent="GMimeFilter"> + <field name="Mode" cname="mode" type="GMimeFilterFromMode" /> + <field name="Midline" cname="midline" type="gboolean" /> + <method name="GetType" cname="g_mime_filter_from_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_from_new"> + <parameters> + <parameter type="GMimeFilterFromMode" name="mode" /> + </parameters> + </constructor> + </object> + <object name="FilterGZip" cname="GMimeFilterGZip" parent="GMimeFilter"> + <field name="Priv" cname="priv" type="struct-_GMimeFilterGZipPrivate*" /> + <field name="Mode" cname="mode" type="GMimeFilterGZipMode" /> + <field name="Level" cname="level" type="int" /> + <method name="GetType" cname="g_mime_filter_gzip_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_gzip_new"> + <parameters> + <parameter type="GMimeFilterGZipMode" name="mode" /> + <parameter type="int" name="level" /> + </parameters> + </constructor> + </object> + <object name="FilterHTML" cname="GMimeFilterHTML" parent="GMimeFilter"> + <field name="Scanner" cname="scanner" type="struct-_UrlScanner*" /> + <field name="Flags" cname="flags" type="guint32" /> + <field name="Colour" cname="colour" type="guint32" /> + <field name="Column" cname="column" bits="31" type="guint32" /> + <field name="PreOpen" cname="pre_open" bits="1" type="guint32" /> + <method name="GetType" cname="g_mime_filter_html_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_html_new"> + <parameters> + <parameter type="guint32" name="flags" /> + <parameter type="guint32" name="colour" /> + </parameters> + </constructor> + </object> + <object name="FilterMd5" cname="GMimeFilterMd5" parent="GMimeFilter"> + <field name="Priv" cname="priv" type="struct-_GMimeFilterMd5Private*" /> + <method name="GetDigest" cname="g_mime_filter_md5_get_digest"> + <return-type type="void" /> + <parameters> + <parameter type="unsigned-char" array="true" name="digest" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_filter_md5_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_md5_new" /> + </object> + <object name="FilterStrip" cname="GMimeFilterStrip" parent="GMimeFilter"> + <method name="GetType" cname="g_mime_filter_strip_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_strip_new" /> + </object> + <object name="FilterWindows" cname="GMimeFilterWindows" parent="GMimeFilter"> + <field name="IsWindows" cname="is_windows" type="gboolean" /> + <field name="ClaimedCharset" cname="claimed_charset" type="char*" /> + <method name="GetType" cname="g_mime_filter_windows_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IsWindowsCharset" cname="g_mime_filter_windows_is_windows_charset"> + <return-type type="gboolean" /> + </method> + <constructor cname="g_mime_filter_windows_new"> + <parameters> + <parameter type="const-char*" name="claimed_charset" /> + </parameters> + </constructor> + <method name="RealCharset" cname="g_mime_filter_windows_real_charset"> + <return-type type="const-char*" /> + </method> + </object> + <object name="FilterYenc" cname="GMimeFilterYenc" parent="GMimeFilter"> + <field name="Encode" cname="encode" type="gboolean" /> + <field name="Part" cname="part" type="int" /> + <field name="State" cname="state" type="int" /> + <field name="Pcrc" cname="pcrc" type="guint32" /> + <field name="Crc" cname="crc" type="guint32" /> + <method name="GetCrc" cname="g_mime_filter_yenc_get_crc"> + <return-type type="guint32" /> + </method> + <method name="GetPcrc" cname="g_mime_filter_yenc_get_pcrc"> + <return-type type="guint32" /> + </method> + <method name="GetType" cname="g_mime_filter_yenc_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_filter_yenc_new"> + <parameters> + <parameter type="gboolean" name="encode" /> + </parameters> + </constructor> + <method name="SetCrc" cname="g_mime_filter_yenc_set_crc"> + <return-type type="void" /> + <parameters> + <parameter type="guint32" name="crc" /> + </parameters> + </method> + <method name="SetState" cname="g_mime_filter_yenc_set_state"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="state" /> + </parameters> + </method> + </object> + <object name="GpgContext" cname="GMimeGpgContext" parent="GMimeCryptoContext"> + <field name="AutoKeyRetrieve" cname="auto_key_retrieve" type="gboolean" /> + <field name="AlwaysTrust" cname="always_trust" type="gboolean" /> + <field name="UseAgent" cname="use_agent" type="gboolean" /> + <field name="Path" cname="path" type="char*" /> + <method name="GetAlwaysTrust" cname="g_mime_gpg_context_get_always_trust"> + <return-type type="gboolean" /> + </method> + <method name="GetAutoKeyRetrieve" cname="g_mime_gpg_context_get_auto_key_retrieve"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_gpg_context_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="GetUseAgent" cname="g_mime_gpg_context_get_use_agent"> + <return-type type="gboolean" /> + </method> + <constructor cname="g_mime_gpg_context_new"> + <parameters> + <parameter type="GMimePasswordRequestFunc" name="request_passwd" /> + <parameter type="const-char*" name="path" /> + </parameters> + </constructor> + <method name="SetAlwaysTrust" cname="g_mime_gpg_context_set_always_trust"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="always_trust" /> + </parameters> + </method> + <method name="SetAutoKeyRetrieve" cname="g_mime_gpg_context_set_auto_key_retrieve"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="auto_key_retrieve" /> + </parameters> + </method> + <method name="SetUseAgent" cname="g_mime_gpg_context_set_use_agent"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="use_agent" /> + </parameters> + </method> + </object> + <object name="Message" cname="GMimeMessage" parent="GMimeObject"> + <field name="Recipients" cname="recipients" type="InternetAddressList**" /> + <field name="MimePart" cname="mime_part" type="GMimeObject*" /> + <field name="MessageId" cname="message_id" type="char*" /> + <field name="ReplyTo" cname="reply_to" type="char*" /> + <field name="Subject" cname="subject" type="char*" /> + <field name="From" cname="from" type="char*" /> + <field name="Date" cname="date" type="time_t" /> + <field name="TzOffset" cname="tz_offset" type="int" /> + <method name="AddRecipient" cname="g_mime_message_add_recipient"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeRecipientType" name="type" /> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="addr" /> + </parameters> + </method> + <method name="Foreach" cname="g_mime_message_foreach"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObjectForeachFunc" name="callback" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </method> + <method name="GetAllRecipients" cname="g_mime_message_get_all_recipients"> + <return-type type="InternetAddressList*" /> + </method> + <method name="GetBody" cname="g_mime_message_get_body"> + <return-type type="GMimeObject*" /> + </method> + <method name="GetDate" cname="g_mime_message_get_date"> + <return-type type="void" /> + <parameters> + <parameter type="time_t*" name="date" /> + <parameter type="int*" name="tz_offset" /> + </parameters> + </method> + <method name="GetDateAsString" cname="g_mime_message_get_date_as_string"> + <return-type type="char*" /> + </method> + <method name="GetMessageId" cname="g_mime_message_get_message_id"> + <return-type type="const-char*" /> + </method> + <method name="GetMimePart" cname="g_mime_message_get_mime_part"> + <return-type type="GMimeObject*" /> + </method> + <method name="GetRecipients" cname="g_mime_message_get_recipients"> + <return-type type="InternetAddressList*" /> + <parameters> + <parameter type="GMimeRecipientType" name="type" /> + </parameters> + </method> + <method name="GetReplyTo" cname="g_mime_message_get_reply_to"> + <return-type type="const-char*" /> + </method> + <method name="GetSender" cname="g_mime_message_get_sender"> + <return-type type="const-char*" /> + </method> + <method name="GetSubject" cname="g_mime_message_get_subject"> + <return-type type="const-char*" /> + </method> + <method name="GetType" cname="g_mime_message_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_message_new"> + <parameters> + <parameter type="gboolean" name="pretty_headers" /> + </parameters> + </constructor> + <method name="SetDate" cname="g_mime_message_set_date"> + <return-type type="void" /> + <parameters> + <parameter type="time_t" name="date" /> + <parameter type="int" name="tz_offset" /> + </parameters> + </method> + <method name="SetDateAsString" cname="g_mime_message_set_date_as_string"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="SetMessageId" cname="g_mime_message_set_message_id"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="message_id" /> + </parameters> + </method> + <method name="SetMimePart" cname="g_mime_message_set_mime_part"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="mime_part" /> + </parameters> + </method> + <method name="SetReplyTo" cname="g_mime_message_set_reply_to"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="reply_to" /> + </parameters> + </method> + <method name="SetSender" cname="g_mime_message_set_sender"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="sender" /> + </parameters> + </method> + <method name="SetSubject" cname="g_mime_message_set_subject"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="subject" /> + </parameters> + </method> + </object> + <object name="MessagePart" cname="GMimeMessagePart" parent="GMimeObject"> + <field name="Message" cname="message" type="GMimeMessage*" /> + <method name="GetMessage" cname="g_mime_message_part_get_message"> + <return-type type="GMimeMessage*" /> + </method> + <method name="GetType" cname="g_mime_message_part_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_message_part_new"> + <parameters> + <parameter type="const-char*" name="subtype" /> + </parameters> + </constructor> + <constructor cname="g_mime_message_part_new_with_message"> + <parameters> + <parameter type="const-char*" name="subtype" /> + <parameter type="GMimeMessage*" name="message" /> + </parameters> + </constructor> + <method name="SetMessage" cname="g_mime_message_part_set_message"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeMessage*" name="message" /> + </parameters> + </method> + </object> + <object name="MessagePartial" cname="GMimeMessagePartial" parent="GMimePart"> + <field name="Number" cname="number" type="int" /> + <field name="Total" cname="total" type="int" /> + <field name="Id" cname="id" type="char*" /> + <method name="GetId" cname="g_mime_message_partial_get_id"> + <return-type type="const-char*" /> + </method> + <method name="GetNumber" cname="g_mime_message_partial_get_number"> + <return-type type="int" /> + </method> + <method name="GetTotal" cname="g_mime_message_partial_get_total"> + <return-type type="int" /> + </method> + <method name="GetType" cname="g_mime_message_partial_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_message_partial_new"> + <parameters> + <parameter type="const-char*" name="id" /> + <parameter type="int" name="number" /> + <parameter type="int" name="total" /> + </parameters> + </constructor> + <method name="ReconstructMessage" cname="g_mime_message_partial_reconstruct_message"> + <return-type type="GMimeMessage*" /> + <parameters> + <parameter type="size_t" name="num" /> + </parameters> + </method> + <method name="SplitMessage" cname="g_mime_message_partial_split_message" shared="true"> + <return-type type="GMimeMessage**" /> + <parameters> + <parameter type="GMimeMessage*" name="message" /> + <parameter type="size_t" name="max_size" /> + <parameter type="size_t*" name="nparts" /> + </parameters> + </method> + </object> + <object name="Multipart" cname="GMimeMultipart" parent="GMimeObject"> + <field name="Children" cname="children" type="GPtrArray*" /> + <field name="Boundary" cname="boundary" type="char*" /> + <field name="Preface" cname="preface" type="char*" /> + <field name="Postface" cname="postface" type="char*" /> + <virtual_method name="Clear" cname="clear"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + </parameters> + </virtual_method> + <virtual_method name="Add" cname="add"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </virtual_method> + <virtual_method name="Insert" cname="insert"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="int" name="index" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </virtual_method> + <virtual_method name="Remove" cname="remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </virtual_method> + <virtual_method name="RemoveAt" cname="remove_at"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="int" name="index" /> + </parameters> + </virtual_method> + <virtual_method name="GetPart" cname="get_part"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="int" name="index" /> + </parameters> + </virtual_method> + <virtual_method name="Contains" cname="contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </virtual_method> + <virtual_method name="IndexOf" cname="index_of"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </virtual_method> + <virtual_method name="GetCount" cname="get_count"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + </parameters> + </virtual_method> + <virtual_method name="SetBoundary" cname="set_boundary"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeMultipart*" name="multipart" /> + <parameter type="const-char*" name="boundary" /> + </parameters> + </virtual_method> + <method name="Add" cname="g_mime_multipart_add"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </method> + <method name="Clear" cname="g_mime_multipart_clear"> + <return-type type="void" /> + </method> + <method name="Contains" cname="g_mime_multipart_contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </method> + <method name="Foreach" cname="g_mime_multipart_foreach"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObjectForeachFunc" name="callback" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </method> + <method name="GetBoundary" cname="g_mime_multipart_get_boundary"> + <return-type type="const-char*" /> + </method> + <method name="GetCount" cname="g_mime_multipart_get_count"> + <return-type type="int" /> + </method> + <method name="GetPart" cname="g_mime_multipart_get_part"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="GetPostface" cname="g_mime_multipart_get_postface"> + <return-type type="const-char*" /> + </method> + <method name="GetPreface" cname="g_mime_multipart_get_preface"> + <return-type type="const-char*" /> + </method> + <method name="GetSubpartFromContentId" cname="g_mime_multipart_get_subpart_from_content_id"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="const-char*" name="content_id" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_multipart_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IndexOf" cname="g_mime_multipart_index_of"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </method> + <method name="Insert" cname="g_mime_multipart_insert"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </method> + <constructor cname="g_mime_multipart_new" /> + <constructor cname="g_mime_multipart_new_with_subtype"> + <parameters> + <parameter type="const-char*" name="subtype" /> + </parameters> + </constructor> + <method name="Remove" cname="g_mime_multipart_remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeObject*" name="part" /> + </parameters> + </method> + <method name="RemoveAt" cname="g_mime_multipart_remove_at"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="Replace" cname="g_mime_multipart_replace"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeObject*" name="replacement" /> + </parameters> + </method> + <method name="SetBoundary" cname="g_mime_multipart_set_boundary"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="boundary" /> + </parameters> + </method> + <method name="SetPostface" cname="g_mime_multipart_set_postface"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="postface" /> + </parameters> + </method> + <method name="SetPreface" cname="g_mime_multipart_set_preface"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="preface" /> + </parameters> + </method> + </object> + <object name="MultipartEncrypted" cname="GMimeMultipartEncrypted" parent="GMimeMultipart"> + <method name="Decrypt" cname="g_mime_multipart_encrypted_decrypt"> + <return-type type="GMimeObject*" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GMimeDecryptResult**" name="result" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="Encrypt" cname="g_mime_multipart_encrypted_encrypt"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeObject*" name="content" /> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="gboolean" name="sign" /> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GPtrArray*" name="recipients" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_multipart_encrypted_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_multipart_encrypted_new" /> + </object> + <object name="MultipartSigned" cname="GMimeMultipartSigned" parent="GMimeMultipart"> + <method name="GetType" cname="g_mime_multipart_signed_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_multipart_signed_new" /> + <method name="Sign" cname="g_mime_multipart_signed_sign"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeObject*" name="content" /> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="const-char*" name="userid" /> + <parameter type="GMimeDigestAlgo" name="digest" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + <method name="Verify" cname="g_mime_multipart_signed_verify"> + <return-type type="GMimeSignatureList*" /> + <parameters> + <parameter type="GMimeCryptoContext*" name="ctx" /> + <parameter type="GError**" name="err" /> + </parameters> + </method> + </object> + <object name="Object" cname="GMimeObject" parent="GObject"> + <field name="Disposition" cname="disposition" type="GMimeContentDisposition*" /> + <field name="ContentType" cname="content_type" type="GMimeContentType*" /> + <field name="Headers" cname="headers" type="GMimeHeaderList*" /> + <field name="ContentId" cname="content_id" type="char*" /> + <virtual_method name="PrependHeader" cname="prepend_header"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </virtual_method> + <virtual_method name="AppendHeader" cname="append_header"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </virtual_method> + <virtual_method name="SetHeader" cname="set_header"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </virtual_method> + <virtual_method name="RemoveHeader" cname="remove_header"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="const-char*" name="header" /> + </parameters> + </virtual_method> + <virtual_method name="SetContentType" cname="set_content_type"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="GMimeContentType*" name="content_type" /> + </parameters> + </virtual_method> + <virtual_method name="GetHeaders" cname="get_headers"> + <return-type type="char*" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + </parameters> + </virtual_method> + <virtual_method name="WriteToStream" cname="write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Encode" cname="encode"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeObject*" name="object" /> + <parameter type="GMimeEncodingConstraint" name="constraint" /> + </parameters> + </virtual_method> + <method name="AppendHeader" cname="g_mime_object_append_header"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="Encode" cname="g_mime_object_encode"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeEncodingConstraint" name="constraint" /> + </parameters> + </method> + <method name="GetContentDisposition" cname="g_mime_object_get_content_disposition"> + <return-type type="GMimeContentDisposition*" /> + </method> + <method name="GetContentDispositionParameter" cname="g_mime_object_get_content_disposition_parameter"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + </parameters> + </method> + <method name="GetContentId" cname="g_mime_object_get_content_id"> + <return-type type="const-char*" /> + </method> + <method name="GetContentType" cname="g_mime_object_get_content_type"> + <return-type type="GMimeContentType*" /> + </method> + <method name="GetContentTypeParameter" cname="g_mime_object_get_content_type_parameter"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="GetDisposition" cname="g_mime_object_get_disposition"> + <return-type type="const-char*" /> + </method> + <method name="GetHeader" cname="g_mime_object_get_header"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="header" /> + </parameters> + </method> + <method name="GetHeaderList" cname="g_mime_object_get_header_list"> + <return-type type="GMimeHeaderList*" /> + </method> + <method name="GetHeaders" cname="g_mime_object_get_headers"> + <return-type type="char*" /> + </method> + <method name="GetType" cname="g_mime_object_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_object_new"> + <parameters> + <parameter type="GMimeContentType*" name="content_type" /> + </parameters> + </constructor> + <constructor cname="g_mime_object_new_type"> + <parameters> + <parameter type="const-char*" name="type" /> + <parameter type="const-char*" name="subtype" /> + </parameters> + </constructor> + <method name="PrependHeader" cname="g_mime_object_prepend_header"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="RegisterType" cname="g_mime_object_register_type" shared="true"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="type" /> + <parameter type="const-char*" name="subtype" /> + <parameter type="GType" name="object_type" /> + </parameters> + </method> + <method name="RemoveHeader" cname="g_mime_object_remove_header"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="header" /> + </parameters> + </method> + <method name="SetContentDisposition" cname="g_mime_object_set_content_disposition"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentDisposition*" name="disposition" /> + </parameters> + </method> + <method name="SetContentDispositionParameter" cname="g_mime_object_set_content_disposition_parameter"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetContentId" cname="g_mime_object_set_content_id"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="content_id" /> + </parameters> + </method> + <method name="SetContentType" cname="g_mime_object_set_content_type"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentType*" name="content_type" /> + </parameters> + </method> + <method name="SetContentTypeParameter" cname="g_mime_object_set_content_type_parameter"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetDisposition" cname="g_mime_object_set_disposition"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="disposition" /> + </parameters> + </method> + <method name="SetHeader" cname="g_mime_object_set_header"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="header" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="ToString" cname="g_mime_object_to_string"> + <return-type type="char*" /> + </method> + <method name="WriteToStream" cname="g_mime_object_write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + </object> + <object name="Parser" cname="GMimeParser" parent="GObject"> + <field name="Priv" cname="priv" type="struct-_GMimeParserPrivate*" /> + <method name="ConstructMessage" cname="g_mime_parser_construct_message"> + <return-type type="GMimeMessage*" /> + </method> + <method name="ConstructPart" cname="g_mime_parser_construct_part"> + <return-type type="GMimeObject*" /> + </method> + <method name="Eos" cname="g_mime_parser_eos"> + <return-type type="gboolean" /> + </method> + <method name="GetFrom" cname="g_mime_parser_get_from"> + <return-type type="char*" /> + </method> + <method name="GetFromOffset" cname="g_mime_parser_get_from_offset"> + <return-type type="gint64" /> + </method> + <method name="GetHeadersBegin" cname="g_mime_parser_get_headers_begin"> + <return-type type="gint64" /> + </method> + <method name="GetHeadersEnd" cname="g_mime_parser_get_headers_end"> + <return-type type="gint64" /> + </method> + <method name="GetPersistStream" cname="g_mime_parser_get_persist_stream"> + <return-type type="gboolean" /> + </method> + <method name="GetRespectContentLength" cname="g_mime_parser_get_respect_content_length"> + <return-type type="gboolean" /> + </method> + <method name="GetScanFrom" cname="g_mime_parser_get_scan_from"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_parser_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="InitWithStream" cname="g_mime_parser_init_with_stream"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + <constructor cname="g_mime_parser_new" /> + <constructor cname="g_mime_parser_new_with_stream"> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </constructor> + <method name="SetHeaderRegex" cname="g_mime_parser_set_header_regex"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="regex" /> + <parameter type="GMimeParserHeaderRegexFunc" name="header_cb" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </method> + <method name="SetPersistStream" cname="g_mime_parser_set_persist_stream"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="persist" /> + </parameters> + </method> + <method name="SetRespectContentLength" cname="g_mime_parser_set_respect_content_length"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="respect_content_length" /> + </parameters> + </method> + <method name="SetScanFrom" cname="g_mime_parser_set_scan_from"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="scan_from" /> + </parameters> + </method> + <method name="Tell" cname="g_mime_parser_tell"> + <return-type type="gint64" /> + </method> + </object> + <object name="Part" cname="GMimePart" parent="GMimeObject"> + <field name="Encoding" cname="encoding" type="GMimeContentEncoding" /> + <field name="ContentDescription" cname="content_description" type="char*" /> + <field name="ContentLocation" cname="content_location" type="char*" /> + <field name="ContentMd5" cname="content_md5" type="char*" /> + <field name="Content" cname="content" type="GMimeDataWrapper*" /> + <virtual_method name="SetContentObject" cname="set_content_object"> + <return-type type="void" /> + <parameters> + <parameter type="GMimePart*" name="mime_part" /> + <parameter type="GMimeDataWrapper*" name="content" /> + </parameters> + </virtual_method> + <method name="GetBestContentEncoding" cname="g_mime_part_get_best_content_encoding"> + <return-type type="GMimeContentEncoding" /> + <parameters> + <parameter type="GMimeEncodingConstraint" name="constraint" /> + </parameters> + </method> + <method name="GetContentDescription" cname="g_mime_part_get_content_description"> + <return-type type="const-char*" /> + </method> + <method name="GetContentEncoding" cname="g_mime_part_get_content_encoding"> + <return-type type="GMimeContentEncoding" /> + </method> + <method name="GetContentId" cname="g_mime_part_get_content_id"> + <return-type type="const-char*" /> + </method> + <method name="GetContentLocation" cname="g_mime_part_get_content_location"> + <return-type type="const-char*" /> + </method> + <method name="GetContentMd5" cname="g_mime_part_get_content_md5"> + <return-type type="const-char*" /> + </method> + <method name="GetContentObject" cname="g_mime_part_get_content_object"> + <return-type type="GMimeDataWrapper*" /> + </method> + <method name="GetFilename" cname="g_mime_part_get_filename"> + <return-type type="const-char*" /> + </method> + <method name="GetType" cname="g_mime_part_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_part_new" /> + <constructor cname="g_mime_part_new_with_type"> + <parameters> + <parameter type="const-char*" name="type" /> + <parameter type="const-char*" name="subtype" /> + </parameters> + </constructor> + <method name="SetContentDescription" cname="g_mime_part_set_content_description"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="description" /> + </parameters> + </method> + <method name="SetContentEncoding" cname="g_mime_part_set_content_encoding"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </method> + <method name="SetContentId" cname="g_mime_part_set_content_id"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="content_id" /> + </parameters> + </method> + <method name="SetContentLocation" cname="g_mime_part_set_content_location"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="content_location" /> + </parameters> + </method> + <method name="SetContentMd5" cname="g_mime_part_set_content_md5"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="content_md5" /> + </parameters> + </method> + <method name="SetContentObject" cname="g_mime_part_set_content_object"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeDataWrapper*" name="content" /> + </parameters> + </method> + <method name="SetFilename" cname="g_mime_part_set_filename"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="filename" /> + </parameters> + </method> + <method name="VerifyContentMd5" cname="g_mime_part_verify_content_md5"> + <return-type type="gboolean" /> + </method> + </object> + <object name="Pkcs7Context" cname="GMimePkcs7Context" parent="GMimeCryptoContext"> + <field name="Priv" cname="priv" type="struct-_GMimePkcs7ContextPrivate*" /> + <method name="GetAlwaysTrust" cname="g_mime_pkcs7_context_get_always_trust"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_pkcs7_context_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_pkcs7_context_new"> + <parameters> + <parameter type="GMimePasswordRequestFunc" name="request_passwd" /> + </parameters> + </constructor> + <method name="SetAlwaysTrust" cname="g_mime_pkcs7_context_set_always_trust"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="always_trust" /> + </parameters> + </method> + </object> + <object name="Signature" cname="GMimeSignature" parent="GObject"> + <field name="Status" cname="status" type="GMimeSignatureStatus" /> + <field name="Errors" cname="errors" type="GMimeSignatureError" /> + <field name="Cert" cname="cert" type="GMimeCertificate*" /> + <field name="Created" cname="created" type="time_t" /> + <field name="Expires" cname="expires" type="time_t" /> + <method name="GetCertificate" cname="g_mime_signature_get_certificate"> + <return-type type="GMimeCertificate*" /> + </method> + <method name="GetCreated" cname="g_mime_signature_get_created"> + <return-type type="time_t" /> + </method> + <method name="GetErrors" cname="g_mime_signature_get_errors"> + <return-type type="GMimeSignatureError" /> + </method> + <method name="GetExpires" cname="g_mime_signature_get_expires"> + <return-type type="time_t" /> + </method> + <method name="GetStatus" cname="g_mime_signature_get_status"> + <return-type type="GMimeSignatureStatus" /> + </method> + <method name="GetType" cname="g_mime_signature_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_signature_new" /> + <method name="SetCertificate" cname="g_mime_signature_set_certificate"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeCertificate*" name="cert" /> + </parameters> + </method> + <method name="SetCreated" cname="g_mime_signature_set_created"> + <return-type type="void" /> + <parameters> + <parameter type="time_t" name="created" /> + </parameters> + </method> + <method name="SetErrors" cname="g_mime_signature_set_errors"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeSignatureError" name="errors" /> + </parameters> + </method> + <method name="SetExpires" cname="g_mime_signature_set_expires"> + <return-type type="void" /> + <parameters> + <parameter type="time_t" name="expires" /> + </parameters> + </method> + <method name="SetStatus" cname="g_mime_signature_set_status"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeSignatureStatus" name="status" /> + </parameters> + </method> + </object> + <object name="SignatureList" cname="GMimeSignatureList" parent="GObject"> + <field name="Array" cname="array" type="GPtrArray*" /> + <method name="Add" cname="g_mime_signature_list_add"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + <method name="Clear" cname="g_mime_signature_list_clear"> + <return-type type="void" /> + </method> + <method name="Contains" cname="g_mime_signature_list_contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + <method name="GetSignature" cname="g_mime_signature_list_get_signature"> + <return-type type="GMimeSignature*" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_signature_list_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IndexOf" cname="g_mime_signature_list_index_of"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + <method name="Insert" cname="g_mime_signature_list_insert"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + <method name="Length" cname="g_mime_signature_list_length"> + <return-type type="int" /> + </method> + <constructor cname="g_mime_signature_list_new" /> + <method name="Remove" cname="g_mime_signature_list_remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + <method name="RemoveAt" cname="g_mime_signature_list_remove_at"> + <return-type type="gboolean" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="SetSignature" cname="g_mime_signature_list_set_signature"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="GMimeSignature*" name="sig" /> + </parameters> + </method> + </object> + <object name="Stream" cname="GMimeStream" parent="GObject"> + <field name="SuperStream" cname="super_stream" type="GMimeStream*" /> + <field name="Position" cname="position" type="gint64" /> + <field name="BoundStart" cname="bound_start" type="gint64" /> + <field name="BoundEnd" cname="bound_end" type="gint64" /> + <virtual_method name="Read" cname="read"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="char*" name="buf" /> + <parameter type="size_t" name="len" /> + </parameters> + </virtual_method> + <virtual_method name="Write" cname="write"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="const-char*" name="buf" /> + <parameter type="size_t" name="len" /> + </parameters> + </virtual_method> + <virtual_method name="Flush" cname="flush"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Close" cname="close"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Eos" cname="eos"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Reset" cname="reset"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Seek" cname="seek"> + <return-type type="gint64" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="gint64" name="offset" /> + <parameter type="GMimeSeekWhence" name="whence" /> + </parameters> + </virtual_method> + <virtual_method name="Tell" cname="tell"> + <return-type type="gint64" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Length" cname="length"> + <return-type type="gint64" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </virtual_method> + <virtual_method name="Substream" cname="substream"> + <return-type type="GMimeStream*" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </virtual_method> + <method name="Close" cname="g_mime_stream_close"> + <return-type type="int" /> + </method> + <method name="Construct" cname="g_mime_stream_construct"> + <return-type type="void" /> + <parameters> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </method> + <method name="Eos" cname="g_mime_stream_eos"> + <return-type type="gboolean" /> + </method> + <method name="Flush" cname="g_mime_stream_flush"> + <return-type type="int" /> + </method> + <method name="GetType" cname="g_mime_stream_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="Length" cname="g_mime_stream_length"> + <return-type type="gint64" /> + </method> + <method name="Printf" cname="g_mime_stream_printf"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="const-char*" name="fmt" printf_format="true" /> + <parameter ellipsis="true" printf_format_args="true" /> + </parameters> + </method> + <method name="Read" cname="g_mime_stream_read"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="char*" name="buf" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="Reset" cname="g_mime_stream_reset"> + <return-type type="int" /> + </method> + <method name="Seek" cname="g_mime_stream_seek"> + <return-type type="gint64" /> + <parameters> + <parameter type="gint64" name="offset" /> + <parameter type="GMimeSeekWhence" name="whence" /> + </parameters> + </method> + <method name="SetBounds" cname="g_mime_stream_set_bounds"> + <return-type type="void" /> + <parameters> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </method> + <method name="Substream" cname="g_mime_stream_substream"> + <return-type type="GMimeStream*" /> + <parameters> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </method> + <method name="Tell" cname="g_mime_stream_tell"> + <return-type type="gint64" /> + </method> + <method name="Write" cname="g_mime_stream_write"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="const-char*" name="buf" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="WriteString" cname="g_mime_stream_write_string"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="WriteToStream" cname="g_mime_stream_write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="dest" /> + </parameters> + </method> + <method name="Writev" cname="g_mime_stream_writev"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStreamIOVector*" name="vector" /> + <parameter type="size_t" name="count" /> + </parameters> + </method> + </object> + <object name="StreamBuffer" cname="GMimeStreamBuffer" parent="GMimeStream"> + <field name="Mode" cname="mode" type="GMimeStreamBufferMode" /> + <field name="Source" cname="source" type="GMimeStream*" /> + <field name="Buffer" cname="buffer" type="char*" /> + <field name="Bufptr" cname="bufptr" type="char*" /> + <field name="Bufend" cname="bufend" type="char*" /> + <field name="Buflen" cname="buflen" type="size_t" /> + <method name="GetType" cname="g_mime_stream_buffer_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="Gets" cname="g_mime_stream_buffer_gets" shared="true"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="char*" name="buf" /> + <parameter type="size_t" name="max" /> + </parameters> + </method> + <constructor cname="g_mime_stream_buffer_new"> + <parameters> + <parameter type="GMimeStream*" name="source" /> + <parameter type="GMimeStreamBufferMode" name="mode" /> + </parameters> + </constructor> + <method name="Readln" cname="g_mime_stream_buffer_readln" shared="true"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + <parameter type="GByteArray*" name="buffer" /> + </parameters> + </method> + </object> + <object name="StreamCat" cname="GMimeStreamCat" parent="GMimeStream"> + <field name="Sources" cname="sources" type="struct-_cat_node*" /> + <field name="Current" cname="current" type="struct-_cat_node*" /> + <method name="AddSource" cname="g_mime_stream_cat_add_source"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeStream*" name="source" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_stream_cat_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_cat_new" /> + </object> + <object name="StreamFile" cname="GMimeStreamFile" parent="GMimeStream"> + <field name="Owner" cname="owner" type="gboolean" /> + <field name="Fp" cname="fp" type="FILE*" /> + <method name="GetOwner" cname="g_mime_stream_file_get_owner"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_stream_file_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_file_new"> + <parameters> + <parameter type="FILE*" name="fp" /> + </parameters> + </constructor> + <constructor cname="g_mime_stream_file_new_with_bounds"> + <parameters> + <parameter type="FILE*" name="fp" /> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </constructor> + <method name="SetOwner" cname="g_mime_stream_file_set_owner"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="owner" /> + </parameters> + </method> + </object> + <object name="StreamFilter" cname="GMimeStreamFilter" parent="GMimeStream"> + <field name="Priv" cname="priv" type="struct-_GMimeStreamFilterPrivate*" /> + <field name="Source" cname="source" type="GMimeStream*" /> + <method name="Add" cname="g_mime_stream_filter_add"> + <return-type type="int" /> + <parameters> + <parameter type="GMimeFilter*" name="filter" /> + </parameters> + </method> + <method name="GetType" cname="g_mime_stream_filter_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_filter_new"> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </constructor> + <method name="Remove" cname="g_mime_stream_filter_remove"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="id" /> + </parameters> + </method> + </object> + <object name="StreamFs" cname="GMimeStreamFs" parent="GMimeStream"> + <field name="Owner" cname="owner" type="gboolean" /> + <field name="Eos" cname="eos" type="gboolean" /> + <field name="Fd" cname="fd" type="int" /> + <method name="GetOwner" cname="g_mime_stream_fs_get_owner"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_stream_fs_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_fs_new"> + <parameters> + <parameter type="int" name="fd" /> + </parameters> + </constructor> + <constructor cname="g_mime_stream_fs_new_with_bounds"> + <parameters> + <parameter type="int" name="fd" /> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </constructor> + <method name="SetOwner" cname="g_mime_stream_fs_set_owner"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="owner" /> + </parameters> + </method> + </object> + <object name="StreamGIO" cname="GMimeStreamGIO" parent="GMimeStream"> + <field name="Ostream" cname="ostream" type="GOutputStream*" /> + <field name="Istream" cname="istream" type="GInputStream*" /> + <field name="File" cname="file" type="GFile*" /> + <field name="Owner" cname="owner" type="gboolean" /> + <field name="Eos" cname="eos" type="gboolean" /> + <method name="GetOwner" cname="g_mime_stream_gio_get_owner"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_stream_gio_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_gio_new"> + <parameters> + <parameter type="GFile*" name="file" /> + </parameters> + </constructor> + <constructor cname="g_mime_stream_gio_new_with_bounds"> + <parameters> + <parameter type="GFile*" name="file" /> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </constructor> + <method name="SetOwner" cname="g_mime_stream_gio_set_owner"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="owner" /> + </parameters> + </method> + </object> + <object name="StreamMem" cname="GMimeStreamMem" parent="GMimeStream"> + <field name="Buffer" cname="buffer" type="GByteArray*" /> + <field name="Owner" cname="owner" type="gboolean" /> + <method name="GetByteArray" cname="g_mime_stream_mem_get_byte_array"> + <return-type type="GByteArray*" /> + </method> + <method name="GetOwner" cname="g_mime_stream_mem_get_owner"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_stream_mem_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_mem_new" /> + <constructor cname="g_mime_stream_mem_new_with_buffer"> + <parameters> + <parameter type="const-char*" name="buffer" /> + <parameter type="size_t" name="len" /> + </parameters> + </constructor> + <constructor cname="g_mime_stream_mem_new_with_byte_array"> + <parameters> + <parameter type="GByteArray*" name="array" /> + </parameters> + </constructor> + <method name="SetByteArray" cname="g_mime_stream_mem_set_byte_array"> + <return-type type="void" /> + <parameters> + <parameter type="GByteArray*" name="array" /> + </parameters> + </method> + <method name="SetOwner" cname="g_mime_stream_mem_set_owner"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="owner" /> + </parameters> + </method> + </object> + <object name="StreamMmap" cname="GMimeStreamMmap" parent="GMimeStream"> + <field name="Owner" cname="owner" type="gboolean" /> + <field name="Eos" cname="eos" type="gboolean" /> + <field name="Fd" cname="fd" type="int" /> + <field name="Map" cname="map" type="char*" /> + <field name="Maplen" cname="maplen" type="size_t" /> + <method name="GetType" cname="g_mime_stream_mmap_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_mmap_new"> + <parameters> + <parameter type="int" name="fd" /> + <parameter type="int" name="prot" /> + <parameter type="int" name="flags" /> + </parameters> + </constructor> + <constructor cname="g_mime_stream_mmap_new_with_bounds"> + <parameters> + <parameter type="int" name="fd" /> + <parameter type="int" name="prot" /> + <parameter type="int" name="flags" /> + <parameter type="gint64" name="start" /> + <parameter type="gint64" name="end" /> + </parameters> + </constructor> + </object> + <object name="StreamNull" cname="GMimeStreamNull" parent="GMimeStream"> + <field name="Written" cname="written" type="size_t" /> + <field name="Newlines" cname="newlines" type="size_t" /> + <method name="GetType" cname="g_mime_stream_null_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_null_new" /> + </object> + <object name="StreamPipe" cname="GMimeStreamPipe" parent="GMimeStream"> + <field name="Owner" cname="owner" type="gboolean" /> + <field name="Eos" cname="eos" type="gboolean" /> + <field name="Fd" cname="fd" type="int" /> + <method name="GetOwner" cname="g_mime_stream_pipe_get_owner"> + <return-type type="gboolean" /> + </method> + <method name="GetType" cname="g_mime_stream_pipe_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_stream_pipe_new"> + <parameters> + <parameter type="int" name="fd" /> + </parameters> + </constructor> + <method name="SetOwner" cname="g_mime_stream_pipe_set_owner"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="owner" /> + </parameters> + </method> + </object> + <object name="ContentDisposition" cname="GMimeContentDisposition" parent="GObject"> + <field name="ParamHash" cname="param_hash" type="GHashTable*" /> + <field name="Params" cname="params" type="GMimeParam*" /> + <field name="Priv" cname="priv" type="gpointer" /> + <field name="Disposition" cname="disposition" type="char*" /> + <method name="GetDisposition" cname="g_mime_content_disposition_get_disposition"> + <return-type type="const-char*" /> + </method> + <method name="GetParameter" cname="g_mime_content_disposition_get_parameter"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + </parameters> + </method> + <method name="GetParams" cname="g_mime_content_disposition_get_params"> + <return-type type="const-GMimeParam*" /> + </method> + <method name="GetType" cname="g_mime_content_disposition_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="g_mime_content_disposition_new" /> + <constructor cname="g_mime_content_disposition_new_from_string"> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </constructor> + <method name="SetDisposition" cname="g_mime_content_disposition_set_disposition"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetParameter" cname="g_mime_content_disposition_set_parameter"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetParams" cname="g_mime_content_disposition_set_params"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeParam*" name="params" /> + </parameters> + </method> + <method name="ToString" cname="g_mime_content_disposition_to_string"> + <return-type type="char*" /> + <parameters> + <parameter type="gboolean" name="fold" /> + </parameters> + </method> + </object> + <object name="ContentType" cname="GMimeContentType" parent="GObject"> + <field name="ParamHash" cname="param_hash" type="GHashTable*" /> + <field name="Params" cname="params" type="GMimeParam*" /> + <field name="Priv" cname="priv" type="gpointer" /> + <field name="Type" cname="type" type="char*" /> + <field name="Subtype" cname="subtype" type="char*" /> + <method name="GetMediaSubtype" cname="g_mime_content_type_get_media_subtype"> + <return-type type="const-char*" /> + </method> + <method name="GetMediaType" cname="g_mime_content_type_get_media_type"> + <return-type type="const-char*" /> + </method> + <method name="GetParameter" cname="g_mime_content_type_get_parameter"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + </parameters> + </method> + <method name="GetParams" cname="g_mime_content_type_get_params"> + <return-type type="const-GMimeParam*" /> + </method> + <method name="GetType" cname="g_mime_content_type_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IsType" cname="g_mime_content_type_is_type"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="type" /> + <parameter type="const-char*" name="subtype" /> + </parameters> + </method> + <constructor cname="g_mime_content_type_new"> + <parameters> + <parameter type="const-char*" name="type" /> + <parameter type="const-char*" name="subtype" /> + </parameters> + </constructor> + <constructor cname="g_mime_content_type_new_from_string"> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </constructor> + <method name="SetMediaSubtype" cname="g_mime_content_type_set_media_subtype"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="subtype" /> + </parameters> + </method> + <method name="SetMediaType" cname="g_mime_content_type_set_media_type"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="type" /> + </parameters> + </method> + <method name="SetParameter" cname="g_mime_content_type_set_parameter"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="attribute" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetParams" cname="g_mime_content_type_set_params"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeParam*" name="params" /> + </parameters> + </method> + <method name="ToString" cname="g_mime_content_type_to_string"> + <return-type type="char*" /> + </method> + </object> + <object name="InternetAddressList" cname="InternetAddressList" parent="GObject"> + <field name="Priv" cname="priv" type="gpointer" /> + <field name="Array" cname="array" type="GPtrArray*" /> + <method name="Add" cname="internet_address_list_add"> + <return-type type="int" /> + <parameters> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="Append" cname="internet_address_list_append"> + <return-type type="void" /> + <parameters> + <parameter type="InternetAddressList*" name="append" /> + </parameters> + </method> + <method name="Clear" cname="internet_address_list_clear"> + <return-type type="void" /> + </method> + <method name="Contains" cname="internet_address_list_contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="GetAddress" cname="internet_address_list_get_address"> + <return-type type="InternetAddress*" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="GetType" cname="internet_address_list_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="IndexOf" cname="internet_address_list_index_of"> + <return-type type="int" /> + <parameters> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="Insert" cname="internet_address_list_insert"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="Length" cname="internet_address_list_length"> + <return-type type="int" /> + </method> + <constructor cname="internet_address_list_new" /> + <method name="ParseString" cname="internet_address_list_parse_string" shared="true"> + <return-type type="InternetAddressList*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="Prepend" cname="internet_address_list_prepend"> + <return-type type="void" /> + <parameters> + <parameter type="InternetAddressList*" name="prepend" /> + </parameters> + </method> + <method name="Remove" cname="internet_address_list_remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="RemoveAt" cname="internet_address_list_remove_at"> + <return-type type="gboolean" /> + <parameters> + <parameter type="int" name="index" /> + </parameters> + </method> + <method name="SetAddress" cname="internet_address_list_set_address"> + <return-type type="void" /> + <parameters> + <parameter type="int" name="index" /> + <parameter type="InternetAddress*" name="ia" /> + </parameters> + </method> + <method name="ToString" cname="internet_address_list_to_string"> + <return-type type="char*" /> + <parameters> + <parameter type="gboolean" name="encode" /> + </parameters> + </method> + <method name="Writer" cname="internet_address_list_writer"> + <return-type type="void" /> + <parameters> + <parameter type="GString*" name="str" /> + </parameters> + </method> + </object> + <object name="InternetAddressGroup" cname="InternetAddressGroup" parent="InternetAddress"> + <field name="Members" cname="members" type="InternetAddressList*" /> + <method name="AddMember" cname="internet_address_group_add_member"> + <return-type type="int" /> + <parameters> + <parameter type="InternetAddress*" name="member" /> + </parameters> + </method> + <method name="GetMembers" cname="internet_address_group_get_members"> + <return-type type="InternetAddressList*" /> + </method> + <method name="GetType" cname="internet_address_group_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="internet_address_group_new"> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </constructor> + <method name="SetMembers" cname="internet_address_group_set_members"> + <return-type type="void" /> + <parameters> + <parameter type="InternetAddressList*" name="members" /> + </parameters> + </method> + </object> + <object name="InternetAddressMailbox" cname="InternetAddressMailbox" parent="InternetAddress"> + <field name="Addr" cname="addr" type="char*" /> + <method name="GetAddr" cname="internet_address_mailbox_get_addr"> + <return-type type="const-char*" /> + </method> + <method name="GetType" cname="internet_address_mailbox_get_type" shared="true"> + <return-type type="GType" /> + </method> + <constructor cname="internet_address_mailbox_new"> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="addr" /> + </parameters> + </constructor> + <method name="SetAddr" cname="internet_address_mailbox_set_addr"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="addr" /> + </parameters> + </method> + </object> + <object name="InternetAddress" cname="InternetAddress" parent="GObject"> + <field name="Priv" cname="priv" type="gpointer" /> + <field name="Name" cname="name" type="char*" /> + <virtual_method name="ToString" cname="to_string"> + <return-type type="void" /> + <parameters> + <parameter type="InternetAddress*" name="ia" /> + <parameter type="guint32" name="flags" /> + <parameter type="size_t*" name="linelen" /> + <parameter type="GString*" name="out" /> + </parameters> + </virtual_method> + <method name="GetName" cname="internet_address_get_name"> + <return-type type="const-char*" /> + </method> + <method name="GetType" cname="internet_address_get_type" shared="true"> + <return-type type="GType" /> + </method> + <method name="SetName" cname="internet_address_set_name"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="ToString" cname="internet_address_to_string"> + <return-type type="char*" /> + <parameters> + <parameter type="gboolean" name="encode" /> + </parameters> + </method> + </object> + <struct name="Charset" cname="GMimeCharset" opaque="true"> + <method name="Best" cname="g_mime_charset_best" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + </parameters> + </method> + <method name="BestName" cname="g_mime_charset_best_name"> + <return-type type="const-char*" /> + </method> + <method name="CanEncode" cname="g_mime_charset_can_encode"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="charset" /> + <parameter type="const-char*" name="text" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="CanonName" cname="g_mime_charset_canon_name" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="charset" /> + </parameters> + </method> + <method name="IconvName" cname="g_mime_charset_iconv_name" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="charset" /> + </parameters> + </method> + <method name="Init" cname="g_mime_charset_init"> + <return-type type="void" /> + </method> + <method name="IsoToWindows" cname="g_mime_charset_iso_to_windows" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="isocharset" /> + </parameters> + </method> + <method name="Language" cname="g_mime_charset_language" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="charset" /> + </parameters> + </method> + <method name="LocaleName" cname="g_mime_charset_locale_name" deprecated="1" shared="true"> + <return-type type="const-char*" /> + </method> + <method name="MapInit" cname="g_mime_charset_map_init" shared="true"> + <return-type type="void" /> + </method> + <method name="MapShutdown" cname="g_mime_charset_map_shutdown" shared="true"> + <return-type type="void" /> + </method> + <method name="Name" cname="g_mime_charset_name" deprecated="1" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="charset" /> + </parameters> + </method> + <method name="Step" cname="g_mime_charset_step"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + </parameters> + </method> + </struct> + <struct name="Encoding" cname="GMimeEncoding" opaque="true"> + <method name="Base64DecodeStep" cname="g_mime_encoding_base64_decode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="Base64EncodeClose" cname="g_mime_encoding_base64_encode_close" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="Base64EncodeStep" cname="g_mime_encoding_base64_encode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="Flush" cname="g_mime_encoding_flush"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="char*" name="outbuf" /> + </parameters> + </method> + <method name="InitDecode" cname="g_mime_encoding_init_decode"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </method> + <method name="InitEncode" cname="g_mime_encoding_init_encode"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </method> + <method name="Outlen" cname="g_mime_encoding_outlen"> + <return-type type="size_t" /> + <parameters> + <parameter type="size_t" name="inlen" /> + </parameters> + </method> + <method name="QuotedDecodeStep" cname="g_mime_encoding_quoted_decode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="QuotedEncodeClose" cname="g_mime_encoding_quoted_encode_close" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="QuotedEncodeStep" cname="g_mime_encoding_quoted_encode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="Reset" cname="g_mime_encoding_reset"> + <return-type type="void" /> + </method> + <method name="Step" cname="g_mime_encoding_step"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="char*" name="outbuf" /> + </parameters> + </method> + <method name="UudecodeStep" cname="g_mime_encoding_uudecode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="UuencodeClose" cname="g_mime_encoding_uuencode_close" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="unsigned-char*" name="uubuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + <method name="UuencodeStep" cname="g_mime_encoding_uuencode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="unsigned-char*" name="uubuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="save" /> + </parameters> + </method> + </struct> + <struct name="Event" cname="GMimeEvent" opaque="true" /> + <struct name="Header" cname="GMimeHeader" opaque="true" /> + <struct name="HeaderIter" cname="GMimeHeaderIter" opaque="true"> + <field name="Hdrlist" cname="hdrlist" type="GMimeHeaderList*" access="public" writeable="true" /> + <field name="Cursor" cname="cursor" type="GMimeHeader*" access="public" writeable="true" /> + <field name="Version" cname="version" type="guint32" access="public" writeable="true" /> + <method name="Copy" cname="g_mime_header_iter_copy"> + <return-type type="GMimeHeaderIter*" owned="true" /> + </method> + <method name="CopyTo" cname="g_mime_header_iter_copy_to"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeHeaderIter*" name="dest" /> + </parameters> + </method> + <method name="Equal" cname="g_mime_header_iter_equal"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeHeaderIter*" name="iter2" /> + </parameters> + </method> + <method name="First" cname="g_mime_header_iter_first"> + <return-type type="gboolean" /> + </method> + <method name="Free" cname="g_mime_header_iter_free"> + <return-type type="void" /> + </method> + <method name="GetName" cname="g_mime_header_iter_get_name"> + <return-type type="const-char*" /> + </method> + <method name="GetValue" cname="g_mime_header_iter_get_value"> + <return-type type="const-char*" /> + </method> + <method name="IsValid" cname="g_mime_header_iter_is_valid"> + <return-type type="gboolean" /> + </method> + <method name="Last" cname="g_mime_header_iter_last"> + <return-type type="gboolean" /> + </method> + <constructor cname="g_mime_header_iter_new" /> + <method name="Next" cname="g_mime_header_iter_next"> + <return-type type="gboolean" /> + </method> + <method name="Prev" cname="g_mime_header_iter_prev"> + <return-type type="gboolean" /> + </method> + <method name="Remove" cname="g_mime_header_iter_remove"> + <return-type type="gboolean" /> + </method> + <method name="SetValue" cname="g_mime_header_iter_set_value"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + </struct> + <struct name="HeaderList" cname="GMimeHeaderList" opaque="true"> + <method name="Append" cname="g_mime_header_list_append"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="Clear" cname="g_mime_header_list_clear"> + <return-type type="void" /> + </method> + <method name="Contains" cname="g_mime_header_list_contains"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="Destroy" cname="g_mime_header_list_destroy"> + <return-type type="void" /> + </method> + <method name="Foreach" cname="g_mime_header_list_foreach"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeHeaderForeachFunc" name="func" /> + <parameter type="gpointer" name="user_data" /> + </parameters> + </method> + <method name="Get" cname="g_mime_header_list_get"> + <return-type type="const-char*" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="GetIter" cname="g_mime_header_list_get_iter"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeHeaderIter*" name="iter" /> + </parameters> + </method> + <method name="GetStream" cname="g_mime_header_list_get_stream"> + <return-type type="GMimeStream*" /> + </method> + <constructor cname="g_mime_header_list_new" /> + <method name="Prepend" cname="g_mime_header_list_prepend"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="RegisterWriter" cname="g_mime_header_list_register_writer"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="GMimeHeaderWriter" name="writer" /> + </parameters> + </method> + <method name="Remove" cname="g_mime_header_list_remove"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="name" /> + </parameters> + </method> + <method name="Set" cname="g_mime_header_list_set"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="SetStream" cname="g_mime_header_list_set_stream"> + <return-type type="void" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + <method name="ToString" cname="g_mime_header_list_to_string"> + <return-type type="char*" /> + </method> + <method name="WriteToStream" cname="g_mime_header_list_write_to_stream"> + <return-type type="ssize_t" /> + <parameters> + <parameter type="GMimeStream*" name="stream" /> + </parameters> + </method> + </struct> + <struct name="Param" cname="GMimeParam" opaque="true"> + <field name="Next" cname="next" type="GMimeParam*" access="public" writeable="true" /> + <field name="Name" cname="name" type="char*" access="public" writeable="true" /> + <field name="Value" cname="value" type="char*" access="public" writeable="true" /> + <method name="Append" cname="g_mime_param_append"> + <return-type type="GMimeParam*" /> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </method> + <method name="AppendParam" cname="g_mime_param_append_param"> + <return-type type="GMimeParam*" /> + <parameters> + <parameter type="GMimeParam*" name="param" /> + </parameters> + </method> + <method name="Destroy" cname="g_mime_param_destroy"> + <return-type type="void" /> + </method> + <method name="GetName" cname="g_mime_param_get_name"> + <return-type type="const-char*" /> + </method> + <method name="GetValue" cname="g_mime_param_get_value"> + <return-type type="const-char*" /> + </method> + <constructor cname="g_mime_param_new"> + <parameters> + <parameter type="const-char*" name="name" /> + <parameter type="const-char*" name="value" /> + </parameters> + </constructor> + <constructor cname="g_mime_param_new_from_string"> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </constructor> + <method name="Next" cname="g_mime_param_next"> + <return-type type="const-GMimeParam*" /> + </method> + <method name="WriteToString" cname="g_mime_param_write_to_string"> + <return-type type="void" /> + <parameters> + <parameter type="gboolean" name="fold" /> + <parameter type="GString*" name="str" /> + </parameters> + </method> + </struct> + <struct name="PartIter" cname="GMimePartIter" opaque="true"> + <method name="Free" cname="g_mime_part_iter_free"> + <return-type type="void" /> + </method> + <method name="GetCurrent" cname="g_mime_part_iter_get_current"> + <return-type type="GMimeObject*" /> + </method> + <method name="GetParent" cname="g_mime_part_iter_get_parent"> + <return-type type="GMimeObject*" /> + </method> + <method name="GetPath" cname="g_mime_part_iter_get_path"> + <return-type type="char*" /> + </method> + <method name="GetToplevel" cname="g_mime_part_iter_get_toplevel"> + <return-type type="GMimeObject*" /> + </method> + <method name="IsValid" cname="g_mime_part_iter_is_valid"> + <return-type type="gboolean" /> + </method> + <method name="JumpTo" cname="g_mime_part_iter_jump_to"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-char*" name="path" /> + </parameters> + </method> + <constructor cname="g_mime_part_iter_new"> + <parameters> + <parameter type="GMimeObject*" name="toplevel" /> + </parameters> + </constructor> + <method name="Next" cname="g_mime_part_iter_next"> + <return-type type="gboolean" /> + </method> + <method name="Prev" cname="g_mime_part_iter_prev"> + <return-type type="gboolean" /> + </method> + <method name="Remove" cname="g_mime_part_iter_remove"> + <return-type type="gboolean" /> + </method> + <method name="Replace" cname="g_mime_part_iter_replace"> + <return-type type="gboolean" /> + <parameters> + <parameter type="GMimeObject*" name="replacement" /> + </parameters> + </method> + <method name="Reset" cname="g_mime_part_iter_reset"> + <return-type type="void" /> + </method> + </struct> + <struct name="References" cname="GMimeReferences"> + <field name="Next" cname="next" type="GMimeReferences*" /> + <field name="Msgid" cname="msgid" type="char*" /> + <method name="Append" cname="g_mime_references_append"> + <return-type type="void" /> + <parameters> + <parameter type="const-char*" name="msgid" /> + </parameters> + </method> + <method name="Clear" cname="g_mime_references_clear"> + <return-type type="void" /> + </method> + <method name="Decode" cname="g_mime_references_decode" shared="true"> + <return-type type="GMimeReferences*" /> + <parameters> + <parameter type="const-char*" name="text" /> + </parameters> + </method> + <method name="Free" cname="g_mime_references_free"> + <return-type type="void" /> + </method> + <method name="GetMessageId" cname="g_mime_references_get_message_id"> + <return-type type="const-char*" /> + </method> + <method name="GetNext" cname="g_mime_references_get_next"> + <return-type type="const-GMimeReferences*" /> + </method> + </struct> + <struct name="StreamIOVector" cname="GMimeStreamIOVector"> + <field name="Data" cname="data" type="void*" /> + <field name="Len" cname="len" type="size_t" /> + </struct> + <class name="Global" cname="GMimeGlobal"> + <method name="CheckVersion" cname="g_mime_check_version" shared="true"> + <return-type type="gboolean" /> + <parameters> + <parameter type="guint" name="major" /> + <parameter type="guint" name="minor" /> + <parameter type="guint" name="micro" /> + </parameters> + </method> + <method name="SetUserCharsets" cname="g_mime_set_user_charsets" shared="true"> + <return-type type="void" /> + <parameters> + <parameter type="const-char**" name="charsets" /> + </parameters> + </method> + <method name="UserCharsets" cname="g_mime_user_charsets" shared="true"> + <return-type type="const-char**" /> + </method> + <method name="YdecodeStep" cname="g_mime_ydecode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="pcrc" /> + <parameter type="guint32*" name="crc" /> + </parameters> + </method> + </class> + <class name="Content" cname="GMimeContent_"> + <method name="EncodingFromString" cname="g_mime_content_encoding_from_string" shared="true"> + <return-type type="GMimeContentEncoding" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="EncodingToString" cname="g_mime_content_encoding_to_string" shared="true"> + <return-type type="const-char*" /> + <parameters> + <parameter type="GMimeContentEncoding" name="encoding" /> + </parameters> + </method> + </class> + <class name="Iconv" cname="GMimeIconv_"> + <method name="Close" cname="g_mime_iconv_close" shared="true"> + <return-type type="int" /> + <parameters> + <parameter type="iconv_t" name="cd" /> + </parameters> + </method> + <method name="Init" cname="g_mime_iconv_init" shared="true"> + <return-type type="void" /> + </method> + <method name="LocaleToUtf8" cname="g_mime_iconv_locale_to_utf8" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="LocaleToUtf8Length" cname="g_mime_iconv_locale_to_utf8_length" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + <parameter type="size_t" name="n" /> + </parameters> + </method> + <method name="Open" cname="g_mime_iconv_open" shared="true"> + <return-type type="iconv_t" /> + <parameters> + <parameter type="const-char*" name="to" /> + <parameter type="const-char*" name="from" /> + </parameters> + </method> + <method name="Shutdown" cname="g_mime_iconv_shutdown" shared="true"> + <return-type type="void" /> + </method> + <method name="Strdup" cname="g_mime_iconv_strdup" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="iconv_t" name="cd" /> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="Strndup" cname="g_mime_iconv_strndup" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="iconv_t" name="cd" /> + <parameter type="const-char*" name="str" /> + <parameter type="size_t" name="n" /> + </parameters> + </method> + <method name="Utf8ToLocale" cname="g_mime_iconv_utf8_to_locale" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="Utf8ToLocaleLength" cname="g_mime_iconv_utf8_to_locale_length" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + <parameter type="size_t" name="n" /> + </parameters> + </method> + </class> + <class name="Locale" cname="GMimeLocale_"> + <method name="Charset" cname="g_mime_locale_charset" shared="true"> + <return-type type="const-char*" /> + </method> + <method name="Language" cname="g_mime_locale_language" shared="true"> + <return-type type="const-char*" /> + </method> + </class> + <class name="Utils" cname="GMimeUtils_"> + <method name="BestEncoding" cname="g_mime_utils_best_encoding" shared="true"> + <return-type type="GMimeContentEncoding" /> + <parameters> + <parameter type="const-unsigned-char*" name="text" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="Decode8bit" cname="g_mime_utils_decode_8bit" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="text" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="DecodeMessageId" cname="g_mime_utils_decode_message_id" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="message_id" /> + </parameters> + </method> + <method name="GenerateMessageId" cname="g_mime_utils_generate_message_id" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="fqdn" /> + </parameters> + </method> + <method name="HeaderDecodeDate" cname="g_mime_utils_header_decode_date" shared="true"> + <return-type type="time_t" /> + <parameters> + <parameter type="const-char*" name="str" /> + <parameter type="int*" name="tz_offset" /> + </parameters> + </method> + <method name="HeaderDecodePhrase" cname="g_mime_utils_header_decode_phrase" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="phrase" /> + </parameters> + </method> + <method name="HeaderDecodeText" cname="g_mime_utils_header_decode_text" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="text" /> + </parameters> + </method> + <method name="HeaderEncodePhrase" cname="g_mime_utils_header_encode_phrase" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="phrase" /> + </parameters> + </method> + <method name="HeaderEncodeText" cname="g_mime_utils_header_encode_text" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="text" /> + </parameters> + </method> + <method name="HeaderFold" cname="g_mime_utils_header_fold" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="HeaderFormatDate" cname="g_mime_utils_header_format_date" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="time_t" name="date" /> + <parameter type="int" name="tz_offset" /> + </parameters> + </method> + <method name="HeaderPrintf" cname="g_mime_utils_header_printf" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="format" /> + <parameter ellipsis="true" /> + </parameters> + </method> + <method name="QuoteString" cname="g_mime_utils_quote_string" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="StructuredHeaderFold" cname="g_mime_utils_structured_header_fold" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + <method name="TextIs8bit" cname="g_mime_utils_text_is_8bit" shared="true"> + <return-type type="gboolean" /> + <parameters> + <parameter type="const-unsigned-char*" name="text" /> + <parameter type="size_t" name="len" /> + </parameters> + </method> + <method name="UnquoteString" cname="g_mime_utils_unquote_string" shared="true"> + <return-type type="void" /> + <parameters> + <parameter type="char*" name="str" /> + </parameters> + </method> + <method name="UnstructuredHeaderFold" cname="g_mime_utils_unstructured_header_fold" shared="true"> + <return-type type="char*" /> + <parameters> + <parameter type="const-char*" name="str" /> + </parameters> + </method> + </class> + <class name="Yencode" cname="GMimeYencode_"> + <method name="Close" cname="g_mime_yencode_close" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="pcrc" /> + <parameter type="guint32*" name="crc" /> + </parameters> + </method> + <method name="Step" cname="g_mime_yencode_step" shared="true"> + <return-type type="size_t" /> + <parameters> + <parameter type="const-unsigned-char*" name="inbuf" /> + <parameter type="size_t" name="inlen" /> + <parameter type="unsigned-char*" name="outbuf" /> + <parameter type="int*" name="state" /> + <parameter type="guint32*" name="pcrc" /> + <parameter type="guint32*" name="crc" /> + </parameters> + </method> + </class> + </namespace> +</api>
\ No newline at end of file diff --git a/mono/gmime-sharp.dll.config.in b/mono/gmime-sharp.dll.config.in new file mode 100644 index 0000000..3285df4 --- /dev/null +++ b/mono/gmime-sharp.dll.config.in @@ -0,0 +1,3 @@ +<configuration> + <dllmap dll="gmime" target="libgmime-@GMIME_API_VERSION@.so.@LT_CURRENT_MINUS_AGE@"/> +</configuration> diff --git a/mono/gmime-sharp.pc.in b/mono/gmime-sharp.pc.in new file mode 100644 index 0000000..ca9fc1c --- /dev/null +++ b/mono/gmime-sharp.pc.in @@ -0,0 +1,11 @@ +prefix=${pcfiledir}/../.. +exec_prefix=${prefix} +libdir=${exec_prefix}/lib +gapidir=${prefix}/share/gapi-2.0 + +Name: gmime-sharp +Version: @VERSION@ +Description: .NET bindings for GMime +Cflags: -I:${gapidir}/gmime-api.xml +Libs: -r:${libdir}/mono/gmime-sharp-@GMIME_API_VERSION@/gmime-sharp.dll +Requires: glib-sharp-2.0 diff --git a/mono/gmime-sharp.snk b/mono/gmime-sharp.snk Binary files differnew file mode 100644 index 0000000..5c62e8c --- /dev/null +++ b/mono/gmime-sharp.snk diff --git a/mono/sources.xml b/mono/sources.xml new file mode 100644 index 0000000..4f0287c --- /dev/null +++ b/mono/sources.xml @@ -0,0 +1,9 @@ +<gapi-parser-input> + <api filename="gmime-api.raw"> + <library name="gmime"> + <namespace name="GMime"> + <dir>../gmime</dir> + </namespace> + </library> + </api> +</gapi-parser-input> |