summaryrefslogtreecommitdiffstats
path: root/mono/Error.cs
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2003-06-22 22:59:31 +0000
committerHavoc Pennington <hp@redhat.com>2003-06-22 22:59:31 +0000
commit1cc184b4a849619b56bed2be0e752fbc0fb75a29 (patch)
tree867409e28e08152147e095606e487793873dd51e /mono/Error.cs
parent958805418359aca169cd363a4a3279f0fdab753c (diff)
2003-06-22 Havoc Pennington <hp@pobox.com>
* mono/Connection.cs, mono/DBus.cs, mono/Error.cs: Start wrapping more stuff.
Diffstat (limited to 'mono/Error.cs')
-rw-r--r--mono/Error.cs29
1 files changed, 29 insertions, 0 deletions
diff --git a/mono/Error.cs b/mono/Error.cs
new file mode 100644
index 00000000..95c0193b
--- /dev/null
+++ b/mono/Error.cs
@@ -0,0 +1,29 @@
+namespace DBus {
+
+ using System;
+ using System.Runtime.InteropServices;
+
+ // FIXME add code to verify that size of DBus.Error
+ // matches the C code.
+
+ [StructLayout (LayoutKind.Sequential)]
+ internal struct Error {
+ internal IntPtr name;
+ internal IntPtr message;
+ private int dummies;
+ private IntPtr padding1;
+
+ internal void Init () {
+ dbus_error_init (ref this);
+ }
+
+ internal void Free () {
+ dbus_error_free (ref this);
+ }
+
+ [DllImport (DBus.Internals.Libname, EntryPoint="dbus_error_init")]
+ private extern static void dbus_error_init (ref Error error);
+ [DllImport (DBus.Internals.Libname, EntryPoint="dbus_error_free")]
+ private extern static void dbus_error_free (ref Error error);
+ }
+}