// Package gio was automatically generated by github.com/bnema/puregotk DO NOT EDIT package gio import ( "github.com/ebitengine/purego" "github.com/bnema/puregotk/pkg/core" "github.com/bnema/puregotk/v4/glib" ) var xIoErrorFromErrno func(int) IOErrorEnum // Converts `errno.h` error codes into GIO error codes. // // The fallback value %G_IO_ERROR_FAILED is returned for error codes not // currently handled (but note that future GLib releases may return a more // specific value instead). // // As `errno` is global and may be modified by intermediate function // calls, you should save its value immediately after the call returns, // and use the saved value instead of `errno`: // // |[<!-- language="C" --> // // int saved_errno; // // ret = read (blah); // saved_errno = errno; // // g_io_error_from_errno (saved_errno); // // ]| func IoErrorFromErrno(ErrNoVar int) IOErrorEnum { cret := xIoErrorFromErrno(ErrNoVar) return cret } var xIoErrorFromFileError func(glib.FileError) IOErrorEnum // Converts #GFileError error codes into GIO error codes. func IoErrorFromFileError(FileErrorVar glib.FileError) IOErrorEnum { cret := xIoErrorFromFileError(FileErrorVar) return cret } var xIoErrorQuark func() glib.Quark // Gets the GIO Error Quark. func IoErrorQuark() glib.Quark { cret := xIoErrorQuark() return cret } func init() { core.SetPackageName("GIO", "gio-2.0") core.SetSharedLibraries("GIO", []string{"libgio-2.0.so.0"}) var libs []uintptr for _, libPath := range core.GetPaths("GIO") { lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) if err != nil { panic(err) } libs = append(libs, lib) } core.PuregoSafeRegister(&xIoErrorFromErrno, libs, "g_io_error_from_errno") core.PuregoSafeRegister(&xIoErrorFromFileError, libs, "g_io_error_from_file_error") core.PuregoSafeRegister(&xIoErrorQuark, libs, "g_io_error_quark") }