// This file was generated by the Gtk# code generator. // Any changes made will be lost if regenerated. namespace GLib { using System; using System.Collections; using System.Collections.Generic; using System.Runtime.InteropServices; #region Autogenerated code [StructLayout(LayoutKind.Sequential)] public partial struct Win32RegistryValueIter : IEquatable { private IntPtr _key; private int counter; private int value_count; private IntPtr _value_name; private UIntPtr value_name_size; private UIntPtr value_name_len; private GLib.Win32RegistryValueType value_type; private IntPtr _value_data; private UIntPtr value_data_size; private UIntPtr value_actual_data_size; private GLib.Win32RegistryValueType value_expanded_type; private IntPtr _value_data_expanded; private UIntPtr value_data_expanded_charsize; private string value_name_u8; private UIntPtr value_name_u8_len; private string value_data_u8; private UIntPtr value_data_u8_size; private string value_data_expanded_u8; private UIntPtr value_data_expanded_u8_size; public static GLib.Win32RegistryValueIter Zero = new GLib.Win32RegistryValueIter (); public static GLib.Win32RegistryValueIter New(IntPtr raw) { if (raw == IntPtr.Zero) return GLib.Win32RegistryValueIter.Zero; return (GLib.Win32RegistryValueIter) Marshal.PtrToStructure (raw, typeof (GLib.Win32RegistryValueIter)); } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate void d_g_win32_registry_value_iter_assign(IntPtr raw, IntPtr other); static d_g_win32_registry_value_iter_assign g_win32_registry_value_iter_assign = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_assign")); public void Assign(GLib.Win32RegistryValueIter other) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); IntPtr native_other = GLib.Marshaller.StructureToPtrAlloc (other); g_win32_registry_value_iter_assign(this_as_native, native_other); ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); Marshal.FreeHGlobal (native_other); } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate void d_g_win32_registry_value_iter_clear(IntPtr raw); static d_g_win32_registry_value_iter_clear g_win32_registry_value_iter_clear = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_clear")); public void Clear() { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); g_win32_registry_value_iter_clear(this_as_native); ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_get_data(IntPtr raw, bool auto_expand, IntPtr value_data, out UIntPtr value_data_size, out IntPtr error); static d_g_win32_registry_value_iter_get_data g_win32_registry_value_iter_get_data = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_get_data")); public unsafe bool GetData(bool auto_expand, IntPtr value_data, out ulong value_data_size) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); UIntPtr native_value_data_size; IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_get_data(this_as_native, auto_expand, value_data, out native_value_data_size, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); value_data_size = (ulong) native_value_data_size; if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_get_data_w(IntPtr raw, bool auto_expand, IntPtr value_data, out UIntPtr value_data_size, out IntPtr error); static d_g_win32_registry_value_iter_get_data_w g_win32_registry_value_iter_get_data_w = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_get_data_w")); public unsafe bool GetDataW(bool auto_expand, IntPtr value_data, out ulong value_data_size) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); UIntPtr native_value_data_size; IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_get_data_w(this_as_native, auto_expand, value_data, out native_value_data_size, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); value_data_size = (ulong) native_value_data_size; if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_get_name(IntPtr raw, IntPtr value_name, out UIntPtr value_name_len, out IntPtr error); static d_g_win32_registry_value_iter_get_name g_win32_registry_value_iter_get_name = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_get_name")); public unsafe bool GetName(string value_name, out ulong value_name_len) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); UIntPtr native_value_name_len; IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_get_name(this_as_native, GLib.Marshaller.StringToPtrGStrdup(value_name), out native_value_name_len, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); value_name_len = (ulong) native_value_name_len; if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate IntPtr d_g_win32_registry_value_iter_get_type(); static d_g_win32_registry_value_iter_get_type g_win32_registry_value_iter_get_type = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_get_type")); public static GLib.GType GType { get { IntPtr raw_ret = g_win32_registry_value_iter_get_type(); GLib.GType ret = new GLib.GType(raw_ret); return ret; } } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_get_value_type(IntPtr raw, out int value_type, out IntPtr error); static d_g_win32_registry_value_iter_get_value_type g_win32_registry_value_iter_get_value_type = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_get_value_type")); public unsafe bool GetValueType(out GLib.Win32RegistryValueType value_type) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); int native_value_type; IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_get_value_type(this_as_native, out native_value_type, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); value_type = (GLib.Win32RegistryValueType) native_value_type; if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_init(IntPtr raw, IntPtr key, out IntPtr error); static d_g_win32_registry_value_iter_init g_win32_registry_value_iter_init = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_init")); public unsafe bool Init(GLib.Win32RegistryKey key) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_init(this_as_native, key == null ? IntPtr.Zero : key.Handle, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate UIntPtr d_g_win32_registry_value_iter_n_values(IntPtr raw); static d_g_win32_registry_value_iter_n_values g_win32_registry_value_iter_n_values = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_n_values")); public ulong NValues() { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); UIntPtr raw_ret = g_win32_registry_value_iter_n_values(this_as_native); ulong ret = (ulong) raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); return ret; } [UnmanagedFunctionPointer (CallingConvention.Cdecl)] delegate bool d_g_win32_registry_value_iter_next(IntPtr raw, bool skip_errors, out IntPtr error); static d_g_win32_registry_value_iter_next g_win32_registry_value_iter_next = FuncLoader.LoadFunction(FuncLoader.GetProcAddress(GLibrary.Load(Library.Gio), "g_win32_registry_value_iter_next")); public unsafe bool Next(bool skip_errors) { IntPtr this_as_native = System.Runtime.InteropServices.Marshal.AllocHGlobal (System.Runtime.InteropServices.Marshal.SizeOf()); System.Runtime.InteropServices.Marshal.StructureToPtr (this, this_as_native, false); IntPtr error = IntPtr.Zero; bool raw_ret = g_win32_registry_value_iter_next(this_as_native, skip_errors, out error); bool ret = raw_ret; ReadNative (this_as_native, ref this); System.Runtime.InteropServices.Marshal.FreeHGlobal (this_as_native); if (error != IntPtr.Zero) throw new GLib.GException (error); return ret; } static void ReadNative (IntPtr native, ref GLib.Win32RegistryValueIter target) { target = New (native); } public bool Equals (Win32RegistryValueIter other) { return true && _key.Equals (other._key) && counter.Equals (other.counter) && value_count.Equals (other.value_count) && _value_name.Equals (other._value_name) && value_name_size.Equals (other.value_name_size) && value_name_len.Equals (other.value_name_len) && value_type.Equals (other.value_type) && _value_data.Equals (other._value_data) && value_data_size.Equals (other.value_data_size) && value_actual_data_size.Equals (other.value_actual_data_size) && value_expanded_type.Equals (other.value_expanded_type) && _value_data_expanded.Equals (other._value_data_expanded) && value_data_expanded_charsize.Equals (other.value_data_expanded_charsize) && value_name_u8.Equals (other.value_name_u8) && value_name_u8_len.Equals (other.value_name_u8_len) && value_data_u8.Equals (other.value_data_u8) && value_data_u8_size.Equals (other.value_data_u8_size) && value_data_expanded_u8.Equals (other.value_data_expanded_u8) && value_data_expanded_u8_size.Equals (other.value_data_expanded_u8_size); } public override bool Equals (object other) { return other is Win32RegistryValueIter && Equals ((Win32RegistryValueIter) other); } public override int GetHashCode () { return this.GetType ().FullName.GetHashCode () ^ _key.GetHashCode () ^ counter.GetHashCode () ^ value_count.GetHashCode () ^ _value_name.GetHashCode () ^ value_name_size.GetHashCode () ^ value_name_len.GetHashCode () ^ value_type.GetHashCode () ^ _value_data.GetHashCode () ^ value_data_size.GetHashCode () ^ value_actual_data_size.GetHashCode () ^ value_expanded_type.GetHashCode () ^ _value_data_expanded.GetHashCode () ^ value_data_expanded_charsize.GetHashCode () ^ value_name_u8.GetHashCode () ^ value_name_u8_len.GetHashCode () ^ value_data_u8.GetHashCode () ^ value_data_u8_size.GetHashCode () ^ value_data_expanded_u8.GetHashCode () ^ value_data_expanded_u8_size.GetHashCode (); } public static explicit operator GLib.Value (GLib.Win32RegistryValueIter boxed) { GLib.Value val = GLib.Value.Empty; val.Init (GLib.Win32RegistryValueIter.GType); val.Val = boxed; return val; } public static explicit operator GLib.Win32RegistryValueIter (GLib.Value val) { return (GLib.Win32RegistryValueIter) val.Val; } #endregion } }