public static void MapIter(MapIterFunc iter, IntPtr _pgf, Action <string, IntPtr> action) { var pool = new NativeGU.NativeMemoryPool(); var exn = new NativeGU.NativeExceptionContext(pool); var f = new GuMapItor() { fn = (self, key, value, _err) => { action(Native.NativeString.StringFromNativeUtf8(key), value); if (exn.IsRaised) { throw new Exception(); } } }; iter(_pgf, ref f, exn.Ptr); }
public void IterFunc(IntPtr pgf, ref GuMapItor fn, IntPtr err) { func(pgf, name, ref fn, err); }
public static extern void pgf_iter_functions_by_cat(IntPtr pgf, IntPtr catNameStr, ref GuMapItor itor, IntPtr err);
public static extern void pgf_iter_functions(IntPtr pgf, ref GuMapItor itor, IntPtr err);
public static extern void pgf_iter_categories(IntPtr pgf, ref GuMapItor itor, IntPtr err);
public static extern void pgf_iter_languages(IntPtr pgf, ref GuMapItor itor, IntPtr err);