From 45858ab58da34fb771de30000a50236fe0faccb6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 16:44:18 +0100 Subject: [PATCH 01/15] Update to Dune 3.17 --- config/discover.ml | 2 +- config/dune | 2 +- dune-project | 2 +- gobject-introspection.opam | 4 ++-- lib/dune | 2 +- stubgen/dune | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/config/discover.ml b/config/discover.ml index 838c833..2146e1e 100644 --- a/config/discover.ml +++ b/config/discover.ml @@ -1,6 +1,6 @@ open Base open Stdio -module C = Configurator +module C = Configurator.V1 let write_sexp fn list_of_str = let data = sexp_of_list sexp_of_string list_of_str |> Sexp.to_string in diff --git a/config/dune b/config/dune index e2ed62f..613473c 100644 --- a/config/dune +++ b/config/dune @@ -1,3 +1,3 @@ (executable (name discover) - (libraries base stdio configurator)) + (libraries base stdio dune-configurator)) diff --git a/dune-project b/dune-project index 5bbef0b..3e2a615 100644 --- a/dune-project +++ b/dune-project @@ -1 +1 @@ -(lang dune 2.5) +(lang dune 3.17) diff --git a/gobject-introspection.opam b/gobject-introspection.opam index 6c3e67c..2d45379 100644 --- a/gobject-introspection.opam +++ b/gobject-introspection.opam @@ -15,13 +15,13 @@ build: [ ] depends: [ "ocaml" - "dune" {>= "1.2"} + "dune" {>= "3.17"} "ctypes" "ctypes-foreign" "ounit" "base" "stdio" - "configurator" + "dune-configurator" {build} "conf-pkg-config" {build} "conf-gobject-introspection" {build} "conf-glib-2" {build} diff --git a/lib/dune b/lib/dune index 26c68a7..74e9863 100644 --- a/lib/dune +++ b/lib/dune @@ -10,7 +10,7 @@ (rule (targets c_flags.sexp c_library_flags.sexp ccopts.sexp) (deps (:x ../config/discover.exe)) - (action (run %{x} -ocamlc %{ocamlc})) + (action (run %{x})) ) (rule diff --git a/stubgen/dune b/stubgen/dune index 027d24c..9ef9af4 100644 --- a/stubgen/dune +++ b/stubgen/dune @@ -154,5 +154,5 @@ (rule (targets c_library_flags c_flags) (deps (:x ../config/discover.exe)) - (action (run %{x} -ocamlc %{ocamlc})) + (action (run %{x})) ) From d5de6b47ac2ee686eb61f5a08fb807e5b4ad7120 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 16:45:54 +0100 Subject: [PATCH 02/15] Require ounit2 --- gobject-introspection.opam | 2 +- tests/dune | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gobject-introspection.opam b/gobject-introspection.opam index 2d45379..899b5ca 100644 --- a/gobject-introspection.opam +++ b/gobject-introspection.opam @@ -18,7 +18,7 @@ depends: [ "dune" {>= "3.17"} "ctypes" "ctypes-foreign" - "ounit" + "ounit2" {with-test} "base" "stdio" "dune-configurator" {build} diff --git a/tests/dune b/tests/dune index b996abf..5362640 100644 --- a/tests/dune +++ b/tests/dune @@ -1,4 +1,4 @@ (test (name test) - (libraries GObject_introspection oUnit ctypes ctypes.foreign stdio) + (libraries GObject_introspection ounit2 ctypes ctypes.foreign stdio) ) From 5b078cadcb6c8e8a5183fc55db1e3acfb079ccd7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 16:58:12 +0100 Subject: [PATCH 03/15] Generate opam file using dune-project --- dune-project | 25 +++++++++++++++++++++ gobject-introspection.opam | 45 ++++++++++++++++++++++++-------------- 2 files changed, 54 insertions(+), 16 deletions(-) diff --git a/dune-project b/dune-project index 3e2a615..c405771 100644 --- a/dune-project +++ b/dune-project @@ -1 +1,26 @@ (lang dune 3.17) +(name gobject-introspection) +(formatting disabled) +(generate_opam_files true) +(source (github cedlemo/OCaml-GObject-Introspection)) +(authors "Cédric Le Moigne ") +(maintainers "Cédric Le Moigne ") +(license "GPL-3.0-or-later") +(documentation https://github.com/cedlemo/OCaml-GObject-Introspection/wiki) +(package + (name gobject-introspection) + (synopsis "OCaml bindings for the GObject-Introspection library (https://gi.readthedocs.io/en/latest/)") + (description "This library provides bindings based on Ctypes for the libgirepository API (see https://developer.gnome.org/gi/stable/)") + (depends + (ocaml (>= 4.08)) + ctypes + ctypes-foreign + (dune-configurator :build) + (base :build) + (stdio (and :build :with-test)) + (conf-pkg-config :build) + (conf-gobject-introspection :build) + (conf-glib-2 :build) + (conf-gtk3 :build) + (ounit2 :with-test) + )) diff --git a/gobject-introspection.opam b/gobject-introspection.opam index 899b5ca..265e49b 100644 --- a/gobject-introspection.opam +++ b/gobject-introspection.opam @@ -1,29 +1,42 @@ +# This file is generated by dune, edit dune-project instead opam-version: "2.0" -name: "OCaml-GObject-Introspection" -version: "0.2" -maintainer: "Cédric Le Moigne " -authors: "Cédric Le Moigne " +synopsis: + "OCaml bindings for the GObject-Introspection library (https://gi.readthedocs.io/en/latest/)" +description: + "This library provides bindings based on Ctypes for the libgirepository API (see https://developer.gnome.org/gi/stable/)" +maintainer: ["Cédric Le Moigne "] +authors: ["Cédric Le Moigne "] +license: "GPL-3.0-or-later" homepage: "https://github.com/cedlemo/OCaml-GObject-Introspection" +doc: "https://github.com/cedlemo/OCaml-GObject-Introspection/wiki" bug-reports: "https://github.com/cedlemo/OCaml-GObject-Introspection/issues" -license: "GPL3" -dev-repo: "git+https://github.com/cedlemo/OCaml-GObject-Introspection.git" -synopsis: "OCaml bindings for the GObject-Introspection library (https://gi.readthedocs.io/en/latest/)" -description: "This library provides bindings based on Ctypes for the libgirepository API (see https://developer.gnome.org/gi/stable/)" -build: [ - ["dune" "build" "-p" name "-j" jobs] - ["dune" "runtest" "-p" name "-j" jobs] {with-test} -] depends: [ - "ocaml" "dune" {>= "3.17"} + "ocaml" {>= "4.08"} "ctypes" "ctypes-foreign" - "ounit2" {with-test} - "base" - "stdio" "dune-configurator" {build} + "base" {build} + "stdio" {build & with-test} "conf-pkg-config" {build} "conf-gobject-introspection" {build} "conf-glib-2" {build} "conf-gtk3" {build} + "ounit2" {with-test} + "odoc" {with-doc} +] +build: [ + ["dune" "subst"] {dev} + [ + "dune" + "build" + "-p" + name + "-j" + jobs + "@install" + "@runtest" {with-test} + "@doc" {with-doc} + ] ] +dev-repo: "git+https://github.com/cedlemo/OCaml-GObject-Introspection.git" From 04b51fce41d46620340c8761fc448513a8330ca8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 17:12:00 +0100 Subject: [PATCH 04/15] Reformat using ocamlformat.0.20.1 --- .ocamlformat | 1 + bindings/Arg_info.ml | 129 +++++---- bindings/Base_info.ml | 137 +++++----- bindings/Field_info.ml | 19 +- bindings/Function_info.ml | 39 ++- bindings/GParam.ml | 87 +++--- bindings/GSignal.ml | 83 +++--- bindings/Types.ml | 181 ++++++------ bindings/VFunc_info.ml | 31 ++- bindings/bindings.ml | 39 ++- bindings/dune | 7 +- bindings/utils.ml | 10 +- config/discover.ml | 99 ++++--- dune-project | 1 - lib/Arg_info.ml | 56 ++-- lib/Arg_info.mli | 52 ++-- lib/Base_info.ml | 32 +-- lib/Base_info.mli | 33 +-- lib/Callable_info.ml | 36 +-- lib/Callable_info.mli | 47 ++-- lib/Constant_info.ml | 35 ++- lib/Constant_info.mli | 24 +- lib/Conversions.ml | 72 +++-- lib/Enum_info.ml | 66 +++-- lib/Enum_info.mli | 49 ++-- lib/Field_info.ml | 42 +-- lib/Field_info.mli | 30 +- lib/Function_info.ml | 87 +++--- lib/Function_info.mli | 42 +-- lib/GParam.ml | 26 +- lib/GSignal.ml | 21 +- lib/Interface_info.ml | 127 +++++---- lib/Interface_info.mli | 84 +++--- lib/Object_info.ml | 195 +++++++------ lib/Object_info.mli | 128 ++++----- lib/Property_info.ml | 27 +- lib/Property_info.mli | 27 +- lib/Registered_type_info.ml | 21 +- lib/Registered_type_info.mli | 25 +- lib/Repository.ml | 92 ++++--- lib/Repository.mli | 62 ++--- lib/Signal_info.ml | 39 ++- lib/Signal_info.mli | 40 +-- lib/Struct_info.ml | 78 +++--- lib/Struct_info.mli | 56 ++-- lib/Stubs.ml | 19 +- lib/Type_info.ml | 61 ++--- lib/Type_info.mli | 48 ++-- lib/Types.ml | 42 +-- lib/Types.mli | 44 +-- lib/Union_info.ml | 85 +++--- lib/Union_info.mli | 66 ++--- lib/VFunc_info.ml | 57 ++-- lib/VFunc_info.mli | 39 +-- lib/Value_info.ml | 32 ++- lib/Value_info.mli | 21 +- lib/Version.ml | 11 +- lib/Version.mli | 6 +- lib/dune | 98 ++++--- lib/utils.ml | 13 +- samples/dune | 14 +- samples/gi_baseinfo_deprecated.ml | 19 +- samples/gi_baseinfo_discriminated.ml | 34 +-- samples/gi_baseinfo_get_name.ml | 18 +- samples/gi_baseinfo_get_type.ml | 28 +- samples/gi_repository.ml | 10 +- stubgen/bindings_c_gen_arg_info.ml | 1 - stubgen/bindings_c_gen_base_info.ml | 1 - stubgen/bindings_c_gen_field_info.ml | 1 - stubgen/bindings_c_gen_function_info.ml | 1 - stubgen/bindings_c_gen_g_param.ml | 1 - stubgen/bindings_c_gen_g_signal.ml | 1 - stubgen/bindings_c_gen_types.ml | 1 - stubgen/bindings_c_gen_vfunc_info.ml | 1 - stubgen/dune | 106 ++++--- tests/Test_arg_info.ml | 93 +++---- tests/Test_base_info.ml | 45 +-- tests/Test_callable_info.ml | 60 ++-- tests/Test_constant_info.ml | 42 +-- tests/Test_enum_info.ml | 61 ++--- tests/Test_field_info.ml | 55 ++-- tests/Test_function_info.ml | 72 ++--- tests/Test_interface_info.ml | 122 ++++----- tests/Test_object_info.ml | 349 +++++++++++------------- tests/Test_property_info.ml | 90 +++--- tests/Test_registered_type_info.ml | 143 +++++----- tests/Test_repository.ml | 76 +++--- tests/Test_repository_default.ml | 70 ++--- tests/Test_signal_info.ml | 51 ++-- tests/Test_struct_info.ml | 146 +++++----- tests/Test_type_info.ml | 116 ++++---- tests/Test_union_info.ml | 125 ++++----- tests/Test_utils.ml | 34 +-- tests/Test_version.ml | 13 +- tests/Test_vfunc_info.ml | 48 ++-- tests/dune | 3 +- tests/test.ml | 44 ++- 97 files changed, 2728 insertions(+), 2623 deletions(-) create mode 100644 .ocamlformat diff --git a/.ocamlformat b/.ocamlformat new file mode 100644 index 0000000..8a3b53e --- /dev/null +++ b/.ocamlformat @@ -0,0 +1 @@ +version = 0.26.2 diff --git a/bindings/Arg_info.ml b/bindings/Arg_info.ml index cae64f7..18ab0f5 100644 --- a/bindings/Arg_info.ml +++ b/bindings/Arg_info.ml @@ -18,9 +18,9 @@ (** The direction of a Arg_info. *) type direction = - | In (** in argument. *) - | Out (** out argument. *) - | InOut (** in and out argument. *) + | In (** in argument. *) + | Out (** out argument. *) + | InOut (** in and out argument. *) let string_of_direction = function | In -> "In" @@ -35,23 +35,25 @@ let string_of_direction = function complete. In case of a containing type such as a list, an array or a hash table the container itself is specified differently from the items within the container itself. Each container is freed differently, check the - documentation for the types themselves for information on how to free them.*) + documentation for the types themselves for information on how to free them. *) type transfer = - | Nothing (** transfer nothing from the callee (function or the type - instance the property belongs to) to the caller. The callee - retains the ownership of the transfer and the caller doesn't - need to do anything to free up the resources of this transfer. *) - | Container (** transfer the container (list, array, hash table) from the - callee to the caller. The callee retains the ownership of - the individual items in the container and the caller has to - free up the container resources (g_list_free()/ - g_hash_table_destroy() etc) of this transfer. *) - | Everything (** transfer everything, eg the container and its contents from - the callee to the caller. This is the case when the callee - creates a copy of all the data it returns. The caller is - responsible for cleaning up the container and item resources - of this transfer. *) + | Nothing + (** transfer nothing from the callee (function or the type instance + the property belongs to) to the caller. The callee retains the + ownership of the transfer and the caller doesn't need to do + anything to free up the resources of this transfer. *) + | Container + (** transfer the container (list, array, hash table) from the callee + to the caller. The callee retains the ownership of the individual + items in the container and the caller has to free up the + container resources (g_list_free()/ g_hash_table_destroy() etc) + of this transfer. *) + | Everything + (** transfer everything, eg the container and its contents from the + callee to the caller. This is the case when the callee creates a + copy of all the data it returns. The caller is responsible for + cleaning up the container and item resources of this transfer. *) let string_of_transfert = function | Nothing -> "Nothing" @@ -62,14 +64,17 @@ let string_of_transfert = function callback is invoked and is used to decided when the invoke structs can be freed. *) type scope_type = - | Invalid (** The argument is not of callback type. *) - | Call (** The callback and associated user_data is only used during the - call to this function. *) - | Async (** The callback and associated user_data is only used until the - callback is invoked, and the callback. is invoked always - exactly once. *) - | Notified (** The callback and and associated user_data is used until the - caller is notfied via the destroy_notify. *) + | Invalid (** The argument is not of callback type. *) + | Call + (** The callback and associated user_data is only used during the + call to this function. *) + | Async + (** The callback and associated user_data is only used until the + callback is invoked, and the callback. is invoked always exactly + once. *) + | Notified + (** The callback and and associated user_data is used until the + caller is notfied via the destroy_notify. *) let string_of_scope_type = function | Invalid -> "Invalid" @@ -77,39 +82,49 @@ let string_of_scope_type = function | Async -> "Async" | Notified -> "Notified" -module Enums = functor (T : Cstubs.Types.TYPE) -> struct - let gi_direction_in = T.constant "GI_DIRECTION_IN" T.int64_t - let gi_direction_out = T.constant "GI_DIRECTION_OUT" T.int64_t - let gi_direction_inout = T.constant "GI_DIRECTION_INOUT" T.int64_t +module Enums = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_direction_in = T.constant "GI_DIRECTION_IN" T.int64_t + let gi_direction_out = T.constant "GI_DIRECTION_OUT" T.int64_t + let gi_direction_inout = T.constant "GI_DIRECTION_INOUT" T.int64_t - let direction = T.enum "GIDirection" ~typedef:true [ - In, gi_direction_in; - Out, gi_direction_out; - InOut, gi_direction_inout; - ] - ~unexpected:(Utils.unexpected_value_for "GIDirection") + let direction = + T.enum "GIDirection" ~typedef:true + [ + (In, gi_direction_in); + (Out, gi_direction_out); + (InOut, gi_direction_inout); + ] + ~unexpected:(Utils.unexpected_value_for "GIDirection") - let gi_transfer_nothing = T.constant "GI_TRANSFER_NOTHING" T.int64_t - let gi_transfer_container = T.constant "GI_TRANSFER_CONTAINER" T.int64_t - let gi_transfer_everything = T.constant "GI_TRANSFER_EVERYTHING" T.int64_t + let gi_transfer_nothing = T.constant "GI_TRANSFER_NOTHING" T.int64_t + let gi_transfer_container = T.constant "GI_TRANSFER_CONTAINER" T.int64_t + let gi_transfer_everything = T.constant "GI_TRANSFER_EVERYTHING" T.int64_t - let transfer = T.enum "GITransfer" ~typedef:true [ - Nothing, gi_transfer_nothing; - Container, gi_transfer_container; - Everything, gi_transfer_everything; - ] - ~unexpected:(Utils.unexpected_value_for "GITransfer") + let transfer = + T.enum "GITransfer" ~typedef:true + [ + (Nothing, gi_transfer_nothing); + (Container, gi_transfer_container); + (Everything, gi_transfer_everything); + ] + ~unexpected:(Utils.unexpected_value_for "GITransfer") - let gi_scope_type_invalid = T.constant "GI_SCOPE_TYPE_INVALID" T.int64_t - let gi_scope_type_call = T.constant "GI_SCOPE_TYPE_CALL" T.int64_t - let gi_scope_type_async = T.constant "GI_SCOPE_TYPE_ASYNC" T.int64_t - let gi_scope_type_notified = T.constant "GI_SCOPE_TYPE_NOTIFIED" T.int64_t + let gi_scope_type_invalid = T.constant "GI_SCOPE_TYPE_INVALID" T.int64_t + let gi_scope_type_call = T.constant "GI_SCOPE_TYPE_CALL" T.int64_t + let gi_scope_type_async = T.constant "GI_SCOPE_TYPE_ASYNC" T.int64_t + let gi_scope_type_notified = T.constant "GI_SCOPE_TYPE_NOTIFIED" T.int64_t - let scope_type = T.enum "GIScopeType" ~typedef:true [ - Invalid, gi_scope_type_invalid; - Call, gi_scope_type_call; - Async, gi_scope_type_async; - Notified, gi_scope_type_notified; - ] - ~unexpected:(Utils.unexpected_value_for "GIScopeType") -end + let scope_type = + T.enum "GIScopeType" ~typedef:true + [ + (Invalid, gi_scope_type_invalid); + (Call, gi_scope_type_call); + (Async, gi_scope_type_async); + (Notified, gi_scope_type_notified); + ] + ~unexpected:(Utils.unexpected_value_for "GIScopeType") + end diff --git a/bindings/Base_info.ml b/bindings/Base_info.ml index 26bdabb..63133bc 100644 --- a/bindings/Base_info.ml +++ b/bindings/Base_info.ml @@ -17,26 +17,27 @@ *) type info_type = - | Invalid (** invalid type *) - | Function (** function, see Function_info *) - | Callback (** callback, see Function_info *) - | Struct (** struct, see Struct_info *) - | Boxed (** boxed, see Struct_info or Union_info *) - | Enum (** enum, see Enum_info *) - | Flags (** flags, see Enum_info *) - | Object (** object, see Object_info *) - | Interface (** interface, see Interface_info *) - | Constant (** contant, see Constant_info *) - | Invalid_0 (** deleted, used to be GI_INFO_TYPE_ERROR_DOMAIN. *) - | Union (** union, see Union_info *) - | Value (** enum value, see Value_info *) - | Signal (** signal, see Signal_info *) - | Vfunc (** virtual function, see VFunc_info *) - | Property (** GObject property, see Property_info *) - | Field (** struct or union field, see Field_info *) - | Arg (** argument of a function or callback, see Arg_info *) - | Type (** type information, see Type_info *) - | Unresolved (** unresolved type, a type which is not present in the typelib, or any of its dependencies. *) + | Invalid (** invalid type *) + | Function (** function, see Function_info *) + | Callback (** callback, see Function_info *) + | Struct (** struct, see Struct_info *) + | Boxed (** boxed, see Struct_info or Union_info *) + | Enum (** enum, see Enum_info *) + | Flags (** flags, see Enum_info *) + | Object (** object, see Object_info *) + | Interface (** interface, see Interface_info *) + | Constant (** contant, see Constant_info *) + | Invalid_0 (** deleted, used to be GI_INFO_TYPE_ERROR_DOMAIN. *) + | Union (** union, see Union_info *) + | Value (** enum value, see Value_info *) + | Signal (** signal, see Signal_info *) + | Vfunc (** virtual function, see VFunc_info *) + | Property (** GObject property, see Property_info *) + | Field (** struct or union field, see Field_info *) + | Arg (** argument of a function or callback, see Arg_info *) + | Type (** type information, see Type_info *) + | Unresolved + (** unresolved type, a type which is not present in the typelib, or any of its dependencies. *) let string_of_info_type = function | Invalid -> "Invalid" @@ -60,49 +61,55 @@ let string_of_info_type = function | Type -> "Type" | Unresolved -> "Unresolved " -module Enums = functor (T : Cstubs.Types.TYPE) -> struct - let gi_info_type_invalid = T.constant "GI_INFO_TYPE_INVALID" T.int64_t - let gi_info_type_function = T.constant "GI_INFO_TYPE_FUNCTION" T.int64_t - let gi_info_type_callback = T.constant "GI_INFO_TYPE_CALLBACK" T.int64_t - let gi_info_type_struct = T.constant "GI_INFO_TYPE_STRUCT" T.int64_t - let gi_info_type_boxed = T.constant "GI_INFO_TYPE_BOXED" T.int64_t - let gi_info_type_enum = T.constant "GI_INFO_TYPE_ENUM" T.int64_t - let gi_info_type_flags = T.constant "GI_INFO_TYPE_FLAGS" T.int64_t - let gi_info_type_object = T.constant "GI_INFO_TYPE_OBJECT" T.int64_t - let gi_info_type_interface = T.constant "GI_INFO_TYPE_INTERFACE" T.int64_t - let gi_info_type_constant = T.constant "GI_INFO_TYPE_CONSTANT" T.int64_t - let gi_info_type_invalid_0 = T.constant "GI_INFO_TYPE_INVALID_0" T.int64_t - let gi_info_type_union = T.constant "GI_INFO_TYPE_UNION" T.int64_t - let gi_info_type_value = T.constant "GI_INFO_TYPE_VALUE" T.int64_t - let gi_info_type_signal = T.constant "GI_INFO_TYPE_SIGNAL" T.int64_t - let gi_info_type_vfunc = T.constant "GI_INFO_TYPE_VFUNC" T.int64_t - let gi_info_type_property = T.constant "GI_INFO_TYPE_PROPERTY" T.int64_t - let gi_info_type_field = T.constant "GI_INFO_TYPE_FIELD" T.int64_t - let gi_info_type_arg = T.constant "GI_INFO_TYPE_ARG" T.int64_t - let gi_info_type_type = T.constant "GI_INFO_TYPE_TYPE" T.int64_t - let gi_info_type_unresolved = T.constant "GI_INFO_TYPE_UNRESOLVED" T.int64_t +module Enums = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_info_type_invalid = T.constant "GI_INFO_TYPE_INVALID" T.int64_t + let gi_info_type_function = T.constant "GI_INFO_TYPE_FUNCTION" T.int64_t + let gi_info_type_callback = T.constant "GI_INFO_TYPE_CALLBACK" T.int64_t + let gi_info_type_struct = T.constant "GI_INFO_TYPE_STRUCT" T.int64_t + let gi_info_type_boxed = T.constant "GI_INFO_TYPE_BOXED" T.int64_t + let gi_info_type_enum = T.constant "GI_INFO_TYPE_ENUM" T.int64_t + let gi_info_type_flags = T.constant "GI_INFO_TYPE_FLAGS" T.int64_t + let gi_info_type_object = T.constant "GI_INFO_TYPE_OBJECT" T.int64_t + let gi_info_type_interface = T.constant "GI_INFO_TYPE_INTERFACE" T.int64_t + let gi_info_type_constant = T.constant "GI_INFO_TYPE_CONSTANT" T.int64_t + let gi_info_type_invalid_0 = T.constant "GI_INFO_TYPE_INVALID_0" T.int64_t + let gi_info_type_union = T.constant "GI_INFO_TYPE_UNION" T.int64_t + let gi_info_type_value = T.constant "GI_INFO_TYPE_VALUE" T.int64_t + let gi_info_type_signal = T.constant "GI_INFO_TYPE_SIGNAL" T.int64_t + let gi_info_type_vfunc = T.constant "GI_INFO_TYPE_VFUNC" T.int64_t + let gi_info_type_property = T.constant "GI_INFO_TYPE_PROPERTY" T.int64_t + let gi_info_type_field = T.constant "GI_INFO_TYPE_FIELD" T.int64_t + let gi_info_type_arg = T.constant "GI_INFO_TYPE_ARG" T.int64_t + let gi_info_type_type = T.constant "GI_INFO_TYPE_TYPE" T.int64_t + let gi_info_type_unresolved = T.constant "GI_INFO_TYPE_UNRESOLVED" T.int64_t - let info_type = T.enum "GIInfoType" ~typedef:true [ - Invalid, gi_info_type_invalid; - Function, gi_info_type_function; - Callback, gi_info_type_callback; - Struct, gi_info_type_struct; - Boxed, gi_info_type_boxed; - Enum, gi_info_type_enum; - Flags, gi_info_type_flags; - Object, gi_info_type_object; - Interface, gi_info_type_interface; - Constant, gi_info_type_constant; - Invalid_0, gi_info_type_invalid_0; - Union, gi_info_type_union; - Value, gi_info_type_value; - Signal, gi_info_type_signal; - Vfunc, gi_info_type_vfunc; - Property, gi_info_type_property; - Field, gi_info_type_field; - Arg, gi_info_type_arg; - Type, gi_info_type_type; - Unresolved, gi_info_type_unresolved; - ] - ~unexpected:(Utils.unexpected_value_for "GIInfoType") -end + let info_type = + T.enum "GIInfoType" ~typedef:true + [ + (Invalid, gi_info_type_invalid); + (Function, gi_info_type_function); + (Callback, gi_info_type_callback); + (Struct, gi_info_type_struct); + (Boxed, gi_info_type_boxed); + (Enum, gi_info_type_enum); + (Flags, gi_info_type_flags); + (Object, gi_info_type_object); + (Interface, gi_info_type_interface); + (Constant, gi_info_type_constant); + (Invalid_0, gi_info_type_invalid_0); + (Union, gi_info_type_union); + (Value, gi_info_type_value); + (Signal, gi_info_type_signal); + (Vfunc, gi_info_type_vfunc); + (Property, gi_info_type_property); + (Field, gi_info_type_field); + (Arg, gi_info_type_arg); + (Type, gi_info_type_type); + (Unresolved, gi_info_type_unresolved); + ] + ~unexpected:(Utils.unexpected_value_for "GIInfoType") + end diff --git a/bindings/Field_info.ml b/bindings/Field_info.ml index a543065..27dd81d 100644 --- a/bindings/Field_info.ml +++ b/bindings/Field_info.ml @@ -18,16 +18,21 @@ (** Flags for a Field_info. *) type flags = - | Is_readable (** field is readable. *) - | Is_writable (** field is writable. *) + | Is_readable (** field is readable. *) + | Is_writable (** field is writable. *) let string_of_flag = function | Is_readable -> "Is_readable" | Is_writable -> "Is_writable" -module Flags = functor (T : Cstubs.Types.TYPE) -> struct - let gi_field_is_readable = T.constant "GI_FIELD_IS_READABLE" T.int64_t - let gi_field_is_writable = T.constant "GI_FIELD_IS_WRITABLE" T.int64_t +module Flags = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_field_is_readable = T.constant "GI_FIELD_IS_READABLE" T.int64_t + let gi_field_is_writable = T.constant "GI_FIELD_IS_WRITABLE" T.int64_t - let flags = T.enum "GIFieldInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) -end + let flags = + T.enum "GIFieldInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) + end diff --git a/bindings/Function_info.ml b/bindings/Function_info.ml index 13048a0..de2281f 100644 --- a/bindings/Function_info.ml +++ b/bindings/Function_info.ml @@ -18,12 +18,12 @@ (** Flags for a Function_info struct. *) type flags = - | Is_method (** is a method. *) - | Is_constructor (** is a constructor. *) - | Is_getter (** is a getter of a Property_info. *) - | Is_setter (** is a setter of a Property_info. *) - | Wraps_vfunc (** represents a virtual function. *) - | Throws (** the function may throw an error. *) + | Is_method (** is a method. *) + | Is_constructor (** is a constructor. *) + | Is_getter (** is a getter of a Property_info. *) + | Is_setter (** is a setter of a Property_info. *) + | Wraps_vfunc (** represents a virtual function. *) + | Throws (** the function may throw an error. *) let string_of_flag = function | Is_method -> "Is_method" @@ -33,12 +33,21 @@ let string_of_flag = function | Wraps_vfunc -> "Wraps_vfunc" | Throws -> "Throws" -module Flags = functor (T : Cstubs.Types.TYPE) -> struct - let gi_function_is_method = T.constant "GI_FUNCTION_IS_METHOD" T.int64_t - let gi_function_is_constructor = T.constant "GI_FUNCTION_IS_CONSTRUCTOR" T.int64_t - let gi_function_is_getter = T.constant "GI_FUNCTION_IS_GETTER" T.int64_t - let gi_function_is_setter = T.constant "GI_FUNCTION_IS_SETTER" T.int64_t - let gi_function_wraps_vfunc = T.constant "GI_FUNCTION_WRAPS_VFUNC" T.int64_t - let gi_function_throws = T.constant "GI_FUNCTION_THROWS" T.int64_t - let flags = T.enum "GIFunctionInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) -end +module Flags = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_function_is_method = T.constant "GI_FUNCTION_IS_METHOD" T.int64_t + + let gi_function_is_constructor = + T.constant "GI_FUNCTION_IS_CONSTRUCTOR" T.int64_t + + let gi_function_is_getter = T.constant "GI_FUNCTION_IS_GETTER" T.int64_t + let gi_function_is_setter = T.constant "GI_FUNCTION_IS_SETTER" T.int64_t + let gi_function_wraps_vfunc = T.constant "GI_FUNCTION_WRAPS_VFUNC" T.int64_t + let gi_function_throws = T.constant "GI_FUNCTION_THROWS" T.int64_t + + let flags = + T.enum "GIFunctionInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) + end diff --git a/bindings/GParam.ml b/bindings/GParam.ml index 4ae9af0..a2ba27c 100644 --- a/bindings/GParam.ml +++ b/bindings/GParam.ml @@ -21,31 +21,36 @@ * Through the GParamFlags flag values, certain aspects of parameters can be * configured. *) type flags = - | Readable (** the parameter is readable *) - | Writable (** the parameter is writable *) - | Readwrite (** alias for G_PARAM_READABLE | G_PARAM_WRITABLE *) - | Construct (** the parameter will be set upon object construction *) - | Construct_only (** the parameter can only be set upon object construction *) - | Lax_validation (** upon parameter conversion (see g_param_value_convert()) - strict validation is not required *) - | Static_name (** the string used as name when constructing the parameter - is guaranteed to remain valid and unmodified for the - lifetime of the parameter. Since 2.8 *) - | Static_nick (** the string used as nick when constructing the parameter - is guaranteed to remain valid and unmmodified for the - lifetime of the parameter. Since 2.8 *) - | Static_blurb (** the string used as blurb when constructing the parameter - is guaranteed to remain valid and unmodified for the - lifetime of the parameter. Since 2.8 *) - | Explicit_notify (** calls to g_object_set_property() for this property will - not automatically result in a "notify" signal being - emitted: the implementation must call g_object_notify() - themselves in case the property actually changes. - Since: 2.42. *) - | Deprecated (** the parameter is deprecated and will be removed in a - future version. A warning will be generated if it is - used while running with G_ENABLE_DIAGNOSTIC=1. - Since 2.26 *) + | Readable (** the parameter is readable *) + | Writable (** the parameter is writable *) + | Readwrite (** alias for G_PARAM_READABLE | G_PARAM_WRITABLE *) + | Construct (** the parameter will be set upon object construction *) + | Construct_only + (** the parameter can only be set upon object construction *) + | Lax_validation + (** upon parameter conversion (see g_param_value_convert()) strict + validation is not required *) + | Static_name + (** the string used as name when constructing the parameter is + guaranteed to remain valid and unmodified for the lifetime of the + parameter. Since 2.8 *) + | Static_nick + (** the string used as nick when constructing the parameter is + guaranteed to remain valid and unmmodified for the lifetime of + the parameter. Since 2.8 *) + | Static_blurb + (** the string used as blurb when constructing the parameter is + guaranteed to remain valid and unmodified for the lifetime of the + parameter. Since 2.8 *) + | Explicit_notify + (** calls to g_object_set_property() for this property will not + automatically result in a "notify" signal being emitted: the + implementation must call g_object_notify() themselves in case the + property actually changes. Since: 2.42. *) + | Deprecated + (** the parameter is deprecated and will be removed in a future + version. A warning will be generated if it is used while running + with G_ENABLE_DIAGNOSTIC=1. Since 2.26 *) let string_of_flag = function | Readable -> "Readable" @@ -60,17 +65,21 @@ let string_of_flag = function | Explicit_notify -> "Explicit_notify" | Deprecated -> "Deprecated" -module Flags = functor (T : Cstubs.Types.TYPE) -> struct - let g_param_readable = T.constant "G_PARAM_READABLE" T.int64_t - let g_param_writable = T.constant "G_PARAM_WRITABLE" T.int64_t - let g_param_readwrite = T.constant "G_PARAM_READWRITE" T.int64_t - let g_param_construct = T.constant "G_PARAM_CONSTRUCT" T.int64_t - let g_param_construct_only = T.constant "G_PARAM_CONSTRUCT_ONLY" T.int64_t - let g_param_lax_validation = T.constant "G_PARAM_LAX_VALIDATION" T.int64_t - let g_param_static_name = T.constant "G_PARAM_STATIC_NAME" T.int64_t - let g_param_static_nick = T.constant "G_PARAM_STATIC_NICK" T.int64_t - let g_param_static_blurb = T.constant "G_PARAM_STATIC_BLURB" T.int64_t - let g_param_explicit_notify = T.constant "G_PARAM_EXPLICIT_NOTIFY" T.int64_t - let g_param_deprecated = T.constant "G_PARAM_DEPRECATED" T.int64_t - let flags = T.enum "GParamFlags" ~typedef:true [] ~unexpected:(fun x -> x) -end +module Flags = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let g_param_readable = T.constant "G_PARAM_READABLE" T.int64_t + let g_param_writable = T.constant "G_PARAM_WRITABLE" T.int64_t + let g_param_readwrite = T.constant "G_PARAM_READWRITE" T.int64_t + let g_param_construct = T.constant "G_PARAM_CONSTRUCT" T.int64_t + let g_param_construct_only = T.constant "G_PARAM_CONSTRUCT_ONLY" T.int64_t + let g_param_lax_validation = T.constant "G_PARAM_LAX_VALIDATION" T.int64_t + let g_param_static_name = T.constant "G_PARAM_STATIC_NAME" T.int64_t + let g_param_static_nick = T.constant "G_PARAM_STATIC_NICK" T.int64_t + let g_param_static_blurb = T.constant "G_PARAM_STATIC_BLURB" T.int64_t + let g_param_explicit_notify = T.constant "G_PARAM_EXPLICIT_NOTIFY" T.int64_t + let g_param_deprecated = T.constant "G_PARAM_DEPRECATED" T.int64_t + let flags = T.enum "GParamFlags" ~typedef:true [] ~unexpected:(fun x -> x) + end diff --git a/bindings/GSignal.ml b/bindings/GSignal.ml index 7e50c92..a057e88 100644 --- a/bindings/GSignal.ml +++ b/bindings/GSignal.ml @@ -21,33 +21,34 @@ signal description outlines how especially the RUN flags control the stages of a signal emission. *) type flags = - | Run_first (** Invoke the object method handler in the first - emission stage. *) - | Run_last (** Invoke the object method handler in the third - emission stage. *) - | Run_cleanup (** Invoke the object method handler in the last - emission stage. *) - | No_recurse (** Signals being emitted for an object while currently - being in emission for this very object will not be - emitted recursively, but instead cause the first - emission to be restarted. *) - | Detailed (** This signal supports "::detail" appendices to the - signal name upon handler connections and emissions. *) - | Action (** Action signals are signals that may freely be - emitted on alive objects from user code via - g_signal_emit() and friends, without the need of - being embedded into extra code that performs pre or - post emission adjustments on the object. They can - also be thought of as object methods which can be - called generically by third-party code. *) - | No_hooks (** No emissions hooks are supported for this signal. *) - | Must_collect (** Varargs signal emission will always collect the - arguments, even if there are no signal handlers - connected. Since 2.30. *) - | Deprecated (** The signal is deprecated and will be removed in a - future version. A warning will be generated if it is - connected while running with G_ENABLE_DIAGNOSTIC=1. - Since 2.32. *) + | Run_first + (** Invoke the object method handler in the first emission stage. *) + | Run_last + (** Invoke the object method handler in the third emission stage. *) + | Run_cleanup + (** Invoke the object method handler in the last emission stage. *) + | No_recurse + (** Signals being emitted for an object while currently being in + emission for this very object will not be emitted recursively, + but instead cause the first emission to be restarted. *) + | Detailed + (** This signal supports "::detail" appendices to the signal name + upon handler connections and emissions. *) + | Action + (** Action signals are signals that may freely be emitted on alive + objects from user code via g_signal_emit() and friends, without + the need of being embedded into extra code that performs pre or + post emission adjustments on the object. They can also be thought + of as object methods which can be called generically by + third-party code. *) + | No_hooks (** No emissions hooks are supported for this signal. *) + | Must_collect + (** Varargs signal emission will always collect the arguments, even + if there are no signal handlers connected. Since 2.30. *) + | Deprecated + (** The signal is deprecated and will be removed in a future + version. A warning will be generated if it is connected while + running with G_ENABLE_DIAGNOSTIC=1. Since 2.32. *) let string_of_flag = function | Run_first -> "Run_first" @@ -60,15 +61,19 @@ let string_of_flag = function | Must_collect -> "Must_collect" | Deprecated -> "Deprecated" -module Flags = functor (T : Cstubs.Types.TYPE) -> struct - let g_signal_run_first = T.constant "G_SIGNAL_RUN_FIRST" T.int64_t - let g_signal_run_last = T.constant "G_SIGNAL_RUN_LAST" T.int64_t - let g_signal_run_cleanup = T.constant "G_SIGNAL_RUN_CLEANUP" T.int64_t - let g_signal_no_recurse = T.constant "G_SIGNAL_NO_RECURSE" T.int64_t - let g_signal_detailed = T.constant "G_SIGNAL_DETAILED" T.int64_t - let g_signal_action = T.constant "G_SIGNAL_ACTION" T.int64_t - let g_signal_no_hooks = T.constant "G_SIGNAL_NO_HOOKS" T.int64_t - let g_signal_must_collect = T.constant "G_SIGNAL_MUST_COLLECT" T.int64_t - let g_signal_deprecated = T.constant "G_SIGNAL_DEPRECATED" T.int64_t - let flags = T.enum "GSignalFlags" ~typedef:true [] ~unexpected:(fun x -> x) -end +module Flags = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let g_signal_run_first = T.constant "G_SIGNAL_RUN_FIRST" T.int64_t + let g_signal_run_last = T.constant "G_SIGNAL_RUN_LAST" T.int64_t + let g_signal_run_cleanup = T.constant "G_SIGNAL_RUN_CLEANUP" T.int64_t + let g_signal_no_recurse = T.constant "G_SIGNAL_NO_RECURSE" T.int64_t + let g_signal_detailed = T.constant "G_SIGNAL_DETAILED" T.int64_t + let g_signal_action = T.constant "G_SIGNAL_ACTION" T.int64_t + let g_signal_no_hooks = T.constant "G_SIGNAL_NO_HOOKS" T.int64_t + let g_signal_must_collect = T.constant "G_SIGNAL_MUST_COLLECT" T.int64_t + let g_signal_deprecated = T.constant "G_SIGNAL_DEPRECATED" T.int64_t + let flags = T.enum "GSignalFlags" ~typedef:true [] ~unexpected:(fun x -> x) + end diff --git a/bindings/Types.ml b/bindings/Types.ml index 6f6ad8b..83fbeaa 100644 --- a/bindings/Types.ml +++ b/bindings/Types.ml @@ -18,10 +18,10 @@ (** The type of array in a GITypeInfo. *) type array_type = - | C (** a C array, char[] for instance *) - | Array (** a GArray array *) + | C (** a C array, char[] for instance *) + | Array (** a GArray array *) | Ptr_array (** a GPtrArray array *) - | Byte_array (** a GByteArray array *) + | Byte_array (** a GByteArray array *) let string_of_array_type = function | C -> "C" @@ -31,28 +31,29 @@ let string_of_array_type = function (** The type tag of a Type_info. *) type tag = - | Void (** void *) - | Boolean (** boolean *) - | Int8 (** 8-bit signed integer *) - | Uint8 (** 8-bit unsigned integer *) - | Int16 (** 16-bit signed integer *) - | Uint16 (** 16-bit unsigned integer *) - | Int32 (** 32-bit signed integer *) - | Uint32 (** 32-bit unsigned integer *) - | Int64 (** 64-bit signed integer *) - | Uint64 (** 64-bit unsigned integer *) - | Float (** float *) - | Double (** double floating point *) - | GType (** a GType *) - | Utf8 (** a UTF-8 encoded string *) - | Filename (** a filename, encoded in the same encoding as the native filesystem is using. *) - | Array (** an array *) - | Interface (** an extended interface object *) - | GList (** a GList *) - | GSList (** a GSList *) - | GHash (** a GHashTable *) - | Error (** a GError *) - | Unichar (** Unicode character *) + | Void (** void *) + | Boolean (** boolean *) + | Int8 (** 8-bit signed integer *) + | Uint8 (** 8-bit unsigned integer *) + | Int16 (** 16-bit signed integer *) + | Uint16 (** 16-bit unsigned integer *) + | Int32 (** 32-bit signed integer *) + | Uint32 (** 32-bit unsigned integer *) + | Int64 (** 64-bit signed integer *) + | Uint64 (** 64-bit unsigned integer *) + | Float (** float *) + | Double (** double floating point *) + | GType (** a GType *) + | Utf8 (** a UTF-8 encoded string *) + | Filename + (** a filename, encoded in the same encoding as the native filesystem is using. *) + | Array (** an array *) + | Interface (** an extended interface object *) + | GList (** a GList *) + | GSList (** a GSList *) + | GHash (** a GHashTable *) + | Error (** a GError *) + | Unichar (** Unicode character *) let string_of_tag = function | Void -> "Void" @@ -78,66 +79,76 @@ let string_of_tag = function | Error -> "Error" | Unichar -> "Unichar" -module Enums = functor (T : Cstubs.Types.TYPE) -> struct - let gi_type_tag_void = T.constant "GI_TYPE_TAG_VOID" T.int64_t - let gi_type_tag_boolean = T.constant "GI_TYPE_TAG_BOOLEAN" T.int64_t - let gi_type_tag_int8 = T.constant "GI_TYPE_TAG_INT8" T.int64_t - let gi_type_tag_uint8 = T.constant "GI_TYPE_TAG_UINT8" T.int64_t - let gi_type_tag_int16 = T.constant "GI_TYPE_TAG_INT16" T.int64_t - let gi_type_tag_uint16 = T.constant "GI_TYPE_TAG_UINT16" T.int64_t - let gi_type_tag_int32 = T.constant "GI_TYPE_TAG_INT32" T.int64_t - let gi_type_tag_uint32 = T.constant "GI_TYPE_TAG_UINT32" T.int64_t - let gi_type_tag_int64 = T.constant "GI_TYPE_TAG_INT64" T.int64_t - let gi_type_tag_uint64 = T.constant "GI_TYPE_TAG_UINT64" T.int64_t - let gi_type_tag_float = T.constant "GI_TYPE_TAG_FLOAT" T.int64_t - let gi_type_tag_double = T.constant "GI_TYPE_TAG_DOUBLE" T.int64_t - let gi_type_tag_gtype = T.constant "GI_TYPE_TAG_GTYPE" T.int64_t - let gi_type_tag_utf8 = T.constant "GI_TYPE_TAG_UTF8" T.int64_t - let gi_type_tag_filename = T.constant "GI_TYPE_TAG_FILENAME" T.int64_t - let gi_type_tag_array = T.constant "GI_TYPE_TAG_ARRAY" T.int64_t - let gi_type_tag_interface = T.constant "GI_TYPE_TAG_INTERFACE" T.int64_t - let gi_type_tag_glist = T.constant "GI_TYPE_TAG_GLIST" T.int64_t - let gi_type_tag_gslist = T.constant "GI_TYPE_TAG_GSLIST" T.int64_t - let gi_type_tag_ghash = T.constant "GI_TYPE_TAG_GHASH" T.int64_t - let gi_type_tag_error = T.constant "GI_TYPE_TAG_ERROR" T.int64_t - let gi_type_tag_unichar = T.constant "GI_TYPE_TAG_UNICHAR" T.int64_t +module Enums = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_type_tag_void = T.constant "GI_TYPE_TAG_VOID" T.int64_t + let gi_type_tag_boolean = T.constant "GI_TYPE_TAG_BOOLEAN" T.int64_t + let gi_type_tag_int8 = T.constant "GI_TYPE_TAG_INT8" T.int64_t + let gi_type_tag_uint8 = T.constant "GI_TYPE_TAG_UINT8" T.int64_t + let gi_type_tag_int16 = T.constant "GI_TYPE_TAG_INT16" T.int64_t + let gi_type_tag_uint16 = T.constant "GI_TYPE_TAG_UINT16" T.int64_t + let gi_type_tag_int32 = T.constant "GI_TYPE_TAG_INT32" T.int64_t + let gi_type_tag_uint32 = T.constant "GI_TYPE_TAG_UINT32" T.int64_t + let gi_type_tag_int64 = T.constant "GI_TYPE_TAG_INT64" T.int64_t + let gi_type_tag_uint64 = T.constant "GI_TYPE_TAG_UINT64" T.int64_t + let gi_type_tag_float = T.constant "GI_TYPE_TAG_FLOAT" T.int64_t + let gi_type_tag_double = T.constant "GI_TYPE_TAG_DOUBLE" T.int64_t + let gi_type_tag_gtype = T.constant "GI_TYPE_TAG_GTYPE" T.int64_t + let gi_type_tag_utf8 = T.constant "GI_TYPE_TAG_UTF8" T.int64_t + let gi_type_tag_filename = T.constant "GI_TYPE_TAG_FILENAME" T.int64_t + let gi_type_tag_array = T.constant "GI_TYPE_TAG_ARRAY" T.int64_t + let gi_type_tag_interface = T.constant "GI_TYPE_TAG_INTERFACE" T.int64_t + let gi_type_tag_glist = T.constant "GI_TYPE_TAG_GLIST" T.int64_t + let gi_type_tag_gslist = T.constant "GI_TYPE_TAG_GSLIST" T.int64_t + let gi_type_tag_ghash = T.constant "GI_TYPE_TAG_GHASH" T.int64_t + let gi_type_tag_error = T.constant "GI_TYPE_TAG_ERROR" T.int64_t + let gi_type_tag_unichar = T.constant "GI_TYPE_TAG_UNICHAR" T.int64_t - let tag = T.enum "GITypeTag" ~typedef:true [ - Void, gi_type_tag_void; - Boolean, gi_type_tag_boolean; - Int8, gi_type_tag_int8; - Uint8, gi_type_tag_uint8; - Int16, gi_type_tag_int16; - Uint16, gi_type_tag_uint16; - Int32, gi_type_tag_int32; - Uint32, gi_type_tag_uint32; - Int64, gi_type_tag_int64; - Uint64, gi_type_tag_uint64; - Float, gi_type_tag_float; - Double, gi_type_tag_double; - GType, gi_type_tag_gtype; - Utf8, gi_type_tag_utf8; - Filename, gi_type_tag_filename; - Array, gi_type_tag_array; - Interface, gi_type_tag_interface; - GList, gi_type_tag_glist; - GSList, gi_type_tag_gslist; - GHash, gi_type_tag_ghash; - Error, gi_type_tag_error; - Unichar, gi_type_tag_unichar; - ] - ~unexpected:(Utils.unexpected_value_for "GITypeTag") + let tag = + T.enum "GITypeTag" ~typedef:true + [ + (Void, gi_type_tag_void); + (Boolean, gi_type_tag_boolean); + (Int8, gi_type_tag_int8); + (Uint8, gi_type_tag_uint8); + (Int16, gi_type_tag_int16); + (Uint16, gi_type_tag_uint16); + (Int32, gi_type_tag_int32); + (Uint32, gi_type_tag_uint32); + (Int64, gi_type_tag_int64); + (Uint64, gi_type_tag_uint64); + (Float, gi_type_tag_float); + (Double, gi_type_tag_double); + (GType, gi_type_tag_gtype); + (Utf8, gi_type_tag_utf8); + (Filename, gi_type_tag_filename); + (Array, gi_type_tag_array); + (Interface, gi_type_tag_interface); + (GList, gi_type_tag_glist); + (GSList, gi_type_tag_gslist); + (GHash, gi_type_tag_ghash); + (Error, gi_type_tag_error); + (Unichar, gi_type_tag_unichar); + ] + ~unexpected:(Utils.unexpected_value_for "GITypeTag") - let gi_array_type_c = T.constant "GI_ARRAY_TYPE_C" T.int64_t - let gi_array_type_array = T.constant "GI_ARRAY_TYPE_ARRAY" T.int64_t - let gi_array_type_ptr_array = T.constant "GI_ARRAY_TYPE_PTR_ARRAY" T.int64_t - let gi_array_type_byte_array = T.constant "GI_ARRAY_TYPE_BYTE_ARRAY" T.int64_t + let gi_array_type_c = T.constant "GI_ARRAY_TYPE_C" T.int64_t + let gi_array_type_array = T.constant "GI_ARRAY_TYPE_ARRAY" T.int64_t + let gi_array_type_ptr_array = T.constant "GI_ARRAY_TYPE_PTR_ARRAY" T.int64_t - let array_type = T.enum "GIArrayType" ~typedef:true [ - C, gi_array_type_c; - Array, gi_array_type_array; - Ptr_array, gi_array_type_ptr_array; - Byte_array, gi_array_type_byte_array; - ] - ~unexpected:(Utils.unexpected_value_for "GIArrayType") -end + let gi_array_type_byte_array = + T.constant "GI_ARRAY_TYPE_BYTE_ARRAY" T.int64_t + + let array_type = + T.enum "GIArrayType" ~typedef:true + [ + (C, gi_array_type_c); + (Array, gi_array_type_array); + (Ptr_array, gi_array_type_ptr_array); + (Byte_array, gi_array_type_byte_array); + ] + ~unexpected:(Utils.unexpected_value_for "GIArrayType") + end diff --git a/bindings/VFunc_info.ml b/bindings/VFunc_info.ml index b5c3802..6a4c05f 100644 --- a/bindings/VFunc_info.ml +++ b/bindings/VFunc_info.ml @@ -17,10 +17,10 @@ *) type flags = - | Must_chain_up (** chains up to the parent type *) - | Must_override (** overrides *) - | Must_not_override (** does not override *) - | Throws (** Includes a GError *) + | Must_chain_up (** chains up to the parent type *) + | Must_override (** overrides *) + | Must_not_override (** does not override *) + | Throws (** Includes a GError *) let string_of_flag = function | Must_chain_up -> "Must_chain_up" @@ -28,10 +28,19 @@ let string_of_flag = function | Must_not_override -> "Must_not_override" | Throws -> "Throws" -module Flags = functor (T : Cstubs.Types.TYPE) -> struct - let gi_vfunc_must_chain_up = T.constant "GI_VFUNC_MUST_CHAIN_UP" T.int64_t - let gi_vfunc_must_override = T.constant "GI_VFUNC_MUST_OVERRIDE" T.int64_t - let gi_vfunc_must_not_override = T.constant "GI_VFUNC_MUST_NOT_OVERRIDE" T.int64_t - let gi_vfunc_throws = T.constant "GI_VFUNC_THROWS" T.int64_t - let flags = T.enum "GIVFuncInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) -end +module Flags = +functor + (T : Cstubs.Types.TYPE) + -> + struct + let gi_vfunc_must_chain_up = T.constant "GI_VFUNC_MUST_CHAIN_UP" T.int64_t + let gi_vfunc_must_override = T.constant "GI_VFUNC_MUST_OVERRIDE" T.int64_t + + let gi_vfunc_must_not_override = + T.constant "GI_VFUNC_MUST_NOT_OVERRIDE" T.int64_t + + let gi_vfunc_throws = T.constant "GI_VFUNC_THROWS" T.int64_t + + let flags = + T.enum "GIVFuncInfoFlags" ~typedef:true [] ~unexpected:(fun x -> x) + end diff --git a/bindings/bindings.ml b/bindings/bindings.ml index 2467cb6..b823ea4 100644 --- a/bindings/bindings.ml +++ b/bindings/bindings.ml @@ -16,11 +16,34 @@ * along with OCaml-GObject-Introspection. If not, see . *) -module Base_info = struct include Base_info end -module Function_info = struct include Function_info end -module Types = struct include Types end -module VFunc_info = struct include VFunc_info end -module Arg_info = struct include Arg_info end -module Field_info = struct include Field_info end -module GParam = struct include GParam end -module GSignal = struct include GSignal end +module Base_info = struct + include Base_info +end + +module Function_info = struct + include Function_info +end + +module Types = struct + include Types +end + +module VFunc_info = struct + include VFunc_info +end + +module Arg_info = struct + include Arg_info +end + +module Field_info = struct + include Field_info +end + +module GParam = struct + include GParam +end + +module GSignal = struct + include GSignal +end diff --git a/bindings/dune b/bindings/dune index 4c20209..a3af9a0 100644 --- a/bindings/dune +++ b/bindings/dune @@ -1,5 +1,4 @@ (library - (name bindings) - (public_name gobject-introspection.bindings) - (libraries ctypes.stubs ctypes) -) + (name bindings) + (public_name gobject-introspection.bindings) + (libraries ctypes.stubs ctypes)) diff --git a/bindings/utils.ml b/bindings/utils.ml index 938df32..61c6ee6 100644 --- a/bindings/utils.ml +++ b/bindings/utils.ml @@ -1,5 +1,5 @@ - -let unexpected_value_for (enum : string) : (int64 -> 'a)= - (fun x -> - let value = " - Unexpexted value " ^ Int64.to_string x in - let message = enum ^ value in failwith message) +let unexpected_value_for (enum : string) : int64 -> 'a = + fun x -> + let value = " - Unexpexted value " ^ Int64.to_string x in + let message = enum ^ value in + failwith message diff --git a/config/discover.ml b/config/discover.ml index 2146e1e..fe106cc 100644 --- a/config/discover.ml +++ b/config/discover.ml @@ -12,42 +12,63 @@ let write_flags file list_of_str = let () = C.main ~name:"GObject-Introspection" (fun c -> - let default : C.Pkg_config.package_conf = - { libs = ["-lgirepository-1.0"; "-lgobject-2.0"; "-lglib-2.0"; "-lffi"] - ; cflags = ["-O2"; "-Wall"; "-Wextra"; "-Wno-unused-parameter"; "-pthread"; - "-I/usr/include/gobject-introspection-1.0"; - "-I/usr/lib/libffi-3.2.1/include"; - "-I/usr/include/glib-2.0"; - "-I/usr/lib/glib-2.0/include"] - } - in - let default_ffi : C.Pkg_config.package_conf = - { libs = ["-lffi"] ; - cflags = ["-O2"; "-Wall"; "-Wextra"; "-Wno-unused-parameter"; - "-I/usr/lib/libffi-3.2.1/include"; - "-I/usr/include/x86_64-linux-gnu"; (* default ubuntu *) - "-I/usr/include"] (* default ubuntu *) - } - in - let conf = - match C.Pkg_config.get c with - | None -> default - | Some pc -> - let get_config package default = - Option.value (C.Pkg_config.query pc ~package) ~default in - let libffi = get_config "libffi" default_ffi in - let gobject = get_config "gobject-introspection-1.0" default in - let module P = C.Pkg_config in - { libs = (libffi.P.libs @ gobject.P.libs); - cflags = (libffi.P.cflags @ gobject.P.cflags) } - in - let os_type = C.ocaml_config_var_exn (C.create "") "system" in - let ccopts = - if Base.String.(os_type = "macosx") then [""] - else ["-Wl,-no-as-needed"] - in - write_sexp "c_flags.sexp" conf.cflags; - write_sexp "c_library_flags.sexp" conf.libs; - write_sexp "ccopts.sexp" ccopts; - write_flags "c_library_flags" conf.libs; - write_flags "c_flags" conf.cflags) + let default : C.Pkg_config.package_conf = + { + libs = + [ "-lgirepository-1.0"; "-lgobject-2.0"; "-lglib-2.0"; "-lffi" ]; + cflags = + [ + "-O2"; + "-Wall"; + "-Wextra"; + "-Wno-unused-parameter"; + "-pthread"; + "-I/usr/include/gobject-introspection-1.0"; + "-I/usr/lib/libffi-3.2.1/include"; + "-I/usr/include/glib-2.0"; + "-I/usr/lib/glib-2.0/include"; + ]; + } + in + let default_ffi : C.Pkg_config.package_conf = + { + libs = [ "-lffi" ]; + cflags = + [ + "-O2"; + "-Wall"; + "-Wextra"; + "-Wno-unused-parameter"; + "-I/usr/lib/libffi-3.2.1/include"; + "-I/usr/include/x86_64-linux-gnu"; + (* default ubuntu *) + "-I/usr/include"; + ] + (* default ubuntu *); + } + in + let conf = + match C.Pkg_config.get c with + | None -> default + | Some pc -> + let get_config package default = + Option.value (C.Pkg_config.query pc ~package) ~default + in + let libffi = get_config "libffi" default_ffi in + let gobject = get_config "gobject-introspection-1.0" default in + let module P = C.Pkg_config in + { + libs = libffi.P.libs @ gobject.P.libs; + cflags = libffi.P.cflags @ gobject.P.cflags; + } + in + let os_type = C.ocaml_config_var_exn (C.create "") "system" in + let ccopts = + if Base.String.(os_type = "macosx") then [ "" ] + else [ "-Wl,-no-as-needed" ] + in + write_sexp "c_flags.sexp" conf.cflags; + write_sexp "c_library_flags.sexp" conf.libs; + write_sexp "ccopts.sexp" ccopts; + write_flags "c_library_flags" conf.libs; + write_flags "c_flags" conf.cflags) diff --git a/dune-project b/dune-project index c405771..5fe460f 100644 --- a/dune-project +++ b/dune-project @@ -1,6 +1,5 @@ (lang dune 3.17) (name gobject-introspection) -(formatting disabled) (generate_opam_files true) (source (github cedlemo/OCaml-GObject-Introspection)) (authors "Cédric Le Moigne ") diff --git a/lib/Arg_info.ml b/lib/Arg_info.ml index a4954dd..8caac36 100644 --- a/lib/Arg_info.ml +++ b/lib/Arg_info.ml @@ -20,67 +20,62 @@ open Ctypes open Foreign type t + let arginfo : t structure typ = structure "Arg_info" let get_direction = - foreign "g_arg_info_get_direction" - (ptr arginfo @-> returning Stubs.Arg_info.direction) + foreign "g_arg_info_get_direction" + (ptr arginfo @-> returning Stubs.Arg_info.direction) let get_closure = - foreign "g_arg_info_get_closure" - (ptr arginfo @-> returning int) + foreign "g_arg_info_get_closure" (ptr arginfo @-> returning int) let get_destroy = - foreign "g_arg_info_get_destroy" - (ptr arginfo @-> returning int) + foreign "g_arg_info_get_destroy" (ptr arginfo @-> returning int) let get_ownership_transfer = foreign "g_arg_info_get_ownership_transfer" (ptr arginfo @-> returning Stubs.Arg_info.transfer) let may_be_null = - foreign "g_arg_info_may_be_null" - (ptr arginfo @-> returning bool) + foreign "g_arg_info_may_be_null" (ptr arginfo @-> returning bool) let is_caller_allocates = - foreign "g_arg_info_is_caller_allocates" - (ptr arginfo @-> returning bool) + foreign "g_arg_info_is_caller_allocates" (ptr arginfo @-> returning bool) let is_optional = - foreign "g_arg_info_is_optional" - (ptr arginfo @-> returning bool) + foreign "g_arg_info_is_optional" (ptr arginfo @-> returning bool) let is_return_value = - foreign "g_arg_info_is_return_value" - (ptr arginfo @-> returning bool) + foreign "g_arg_info_is_return_value" (ptr arginfo @-> returning bool) -let is_skip = - foreign "g_arg_info_is_skip" - (ptr arginfo @-> returning bool) +let is_skip = foreign "g_arg_info_is_skip" (ptr arginfo @-> returning bool) let get_scope = - foreign "g_arg_info_get_scope" - (ptr arginfo @-> returning Stubs.Arg_info.scope_type) + foreign "g_arg_info_get_scope" + (ptr arginfo @-> returning Stubs.Arg_info.scope_type) let get_type info = let get_type_raw = foreign "g_arg_info_get_type" - (ptr arginfo @-> returning (ptr Type_info.typeinfo)) in + (ptr arginfo @-> returning (ptr Type_info.typeinfo)) + in let info' = get_type_raw info in Type_info.add_unref_finaliser info' (* TODO : check that the info can be casted to arg info ? *) -let cast_from_baseinfo info = - coerce (ptr Base_info.baseinfo) (ptr arginfo) info - -let cast_to_baseinfo info = - coerce (ptr arginfo) (ptr Base_info.baseinfo) info +let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr arginfo) info +let cast_to_baseinfo info = coerce (ptr arginfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -90,6 +85,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Arg_info.mli b/lib/Arg_info.mli index 895b7b7..a2516e7 100644 --- a/lib/Arg_info.mli +++ b/lib/Arg_info.mli @@ -20,90 +20,74 @@ open Ctypes +type t (** Arg_info represents an argument. An argument is always part of a Callable_info. *) -type t + val arginfo : t structure typ +val get_direction : t structure ptr -> Bindings.Arg_info.direction (** Obtain the direction of the argument. Check GIDirection for possible direction values.*) -val get_direction: - t structure ptr -> Bindings.Arg_info.direction +val get_closure : t structure ptr -> int (** Obtain the index of the user data argument. This is only valid for arguments which are callbacks. Returns index of the user data argument or -1 if there is none. *) -val get_closure: - t structure ptr -> int +val get_destroy : t structure ptr -> int (** Obtains the index of the GDestroyNotify argument. This is only valid for arguments which are callbacks. Returns index of the GDestroyNotify argument or -1 if there is none *) -val get_destroy: - t structure ptr -> int +val get_ownership_transfer : t structure ptr -> Bindings.Arg_info.transfer (** Obtain the ownership transfer for this argument. GITransfer contains a list of possible values. *) -val get_ownership_transfer: - t structure ptr -> Bindings.Arg_info.transfer +val may_be_null : t structure ptr -> bool (** Obtain if the type of the argument includes the possibility of NULL. For 'in' values this means that NULL is a valid value. For 'out' values, this means that NULL may be returned. See also Arg_info.is_optional. *) -val may_be_null: - t structure ptr -> bool +val is_caller_allocates : t structure ptr -> bool (** Obtain if the argument is a pointer to a struct or object that will receive an output of a function. The default assumption for Arg_info.Out arguments which have allocation is that the callee allocates; if this is TRUE, then the caller must allocate. *) -val is_caller_allocates: - t structure ptr -> bool +val is_optional : t structure ptr -> bool (** Obtain if the argument is optional. For 'out' arguments this means that you can pass NULL in order to ignore the result. *) -val is_optional: - t structure ptr -> bool +val is_return_value : t structure ptr -> bool (** Obtain if the argument is a return value. It can either be a parameter or a return value. *) -val is_return_value: - t structure ptr -> bool +val is_skip : t structure ptr -> bool (** Obtain if an argument is only useful in C. *) -val is_skip: - t structure ptr -> bool - -val get_scope: - t structure ptr -> Bindings.Arg_info.scope_type -val get_type: - t structure ptr -> Type_info.t structure ptr +val get_scope : t structure ptr -> Bindings.Arg_info.scope_type +val get_type : t structure ptr -> Type_info.t structure ptr (* TODO : void g_arg_info_load_type () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to arg info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes arg info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Arg_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Arg_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Base_info.ml b/lib/Base_info.ml index d177c54..4a3db14 100644 --- a/lib/Base_info.ml +++ b/lib/Base_info.ml @@ -21,6 +21,7 @@ open Foreign open Stubs type t + let baseinfo : t structure typ = structure "Base_info" let base_info_ref = @@ -46,35 +47,34 @@ let get_type = (ptr baseinfo @-> returning Stubs.Base_info.info_type) let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - base_info_unref i - ) info in + let _ = Gc.finalise (fun i -> base_info_unref i) info in info let get_container info = let get_container_raw = - foreign "g_base_info_get_container" - (ptr baseinfo @-> returning (ptr_opt baseinfo)) in + foreign "g_base_info_get_container" + (ptr baseinfo @-> returning (ptr_opt baseinfo)) + in match get_container_raw info with | None -> None | Some container_info -> Some (add_unref_finaliser container_info) (** GIRealInfo private struct only used to check ref_count and memory leaks *) (* type realinfo -let realinfo : realinfo structure typ = structure "GIRealInfo" -let girealinfo_type = field realinfo "type" (int32_t) -let girealinfo_ref_count = field realinfo "ref_count" (int) -let () = seal realinfo + let realinfo : realinfo structure typ = structure "GIRealInfo" + let girealinfo_type = field realinfo "type" (int32_t) + let girealinfo_ref_count = field realinfo "ref_count" (int) + let () = seal realinfo -let realinfo_of_baseinfo info = - coerce (ptr baseinfo) (ptr realinfo) info + let realinfo_of_baseinfo info = + coerce (ptr baseinfo) (ptr realinfo) info -let get_ref_count info = - let realinfo = realinfo_of_baseinfo info in - getf (!@realinfo) girealinfo_ref_count + let get_ref_count info = + let realinfo = realinfo_of_baseinfo info in + getf (!@realinfo) girealinfo_ref_count -let ref_count_file = (Sys.getcwd ()) ^ "/ref_count.log" - *) + let ref_count_file = (Sys.getcwd ()) ^ "/ref_count.log" +*) (* http://stackoverflow.com/questions/8090490/how-to-implement-appendfile-function *) (* let write_ref_count_log message = diff --git a/lib/Base_info.mli b/lib/Base_info.mli index 1c6f491..4a9d43d 100644 --- a/lib/Base_info.mli +++ b/lib/Base_info.mli @@ -16,55 +16,49 @@ * along with OCaml-GObject-Introspection. If not, see . *) -(** Base_info — Base struct for all GITypelib structs *) open Ctypes +(** Base_info — Base struct for all GITypelib structs *) + open Stubs +type t (** Base_info is the common base struct of all other *Info structs accessible through the Repository API. All other structs can be casted to a Base_info *) -type t + val baseinfo : t structure typ +val base_info_ref : t structure ptr -> t structure ptr (** Increases the reference count of underlying Base_info *info. *) -val base_info_ref: - t structure ptr -> t structure ptr +val base_info_unref : t structure ptr -> unit (** Decreases the reference count of underlying Base_info *info . When its reference count drops to 0, the info is freed. *) -val base_info_unref: - t structure ptr -> unit +val get_name : t structure ptr -> string option (** Obtain the name of the info . What the name represents depends on the GIInfoType of the info . For instance for Function_info it is the name of the function.*) -val get_name: - t structure ptr -> string option +val equal : t structure ptr -> t structure ptr -> bool (** Compare two Base_info. Using pointer comparison is not practical since many functions return different instances of Base_info that refers to the same part of the TypeLib; use this function instead to do Base_info comparisons. *) -val equal: - t structure ptr -> t structure ptr -> bool +val get_namespace : t structure ptr -> string (** Obtain the namespace of info *) -val get_namespace: - t structure ptr -> string +val is_deprecated : t structure ptr -> bool (** Obtain whether the info is represents a metadata which is deprecated or not. *) -val is_deprecated: - t structure ptr -> bool +val get_container : t structure ptr -> t structure ptr option (** Obtain the container of the info . The container is the parent Base_info. For instance, the parent of a Function_info is an Object_info or Interface_info. *) -val get_container: - t structure ptr -> t structure ptr option +val get_type : t structure ptr -> Bindings.Base_info.info_type (** Obtain the info type of the Base_info. *) -val get_type: - t structure ptr -> Bindings.Base_info.info_type (* Base_info * g_info_new () TODO : GITypelib * g_base_info_get_typelib () @@ -72,5 +66,4 @@ val get_type: TODO : gboolean g_base_info_iterate_attributes () *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr diff --git a/lib/Callable_info.ml b/lib/Callable_info.ml index 65b6a9c..2dd5acc 100644 --- a/lib/Callable_info.ml +++ b/lib/Callable_info.ml @@ -22,6 +22,7 @@ open Ctypes open Foreign type t + let callableinfo : t structure typ = structure "Callable_info" let can_throw_gerror = @@ -29,31 +30,28 @@ let can_throw_gerror = (ptr callableinfo @-> returning bool) let get_n_args = - foreign "g_callable_info_get_n_args" - (ptr callableinfo @-> returning int) + foreign "g_callable_info_get_n_args" (ptr callableinfo @-> returning int) let get_return_attribute = foreign "g_callable_info_get_return_attribute" (ptr callableinfo @-> returning string_opt) let is_method = - foreign "g_callable_info_is_method" - (ptr callableinfo @-> returning bool) + foreign "g_callable_info_is_method" (ptr callableinfo @-> returning bool) let may_return_null = - foreign "g_callable_info_may_return_null" - (ptr callableinfo @-> returning bool) + foreign "g_callable_info_may_return_null" (ptr callableinfo @-> returning bool) let skip_return = - foreign "g_callable_info_skip_return" - (ptr callableinfo @-> returning bool) + foreign "g_callable_info_skip_return" (ptr callableinfo @-> returning bool) let get_arg info n = let get_arg_raw = foreign "g_callable_info_get_arg" (ptr callableinfo @-> int @-> returning (ptr Arg_info.arginfo)) - in let max = get_n_args info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") + in + let max = get_n_args info in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") else let info' = get_arg_raw info n in Arg_info.add_unref_finaliser info' @@ -62,7 +60,8 @@ let get_return_type info = let get_return_type_raw = foreign "g_callable_info_get_return_type" (ptr callableinfo @-> returning (ptr Type_info.typeinfo)) - in let info' = get_return_type_raw info in + in + let info' = get_return_type_raw info in Type_info.add_unref_finaliser info' let get_caller_owns = @@ -76,10 +75,14 @@ let cast_to_baseinfo info = coerce (ptr callableinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -89,6 +92,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Callable_info.mli b/lib/Callable_info.mli index fe5ec55..6a7fb38 100644 --- a/lib/Callable_info.mli +++ b/lib/Callable_info.mli @@ -20,55 +20,47 @@ open Ctypes +type t (** Callable_info represents an entity which is callable. Currently a function (Function_info), virtual function, (VFunc_info) or callback (GICallbackInfo). A callable has a list of arguments (Arg_info), a return type, direction and a flag which decides if it returns null*) -type t -val callableinfo: t structure typ +val callableinfo : t structure typ + +val can_throw_gerror : t structure ptr -> bool (** Does the function throws an error. *) -val can_throw_gerror: - t structure ptr -> bool +val get_n_args : t structure ptr -> int (** Obtain the number of arguments (both IN and OUT) for this callable. *) -val get_n_args: - t structure ptr -> int +val get_return_attribute : t structure ptr -> string option (** Retrieve an arbitrary attribute associated with the return value. *) -val get_return_attribute: - t structure ptr -> string option +val is_method : t structure ptr -> bool (** Determines if the callable info is a method. For VFunc_infos, GICallbackInfos, and Signal_infos, this is always true. Otherwise, this looks at the Function_info.Is_method flag on the Function_info. Concretely, this function returns whether Callable_info.get_n_args matches the number of arguments in the raw C method. For methods, there is one more C argument than is exposed by introspection: the "self" or "this" object. *) -val is_method: - t structure ptr -> bool +val may_return_null : t structure ptr -> bool (** See if a callable could return NULL.*) -val may_return_null: - t structure ptr -> bool +val skip_return : t structure ptr -> bool (** See if a callable's return value is only useful in C. *) -val skip_return: - t structure ptr -> bool +val get_arg : t structure ptr -> int -> Arg_info.t structure ptr (** Obtain information about a particular argument of this callable. *) -val get_arg: - t structure ptr -> int -> Arg_info.t structure ptr +val get_return_type : t structure ptr -> Type_info.t structure ptr (** Obtain the return type of a callable item as a Type_info. *) -val get_return_type: - t structure ptr -> Type_info.t structure ptr +val get_caller_owns : t structure ptr -> Bindings.Arg_info.transfer (** See whether the caller owns the return value of this callable. GITransfer contains a list of possible transfer values. *) -val get_caller_owns: - t structure ptr -> Bindings.Arg_info.transfer (* gboolean g_callable_info_invoke () @@ -77,26 +69,21 @@ val get_caller_owns: void g_callable_info_load_return_type () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to callable info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes callable info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Constant_info.ml b/lib/Constant_info.ml index 9491d18..6395352 100644 --- a/lib/Constant_info.ml +++ b/lib/Constant_info.ml @@ -20,12 +20,14 @@ open Ctypes open Foreign type t -let constantinfo: t structure typ = structure "Constant_info" + +let constantinfo : t structure typ = structure "Constant_info" let get_type info = let get_type_raw = foreign "g_constant_info_get_type" - (ptr constantinfo @-> returning (ptr Type_info.typeinfo)) in + (ptr constantinfo @-> returning (ptr Type_info.typeinfo)) + in let info' = get_type_raw info in Type_info.add_unref_finaliser info' @@ -37,24 +39,31 @@ let cast_to_baseinfo info = coerce (ptr constantinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in info let from_baseinfo info = let _ = Base_info.base_info_ref info in let info' = cast_from_baseinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' let info_free_value = @@ -64,9 +73,9 @@ let info_free_value = let get_value info = let get_value_raw = foreign "g_constant_info_get_value" - (ptr constantinfo @-> ptr Types.argument @-> returning int) in + (ptr constantinfo @-> ptr Types.argument @-> returning int) + in let arg_ptr = allocate_n Types.argument ~count:1 in let _ = get_value_raw info arg_ptr in - let _ = Gc.finalise (fun v -> - info_free_value info v) arg_ptr in + let _ = Gc.finalise (fun v -> info_free_value info v) arg_ptr in arg_ptr diff --git a/lib/Constant_info.mli b/lib/Constant_info.mli index b89c224..4f0807f 100644 --- a/lib/Constant_info.mli +++ b/lib/Constant_info.mli @@ -20,43 +20,37 @@ open Ctypes +type t (** Constant_info represents a constant. A constant has a type associated which can be obtained by calling Constant_info.get_type and a value, which can be obtained by calling GIConstant.get_value. *) -type t + val constantinfo : t structure typ +val get_type : t structure ptr -> Type_info.t structure ptr (** Obtain the type of the constant as a Type_info. *) -val get_type: - t structure ptr -> Type_info.t structure ptr +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to constant info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes constant info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Constant_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Constant_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val get_value : t structure ptr -> Types.argument_t union ptr (** Obtain the value associated with the Constant_info and store it in the value parameter. argument needs to be allocated before passing it in. The size of the constant value stored in argument will be returned. Free the value with Constant_info.free_value. *) -val get_value: - t structure ptr -> Types.argument_t union ptr diff --git a/lib/Conversions.ml b/lib/Conversions.ml index 0385a29..bf5b2bc 100644 --- a/lib/Conversions.ml +++ b/lib/Conversions.ml @@ -3,8 +3,9 @@ open Ctypes open Foreign -(** C pointer of null terminated array of C strings *) type carray_of_strings = char ptr ptr +(** C pointer of null terminated array of C strings *) + let carray_of_strings : carray_of_strings typ = ptr (ptr char) (** Converts C array of strings to OCaml list of strings *) @@ -13,76 +14,73 @@ let carray_of_strings_to_list : char ptr ptr -> string list = match coerce (ptr char) string_opt !@p with | None -> List.rev acc | Some s -> loop (s :: acc) (p +@ 1) -in loop [] + in + loop [] +external carray_of_strings_to_array : carray_of_strings -> string array + = "caml_copy_string_array" (** Converts C array of strings to OCaml array of strings *) -external carray_of_strings_to_array : carray_of_strings -> string array = - "caml_copy_string_array" -(** GList struct *) type glist +(** GList struct *) + let glist : glist structure typ = structure "GList" -let glist_data = field glist "data" (ptr void) -let glist_next = field glist "next" (ptr_opt glist) -let glist_prev = field glist "prev" (ptr_opt glist) +let glist_data = field glist "data" (ptr void) +let glist_next = field glist "next" (ptr_opt glist) +let glist_prev = field glist "prev" (ptr_opt glist) let () = seal glist - -let g_free = - foreign "g_free" - (ptr void @-> returning void) - +let g_free = foreign "g_free" (ptr void @-> returning void) let g_free_t = ptr void @-> returning void let glist_free_full = - foreign "g_list_free_full" - (ptr glist @-> funptr g_free_t @-> returning void) + foreign "g_list_free_full" (ptr glist @-> funptr g_free_t @-> returning void) (** Get the next element of a glist *) -let g_list_next l_ptr = - getf (!@l_ptr) glist_next +let g_list_next l_ptr = getf !@l_ptr glist_next (** Get the void ptr data of the current element *) -let g_list_data l_ptr = - getf (!@l_ptr) glist_data +let g_list_data l_ptr = getf !@l_ptr glist_data (** Transform a GList of strings to an OCaml list of strings *) let glist_of_strings_to_list glist_ptr = let rec loop acc p = match p with | None -> List.rev acc - | Some p' -> let data = g_list_data p' in - let next = g_list_next p' in - match coerce (ptr void) string_opt data with - | None -> loop acc next - | Some s -> loop (s :: acc) next + | Some p' -> ( + let data = g_list_data p' in + let next = g_list_next p' in + match coerce (ptr void) string_opt data with + | None -> loop acc next + | Some s -> loop (s :: acc) next) in let ocaml_list = loop [] (Some glist_ptr) in let _ = glist_free_full glist_ptr g_free in ocaml_list -(** GSList struct *) type gslist +(** GSList struct *) + let gslist : gslist structure typ = structure "GSList" -let gslist_data = field gslist "data" (ptr void) -let gslist_next = field gslist "next" (ptr_opt gslist) +let gslist_data = field gslist "data" (ptr void) +let gslist_next = field gslist "next" (ptr_opt gslist) let () = seal gslist (** Get the next element of a gslist *) -let g_slist_next l_ptr = - getf (!@l_ptr) gslist_next +let g_slist_next l_ptr = getf !@l_ptr gslist_next (** Get the void ptr data of the current element *) -let g_slist_data l_ptr = - getf (!@l_ptr) gslist_data +let g_slist_data l_ptr = getf !@l_ptr gslist_data (** Transform a GSList of strings to an OCaml list of strings *) let gslist_of_strings_to_list gslist_ptr = let rec loop acc p = match p with | None -> List.rev acc - | Some p' -> let data = g_slist_data p' in - let next = g_slist_next p' in - match coerce (ptr void) string_opt data with - | None -> loop acc next - | Some s -> loop (s :: acc) next - in loop [] (Some gslist_ptr) + | Some p' -> ( + let data = g_slist_data p' in + let next = g_slist_next p' in + match coerce (ptr void) string_opt data with + | None -> loop acc next + | Some s -> loop (s :: acc) next) + in + loop [] (Some gslist_ptr) diff --git a/lib/Enum_info.ml b/lib/Enum_info.ml index 194f8b1..73c46f7 100644 --- a/lib/Enum_info.ml +++ b/lib/Enum_info.ml @@ -20,63 +20,67 @@ open Ctypes open Foreign type t + let enuminfo : t structure typ = structure "Union_info" let get_n_values = - foreign "g_enum_info_get_n_values" - (ptr enuminfo @-> returning int) + foreign "g_enum_info_get_n_values" (ptr enuminfo @-> returning int) let get_n_methods = - foreign "g_enum_info_get_n_methods" - (ptr enuminfo @-> returning int) + foreign "g_enum_info_get_n_methods" (ptr enuminfo @-> returning int) let get_method info n = let get_method_raw = foreign "g_enum_info_get_method" - (ptr enuminfo @-> int @-> returning (ptr Function_info.functioninfo)) in + (ptr enuminfo @-> int @-> returning (ptr Function_info.functioninfo)) + in let max = get_n_methods info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_method_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_method_raw info n in Function_info.add_unref_finaliser info' let get_value info n = let get_value_raw = foreign "g_enum_info_get_value" - (ptr enuminfo @-> int @-> returning (ptr_opt Value_info.valueinfo)) in + (ptr enuminfo @-> int @-> returning (ptr_opt Value_info.valueinfo)) + in let max = get_n_values info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else match get_value_raw info n with + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + match get_value_raw info n with | None -> None | Some info' -> Some (Value_info.add_unref_finaliser info') let get_error_domain = - foreign "g_enum_info_get_error_domain" - (ptr enuminfo @-> returning string_opt) + foreign "g_enum_info_get_error_domain" (ptr enuminfo @-> returning string_opt) let get_storage_type = - foreign "g_enum_info_get_storage_type" - (ptr enuminfo @-> returning Stubs.Types.tag) + foreign "g_enum_info_get_storage_type" + (ptr enuminfo @-> returning Stubs.Types.tag) (* TODO : check that the info can be casted to a enuminfo ? *) let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr enuminfo) info -let cast_to_baseinfo info = - coerce (ptr enuminfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr enuminfo) (ptr Base_info.baseinfo) info let from_baseinfo info = let _ = Base_info.base_info_ref info in let info' = cast_from_baseinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' (* TODO : check that the info can be casted to a enuminfo ? *) @@ -90,16 +94,24 @@ let from_registeredtypeinfo info = let base_info = Registered_type_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_from_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_registeredtypeinfo info = let base_info = cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_to_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = Registered_type_info.cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = Registered_type_info.cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' diff --git a/lib/Enum_info.mli b/lib/Enum_info.mli index 9639545..0acce22 100644 --- a/lib/Enum_info.mli +++ b/lib/Enum_info.mli @@ -20,78 +20,69 @@ open Ctypes +type t (** A Enum_info represents an enumeration and a Value_info struct represents a value of an enumeration. The Enum_info contains a set of values and a type The Value_info is fetched by calling Enum_info.get_value on a Enum_info.*) -type t + val enuminfo : t structure typ +val get_n_values : t structure ptr -> int (** Obtain the number of values this enumeration contains. *) -val get_n_values: - t structure ptr -> int +val get_n_methods : t structure ptr -> int (** Obtain the number of methods that this enum type has. *) -val get_n_methods: - t structure ptr -> int +val get_method : t structure ptr -> int -> Function_info.t structure ptr (** Obtain an enum type method at index n . *) -val get_method: - t structure ptr -> int -> Function_info.t structure ptr +val get_value : t structure ptr -> int -> Value_info.t structure ptr option (** Obtain a value for this enumeration. *) -val get_value: - t structure ptr -> int -> Value_info.t structure ptr option +val get_error_domain : t structure ptr -> string option (** Obtain the string form of the quark for the error domain associated with this enum, if any. *) -val get_error_domain: - t structure ptr -> string option +val get_storage_type : t structure ptr -> Bindings.Types.tag (** Obtain the tag of the type used for the enum in the C ABI. This will be a signed or unsigned integral type. Note that in the current implementation the width of the type is computed correctly, but the signed or unsigned nature of the type may not match the sign of the type used by the C compiler. *) -val get_storage_type: - t structure ptr -> Bindings.Types.tag +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to enum info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes enum info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Enum_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr -(** Just cast OCaml Ctypes registeredtype info to enum info. *) -val cast_from_registeredtypeinfo: +val cast_from_registeredtypeinfo : Registered_type_info.t structure ptr -> t structure ptr +(** Just cast OCaml Ctypes registeredtype info to enum info. *) -(** Just cast OCaml Ctypes enum info to registeredtype info *) -val cast_to_registeredtypeinfo: +val cast_to_registeredtypeinfo : t structure ptr -> Registered_type_info.t structure ptr +(** Just cast OCaml Ctypes enum info to registeredtype info *) +val from_registeredtypeinfo : + Registered_type_info.t structure ptr -> t structure ptr (** Return a Enum_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val from_registeredtypeinfo: - Registered_type_info.t structure ptr -> t structure ptr +val to_registeredtypeinfo : + t structure ptr -> Registered_type_info.t structure ptr (** Return a Registered_type_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val to_registeredtypeinfo: - t structure ptr -> Registered_type_info.t structure ptr diff --git a/lib/Field_info.ml b/lib/Field_info.ml index f54f7ff..3e9411b 100644 --- a/lib/Field_info.ml +++ b/lib/Field_info.ml @@ -20,46 +20,49 @@ open Ctypes open Foreign type t + let fieldinfo : t structure typ = structure "Field_info" -let all_flags : (int64 * Bindings.Field_info.flags) list= [ - Stubs.Field_info.gi_field_is_readable, Is_readable; - Stubs.Field_info.gi_field_is_writable, Is_writable; +let all_flags : (int64 * Bindings.Field_info.flags) list = + [ + (Stubs.Field_info.gi_field_is_readable, Is_readable); + (Stubs.Field_info.gi_field_is_writable, Is_writable); ] -let flags_list = Utils.generate_flags_list_view Stubs.Function_info.flags all_flags +let flags_list = + Utils.generate_flags_list_view Stubs.Function_info.flags all_flags let get_flags = - foreign "g_field_info_get_flags" - (ptr fieldinfo @-> returning flags_list) + foreign "g_field_info_get_flags" (ptr fieldinfo @-> returning flags_list) let get_offset = - foreign "g_field_info_get_offset" - (ptr fieldinfo @-> returning int) + foreign "g_field_info_get_offset" (ptr fieldinfo @-> returning int) -let get_size = - foreign "g_field_info_get_size" - (ptr fieldinfo @-> returning int) +let get_size = foreign "g_field_info_get_size" (ptr fieldinfo @-> returning int) let get_type info = let get_type_raw = foreign "g_field_info_get_type" (ptr fieldinfo @-> returning (ptr Type_info.typeinfo)) - in let info' = get_type_raw info in + in + let info' = get_type_raw info in Type_info.add_unref_finaliser info' (* TODO : check that the info can be casted to field info ? *) let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr fieldinfo) info -let cast_to_baseinfo info = - coerce (ptr fieldinfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr fieldinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -69,6 +72,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Field_info.mli b/lib/Field_info.mli index 5c478e3..e9c2d59 100644 --- a/lib/Field_info.mli +++ b/lib/Field_info.mli @@ -20,6 +20,7 @@ open Ctypes +type t (** A Field_info struct represents a field of a struct (see Struct_info), union (see Union_info) or an object (see Object_info). The Field_info is fetched by calling @@ -28,53 +29,44 @@ open Ctypes or Object_info.get_field. A field has a size, type and a struct offset asssociated and a set of flags, which is currently GI_FIELD_IS_READABLE or GI_FIELD_IS_WRITABLE.*) -type t + val fieldinfo : t structure typ +val get_flags : t structure ptr -> Bindings.Field_info.flags list (** Obtain the flags for this Field_info. See Field_info.flags for possible flag values. *) -val get_flags: - t structure ptr -> Bindings.Field_info.flags list +val get_offset : t structure ptr -> int (** Obtain the offset in bits of the field member, this is relative to the beginning of the struct or union. *) -val get_offset: - t structure ptr -> int +val get_size : t structure ptr -> int (** Obtain the size in bits of the field member, this is how much space you need to allocate to store the field. *) -val get_size: - t structure ptr -> int +val get_type : t structure ptr -> Type_info.t structure ptr (** Obtain the type of a field as a Type_info. *) -val get_type: - t structure ptr -> Type_info.t structure ptr (* gboolean g_field_info_get_field () gboolean g_field_info_set_field () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to field info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes field info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Field_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Field_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Function_info.ml b/lib/Function_info.ml index c93f38f..7304bf6 100644 --- a/lib/Function_info.ml +++ b/lib/Function_info.ml @@ -20,60 +20,68 @@ open Ctypes open Foreign type t + let functioninfo : t structure typ = structure "Function_info" let get_symbol = - foreign "g_function_info_get_symbol" - (ptr functioninfo @-> returning string) - -let all_flags : (int64 * Bindings.Function_info.flags) list= [ - Stubs.Function_info.gi_function_is_method, Is_method; - Stubs.Function_info.gi_function_is_constructor, Is_constructor; - Stubs.Function_info.gi_function_is_getter, Is_getter; - Stubs.Function_info.gi_function_is_setter, Is_setter; - Stubs.Function_info.gi_function_wraps_vfunc, Wraps_vfunc; - Stubs.Function_info.gi_function_throws, Throws; + foreign "g_function_info_get_symbol" (ptr functioninfo @-> returning string) + +let all_flags : (int64 * Bindings.Function_info.flags) list = + [ + (Stubs.Function_info.gi_function_is_method, Is_method); + (Stubs.Function_info.gi_function_is_constructor, Is_constructor); + (Stubs.Function_info.gi_function_is_getter, Is_getter); + (Stubs.Function_info.gi_function_is_setter, Is_setter); + (Stubs.Function_info.gi_function_wraps_vfunc, Wraps_vfunc); + (Stubs.Function_info.gi_function_throws, Throws); ] -let flags_list = Utils.generate_flags_list_view Stubs.Function_info.flags all_flags +let flags_list = + Utils.generate_flags_list_view Stubs.Function_info.flags all_flags let get_flags = - foreign "g_function_info_get_flags" - (ptr functioninfo @-> returning flags_list) + foreign "g_function_info_get_flags" (ptr functioninfo @-> returning flags_list) let get_property info = let flags = get_flags info in let rec find_set_get = function | [] -> false - | h :: q -> match h with - | Bindings.Function_info.Is_setter | Bindings.Function_info.Is_getter -> true - | _ -> find_set_get q - in if (find_set_get flags) then ( + | h :: q -> ( + match h with + | Bindings.Function_info.Is_setter | Bindings.Function_info.Is_getter -> + true + | _ -> find_set_get q) + in + if find_set_get flags then let get_property_raw = foreign "g_function_info_get_property" - (ptr functioninfo @-> returning (ptr_opt Property_info.propertyinfo)) in + (ptr functioninfo @-> returning (ptr_opt Property_info.propertyinfo)) + in match get_property_raw info with | None -> None - | Some info' -> let info'' = Property_info.add_unref_finaliser info' in - Some info'' - ) + | Some info' -> + let info'' = Property_info.add_unref_finaliser info' in + Some info'' else None let get_vfunc info = let flags = get_flags info in let rec has_wraps_vfunc = function | [] -> false - | h :: q -> if h == Bindings.Function_info.Wraps_vfunc then true - else has_wraps_vfunc q + | h :: q -> + if h == Bindings.Function_info.Wraps_vfunc then true + else has_wraps_vfunc q in - if (has_wraps_vfunc flags) then + if has_wraps_vfunc flags then let get_vfunc_raw = foreign "g_function_info_get_vfunc" - (ptr functioninfo @-> returning (ptr_opt Callable_info.callableinfo)) in + (ptr functioninfo @-> returning (ptr_opt Callable_info.callableinfo)) + in match get_vfunc_raw info with | None -> None - | Some info' -> let info'' = Callable_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Callable_info.add_unref_finaliser info' in + Some info'' else None (* TODO : check that the info can be casted to function info ? *) @@ -84,10 +92,14 @@ let cast_to_baseinfo info = coerce (ptr functioninfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -97,8 +109,7 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' let cast_from_callableinfo info = @@ -117,7 +128,11 @@ let from_callableinfo info = let info' = Callable_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in let info'' = cast_from_callableinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info'' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info'' + in info'' diff --git a/lib/Function_info.mli b/lib/Function_info.mli index e2822a5..b054da1 100644 --- a/lib/Function_info.mli +++ b/lib/Function_info.mli @@ -20,83 +20,71 @@ open Ctypes +type t (** Function_info represents a function, method or constructor. To find out what kind of entity a Function_info represents, call Function_info.get_flags. See also Callable_info for information on how to retreive arguments and other metadata. *) -type t + val functioninfo : t structure typ +val get_symbol : t structure ptr -> string (** Obtain the symbol of the function. The symbol is the name of the exported function, suitable to be used as an argument to g_module_symbol().*) -val get_symbol: - t structure ptr -> string +val get_flags : t structure ptr -> Bindings.Function_info.flags list (** Obtain the Function_infoFlags for the info . *) -val get_flags: - t structure ptr -> Bindings.Function_info.flags list +val get_property : t structure ptr -> Property_info.t structure ptr option (** Obtain the property associated with this Function_info. Only Function_info with the flag GIFunction.Is_getter or GIFunction.Is_setter have a property set. For other cases, NULL will be returned. *) -val get_property: - t structure ptr -> Property_info.t structure ptr option +val get_vfunc : t structure ptr -> Callable_info.t structure ptr option (** Obtain the virtual function associated with this Function_info. Only Function_info with the flag Wraps_vfunc has a virtual function set. For other cases, None will be returned. In order to avoid circular call graph between Function_info and VFunc_info, this function will return a Callable_info. It is upto the user to use VFunc_info.from_callableinfo in order to have the VFunc_info.*) -val get_vfunc: - t structure ptr -> Callable_info.t structure ptr option (* gboolean g_function_info_invoke () GQuark g_invoke_error_quark () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to function info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes function info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val cast_from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes callable info to function info. *) -val cast_from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val cast_to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Just cast OCaml Ctypes function info to callable info *) -val cast_to_callableinfo: - t structure ptr -> Callable_info.t structure ptr +val from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Return a Function_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Return a Callable_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_callableinfo: - t structure ptr -> Callable_info.t structure ptr diff --git a/lib/GParam.ml b/lib/GParam.ml index a861d62..0a640aa 100644 --- a/lib/GParam.ml +++ b/lib/GParam.ml @@ -19,18 +19,19 @@ open Ctypes open Foreign -let all_flags : (int64 * Bindings.GParam.flags) list= [ - Stubs.GParam.g_param_readable, Bindings.GParam.Readable; - Stubs.GParam.g_param_writable, Bindings.GParam.Writable; - Stubs.GParam.g_param_readwrite, Bindings.GParam.Readwrite; - Stubs.GParam.g_param_construct, Bindings.GParam.Construct; - Stubs.GParam.g_param_construct_only, Bindings.GParam.Construct_only; - Stubs.GParam.g_param_lax_validation, Bindings.GParam.Lax_validation; - Stubs.GParam.g_param_static_name, Bindings.GParam.Static_name; - Stubs.GParam.g_param_static_nick, Bindings.GParam.Static_nick; - Stubs.GParam.g_param_static_blurb, Bindings.GParam.Static_blurb; - Stubs.GParam.g_param_explicit_notify, Bindings.GParam.Explicit_notify; - Stubs.GParam.g_param_deprecated, Bindings.GParam.Deprecated; +let all_flags : (int64 * Bindings.GParam.flags) list = + [ + (Stubs.GParam.g_param_readable, Bindings.GParam.Readable); + (Stubs.GParam.g_param_writable, Bindings.GParam.Writable); + (Stubs.GParam.g_param_readwrite, Bindings.GParam.Readwrite); + (Stubs.GParam.g_param_construct, Bindings.GParam.Construct); + (Stubs.GParam.g_param_construct_only, Bindings.GParam.Construct_only); + (Stubs.GParam.g_param_lax_validation, Bindings.GParam.Lax_validation); + (Stubs.GParam.g_param_static_name, Bindings.GParam.Static_name); + (Stubs.GParam.g_param_static_nick, Bindings.GParam.Static_nick); + (Stubs.GParam.g_param_static_blurb, Bindings.GParam.Static_blurb); + (Stubs.GParam.g_param_explicit_notify, Bindings.GParam.Explicit_notify); + (Stubs.GParam.g_param_deprecated, Bindings.GParam.Deprecated); ] let flags_list = Utils.generate_flags_list_view Stubs.GParam.flags all_flags @@ -47,4 +48,3 @@ let flag_to_string = function | Bindings.GParam.Static_blurb -> "Static_blurb" | Bindings.GParam.Explicit_notify -> "Explicit_notify" | Bindings.GParam.Deprecated -> "Deprecated" - diff --git a/lib/GSignal.ml b/lib/GSignal.ml index 4484cc4..8e2c9ea 100644 --- a/lib/GSignal.ml +++ b/lib/GSignal.ml @@ -19,16 +19,17 @@ open Ctypes open Foreign -let all_flags : (int64 * Bindings.GSignal.flags) list= [ - Stubs.GSignal.g_signal_run_first, Bindings.GSignal.Run_first; - Stubs.GSignal.g_signal_run_last, Bindings.GSignal.Run_last; - Stubs.GSignal.g_signal_run_cleanup, Bindings.GSignal.Run_cleanup; - Stubs.GSignal.g_signal_no_recurse, Bindings.GSignal.No_recurse; - Stubs.GSignal.g_signal_detailed, Bindings.GSignal.Detailed; - Stubs.GSignal.g_signal_action, Bindings.GSignal.Action; - Stubs.GSignal.g_signal_no_hooks, Bindings.GSignal.No_hooks; - Stubs.GSignal.g_signal_must_collect, Bindings.GSignal.Must_collect; - Stubs.GSignal.g_signal_deprecated, Bindings.GSignal.Deprecated; +let all_flags : (int64 * Bindings.GSignal.flags) list = + [ + (Stubs.GSignal.g_signal_run_first, Bindings.GSignal.Run_first); + (Stubs.GSignal.g_signal_run_last, Bindings.GSignal.Run_last); + (Stubs.GSignal.g_signal_run_cleanup, Bindings.GSignal.Run_cleanup); + (Stubs.GSignal.g_signal_no_recurse, Bindings.GSignal.No_recurse); + (Stubs.GSignal.g_signal_detailed, Bindings.GSignal.Detailed); + (Stubs.GSignal.g_signal_action, Bindings.GSignal.Action); + (Stubs.GSignal.g_signal_no_hooks, Bindings.GSignal.No_hooks); + (Stubs.GSignal.g_signal_must_collect, Bindings.GSignal.Must_collect); + (Stubs.GSignal.g_signal_deprecated, Bindings.GSignal.Deprecated); ] let flags_list = Utils.generate_flags_list_view Stubs.GSignal.flags all_flags diff --git a/lib/Interface_info.ml b/lib/Interface_info.ml index fa388c4..ae08926 100644 --- a/lib/Interface_info.ml +++ b/lib/Interface_info.ml @@ -20,6 +20,7 @@ open Ctypes open Foreign type t + let interfaceinfo : t structure typ = structure "Interface_info" let get_n_prerequisites = @@ -29,10 +30,12 @@ let get_n_prerequisites = let get_prerequisite info n = let get_prerequisite_raw = foreign "g_interface_info_get_prerequisite" - (ptr interfaceinfo @-> int @-> returning (ptr Base_info.baseinfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr Base_info.baseinfo)) + in let max = get_n_prerequisites info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_prerequisite_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_prerequisite_raw info n in Base_info.add_unref_finaliser info' let get_n_properties = @@ -42,55 +45,65 @@ let get_n_properties = let get_property info n = let get_property_raw = foreign "g_interface_info_get_property" - (ptr interfaceinfo @-> int @-> returning (ptr Property_info.propertyinfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr Property_info.propertyinfo)) + in let max = get_n_properties info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_property_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_property_raw info n in Property_info.add_unref_finaliser info' let get_n_methods = - foreign "g_interface_info_get_n_methods" - (ptr interfaceinfo @-> returning int) + foreign "g_interface_info_get_n_methods" (ptr interfaceinfo @-> returning int) let get_method info n = let get_method_raw = foreign "g_interface_info_get_method" - (ptr interfaceinfo @-> int @-> returning (ptr Function_info.functioninfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr Function_info.functioninfo)) + in let max = get_n_methods info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_method_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_method_raw info n in Function_info.add_unref_finaliser info' let find_method info name = let find_method_raw = foreign "g_interface_info_find_method" - (ptr interfaceinfo @-> string @-> returning (ptr_opt Function_info.functioninfo)) in + (ptr interfaceinfo @-> string + @-> returning (ptr_opt Function_info.functioninfo)) + in match find_method_raw info name with | None -> None - | Some info' -> let info'' = Function_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Function_info.add_unref_finaliser info' in + Some info'' let get_n_signals = - foreign "g_interface_info_get_n_signals" - (ptr interfaceinfo @-> returning int) + foreign "g_interface_info_get_n_signals" (ptr interfaceinfo @-> returning int) let get_signal info n = let get_signal_raw = foreign "g_interface_info_get_signal" - (ptr interfaceinfo @-> int @-> returning (ptr Signal_info.signalinfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr Signal_info.signalinfo)) + in let max = get_n_signals info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_signal_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_signal_raw info n in Signal_info.add_unref_finaliser info' let find_signal info name = let find_signal_raw = foreign "g_interface_info_find_signal" - (ptr interfaceinfo @-> string @-> returning (ptr_opt Signal_info.signalinfo)) in + (ptr interfaceinfo @-> string + @-> returning (ptr_opt Signal_info.signalinfo)) + in match find_signal_raw info name with | None -> None - | Some info' -> let info'' = Signal_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Signal_info.add_unref_finaliser info' in + Some info'' let get_n_constants = foreign "g_interface_info_get_n_constants" @@ -100,42 +113,49 @@ let get_n_constants = let get_constant info n = let get_constant_raw = foreign "g_interface_info_get_constant" - (ptr interfaceinfo @-> int @-> returning (ptr Constant_info.constantinfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr Constant_info.constantinfo)) + in let max = get_n_constants info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_constant_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_constant_raw info n in Constant_info.add_unref_finaliser info' let get_iface_struct info = let get_iface_struct_raw = foreign "g_interface_info_get_iface_struct" - (ptr interfaceinfo @-> returning (ptr_opt Struct_info.structinfo)) in + (ptr interfaceinfo @-> returning (ptr_opt Struct_info.structinfo)) + in match get_iface_struct_raw info with | None -> None - | Some info' -> let info'' = Struct_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Struct_info.add_unref_finaliser info' in + Some info'' let get_n_vfuncs = - foreign "g_interface_info_get_n_vfuncs" - (ptr interfaceinfo @-> returning int) + foreign "g_interface_info_get_n_vfuncs" (ptr interfaceinfo @-> returning int) let get_vfunc info n = let get_vfunc_raw = foreign "g_interface_info_get_vfunc" - (ptr interfaceinfo @-> int @-> returning (ptr VFunc_info.vfuncinfo)) in + (ptr interfaceinfo @-> int @-> returning (ptr VFunc_info.vfuncinfo)) + in let max = get_n_vfuncs info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_vfunc_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_vfunc_raw info n in VFunc_info.add_unref_finaliser info' let find_vfunc info name = let find_vfunc_raw = foreign "g_interface_info_find_vfunc" - (ptr interfaceinfo @-> string @-> returning (ptr_opt VFunc_info.vfuncinfo)) in + (ptr interfaceinfo @-> string @-> returning (ptr_opt VFunc_info.vfuncinfo)) + in match find_vfunc_raw info name with | None -> None - | Some info' -> let info'' = VFunc_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = VFunc_info.add_unref_finaliser info' in + Some info'' (* TODO : check that the info can be casted to interface info ? *) let cast_from_baseinfo info = @@ -145,10 +165,14 @@ let cast_to_baseinfo info = coerce (ptr interfaceinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -158,8 +182,7 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' (* TODO : check that the info can be casted to a interfaceinfo ? *) @@ -173,16 +196,24 @@ let from_registeredtypeinfo info = let base_info = Registered_type_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_from_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_registeredtypeinfo info = let base_info = cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_to_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = Registered_type_info.cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = Registered_type_info.cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' diff --git a/lib/Interface_info.mli b/lib/Interface_info.mli index 810f7a4..da6654f 100644 --- a/lib/Interface_info.mli +++ b/lib/Interface_info.mli @@ -20,120 +20,102 @@ open Ctypes +type t (** Interface_info represents a GInterface type. A GInterface has methods, fields, properties, signals, interfaces, constants, virtual functions and prerequisites.*) -type t + val interfaceinfo : t structure typ +val get_n_prerequisites : t structure ptr -> int (** Obtain the number of prerequisites for this interface type. A prerequisites is another interface that needs to be implemented for interface, similar to an base class for GObjects. *) -val get_n_prerequisites: - t structure ptr -> int +val get_prerequisite : t structure ptr -> int -> Base_info.t structure ptr (** Obtain an interface type prerequisites index n . *) -val get_prerequisite: - t structure ptr -> int -> Base_info.t structure ptr +val get_n_properties : t structure ptr -> int (** Obtain the number of properties that this interface type has.*) -val get_n_properties: - t structure ptr -> int +val get_property : t structure ptr -> int -> Property_info.t structure ptr (** Obtain an interface type property at index n . *) -val get_property: - t structure ptr -> int -> Property_info.t structure ptr +val get_n_methods : t structure ptr -> int (** Obtain the number of methods that this interface type has. *) -val get_n_methods: - t structure ptr -> int +val get_method : t structure ptr -> int -> Function_info.t structure ptr (** Obtain an interface type method at index n . *) -val get_method: - t structure ptr -> int -> Function_info.t structure ptr +val find_method : + t structure ptr -> string -> Function_info.t structure ptr option (** Obtain a method of the interface type given a name . NULL will be returned if there's no method available with that name. *) -val find_method: - t structure ptr -> string -> Function_info.t structure ptr option +val get_n_signals : t structure ptr -> int (** Obtain the number of signals that this interface type has. *) -val get_n_signals: - t structure ptr -> int +val get_signal : t structure ptr -> int -> Signal_info.t structure ptr (** Obtain an interface type signal at index n . *) -val get_signal: - t structure ptr -> int -> Signal_info.t structure ptr -(** Find a signal of the interface *) -val find_signal: +val find_signal : t structure ptr -> string -> Signal_info.t structure ptr option +(** Find a signal of the interface *) +val get_n_constants : t structure ptr -> int (** Obtain the number of constants that this interface type has. *) -val get_n_constants: - t structure ptr -> int +val get_constant : t structure ptr -> int -> Constant_info.t structure ptr (** Obtain an interface type constant at index n . *) -val get_constant: - t structure ptr -> int -> Constant_info.t structure ptr +val get_iface_struct : t structure ptr -> Struct_info.t structure ptr option (** Returns the layout C structure associated with this GInterface. *) -val get_iface_struct: - t structure ptr -> Struct_info.t structure ptr option +val get_n_vfuncs : t structure ptr -> int (** Obtain the number of virtual functions that this interface type has. *) -val get_n_vfuncs: - t structure ptr -> int +val get_vfunc : t structure ptr -> int -> VFunc_info.t structure ptr (** Obtain an interface type virtual function at index n . *) -val get_vfunc: - t structure ptr -> int -> VFunc_info.t structure ptr +val find_vfunc : t structure ptr -> string -> VFunc_info.t structure ptr option (** Locate a virtual function slot with name name . See the documentation for g_object_info_find_vfunc() for more information on virtuals. *) -val find_vfunc: - t structure ptr -> string -> VFunc_info.t structure ptr option +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to interface info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes interface info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Interface_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr -(** Just cast OCaml Ctypes registeredtype info to enum info. *) -val cast_from_registeredtypeinfo: +val cast_from_registeredtypeinfo : Registered_type_info.t structure ptr -> t structure ptr +(** Just cast OCaml Ctypes registeredtype info to enum info. *) -(** Just cast OCaml Ctypes enum info to registeredtype info *) -val cast_to_registeredtypeinfo: +val cast_to_registeredtypeinfo : t structure ptr -> Registered_type_info.t structure ptr +(** Just cast OCaml Ctypes enum info to registeredtype info *) +val from_registeredtypeinfo : + Registered_type_info.t structure ptr -> t structure ptr (** Return a Interface_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val from_registeredtypeinfo: - Registered_type_info.t structure ptr -> t structure ptr +val to_registeredtypeinfo : + t structure ptr -> Registered_type_info.t structure ptr (** Return a Registered_type_info.t form a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val to_registeredtypeinfo: - t structure ptr -> Registered_type_info.t structure ptr diff --git a/lib/Object_info.ml b/lib/Object_info.ml index 7c61e45..d1cd24d 100644 --- a/lib/Object_info.ml +++ b/lib/Object_info.ml @@ -20,157 +20,171 @@ open Ctypes open Foreign type t + let objectinfo : t structure typ = structure "Object_info" let get_abstract = - foreign "g_object_info_get_abstract" - (ptr objectinfo @-> returning bool) + foreign "g_object_info_get_abstract" (ptr objectinfo @-> returning bool) let get_fundamental = - foreign "g_object_info_get_fundamental" - (ptr objectinfo @-> returning bool) + foreign "g_object_info_get_fundamental" (ptr objectinfo @-> returning bool) let get_parent info = let get_parent_raw = foreign "g_object_info_get_parent" - (ptr objectinfo @-> returning (ptr Base_info.baseinfo)) in + (ptr objectinfo @-> returning (ptr Base_info.baseinfo)) + in let info' = get_parent_raw info in Base_info.add_unref_finaliser info' let get_type_name = - foreign "g_object_info_get_type_name" - (ptr objectinfo @-> returning string) + foreign "g_object_info_get_type_name" (ptr objectinfo @-> returning string) let get_type_init = - foreign "g_object_info_get_type_init" - (ptr objectinfo @-> returning string) + foreign "g_object_info_get_type_init" (ptr objectinfo @-> returning string) let get_n_constants = - foreign "g_object_info_get_n_constants" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_constants" (ptr objectinfo @-> returning int) let get_constant info n = let get_constant_raw = foreign "g_object_info_get_constant" - (ptr objectinfo @-> int @-> returning (ptr Constant_info.constantinfo)) in + (ptr objectinfo @-> int @-> returning (ptr Constant_info.constantinfo)) + in let max = get_n_constants info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_constant_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_constant_raw info n in Constant_info.add_unref_finaliser info' let get_n_fields = - foreign "g_object_info_get_n_fields" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_fields" (ptr objectinfo @-> returning int) let get_field info n = let get_field_raw = foreign "g_object_info_get_field" - (ptr objectinfo @-> int @-> returning (ptr Field_info.fieldinfo)) in + (ptr objectinfo @-> int @-> returning (ptr Field_info.fieldinfo)) + in let max = get_n_fields info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_field_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_field_raw info n in Field_info.add_unref_finaliser info' let get_n_interfaces = - foreign "g_object_info_get_n_interfaces" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_interfaces" (ptr objectinfo @-> returning int) let get_interface info n = let get_interface_raw = foreign "g_object_info_get_interface" - (ptr objectinfo @-> int @-> returning (ptr Interface_info.interfaceinfo)) in + (ptr objectinfo @-> int @-> returning (ptr Interface_info.interfaceinfo)) + in let max = get_n_interfaces info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_interface_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_interface_raw info n in Interface_info.add_unref_finaliser info' let get_n_methods = - foreign "g_object_info_get_n_methods" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_methods" (ptr objectinfo @-> returning int) let get_method info n = let get_method_raw = foreign "g_object_info_get_method" - (ptr objectinfo @-> int @-> returning (ptr Function_info.functioninfo)) in + (ptr objectinfo @-> int @-> returning (ptr Function_info.functioninfo)) + in let max = get_n_methods info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_method_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_method_raw info n in Function_info.add_unref_finaliser info' let find_method info name = let find_method_raw = foreign "g_object_info_find_method" - (ptr objectinfo @-> string @-> returning (ptr_opt Function_info.functioninfo)) in + (ptr objectinfo @-> string + @-> returning (ptr_opt Function_info.functioninfo)) + in match find_method_raw info name with | None -> None - | Some info' -> let info'' = Function_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Function_info.add_unref_finaliser info' in + Some info'' let get_n_properties = - foreign "g_object_info_get_n_properties" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_properties" (ptr objectinfo @-> returning int) let get_property info n = let get_property_raw = foreign "g_object_info_get_property" - (ptr objectinfo @-> int @-> returning (ptr Property_info.propertyinfo)) in + (ptr objectinfo @-> int @-> returning (ptr Property_info.propertyinfo)) + in let max = get_n_properties info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_property_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_property_raw info n in Property_info.add_unref_finaliser info' let get_n_signals = - foreign "g_object_info_get_n_signals" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_signals" (ptr objectinfo @-> returning int) let get_signal info n = let get_signal_raw = foreign "g_object_info_get_signal" - (ptr objectinfo @-> int @-> returning (ptr Signal_info.signalinfo)) in + (ptr objectinfo @-> int @-> returning (ptr Signal_info.signalinfo)) + in let max = get_n_signals info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_signal_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_signal_raw info n in Signal_info.add_unref_finaliser info' let find_signal info name = let find_signal_raw = foreign "g_object_info_find_signal" - (ptr objectinfo @-> string @-> returning (ptr_opt Signal_info.signalinfo)) in + (ptr objectinfo @-> string @-> returning (ptr_opt Signal_info.signalinfo)) + in match find_signal_raw info name with | None -> None - | Some info' -> let info'' = Signal_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Signal_info.add_unref_finaliser info' in + Some info'' let get_n_vfuncs = - foreign "g_object_info_get_n_vfuncs" - (ptr objectinfo @-> returning int) + foreign "g_object_info_get_n_vfuncs" (ptr objectinfo @-> returning int) let get_vfunc info n = let get_vfunc_raw = foreign "g_object_info_get_vfunc" - (ptr objectinfo @-> int @-> returning (ptr VFunc_info.vfuncinfo)) in + (ptr objectinfo @-> int @-> returning (ptr VFunc_info.vfuncinfo)) + in let max = get_n_vfuncs info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_vfunc_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_vfunc_raw info n in VFunc_info.add_unref_finaliser info' let find_vfunc info name = let find_vfunc_raw = foreign "g_object_info_find_vfunc" - (ptr objectinfo @-> string @-> returning (ptr_opt VFunc_info.vfuncinfo)) in + (ptr objectinfo @-> string @-> returning (ptr_opt VFunc_info.vfuncinfo)) + in match find_vfunc_raw info name with | None -> None - | Some info' -> let info'' = VFunc_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = VFunc_info.add_unref_finaliser info' in + Some info'' let get_class_struct info = let get_class_struct_raw = foreign "g_object_info_get_class_struct" - (ptr objectinfo @-> returning (ptr_opt Struct_info.structinfo)) in + (ptr objectinfo @-> returning (ptr_opt Struct_info.structinfo)) + in match get_class_struct_raw info with | None -> None - | Some info' -> let info'' = Struct_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Struct_info.add_unref_finaliser info' in + Some info'' let get_ref_function = foreign "g_object_info_get_ref_function" @@ -196,10 +210,14 @@ let cast_to_baseinfo info = coerce (ptr objectinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -209,35 +227,44 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' let find_method_using_interfaces info name = let find_method_using_interfaces_raw = foreign "g_object_info_find_method_using_interfaces" - (ptr objectinfo @-> string @-> ptr (ptr objectinfo) @-> - returning (ptr_opt Function_info.functioninfo)) in + (ptr objectinfo @-> string + @-> ptr (ptr objectinfo) + @-> returning (ptr_opt Function_info.functioninfo)) + in let implementor_addr = allocate_n (ptr objectinfo) ~count:1 in match find_method_using_interfaces_raw info name implementor_addr with | None -> (None, None) - | Some info' -> (Some info', - match coerce (ptr objectinfo) (ptr_opt objectinfo) (!@implementor_addr) with - | None -> None - | Some implementor -> Some (add_unref_finaliser implementor)) + | Some info' -> + ( Some info', + match + coerce (ptr objectinfo) (ptr_opt objectinfo) !@implementor_addr + with + | None -> None + | Some implementor -> Some (add_unref_finaliser implementor) ) let find_vfunc_using_interfaces info name = let find_vfunc_using_interfaces_raw = foreign "g_object_info_find_vfunc_using_interfaces" - (ptr objectinfo @-> string @-> ptr (ptr objectinfo) @-> - returning (ptr_opt VFunc_info.vfuncinfo)) in + (ptr objectinfo @-> string + @-> ptr (ptr objectinfo) + @-> returning (ptr_opt VFunc_info.vfuncinfo)) + in let implementor_addr = allocate_n (ptr objectinfo) ~count:1 in match find_vfunc_using_interfaces_raw info name implementor_addr with | None -> (None, None) - | Some info' -> (Some info', - match coerce (ptr objectinfo) (ptr_opt objectinfo) (!@implementor_addr) with - | None -> None - | Some implementor -> Some (add_unref_finaliser implementor)) + | Some info' -> + ( Some info', + match + coerce (ptr objectinfo) (ptr_opt objectinfo) !@implementor_addr + with + | None -> None + | Some implementor -> Some (add_unref_finaliser implementor) ) (* TODO : check that the info can be casted to a objectinfo ? *) let cast_from_registeredtypeinfo info = @@ -250,16 +277,24 @@ let from_registeredtypeinfo info = let base_info = Registered_type_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_from_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_registeredtypeinfo info = let base_info = cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_to_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = Registered_type_info.cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = Registered_type_info.cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' diff --git a/lib/Object_info.mli b/lib/Object_info.mli index 4602cc8..bb5119f 100644 --- a/lib/Object_info.mli +++ b/lib/Object_info.mli @@ -20,155 +20,136 @@ open Ctypes +type t (** Object_info represents a GObject. This doesn't represent a specific instance of a GObject, instead this represent the object type (eg class). A GObject has methods, fields, properties, signals, interfaces, constants and virtual functions.*) -type t + val objectinfo : t structure typ +val get_abstract : t structure ptr -> bool (** Obtain if the object type is an abstract type, eg if it cannot be instantiated *) -val get_abstract: - t structure ptr -> bool +val get_fundamental : t structure ptr -> bool (** Obtain if the object type is of a fundamental type which is not G_TYPE_OBJECT. This is mostly for supporting GstMiniObject. *) -val get_fundamental: - t structure ptr -> bool +val get_parent : t structure ptr -> Base_info.t structure ptr (** Obtain the parent of the object type.*) -val get_parent: - t structure ptr -> Base_info.t structure ptr +val get_type_name : t structure ptr -> string (** Obtain the name of the objects class/type. *) -val get_type_name: - t structure ptr -> string +val get_type_init : t structure ptr -> string (** Obtain the function which when called will return the GType function for which this object type is registered. *) -val get_type_init: - t structure ptr -> string +val get_n_constants : t structure ptr -> int (** Obtain the number of constants that this object type has. *) -val get_n_constants: - t structure ptr -> int +val get_constant : t structure ptr -> int -> Constant_info.t structure ptr (** Obtain an object type constant at index n . *) -val get_constant: - t structure ptr -> int -> Constant_info.t structure ptr +val get_n_fields : t structure ptr -> int (** Obtain the number of fields that this object type has. *) -val get_n_fields: - t structure ptr -> int +val get_field : t structure ptr -> int -> Field_info.t structure ptr (** Obtain an object type field at index n . *) -val get_field: - t structure ptr -> int -> Field_info.t structure ptr +val get_n_interfaces : t structure ptr -> int (** Obtain the number of interfaces that this object type has. *) -val get_n_interfaces: - t structure ptr -> int +val get_interface : t structure ptr -> int -> Interface_info.t structure ptr (** Obtain an object type interface at index n . *) -val get_interface: - t structure ptr -> int -> Interface_info.t structure ptr +val get_n_methods : t structure ptr -> int (** Obtain the number of methods that this object type has. *) -val get_n_methods: - t structure ptr -> int +val get_method : t structure ptr -> int -> Function_info.t structure ptr (** Obtain an object type method at index n . *) -val get_method: - t structure ptr -> int -> Function_info.t structure ptr +val find_method : + t structure ptr -> string -> Function_info.t structure ptr option (** Obtain a method of the object type given a name . None will be returned if there's no method available with that name. *) -val find_method: - t structure ptr -> string -> Function_info.t structure ptr option +val get_n_properties : t structure ptr -> int (** Obtain the number of properties that this object type has. *) -val get_n_properties: - t structure ptr -> int +val get_property : t structure ptr -> int -> Property_info.t structure ptr (** Obtain an object type property at index n .*) -val get_property: - t structure ptr -> int -> Property_info.t structure ptr +val get_n_signals : t structure ptr -> int (** Obtain the number of signals that this object type has. *) -val get_n_signals: - t structure ptr -> int +val get_signal : t structure ptr -> int -> Signal_info.t structure ptr (** Obtain an object type signal at index n .*) -val get_signal: - t structure ptr -> int -> Signal_info.t structure ptr -(** Find a signal with a name. *) -val find_signal: +val find_signal : t structure ptr -> string -> Signal_info.t structure ptr option +(** Find a signal with a name. *) +val get_n_vfuncs : t structure ptr -> int (** Obtain the number of virtual functions that this object type has. *) -val get_n_vfuncs: - t structure ptr -> int +val get_vfunc : t structure ptr -> int -> VFunc_info.t structure ptr (** Obtain an object type virtual function at index n . *) -val get_vfunc: - t structure ptr -> int -> VFunc_info.t structure ptr +val find_vfunc : t structure ptr -> string -> VFunc_info.t structure ptr option (** Locate a virtual function slot with name name . Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method associated for a virtual. If there is one, it may be retrieved using VFunc_info.get_invoker, otherwise None will be returned. See the documentation for VFunc_info.get_invoker for more information on invoking virtuals. *) -val find_vfunc: - t structure ptr -> string -> VFunc_info.t structure ptr option +val get_class_struct : t structure ptr -> Struct_info.t structure ptr option (** Every GObject has two structures; an instance structure and a class structure. This function returns the metadata for the class structure. It returns a Struct_info.t or None. *) -val get_class_struct: - t structure ptr -> Struct_info.t structure ptr option +val find_method_using_interfaces : + t structure ptr -> + string -> + Function_info.t structure ptr option * t structure ptr option (** Obtain a method of the object given a name , searching both the object info and any interfaces it implements. None will be returned if there's no method available with that name. Note that this function does *not* search parent classes; you will have to chain up if that's desired. *) -val find_method_using_interfaces: - t structure ptr -> string -> (Function_info.t structure ptr option * - t structure ptr option) +val get_ref_function : t structure ptr -> string option (** Obtain the symbol name of the function that should be called to ref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoRefFunction, to fetch the function pointer see Object_info.get_ref_function. *) -val get_ref_function: - t structure ptr -> string option +val get_unref_function : t structure ptr -> string option (** Obtain the symbol name of the function that should be called to unref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoUnrefFunction, to fetch the function pointer see Object_info.get_unref_function. *) -val get_unref_function: - t structure ptr -> string option +val get_set_value_function : t structure ptr -> string option (** Obtain the symbol name of the function that should be called to convert set a GValue giving an object instance pointer of this object type. I's mainly used fundamental types. The type signature for the symbol is Object_infoSetValueFunction, to fetch the function pointer see Object_info.get_set_value_function. *) -val get_set_value_function: - t structure ptr -> string option +val get_get_value_function : t structure ptr -> string option (** Obtain the symbol name of the function that should be called to convert an object instance pointer of this object type to a GValue. I's mainly used fundamental types. The type signature for the symbol is Object_infoGetValueFunction, to fetch the function pointer see Object_info.get_get_value_function. *) -val get_get_value_function: - t structure ptr -> string option +val find_vfunc_using_interfaces : + t structure ptr -> + string -> + VFunc_info.t structure ptr option * t structure ptr option (** Locate a virtual function slot with name name , searching both the object info and any interfaces it implements. Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method @@ -176,9 +157,6 @@ val get_get_value_function: g_vfunc_info_get_invoker(), otherwise None will be returned. Note that this function does *not* search parent classes; you will have to chain up if that's desired. *) -val find_vfunc_using_interfaces: - t structure ptr -> string -> (VFunc_info.t structure ptr option * - t structure ptr option) (* TODO : Object_infoRefFunction g_object_info_get_ref_function_pointer () @@ -187,42 +165,38 @@ val find_vfunc_using_interfaces: TODO : Object_infoGetValueFunction g_object_info_get_get_value_function_pointer () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to object info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes object info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Object_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr -(** Just cast OCaml Ctypes registeredtype info to object info. *) -val cast_from_registeredtypeinfo: +val cast_from_registeredtypeinfo : Registered_type_info.t structure ptr -> t structure ptr +(** Just cast OCaml Ctypes registeredtype info to object info. *) -(** Just cast OCaml Ctypes object info to registeredtype info *) -val cast_to_registeredtypeinfo: +val cast_to_registeredtypeinfo : t structure ptr -> Registered_type_info.t structure ptr +(** Just cast OCaml Ctypes object info to registeredtype info *) +val from_registeredtypeinfo : + Registered_type_info.t structure ptr -> t structure ptr (** Return a Object_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val from_registeredtypeinfo: - Registered_type_info.t structure ptr -> t structure ptr +val to_registeredtypeinfo : + t structure ptr -> Registered_type_info.t structure ptr (** Return a Registered_type_info.t form a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val to_registeredtypeinfo: - t structure ptr -> Registered_type_info.t structure ptr diff --git a/lib/Property_info.ml b/lib/Property_info.ml index c5e74e6..f415b78 100644 --- a/lib/Property_info.ml +++ b/lib/Property_info.ml @@ -20,22 +20,24 @@ open Ctypes open Foreign type t + let propertyinfo : t structure typ = structure "Property_info" let get_ownership_transfer = - foreign "g_property_info_get_ownership_transfer" - (ptr propertyinfo @-> returning Stubs.Arg_info.transfer) + foreign "g_property_info_get_ownership_transfer" + (ptr propertyinfo @-> returning Stubs.Arg_info.transfer) let get_type info = let get_type_raw = foreign "g_property_info_get_type" - (ptr propertyinfo @-> returning (ptr Type_info.typeinfo)) in + (ptr propertyinfo @-> returning (ptr Type_info.typeinfo)) + in let info' = get_type_raw info in Type_info.add_unref_finaliser info' let get_flags = - foreign "g_property_info_get_flags" - (ptr propertyinfo @-> returning GParam.flags_list) + foreign "g_property_info_get_flags" + (ptr propertyinfo @-> returning GParam.flags_list) (* TODO : check that the info can be casted to property info ? *) let cast_from_baseinfo info = @@ -45,10 +47,14 @@ let cast_to_baseinfo info = coerce (ptr propertyinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -58,6 +64,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Property_info.mli b/lib/Property_info.mli index 99058e5..4202061 100644 --- a/lib/Property_info.mli +++ b/lib/Property_info.mli @@ -20,45 +20,38 @@ open Ctypes +type t (** Property_info represents a property. A property belongs to either a Object_info or a Interface_info.*) -type t + val propertyinfo : t structure typ +val get_ownership_transfer : t structure ptr -> Bindings.Arg_info.transfer (** Obtain the ownership transfer for this property. See GITransfer for more information about transfer values. *) -val get_ownership_transfer: - t structure ptr -> Bindings.Arg_info.transfer +val get_type : t structure ptr -> Type_info.t structure ptr (** Obtain the type information for the property info . *) -val get_type: - t structure ptr -> Type_info.t structure ptr +val get_flags : t structure ptr -> Bindings.GParam.flags list (** Obtain the flags for this property info. See GParamFlags for more information about possible flag values. *) -val get_flags: - t structure ptr -> Bindings.GParam.flags list +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to property info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes property info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Property_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Property_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Registered_type_info.ml b/lib/Registered_type_info.ml index 83a7032..b795f1a 100644 --- a/lib/Registered_type_info.ml +++ b/lib/Registered_type_info.ml @@ -20,6 +20,7 @@ open Ctypes open Foreign type t + let registeredtypeinfo : t structure typ = structure "Registered_type_info" let get_type_name = @@ -29,9 +30,10 @@ let get_type_name = let get_g_type info = let get_g_type_raw = foreign "g_registered_type_info_get_g_type" - (ptr registeredtypeinfo @-> returning Repository.gtype) in + (ptr registeredtypeinfo @-> returning Repository.gtype) + in let gtype = get_g_type_raw info in - if gtype == (Int64.shift_left (Int64.of_int 1) 2) then None (* G_TYPE_NONE *) + if gtype == Int64.shift_left (Int64.of_int 1) 2 then None (* G_TYPE_NONE *) else Some gtype let get_type_init = @@ -46,10 +48,14 @@ let cast_to_baseinfo info = coerce (ptr registeredtypeinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -59,6 +65,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Registered_type_info.mli b/lib/Registered_type_info.mli index 5d9ee55..d238bfc 100644 --- a/lib/Registered_type_info.mli +++ b/lib/Registered_type_info.mli @@ -29,47 +29,40 @@ open Ctypes details. *) type t + val registeredtypeinfo : t structure typ +val get_type_name : t structure ptr -> string option (** Obtain the type name of the struct within the GObject type system. This type can be passed to g_type_name() to get a #GType. *) -val get_type_name: - t structure ptr -> string option +val get_g_type : t structure ptr -> Repository.gtype option (** Obtain the gtype for this registered type or None which a special meaning. It means that either there is no type information associated with this info or that the shared library which provides the type_init function for this info cannot be called. *) -val get_g_type: - t structure ptr -> Repository.gtype option +val get_type_init : t structure ptr -> string option (** Obtain the type init function for info . The type init function is the function which will register the GType within the GObject type system. Usually this is not called by langauge bindings or applications, use Registered_type_info.get_g_type directly instead. *) -val get_type_init: - t structure ptr -> string option +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to registeredtype info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes registeredtype info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Registered_type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Registered_type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Repository.ml b/lib/Repository.ml index fcfaad8..dcbcad9 100644 --- a/lib/Repository.ml +++ b/lib/Repository.ml @@ -21,14 +21,17 @@ open Foreign open Conversions type repository = unit ptr option + let repository_typ : repository typ = ptr_opt void type typelib = unit ptr + let typelib : typelib typ = ptr void type gerror_t + let gerror : gerror_t structure typ = structure "GError" -let f_message = field gerror "message" (string) +let f_message = field gerror "message" string let _ = seal gerror let get_default = @@ -36,29 +39,34 @@ let get_default = let require ?repository namespace ?version () = let require_raw = - foreign "g_irepository_require" - (repository_typ @-> string @-> string_opt @-> int @-> ptr (ptr gerror) @-> returning (ptr_opt void)) in + foreign "g_irepository_require" + (repository_typ @-> string @-> string_opt @-> int + @-> ptr (ptr gerror) + @-> returning (ptr_opt void)) + in let error_addr = allocate_n (ptr gerror) ~count:1 in let repo = match repository with None -> None | Some r -> r in match require_raw repo namespace version 0 error_addr with | None -> - let message = begin - match version with - | None -> "Unable to load namespace " ^ namespace - | Some v -> - Printf.sprintf "Unable to load namespace %s version %s" namespace v - end - in Error message - | Some typelib_ptr -> - match coerce (ptr gerror) (ptr_opt gerror) (!@error_addr) with - | None ->let typelib_ptr' = coerce (ptr void) (typelib) typelib_ptr in + let message = + match version with + | None -> "Unable to load namespace " ^ namespace + | Some v -> + Printf.sprintf "Unable to load namespace %s version %s" namespace v + in + Error message + | Some typelib_ptr -> ( + match coerce (ptr gerror) (ptr_opt gerror) !@error_addr with + | None -> + let typelib_ptr' = coerce (ptr void) typelib typelib_ptr in Ok typelib_ptr' - | Some error -> Error (getf !@error f_message) + | Some error -> Error (getf !@error f_message)) let get_loaded_namespaces ?repository () = let get_loaded_namespaces_raw = foreign "g_irepository_get_loaded_namespaces" - (repository_typ @-> returning carray_of_strings) in + (repository_typ @-> returning carray_of_strings) + in let repo = match repository with None -> None | Some r -> r in let c_arr = get_loaded_namespaces_raw repo in carray_of_strings_to_list c_arr @@ -66,7 +74,8 @@ let get_loaded_namespaces ?repository () = let get_dependencies ?repository namespace = let get_dependencies_raw = foreign "g_irepository_get_dependencies" - (repository_typ @-> string @-> returning carray_of_strings) in + (repository_typ @-> string @-> returning carray_of_strings) + in let repo = match repository with None -> None | Some r -> r in let c_arr = get_dependencies_raw repo namespace in carray_of_strings_to_list c_arr @@ -74,20 +83,23 @@ let get_dependencies ?repository namespace = let get_c_prefix ?repository namespace = let get_c_prefix_raw = foreign "g_irepository_get_c_prefix" - (repository_typ @-> string @-> returning string) in + (repository_typ @-> string @-> returning string) + in let repo = match repository with None -> None | Some r -> r in get_c_prefix_raw repo namespace let get_version ?repository namespace = let get_version_raw = - foreign "g_irepository_get_version" (repository_typ @-> string @-> returning string) + foreign "g_irepository_get_version" + (repository_typ @-> string @-> returning string) in let repo = match repository with None -> None | Some r -> r in get_version_raw repo namespace let get_typelib_path ?repository namespace = let get_typelib_path_raw = - foreign "g_irepository_get_typelib_path" (repository_typ @-> string @-> returning string) + foreign "g_irepository_get_typelib_path" + (repository_typ @-> string @-> returning string) in let repo = match repository with None -> None | Some r -> r in get_typelib_path_raw repo namespace @@ -95,7 +107,8 @@ let get_typelib_path ?repository namespace = let enumerate_versions ?repository namespace = let enumerate_versions_raw = foreign "g_irepository_enumerate_versions" - (repository_typ @-> string @-> returning (ptr_opt glist)) in + (repository_typ @-> string @-> returning (ptr_opt glist)) + in let repo = match repository with None -> None | Some r -> r in match enumerate_versions_raw repo namespace with | None -> [] @@ -103,8 +116,8 @@ let enumerate_versions ?repository namespace = let get_search_path () = let get_search_path_raw = - foreign "g_irepository_get_search_path" - (void @-> returning (ptr_opt gslist)) in + foreign "g_irepository_get_search_path" (void @-> returning (ptr_opt gslist)) + in match get_search_path_raw () with | None -> [] | Some gslist_ptr -> gslist_of_strings_to_list gslist_ptr @@ -115,53 +128,60 @@ let prepend_search_path = let find_by_name ?repository namespace name = let find_by_name_raw = foreign "g_irepository_find_by_name" - (repository_typ @-> string @-> string @-> returning (ptr_opt Base_info.baseinfo)) + (repository_typ @-> string @-> string + @-> returning (ptr_opt Base_info.baseinfo)) in let repo = match repository with None -> None | Some r -> r in match find_by_name_raw repo namespace name with | None -> None - | Some info -> let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info - in Some info + | Some info -> + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info in + Some info let get_n_infos ?repository namespace = let get_n_infos_raw = - foreign "g_irepository_get_n_infos" (repository_typ @-> string @-> returning int) + foreign "g_irepository_get_n_infos" + (repository_typ @-> string @-> returning int) in let repo = match repository with None -> None | Some r -> r in get_n_infos_raw repo namespace -let get_info ?repository namespace n= +let get_info ?repository namespace n = let get_info_raw = foreign "g_irepository_get_info" (repository_typ @-> string @-> int @-> returning (ptr Base_info.baseinfo)) in let repo = match repository with None -> None | Some r -> r in let max_infos = get_n_infos ?repository namespace in - if (n < 0 || n >= max_infos) then raise (Failure "Array Index out of bounds") - else let info = get_info_raw repo namespace n in + if n < 0 || n >= max_infos then raise (Failure "Array Index out of bounds") + else + let info = get_info_raw repo namespace n in let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info in info let get_shared_library ?repository namespace = let get_shared_library_raw = - foreign "g_irepository_get_shared_library" (repository_typ @-> string @-> returning string_opt) + foreign "g_irepository_get_shared_library" + (repository_typ @-> string @-> returning string_opt) in let repo = match repository with None -> None | Some r -> r in get_shared_library_raw repo namespace -let prepend_library_path= - foreign "g_irepository_prepend_library_path" - (string @-> returning void) +let prepend_library_path = + foreign "g_irepository_prepend_library_path" (string @-> returning void) type gtype = int64 + let gtype : gtype typ = int64_t let find_by_gtype ?repository gtyp = let find_by_gtype_raw = foreign "g_irepository_find_by_gtype" - (repository_typ @-> gtype @-> returning (ptr_opt Base_info.baseinfo)) in + (repository_typ @-> gtype @-> returning (ptr_opt Base_info.baseinfo)) + in let repo = match repository with None -> None | Some r -> r in match find_by_gtype_raw repo gtyp with | None -> None - | Some info -> let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info - in Some info + | Some info -> + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info in + Some info diff --git a/lib/Repository.mli b/lib/Repository.mli index 596435f..9fe2267 100644 --- a/lib/Repository.mli +++ b/lib/Repository.mli @@ -29,101 +29,94 @@ open Ctypes *) type repository - type typelib +val get_default : unit -> repository (** Returns the singleton process-global default Repository. *) -val get_default: - unit -> repository +val require : + ?repository:repository -> + string -> + ?version:string -> + unit -> + (typelib, string) result (** Force the namespace namespace_ to be loaded if it isn't already. If namespace_ is not loaded, this function will search for a ".typelib" file using the repository search path. In addition, a version version of namespace may be specified. If version is not specified, the latest will be used). *) -val require: - ?repository:repository -> string -> ?version:string -> unit -> (typelib, string) result +val get_loaded_namespaces : ?repository:repository -> unit -> string list (** Return the list of currently loaded namespaces. *) -val get_loaded_namespaces: - ?repository:repository -> unit -> string list +val get_dependencies : ?repository:repository -> string -> string list (** Return an list of all (transitive) versioned dependencies for namespace_ . Returned strings are of the form namespace-version. Note: namespace_ must have already been loaded using a function such as Repository.require before calling this function. To get only the immediate dependencies for namespace_ , use Repository.get_immediate_dependencies. *) -val get_dependencies: - ?repository:repository -> string -> string list +val get_c_prefix : ?repository:repository -> string -> string (** This function returns the "C prefix", or the C level namespace associated with the given introspection namespace. Each C symbol starts with this prefix, as well each GType in the library. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function. *) -val get_c_prefix: - ?repository:repository -> string -> string +val get_version : ?repository:repository -> string -> string (** This function returns the loaded version associated with the given namespace namespace_ . Note: The namespace must have already been loaded using a function such as Repository.require before calling this function. *) -val get_version: - ?repository:repository -> string -> string +val get_typelib_path : ?repository:repository -> string -> string (** If namespace namespace_ is loaded, return the full path to the .typelib file it was loaded from. If the typelib for namespace namespace_ was included in a shared library, return the special string "". *) -val get_typelib_path: - ?repository:repository -> string -> string +val enumerate_versions : ?repository:repository -> string -> string list (** Obtain an unordered list of versions (either currently loaded or available) for namespace_ in this repository . *) -val enumerate_versions: - ?repository:repository -> string -> string list +val get_search_path : unit -> string list (** Returns the current search path Repository will use when loading typelib files. The list is internal to GIRespository and should not be freed, nor should its string elements. *) -val get_search_path: - unit -> string list +val prepend_search_path : string -> unit (** Prepends directory to the typelib search path. See Repository.get_search_path. *) -val prepend_search_path: - string -> unit +val find_by_name : + ?repository:repository -> string -> string -> Base_info.t structure ptr option (** Searches for a particular entry in a namespace. Before calling this function for a particular namespace, you must call Repository.require once to load the namespace, or otherwise ensure the namespace has already been loaded.*) -val find_by_name: - ?repository:repository -> string -> string -> Base_info.t structure ptr option +val get_n_infos : ?repository:repository -> string -> int (** This function returns the number of metadata entries in given namespace namespace_ . The namespace must have already been loaded before calling this function. *) -val get_n_infos: - ?repository:repository -> string -> int +val get_info : + ?repository:repository -> string -> int -> Base_info.t structure ptr (** This function returns a particular metadata entry in the given namespace namespace_ . The namespace must have already been loaded before calling this function. See Repository.get_n_infos to find the maximum number of entries. *) -val get_info: - ?repository:repository -> string -> int -> Base_info.t structure ptr +val get_shared_library : ?repository:repository -> string -> string option (** This function returns a comma-separated list of paths to the shared C libraries associated with the given namespace namespace_ . There may be no shared library path associated, in which case this function will return NULL. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function. *) -val get_shared_library: - ?repository:repository -> string -> string option +val prepend_library_path : string -> unit (** Prepends directory to the search path that is used to search shared libraries referenced by imported namespaces. Multiple calls to this function all contribute to the final list of paths. The list of paths is @@ -133,20 +126,19 @@ val get_shared_library: loading will fall back to the system library path (ie. LD_LIBRARY_PATH and DT_RPATH in ELF systems). See the documentation of your dynamic linker for full details. *) -val prepend_library_path: - string -> unit type gtype = int64 -val gtype: int64 typ - (** Searches all loaded namespaces for a particular #GType. Note that +val gtype : int64 typ + +val find_by_gtype : + ?repository:repository -> gtype -> Base_info.t structure ptr option +(** Searches all loaded namespaces for a particular #GType. Note that in order to locate the metadata, the namespace corresponding to the type must first have been loaded. There is currently no mechanism for determining the namespace which corresponds to an arbitrary GType - thus, this function will operate most reliably when you know the GType to originate from be from a loaded namespace. *) -val find_by_gtype: - ?repository:repository -> gtype -> Base_info.t structure ptr option (* gchar ** g_irepository_get_immediate_dependencies () diff --git a/lib/Signal_info.ml b/lib/Signal_info.ml index b0e3b81..ae7d4e8 100644 --- a/lib/Signal_info.ml +++ b/lib/Signal_info.ml @@ -20,24 +20,26 @@ open Ctypes open Foreign type t + let signalinfo : t structure typ = structure "Signal_info" let true_stops_emit = - foreign "g_signal_info_true_stops_emit" - (ptr signalinfo @-> returning bool) + foreign "g_signal_info_true_stops_emit" (ptr signalinfo @-> returning bool) let get_flags = foreign "g_signal_info_get_flags" - (ptr signalinfo @-> returning GSignal.flags_list) + (ptr signalinfo @-> returning GSignal.flags_list) let get_class_closure info = let get_class_closure_raw = foreign "g_signal_info_get_class_closure" - (ptr signalinfo @-> returning (ptr_opt Callable_info.callableinfo)) in + (ptr signalinfo @-> returning (ptr_opt Callable_info.callableinfo)) + in match get_class_closure_raw info with | None -> None - | Some info' -> let info'' = Callable_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Callable_info.add_unref_finaliser info' in + Some info'' (* TODO : check that the info can be casted to signal info ? *) let cast_from_baseinfo info = @@ -47,10 +49,14 @@ let cast_to_baseinfo info = coerce (ptr signalinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -60,8 +66,7 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' let cast_from_callableinfo info = @@ -80,7 +85,11 @@ let from_callableinfo info = let info' = Callable_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in let info'' = cast_from_callableinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info'' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info'' + in info'' diff --git a/lib/Signal_info.mli b/lib/Signal_info.mli index a09e50f..021f707 100644 --- a/lib/Signal_info.mli +++ b/lib/Signal_info.mli @@ -20,73 +20,61 @@ open Ctypes +type t (** Signal_info represents a signal. It's a sub-struct of Callable_info and contains a set of flags and a class closure. See Callable_info for information on how to retreive arguments and other metadata from the signal. *) -type t + val signalinfo : t structure typ +val true_stops_emit : t structure ptr -> bool (** Obtain if the returning true in the signal handler will stop the emission of the signal. *) -val true_stops_emit: - t structure ptr -> bool +val get_flags : t structure ptr -> Bindings.GSignal.flags list (** Obtain the flags for this signal info. See GSignalFlags for more information about possible flag values. *) -val get_flags: - t structure ptr -> Bindings.GSignal.flags list +val get_class_closure : t structure ptr -> Callable_info.t structure ptr option (** Obtain the class closure for this signal if one is set. The class closure is a virtual function on the type that the signal belongs to. If the signal lacks a closure None will be returned. In order to avoid circular call graph between Signal_info and VFunc_info, this function will return a Callable_info. It is upto the user to use GIVSignalInfo.from_callableinfo in order to have the VFunc_info.*) -val get_class_closure: - t structure ptr -> Callable_info.t structure ptr option +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to signal info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes signal info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Signal_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val cast_from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes callable info to signal info. *) -val cast_from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val cast_to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Just cast OCaml Ctypes signal info to callable info *) -val cast_to_callableinfo: - t structure ptr -> Callable_info.t structure ptr +val from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Return a Signal_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Return a Callable_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_callableinfo: - t structure ptr -> Callable_info.t structure ptr - diff --git a/lib/Struct_info.ml b/lib/Struct_info.ml index cbb217e..e6b9202 100644 --- a/lib/Struct_info.ml +++ b/lib/Struct_info.ml @@ -20,59 +20,60 @@ open Ctypes open Foreign type t + let structinfo : t structure typ = structure "Struct_info" let is_gtype_struct = - foreign "g_struct_info_is_gtype_struct" - (ptr structinfo @-> returning bool) + foreign "g_struct_info_is_gtype_struct" (ptr structinfo @-> returning bool) let get_alignment = - foreign "g_struct_info_get_alignment" - (ptr structinfo @-> returning int) + foreign "g_struct_info_get_alignment" (ptr structinfo @-> returning int) let get_size = - foreign "g_struct_info_get_size" - (ptr structinfo @-> returning int) + foreign "g_struct_info_get_size" (ptr structinfo @-> returning int) let is_foreign = - foreign "g_struct_info_is_foreign" - (ptr structinfo @-> returning bool) + foreign "g_struct_info_is_foreign" (ptr structinfo @-> returning bool) let get_n_fields = - foreign "g_struct_info_get_n_fields" - (ptr structinfo @-> returning int) + foreign "g_struct_info_get_n_fields" (ptr structinfo @-> returning int) let get_n_methods = - foreign "g_struct_info_get_n_methods" - (ptr structinfo @-> returning int) + foreign "g_struct_info_get_n_methods" (ptr structinfo @-> returning int) let get_field info n = let get_field_raw = foreign "g_struct_info_get_field" - (ptr structinfo @-> int @-> returning (ptr Field_info.fieldinfo)) in + (ptr structinfo @-> int @-> returning (ptr Field_info.fieldinfo)) + in let max = get_n_fields info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_field_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_field_raw info n in Field_info.add_unref_finaliser info' let get_method info n = let get_method_raw = foreign "g_struct_info_get_method" - (ptr structinfo @-> int @-> returning (ptr Function_info.functioninfo)) in + (ptr structinfo @-> int @-> returning (ptr Function_info.functioninfo)) + in let max = get_n_methods info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_method_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_method_raw info n in Function_info.add_unref_finaliser info' let find_method info name = let find_method_raw = foreign "g_struct_info_find_method" - (ptr structinfo @-> string @-> returning (ptr_opt Function_info.functioninfo)) - in match find_method_raw info name with + (ptr structinfo @-> string + @-> returning (ptr_opt Function_info.functioninfo)) + in + match find_method_raw info name with | None -> None | Some info' -> - let fn_info = Function_info.add_unref_finaliser info' in - Some fn_info + let fn_info = Function_info.add_unref_finaliser info' in + Some fn_info (* TODO : check that the info can be casted to a structinfo ? *) let cast_from_baseinfo info = @@ -82,9 +83,13 @@ let cast_to_baseinfo info = coerce (ptr structinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in info let from_baseinfo info = @@ -95,8 +100,7 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' (* TODO : check that the info can be casted to a structinfo ? *) @@ -110,16 +114,24 @@ let from_registeredtypeinfo info = let base_info = Registered_type_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_from_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_registeredtypeinfo info = let base_info = cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_to_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = Registered_type_info.cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = Registered_type_info.cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' diff --git a/lib/Struct_info.mli b/lib/Struct_info.mli index c7618e5..fd7819c 100644 --- a/lib/Struct_info.mli +++ b/lib/Struct_info.mli @@ -20,82 +20,72 @@ open Ctypes +type t (** Struct_info represents a generic C structure type. A structure has methods and fields.*) -type t + val structinfo : t structure typ +val is_gtype_struct : t structure ptr -> bool (** Return true if this structure represents the "class structure" for some GObject or GInterface. This function is mainly useful to hide this kind of structure from generated public APIs. *) -val is_gtype_struct: - t structure ptr -> bool +val get_alignment : t structure ptr -> int (** Obtain the required alignment of the structure.*) -val get_alignment: - t structure ptr -> int +val get_size : t structure ptr -> int (** Obtain the total size of the structure. *) -val get_size: - t structure ptr -> int +val is_foreign : t structure ptr -> bool (** No doc yet *) -val is_foreign: - t structure ptr -> bool +val get_n_fields : t structure ptr -> int (** Obtain the number of fields this structure has. *) -val get_n_fields: - t structure ptr -> int +val get_n_methods : t structure ptr -> int (** Obtain the number of methods this structure has. *) -val get_n_methods: - t structure ptr -> int +val get_field : t structure ptr -> int -> Field_info.t structure ptr (** Obtain the type information for field with specified index. *) -val get_field: - t structure ptr -> int -> Field_info.t structure ptr +val get_method : t structure ptr -> int -> Function_info.t structure ptr (** Obtain the type information for method with specified index. *) -val get_method: - t structure ptr -> int -> Function_info.t structure ptr -(** Obtain the type information for method named name .*) -val find_method: +val find_method : t structure ptr -> string -> Function_info.t structure ptr option +(** Obtain the type information for method named name .*) +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr -(** Just cast OCaml Ctypes registeredtype info to struct info. *) -val cast_from_registeredtypeinfo: +val cast_from_registeredtypeinfo : Registered_type_info.t structure ptr -> t structure ptr +(** Just cast OCaml Ctypes registeredtype info to struct info. *) -(** Just cast OCaml Ctypes struct info to registeredtype info *) -val cast_to_registeredtypeinfo: +val cast_to_registeredtypeinfo : t structure ptr -> Registered_type_info.t structure ptr +(** Just cast OCaml Ctypes struct info to registeredtype info *) +val from_registeredtypeinfo : + Registered_type_info.t structure ptr -> t structure ptr (** Return a Struct_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val from_registeredtypeinfo: - Registered_type_info.t structure ptr -> t structure ptr +val to_registeredtypeinfo : + t structure ptr -> Registered_type_info.t structure ptr (** Return a Registered_type_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val to_registeredtypeinfo: - t structure ptr -> Registered_type_info.t structure ptr diff --git a/lib/Stubs.ml b/lib/Stubs.ml index 20ff532..4ae6daa 100644 --- a/lib/Stubs.ml +++ b/lib/Stubs.ml @@ -1,8 +1,11 @@ -module Base_info = Bindings.Base_info.Enums(Bindings_stubs_base_info) -module Function_info = Bindings.Function_info.Flags(Bindings_stubs_function_info) -module Types = Bindings.Types.Enums(Bindings_stubs_types) -module VFunc_info = Bindings.VFunc_info.Flags(Bindings_stubs_vfunc_info) -module Arg_info = Bindings.Arg_info.Enums(Bindings_stubs_arg_info) -module Field_info = Bindings.Field_info.Flags(Bindings_stubs_field_info) -module GParam = Bindings.GParam.Flags(Bindings_stubs_g_param) -module GSignal = Bindings.GSignal.Flags(Bindings_stubs_g_signal) +module Base_info = Bindings.Base_info.Enums (Bindings_stubs_base_info) + +module Function_info = + Bindings.Function_info.Flags (Bindings_stubs_function_info) + +module Types = Bindings.Types.Enums (Bindings_stubs_types) +module VFunc_info = Bindings.VFunc_info.Flags (Bindings_stubs_vfunc_info) +module Arg_info = Bindings.Arg_info.Enums (Bindings_stubs_arg_info) +module Field_info = Bindings.Field_info.Flags (Bindings_stubs_field_info) +module GParam = Bindings.GParam.Flags (Bindings_stubs_g_param) +module GSignal = Bindings.GSignal.Flags (Bindings_stubs_g_signal) diff --git a/lib/Type_info.ml b/lib/Type_info.ml index 3386be8..181f440 100644 --- a/lib/Type_info.ml +++ b/lib/Type_info.ml @@ -20,70 +20,70 @@ open Ctypes open Foreign type t + let typeinfo : t structure typ = structure "Type_info" let to_string = - foreign "g_info_type_to_string" - (ptr typeinfo @-> returning string) + foreign "g_info_type_to_string" (ptr typeinfo @-> returning string) let is_pointer = - foreign "g_type_info_is_pointer" - (ptr typeinfo @-> returning bool) + foreign "g_type_info_is_pointer" (ptr typeinfo @-> returning bool) let get_tag = - foreign "g_type_info_get_tag" - (ptr typeinfo @-> returning Stubs.Types.tag) + foreign "g_type_info_get_tag" (ptr typeinfo @-> returning Stubs.Types.tag) let get_array_length = - foreign "g_type_info_get_array_length" - (ptr typeinfo @-> returning int) + foreign "g_type_info_get_array_length" (ptr typeinfo @-> returning int) let get_array_fixed_size = - foreign "g_type_info_get_array_fixed_size" - (ptr typeinfo @-> returning int) + foreign "g_type_info_get_array_fixed_size" (ptr typeinfo @-> returning int) let is_zero_terminated = - foreign "g_type_info_is_zero_terminated" - (ptr typeinfo @-> returning bool) + foreign "g_type_info_is_zero_terminated" (ptr typeinfo @-> returning bool) let get_array_type info = let get_array_type_raw = foreign "g_type_info_get_array_type" - (ptr typeinfo @-> returning Stubs.Types.array_type) in - try Some (get_array_type_raw info) with - | _ -> None + (ptr typeinfo @-> returning Stubs.Types.array_type) + in + try Some (get_array_type_raw info) with _ -> None let get_interface info = let get_interface_raw = foreign "g_type_info_get_interface" - (ptr typeinfo @-> returning (ptr_opt Base_info.baseinfo)) in + (ptr typeinfo @-> returning (ptr_opt Base_info.baseinfo)) + in match get_interface_raw info with | None -> None - | Some info' -> let info'' = Base_info.add_unref_finaliser info' in - Some info'' + | Some info' -> + let info'' = Base_info.add_unref_finaliser info' in + Some info'' (* TODO : check that the info can be casted to arg info ? *) let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr typeinfo) info -let cast_to_baseinfo info = - coerce (ptr typeinfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr typeinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let unsafe_get_param_type info n = let get_param_type_raw = foreign "g_type_info_get_param_type" - (ptr typeinfo @-> int @-> returning (ptr typeinfo)) in - let param_type = get_param_type_raw info n in - add_unref_finaliser param_type + (ptr typeinfo @-> int @-> returning (ptr typeinfo)) + in + let param_type = get_param_type_raw info n in + add_unref_finaliser param_type -let get_param_type info = - unsafe_get_param_type info 0 +let get_param_type info = unsafe_get_param_type info 0 let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -93,6 +93,5 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Type_info.mli b/lib/Type_info.mli index f72d359..7533329 100644 --- a/lib/Type_info.mli +++ b/lib/Type_info.mli @@ -20,6 +20,7 @@ open Ctypes +type t (** Type_info represents a type. You can retrieve a type info from an argument (see Arg_info), a function return value (see Function_info), a field (see Field_info), a property (see Property_info), a constant @@ -28,45 +29,39 @@ open Ctypes or an interface type. For interface types you need to call Type_info.get_interface to get a reference to the base info for that interface. *) -type t + val typeinfo : t structure typ +val to_string : t structure ptr -> string (** Obtain a string representation of type. *) -val to_string: - t structure ptr -> string +val is_pointer : t structure ptr -> bool (** Obtain if the type is passed as a reference. Note that the types of GI_DIRECTION_OUT and GI_DIRECTION_INOUT parameters will only be pointers if the underlying type being transferred is a pointer (i.e. only if the type of the C function’s formal parameter is a pointer to a pointer). *) -val is_pointer: - t structure ptr -> bool +val get_tag : t structure ptr -> Bindings.Types.tag (** Obtain the type tag for the type. See GITypeTag for a list of type tags. *) -val get_tag: - t structure ptr -> Bindings.Types.tag +val get_array_length : t structure ptr -> int (** Obtain the array length of the type. The type tag must be a GIType.array or -1 will returned. *) -val get_array_length: - t structure ptr -> int +val get_array_fixed_size : t structure ptr -> int (** Obtain the fixed array size of the type. The type tag must be a GIType.array or -1 will returned. *) -val get_array_fixed_size: - t structure ptr -> int +val is_zero_terminated : t structure ptr -> bool (** Obtain if the last element of the array is NULL. The type tag must be a GIType.array or FALSE will returned. *) -val is_zero_terminated: - t structure ptr -> bool +val get_array_type : t structure ptr -> Bindings.Types.array_type option (** Obtain the array type for this type. See GIArrayType for a list of possible values. If the type tag of this type is not array, None will be returned. *) -val get_array_type: - t structure ptr -> Bindings.Types.array_type option +val unsafe_get_param_type : t structure ptr -> int -> t structure ptr (** Obtain the parameter type n. It is used to get the parameter type of generic * container. For example if the current Type_info.t is an array, a GList, a * GSList or an Hash, you have to use this in order to get the Type_info.t of @@ -77,43 +72,34 @@ val get_array_type: * This function is unsafe meanings that it is your responsability to not use * a number out of bounds. *) -val unsafe_get_param_type: - t structure ptr -> int -> t structure ptr +val get_param_type : t structure ptr -> t structure ptr (** This is just an alias to Type_info.unsage_get_param_type with the index set to 0. *) -val get_param_type: - t structure ptr -> t structure ptr +val get_interface : t structure ptr -> Base_info.t structure ptr option (** For types which have Types.Interface such as GObjects and boxed values, this function returns full information about the referenced type. You can then inspect the type of the returned Base_info to further query whether it is a concrete GObject, a GInterface, a structure, etc. using Base_info.get_type. *) -val get_interface: - t structure ptr -> Base_info.t structure ptr option +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to typeinfo. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes typeinfo to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Types.ml b/lib/Types.ml index fe5ddf5..7c8523f 100644 --- a/lib/Types.ml +++ b/lib/Types.ml @@ -20,27 +20,27 @@ open Ctypes open Stubs type argument_t + let argument : argument_t union typ = union "GIArgument" -let v_boolean = field argument "v_boolean" (bool) -let v_int8 = field argument "v_int8" (int8_t) -let v_uint8 = field argument "v_uint8" (uint8_t) -let v_int16 = field argument "v_int16" (int16_t) -let v_uint16 = field argument "v_uint16" (uint16_t) -let v_int32 = field argument "v_int32" (int32_t) -let v_uint32 = field argument "v_uint32" (uint32_t) -let v_int64 = field argument "v_int64" (int64_t) -let v_uint64 = field argument "v_uint64" (uint64_t) -let v_float = field argument "v_float" (float) -let v_double = field argument "v_double" (double) -let v_short = field argument "v_short" (short) -let v_ushort = field argument "v_ushort" (ushort) -let v_int = field argument "v_int" (int) -let v_uint = field argument "v_uint" (uint) -let v_long = field argument "v_long" (long) -let v_ulong = field argument "v_ulong" (ulong) -let v_ssize = field argument "v_ssize" (PosixTypes.ssize_t) -let v_size = field argument "v_size" (size_t) -let v_string = field argument "v_string" (string) +let v_boolean = field argument "v_boolean" bool +let v_int8 = field argument "v_int8" int8_t +let v_uint8 = field argument "v_uint8" uint8_t +let v_int16 = field argument "v_int16" int16_t +let v_uint16 = field argument "v_uint16" uint16_t +let v_int32 = field argument "v_int32" int32_t +let v_uint32 = field argument "v_uint32" uint32_t +let v_int64 = field argument "v_int64" int64_t +let v_uint64 = field argument "v_uint64" uint64_t +let v_float = field argument "v_float" float +let v_double = field argument "v_double" double +let v_short = field argument "v_short" short +let v_ushort = field argument "v_ushort" ushort +let v_int = field argument "v_int" int +let v_uint = field argument "v_uint" uint +let v_long = field argument "v_long" long +let v_ulong = field argument "v_ulong" ulong +let v_ssize = field argument "v_ssize" PosixTypes.ssize_t +let v_size = field argument "v_size" size_t +let v_string = field argument "v_string" string let v_pointer = field argument "v_pointer" (ptr_opt void) - let () = seal argument diff --git a/lib/Types.mli b/lib/Types.mli index 12ffb3f..120de3b 100644 --- a/lib/Types.mli +++ b/lib/Types.mli @@ -22,26 +22,26 @@ open Ctypes open Stubs type argument_t -val argument: argument_t union typ -val v_boolean: (bool, argument_t union) field -val v_int8: (int, argument_t union) field -val v_uint8: (Unsigned.uint8, argument_t union) field -val v_int16: (int, argument_t union) field -val v_uint16: (Unsigned.uint16, argument_t union) field -val v_int32: (int32, argument_t union) field -val v_uint32: (Unsigned.uint32, argument_t union) field -val v_int64: (int64, argument_t union) field -val v_uint64: (Unsigned.uint64, argument_t union) field -val v_float: (float, argument_t union) field -val v_double: (float, argument_t union) field -val v_short: (int, argument_t union) field -val v_ushort: (Unsigned.ushort, argument_t union) field -val v_int: (int, argument_t union) field -val v_uint: (Unsigned.uint, argument_t union) field -val v_long: (Signed.long, argument_t union) field -val v_ulong: (Unsigned.ulong, argument_t union) field -val v_ssize: (PosixTypes.ssize_t, argument_t union) field -val v_size: (PosixTypes.size_t, argument_t union) field -val v_string: (string, argument_t union) field -val v_pointer: (unit Ctypes_static.ptr option, argument_t union) field +val argument : argument_t union typ +val v_boolean : (bool, argument_t union) field +val v_int8 : (int, argument_t union) field +val v_uint8 : (Unsigned.uint8, argument_t union) field +val v_int16 : (int, argument_t union) field +val v_uint16 : (Unsigned.uint16, argument_t union) field +val v_int32 : (int32, argument_t union) field +val v_uint32 : (Unsigned.uint32, argument_t union) field +val v_int64 : (int64, argument_t union) field +val v_uint64 : (Unsigned.uint64, argument_t union) field +val v_float : (float, argument_t union) field +val v_double : (float, argument_t union) field +val v_short : (int, argument_t union) field +val v_ushort : (Unsigned.ushort, argument_t union) field +val v_int : (int, argument_t union) field +val v_uint : (Unsigned.uint, argument_t union) field +val v_long : (Signed.long, argument_t union) field +val v_ulong : (Unsigned.ulong, argument_t union) field +val v_ssize : (PosixTypes.ssize_t, argument_t union) field +val v_size : (PosixTypes.size_t, argument_t union) field +val v_string : (string, argument_t union) field +val v_pointer : (unit Ctypes_static.ptr option, argument_t union) field diff --git a/lib/Union_info.ml b/lib/Union_info.ml index de4a961..1de44ea 100644 --- a/lib/Union_info.ml +++ b/lib/Union_info.ml @@ -20,55 +20,56 @@ open Ctypes open Foreign type t + let unioninfo : t structure typ = structure "Union_info" let get_n_fields = - foreign "g_union_info_get_n_fields" - (ptr unioninfo @-> returning int) + foreign "g_union_info_get_n_fields" (ptr unioninfo @-> returning int) -let get_size = - foreign "g_union_info_get_size" - (ptr unioninfo @-> returning int) +let get_size = foreign "g_union_info_get_size" (ptr unioninfo @-> returning int) let get_alignment = - foreign "g_union_info_get_alignment" - (ptr unioninfo @-> returning int) + foreign "g_union_info_get_alignment" (ptr unioninfo @-> returning int) let get_n_methods = - foreign "g_union_info_get_n_methods" - (ptr unioninfo @-> returning int) + foreign "g_union_info_get_n_methods" (ptr unioninfo @-> returning int) let get_field info n = let get_field_raw = foreign "g_union_info_get_field" - (ptr unioninfo @-> int @-> returning (ptr Field_info.fieldinfo)) in + (ptr unioninfo @-> int @-> returning (ptr Field_info.fieldinfo)) + in let max = get_n_fields info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_field_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_field_raw info n in Field_info.add_unref_finaliser info' let get_method info n = let get_method_raw = foreign "g_union_info_get_method" - (ptr unioninfo @-> int @-> returning (ptr Function_info.functioninfo)) in + (ptr unioninfo @-> int @-> returning (ptr Function_info.functioninfo)) + in let max = get_n_methods info in - if (n < 0 || n >= max) then raise (Failure "Array Index out of bounds") - else let info' = get_method_raw info n in + if n < 0 || n >= max then raise (Failure "Array Index out of bounds") + else + let info' = get_method_raw info n in Function_info.add_unref_finaliser info' let find_method info name = let find_method_raw = foreign "g_union_info_find_method" - (ptr unioninfo @-> string @-> returning (ptr_opt Function_info.functioninfo)) - in match find_method_raw info name with + (ptr unioninfo @-> string + @-> returning (ptr_opt Function_info.functioninfo)) + in + match find_method_raw info name with | None -> None | Some info' -> - let fn_info = Function_info.add_unref_finaliser info' in - Some fn_info + let fn_info = Function_info.add_unref_finaliser info' in + Some fn_info let is_discriminated = - foreign "g_union_info_is_discriminated" - (ptr unioninfo @-> returning bool) + foreign "g_union_info_is_discriminated" (ptr unioninfo @-> returning bool) (* TODO : get_discriminator_offset find a test value *) let get_discriminator_offset = @@ -79,7 +80,8 @@ let get_discriminator_offset = let get_discriminator_type info = let get_discriminator_type_raw = foreign "g_union_info_get_discriminator_type" - (ptr unioninfo @-> returning (ptr Type_info.typeinfo)) in + (ptr unioninfo @-> returning (ptr Type_info.typeinfo)) + in let info' = get_discriminator_type_raw info in Type_info.add_unref_finaliser info' @@ -87,7 +89,8 @@ let get_discriminator_type info = let get_discriminator info n = let get_discriminator_raw = foreign "g_union_info_get_discriminator" - (ptr unioninfo @-> int @-> returning (ptr Constant_info.constantinfo)) in + (ptr unioninfo @-> int @-> returning (ptr Constant_info.constantinfo)) + in let info' = get_discriminator_raw info n in Constant_info.add_unref_finaliser info' @@ -95,22 +98,24 @@ let get_discriminator info n = let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr unioninfo) info -let cast_to_baseinfo info = - coerce (ptr unioninfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr unioninfo) (ptr Base_info.baseinfo) info let from_baseinfo info = let _ = Base_info.base_info_ref info in let info' = cast_from_baseinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' (* TODO : check that the info can be casted to a unioninfo ? *) @@ -124,16 +129,24 @@ let from_registeredtypeinfo info = let base_info = Registered_type_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_from_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_registeredtypeinfo info = let base_info = cast_to_baseinfo info in let _ = Base_info.base_info_ref base_info in let info' = cast_to_registeredtypeinfo info in - let _ = Gc.finalise (fun i -> - let i' = Registered_type_info.cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = Registered_type_info.cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' diff --git a/lib/Union_info.mli b/lib/Union_info.mli index f709d4e..cb5fd3a 100644 --- a/lib/Union_info.mli +++ b/lib/Union_info.mli @@ -20,95 +20,81 @@ open Ctypes +type t (** Union_info represents a union type. A union has methods and fields. Unions can optionally have a discriminator, which is a field deciding what type of real union fields is valid for specified instance.*) -type t + val unioninfo : t structure typ +val get_n_fields : t structure ptr -> int (** Obtain the number of fields this union has. *) -val get_n_fields: - t structure ptr -> int +val get_size : t structure ptr -> int (** Obtain the total size of the union. *) -val get_size: - t structure ptr -> int +val get_alignment : t structure ptr -> int (** Obtain the required alignment of the union. *) -val get_alignment: - t structure ptr -> int +val get_n_methods : t structure ptr -> int (** Obtain the number of methods this union has. *) -val get_n_methods: - t structure ptr -> int +val get_field : t structure ptr -> int -> Field_info.t structure ptr (** Obtain the type information for field with specified index. *) -val get_field: - t structure ptr -> int -> Field_info.t structure ptr +val get_method : t structure ptr -> int -> Function_info.t structure ptr (** Obtain the type information for method with specified index. *) -val get_method: - t structure ptr -> int -> Function_info.t structure ptr -(** Obtain the type information for method named name .*) -val find_method: +val find_method : t structure ptr -> string -> Function_info.t structure ptr option +(** Obtain the type information for method named name .*) +val is_discriminated : t structure ptr -> bool (** Return true if this union contains discriminator field. *) -val is_discriminated: - t structure ptr -> bool +val get_discriminator_offset : t structure ptr -> int (** Returns offset of the discriminator field in the structure. *) -val get_discriminator_offset: - t structure ptr -> int +val get_discriminator_type : t structure ptr -> Type_info.t structure ptr (** Obtain the type information of the union discriminator. *) -val get_discriminator_type: - t structure ptr -> Type_info.t structure ptr +val get_discriminator : t structure ptr -> int -> Constant_info.t structure ptr (** Obtain discriminator value assigned for n-th union field, i.e. n-th union field is the active one if discriminator contains this constant. *) -val get_discriminator: - t structure ptr -> int -> Constant_info.t structure ptr +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to union info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes union info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Union_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr -(** Just cast OCaml Ctypes registeredtype info to union info. *) -val cast_from_registeredtypeinfo: +val cast_from_registeredtypeinfo : Registered_type_info.t structure ptr -> t structure ptr +(** Just cast OCaml Ctypes registeredtype info to union info. *) -(** Just cast OCaml Ctypes union info to registeredtype info *) -val cast_to_registeredtypeinfo: +val cast_to_registeredtypeinfo : t structure ptr -> Registered_type_info.t structure ptr +(** Just cast OCaml Ctypes union info to registeredtype info *) +val from_registeredtypeinfo : + Registered_type_info.t structure ptr -> t structure ptr (** Return a Union_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val from_registeredtypeinfo: - Registered_type_info.t structure ptr -> t structure ptr +val to_registeredtypeinfo : + t structure ptr -> Registered_type_info.t structure ptr (** Return a Registered_type_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref. *) -val to_registeredtypeinfo: - t structure ptr -> Registered_type_info.t structure ptr - diff --git a/lib/VFunc_info.ml b/lib/VFunc_info.ml index 3cd92a2..42f2b01 100644 --- a/lib/VFunc_info.ml +++ b/lib/VFunc_info.ml @@ -20,46 +20,51 @@ open Ctypes open Foreign type t + let vfuncinfo : t structure typ = structure "VFunc_info" let get_offset = - foreign "g_vfunc_info_get_offset" - (ptr vfuncinfo @-> returning int) + foreign "g_vfunc_info_get_offset" (ptr vfuncinfo @-> returning int) let get_signal info = let get_signal_raw = foreign "g_vfunc_info_get_signal" - (ptr vfuncinfo @-> returning (ptr_opt Callable_info.callableinfo)) in + (ptr vfuncinfo @-> returning (ptr_opt Callable_info.callableinfo)) + in match get_signal_raw info with | None -> None - | Some info' -> let info'' = Callable_info.add_unref_finaliser info' in - Some info'' - -let all_flags : (int64 * Bindings.VFunc_info.flags) list= [ - Stubs.VFunc_info.gi_vfunc_must_chain_up, Must_chain_up; - Stubs.VFunc_info.gi_vfunc_must_override, Must_override; - Stubs.VFunc_info.gi_vfunc_must_not_override, Must_not_override; - Stubs.VFunc_info.gi_vfunc_throws, Throws; + | Some info' -> + let info'' = Callable_info.add_unref_finaliser info' in + Some info'' + +let all_flags : (int64 * Bindings.VFunc_info.flags) list = + [ + (Stubs.VFunc_info.gi_vfunc_must_chain_up, Must_chain_up); + (Stubs.VFunc_info.gi_vfunc_must_override, Must_override); + (Stubs.VFunc_info.gi_vfunc_must_not_override, Must_not_override); + (Stubs.VFunc_info.gi_vfunc_throws, Throws); ] let flags_list = Utils.generate_flags_list_view Stubs.VFunc_info.flags all_flags let get_flags = - foreign "g_vfunc_info_get_flags" - (ptr vfuncinfo @-> returning flags_list) + foreign "g_vfunc_info_get_flags" (ptr vfuncinfo @-> returning flags_list) (* TODO : check that the info can be casted to vfunc info ? *) let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr vfuncinfo) info -let cast_to_baseinfo info = - coerce (ptr vfuncinfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr vfuncinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in @@ -69,8 +74,7 @@ let from_baseinfo info = let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' let cast_from_callableinfo info = @@ -89,8 +93,11 @@ let from_callableinfo info = let info' = Callable_info.cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in let info'' = cast_from_callableinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info'' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info'' + in info'' - diff --git a/lib/VFunc_info.mli b/lib/VFunc_info.mli index 57f790a..56582b5 100644 --- a/lib/VFunc_info.mli +++ b/lib/VFunc_info.mli @@ -20,28 +20,26 @@ open Ctypes +type t (** GIVfuncInfo represents a virtual function. A property belongs to either a Object_info or a Interface_info. *) -type t + val vfuncinfo : t structure typ +val get_offset : t structure ptr -> int (** Obtain the offset of the function pointer in the class struct. The value 0xFFFF indicates that the struct offset is unknown. *) -val get_offset: - t structure ptr -> int +val get_signal : t structure ptr -> Callable_info.t structure ptr option (** Obtain the signal for the virtual function if one is set. The signal comes from the object or interface to which this virtual function belongs. In order to avoid circular call graph between VFunc_info and Signal_info, this function will return a Callable_info. It is upto the user to use Signal_info.from_callableinfo in order to have the Signal_info.*) -val get_signal: - t structure ptr -> Callable_info.t structure ptr option +val get_flags : t structure ptr -> Bindings.VFunc_info.flags list (** Obtain the flags for this virtual function info. See VFunc_infoFlags for more information about possible flag values. *) -val get_flags: - t structure ptr -> Bindings.VFunc_info.flags list (* TODO : Function_info * g_vfunc_info_get_invoker () @@ -49,46 +47,37 @@ val get_flags: TODO : gboolean g_vfunc_info_invoke () *) +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to vfunc info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes vfunc info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a VFunc_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val cast_from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes callable info to vfunc info. *) -val cast_from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val cast_to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Just cast OCaml Ctypes vfunc info to callable info *) -val cast_to_callableinfo: - t structure ptr -> Callable_info.t structure ptr +val from_callableinfo : Callable_info.t structure ptr -> t structure ptr (** Return a VFunc_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_callableinfo: - Callable_info.t structure ptr -> t structure ptr +val to_callableinfo : t structure ptr -> Callable_info.t structure ptr (** Return a Callable_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_callableinfo: - t structure ptr -> Callable_info.t structure ptr diff --git a/lib/Value_info.ml b/lib/Value_info.ml index 804c6b2..a0c6ff6 100644 --- a/lib/Value_info.ml +++ b/lib/Value_info.ml @@ -20,36 +20,42 @@ open Ctypes open Foreign type t + let valueinfo : t structure typ = structure "Value_info" let get_value = - foreign "g_value_info_get_value" - (ptr valueinfo @-> returning int64_t) + foreign "g_value_info_get_value" (ptr valueinfo @-> returning int64_t) (* TODO : check that the info can be casted to a valueinfo ? *) let cast_from_baseinfo info = coerce (ptr Base_info.baseinfo) (ptr valueinfo) info -let cast_to_baseinfo info = - coerce (ptr valueinfo) (ptr Base_info.baseinfo) info +let cast_to_baseinfo info = coerce (ptr valueinfo) (ptr Base_info.baseinfo) info let add_unref_finaliser info = - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info - in info + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info + in + info let from_baseinfo info = let _ = Base_info.base_info_ref info in let info' = cast_from_baseinfo info in - let _ = Gc.finalise (fun i -> - let i' = cast_to_baseinfo i in - Base_info.base_info_unref i') info' in + let _ = + Gc.finalise + (fun i -> + let i' = cast_to_baseinfo i in + Base_info.base_info_unref i') + info' + in info' let to_baseinfo info = let info' = cast_to_baseinfo info in let _ = Base_info.base_info_ref info' in - let _ = Gc.finalise (fun i -> - Base_info.base_info_unref i) info' in + let _ = Gc.finalise (fun i -> Base_info.base_info_unref i) info' in info' diff --git a/lib/Value_info.mli b/lib/Value_info.mli index 9d83395..152dffd 100644 --- a/lib/Value_info.mli +++ b/lib/Value_info.mli @@ -20,34 +20,29 @@ open Ctypes -(** Represents a enum value of a Enum_info.*) type t +(** Represents a enum value of a Enum_info.*) + val valueinfo : t structure typ +val get_value : t structure ptr -> int64 (** Obtain the enumeration value of the Value_info. *) -val get_value: - t structure ptr -> int64 +val cast_from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Just cast OCaml Ctypes base info to enum info. *) -val cast_from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val cast_to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Just cast OCaml Ctypes enum info to base info *) -val cast_to_baseinfo: - t structure ptr -> Base_info.t structure ptr +val add_unref_finaliser : t structure ptr -> t structure ptr (** Add unref of the C underlying structure whith Gc.finalise. *) -val add_unref_finaliser: - t structure ptr -> t structure ptr +val from_baseinfo : Base_info.t structure ptr -> t structure ptr (** Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val from_baseinfo: - Base_info.t structure ptr -> t structure ptr +val to_baseinfo : t structure ptr -> Base_info.t structure ptr (** Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref. *) -val to_baseinfo: - t structure ptr -> Base_info.t structure ptr diff --git a/lib/Version.ml b/lib/Version.ml index 83c85dd..d9cdcfe 100644 --- a/lib/Version.ml +++ b/lib/Version.ml @@ -19,11 +19,6 @@ open Ctypes open Foreign -let get_major_version = - foreign "gi_get_major_version" (void @-> returning int) - -let get_minor_version = - foreign "gi_get_minor_version" (void @-> returning int) - -let get_micro_version = - foreign "gi_get_micro_version" (void @-> returning int) +let get_major_version = foreign "gi_get_major_version" (void @-> returning int) +let get_minor_version = foreign "gi_get_minor_version" (void @-> returning int) +let get_micro_version = foreign "gi_get_micro_version" (void @-> returning int) diff --git a/lib/Version.mli b/lib/Version.mli index 17689bc..7d59988 100644 --- a/lib/Version.mli +++ b/lib/Version.mli @@ -16,17 +16,17 @@ * along with OCaml-GObject-Introspection. If not, see . *) +val get_major_version : unit -> int (** * Returns the major version number of the girepository library. (e.g. in version 1.58.2 this is 1.) * *) -val get_major_version : unit -> int +val get_minor_version : unit -> int (** * Returns the minor version number of the girepository library. (e.g. in version 1.58.2 this is 58.) * *) -val get_minor_version : unit -> int +val get_micro_version : unit -> int (** * Returns the micro version number of the girepository library. (e.g. in version 1.58.2 this is 2.) * *) -val get_micro_version : unit -> int diff --git a/lib/dune b/lib/dune index 74e9863..2dba212 100644 --- a/lib/dune +++ b/lib/dune @@ -1,55 +1,81 @@ (library -(name GObject_introspection) - (public_name gobject-introspection) - (libraries ctypes ctypes.foreign str gobject-introspection.bindings) - ;(c_flags (:include c_flags.sexp)) - (c_library_flags (:include c_library_flags.sexp)) - (ocamlopt_flags (-ccopt (:include ccopts.sexp))) -) + (name GObject_introspection) + (public_name gobject-introspection) + (libraries ctypes ctypes.foreign str gobject-introspection.bindings) + ;(c_flags (:include c_flags.sexp)) + (c_library_flags + (:include c_library_flags.sexp)) + (ocamlopt_flags + (-ccopt + (:include ccopts.sexp)))) (rule - (targets c_flags.sexp c_library_flags.sexp ccopts.sexp) - (deps (:x ../config/discover.exe)) - (action (run %{x})) -) + (targets c_flags.sexp c_library_flags.sexp ccopts.sexp) + (deps + (:x ../config/discover.exe)) + (action + (run %{x}))) (rule - (targets bindings_stubs_base_info.ml) - (deps ../stubgen/bindings_stubs_gen_base_info.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_base_info.ml) + (deps ../stubgen/bindings_stubs_gen_base_info.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_function_info.ml) - (deps ../stubgen/bindings_stubs_gen_function_info.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_function_info.ml) + (deps ../stubgen/bindings_stubs_gen_function_info.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_types.ml) - (deps ../stubgen/bindings_stubs_gen_types.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_types.ml) + (deps ../stubgen/bindings_stubs_gen_types.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_vfunc_info.ml) - (deps ../stubgen/bindings_stubs_gen_vfunc_info.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_vfunc_info.ml) + (deps ../stubgen/bindings_stubs_gen_vfunc_info.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_arg_info.ml) - (deps ../stubgen/bindings_stubs_gen_arg_info.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_arg_info.ml) + (deps ../stubgen/bindings_stubs_gen_arg_info.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_field_info.ml) - (deps ../stubgen/bindings_stubs_gen_field_info.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_field_info.ml) + (deps ../stubgen/bindings_stubs_gen_field_info.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_g_param.ml) - (deps ../stubgen/bindings_stubs_gen_g_param.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) + (targets bindings_stubs_g_param.ml) + (deps ../stubgen/bindings_stubs_gen_g_param.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) (rule - (targets bindings_stubs_g_signal.ml) - (deps ../stubgen/bindings_stubs_gen_g_signal.exe) - (action (with-stdout-to %{targets} (run %{deps} -ml)))) - + (targets bindings_stubs_g_signal.ml) + (deps ../stubgen/bindings_stubs_gen_g_signal.exe) + (action + (with-stdout-to + %{targets} + (run %{deps} -ml)))) diff --git a/lib/utils.ml b/lib/utils.ml index 9f9c637..ca62285 100644 --- a/lib/utils.ml +++ b/lib/utils.ml @@ -23,14 +23,17 @@ let flags_list_of_int64 all_flags v = let rec build_flags_list allf acc = match allf with | [] -> acc - | (i, f) :: q -> if ((logand v i) <> zero) then build_flags_list q (f :: acc) - else build_flags_list q acc - in build_flags_list all_flags [] + | (i, f) :: q -> + if logand v i <> zero then build_flags_list q (f :: acc) + else build_flags_list q acc + in + build_flags_list all_flags [] let int64_of_flags_list all_flags f = let open Int64 in - let bitwise_or = fun acc value -> - let (i, _f) = List.find (fun (i', f') -> value = f') all_flags in logor acc i + let bitwise_or acc value = + let i, _f = List.find (fun (i', f') -> value = f') all_flags in + logor acc i in List.fold_left bitwise_or Int64.zero f diff --git a/samples/dune b/samples/dune index 4aac916..b5fdc1a 100644 --- a/samples/dune +++ b/samples/dune @@ -1,8 +1,8 @@ (executables - (names gi_repository - gi_baseinfo_deprecated - gi_baseinfo_discriminated - gi_baseinfo_get_name - gi_baseinfo_get_type) - (libraries GObject_introspection) -) + (names + gi_repository + gi_baseinfo_deprecated + gi_baseinfo_discriminated + gi_baseinfo_get_name + gi_baseinfo_get_type) + (libraries GObject_introspection)) diff --git a/samples/gi_baseinfo_deprecated.ml b/samples/gi_baseinfo_deprecated.ml index db10faf..3b107a3 100644 --- a/samples/gi_baseinfo_deprecated.ml +++ b/samples/gi_baseinfo_deprecated.ml @@ -22,15 +22,16 @@ let () = let namespace = "Gtk" in let _ = Repository.require namespace () in let n = Repository.get_n_infos namespace in - for i = 0 to (n - 1) do - print_endline (String.concat "/" ["\t\t"; string_of_int i; string_of_int n]); + for i = 0 to n - 1 do + print_endline + (String.concat "/" [ "\t\t"; string_of_int i; string_of_int n ]); let info = Repository.get_info namespace i in if Base_info.is_deprecated info then - let name = (match Base_info.get_name info with - | None -> "No name" - | Some str -> str ) in - let message = String.concat " " ["Base_info number"; - string_of_int i; - name] - in print_endline message; + let name = + match Base_info.get_name info with None -> "No name" | Some str -> str + in + let message = + String.concat " " [ "Base_info number"; string_of_int i; name ] + in + print_endline message done diff --git a/samples/gi_baseinfo_discriminated.ml b/samples/gi_baseinfo_discriminated.ml index 4ccabaf..b94eac1 100644 --- a/samples/gi_baseinfo_discriminated.ml +++ b/samples/gi_baseinfo_discriminated.ml @@ -22,23 +22,23 @@ let () = let namespace = "Gtk" in let _ = Repository.require namespace () in let n = Repository.get_n_infos namespace in - for i = 0 to (n - 1) do - let info = Repository.get_info namespace i in + for i = 0 to n - 1 do + let info = Repository.get_info namespace i in match Base_info.get_type info with - | Bindings.Base_info.Union -> let info' = Union_info.from_baseinfo info in - if Union_info.is_discriminated info' then - let message = ( match Base_info.get_name info with - | None -> String.concat " " ["Anonymous"; - "Index"; - string_of_int i; - "/"; - string_of_int n] - | Some name -> String.concat " " [name; - "Index"; - string_of_int i; - "/"; - string_of_int n] - ) in print_endline message - + | Bindings.Base_info.Union -> + let info' = Union_info.from_baseinfo info in + if Union_info.is_discriminated info' then + let message = + match Base_info.get_name info with + | None -> + String.concat " " + [ + "Anonymous"; "Index"; string_of_int i; "/"; string_of_int n; + ] + | Some name -> + String.concat " " + [ name; "Index"; string_of_int i; "/"; string_of_int n ] + in + print_endline message | _ -> () done diff --git a/samples/gi_baseinfo_get_name.ml b/samples/gi_baseinfo_get_name.ml index 993abdd..7d5c3e0 100644 --- a/samples/gi_baseinfo_get_name.ml +++ b/samples/gi_baseinfo_get_name.ml @@ -20,18 +20,20 @@ open GObject_introspection let print_info namespace n = let message = - let info = Repository.get_info namespace n in - let name = match Base_info.get_name info with + let info = Repository.get_info namespace n in + let name = + match Base_info.get_name info with | None -> "Anonymous" - | Some name -> name in String.concat " " ["Base_info number"; - string_of_int n; - name] - in print_endline message + | Some name -> name + in + String.concat " " [ "Base_info number"; string_of_int n; name ] + in + print_endline message let () = let namespace = "Gtk" in let _ = Repository.require namespace () in let n = Repository.get_n_infos namespace in - for i = 0 to (n - 1) do - print_info namespace i; + for i = 0 to n - 1 do + print_info namespace i done diff --git a/samples/gi_baseinfo_get_type.ml b/samples/gi_baseinfo_get_type.ml index 1c43fa2..a083bf6 100644 --- a/samples/gi_baseinfo_get_type.ml +++ b/samples/gi_baseinfo_get_type.ml @@ -18,24 +18,28 @@ open GObject_introspection -let get_info_strings info n= - ["Base_info -> number:"; - string_of_int n; - "name:"; - (match Base_info.get_name info with None -> "noname" | Some name -> name); - "type:"; - (let t = Base_info.get_type info in - Bindings.Base_info.string_of_info_type t) ] +let get_info_strings info n = + [ + "Base_info -> number:"; + string_of_int n; + "name:"; + (match Base_info.get_name info with None -> "noname" | Some name -> name); + "type:"; + (let t = Base_info.get_type info in + Bindings.Base_info.string_of_info_type t); + ] let print_info namespace n = - let message = let info = Repository.get_info namespace n in + let message = + let info = Repository.get_info namespace n in String.concat " " (get_info_strings info n) - in print_endline message + in + print_endline message let () = let namespace = "Gtk" in let _ = Repository.require namespace in let n = Repository.get_n_infos namespace in - for i = 0 to (n - 1) do - print_info namespace i; + for i = 0 to n - 1 do + print_info namespace i done diff --git a/samples/gi_repository.ml b/samples/gi_repository.ml index 6782ece..aae8a5d 100644 --- a/samples/gi_repository.ml +++ b/samples/gi_repository.ml @@ -25,24 +25,24 @@ let () = List.iter (fun x -> print_endline ("\t -" ^ x)) sp; let _ = Repository.require namespace () in let c_prefix = Repository.get_c_prefix namespace in -(* let shared_lib = Repository.get_shared_library repo namespace in *) + (* let shared_lib = Repository.get_shared_library repo namespace in *) let typelib_path = Repository.get_typelib_path namespace in let version = Repository.get_version namespace in print_endline ("Prefix: " ^ c_prefix); (* print_endline ("Shared library: " ^ shared_lib); *) print_endline ("Typelib path : " ^ typelib_path); print_endline ("Version: " ^ version); - print_endline ("Versions: "); + print_endline "Versions: "; let versions = Repository.enumerate_versions namespace in List.iter (fun x -> print_endline ("\t v. : " ^ x)) versions; print_endline "Dependencies"; let dependencies = Repository.get_dependencies namespace in List.iter (fun x -> print_endline ("\t dep. : " ^ x)) dependencies; print_endline "Immediate Dependencies"; -(* let dependencies = Repository.get_immediate_dependencies (Some repo) namespace in - List.iter (fun x -> print_endline ("\t dep. : " ^ x)) dependencies; *) + (* let dependencies = Repository.get_immediate_dependencies (Some repo) namespace in + List.iter (fun x -> print_endline ("\t dep. : " ^ x)) dependencies; *) print_endline "Loaded namespaces"; let namespaces = Repository.get_loaded_namespaces () in List.iter (fun x -> print_endline ("\t namespace : " ^ x)) namespaces; let n_infos = Repository.get_n_infos namespace in - print_endline ("Number of elements : " ^ (string_of_int n_infos)) + print_endline ("Number of elements : " ^ string_of_int n_infos) diff --git a/stubgen/bindings_c_gen_arg_info.ml b/stubgen/bindings_c_gen_arg_info.ml index 873ed5d..a64754c 100644 --- a/stubgen/bindings_c_gen_arg_info.ml +++ b/stubgen/bindings_c_gen_arg_info.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_base_info.ml b/stubgen/bindings_c_gen_base_info.ml index b284bc5..e532f23 100644 --- a/stubgen/bindings_c_gen_base_info.ml +++ b/stubgen/bindings_c_gen_base_info.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_field_info.ml b/stubgen/bindings_c_gen_field_info.ml index 26ab1ea..a9ae6e2 100644 --- a/stubgen/bindings_c_gen_field_info.ml +++ b/stubgen/bindings_c_gen_field_info.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_function_info.ml b/stubgen/bindings_c_gen_function_info.ml index f8c0dd1..7f4dc93 100644 --- a/stubgen/bindings_c_gen_function_info.ml +++ b/stubgen/bindings_c_gen_function_info.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_g_param.ml b/stubgen/bindings_c_gen_g_param.ml index fa08904..f990859 100644 --- a/stubgen/bindings_c_gen_g_param.ml +++ b/stubgen/bindings_c_gen_g_param.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_g_signal.ml b/stubgen/bindings_c_gen_g_signal.ml index c470ed9..3c6dc27 100644 --- a/stubgen/bindings_c_gen_g_signal.ml +++ b/stubgen/bindings_c_gen_g_signal.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_types.ml b/stubgen/bindings_c_gen_types.ml index 76d7319..c217c19 100644 --- a/stubgen/bindings_c_gen_types.ml +++ b/stubgen/bindings_c_gen_types.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/bindings_c_gen_vfunc_info.ml b/stubgen/bindings_c_gen_vfunc_info.ml index 36bb4ac..d5514cd 100644 --- a/stubgen/bindings_c_gen_vfunc_info.ml +++ b/stubgen/bindings_c_gen_vfunc_info.ml @@ -9,4 +9,3 @@ let main () = close_out stubs_out let () = main () - diff --git a/stubgen/dune b/stubgen/dune index 9ef9af4..9f72481 100644 --- a/stubgen/dune +++ b/stubgen/dune @@ -1,4 +1,5 @@ ; Base_info stubs rules + (executable (name bindings_c_gen_base_info) (modules bindings_c_gen_base_info) @@ -6,18 +7,22 @@ (rule (targets bindings_stubs_gen_base_info.c) - (deps (:stubgen ../stubgen/bindings_c_gen_base_info.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_base_info.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_base_info.exe) (deps bindings_stubs_gen_base_info.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_base_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_base_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; Function_info stubs rules + (executable (name bindings_c_gen_function_info) (modules bindings_c_gen_function_info) @@ -25,18 +30,22 @@ (rule (targets bindings_stubs_gen_function_info.c) - (deps (:stubgen ../stubgen/bindings_c_gen_function_info.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_function_info.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_function_info.exe) (deps bindings_stubs_gen_function_info.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_function_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_function_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; Types stubs rules + (executable (name bindings_c_gen_types) (modules bindings_c_gen_types) @@ -44,18 +53,22 @@ (rule (targets bindings_stubs_gen_types.c) - (deps (:stubgen ../stubgen/bindings_c_gen_types.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_types.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_types.exe) (deps bindings_stubs_gen_types.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_types.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_types.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; VFunc_info stubs rules + (executable (name bindings_c_gen_vfunc_info) (modules bindings_c_gen_vfunc_info) @@ -63,18 +76,22 @@ (rule (targets bindings_stubs_gen_vfunc_info.c) - (deps (:stubgen ../stubgen/bindings_c_gen_vfunc_info.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_vfunc_info.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_vfunc_info.exe) (deps bindings_stubs_gen_vfunc_info.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_vfunc_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_vfunc_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; Arg_info stubs rules + (executable (name bindings_c_gen_arg_info) (modules bindings_c_gen_arg_info) @@ -82,18 +99,22 @@ (rule (targets bindings_stubs_gen_arg_info.c) - (deps (:stubgen ../stubgen/bindings_c_gen_arg_info.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_arg_info.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_arg_info.exe) (deps bindings_stubs_gen_arg_info.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_arg_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_arg_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; Field_info stubs rules + (executable (name bindings_c_gen_field_info) (modules bindings_c_gen_field_info) @@ -101,18 +122,22 @@ (rule (targets bindings_stubs_gen_field_info.c) - (deps (:stubgen ../stubgen/bindings_c_gen_field_info.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_field_info.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_field_info.exe) (deps bindings_stubs_gen_field_info.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_field_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_field_info.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; GParam stubs rules + (executable (name bindings_c_gen_g_param) (modules bindings_c_gen_g_param) @@ -120,18 +145,22 @@ (rule (targets bindings_stubs_gen_g_param.c) - (deps (:stubgen ../stubgen/bindings_c_gen_g_param.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_g_param.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_g_param.exe) (deps bindings_stubs_gen_g_param.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_g_param.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_g_param.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; GSignal stubs rules + (executable (name bindings_c_gen_g_signal) (modules bindings_c_gen_g_signal) @@ -139,20 +168,25 @@ (rule (targets bindings_stubs_gen_g_signal.c) - (deps (:stubgen ../stubgen/bindings_c_gen_g_signal.exe)) - (action (with-stdout-to %{targets} (run %{stubgen} -c)))) + (deps + (:stubgen ../stubgen/bindings_c_gen_g_signal.exe)) + (action + (with-stdout-to + %{targets} + (run %{stubgen} -c)))) (rule (targets bindings_stubs_gen_g_signal.exe) (deps bindings_stubs_gen_g_signal.c c_flags c_library_flags) (action (bash - "%{cc} bindings_stubs_gen_g_signal.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}")) -) + "%{cc} bindings_stubs_gen_g_signal.c -I `dirname %{lib:ctypes:ctypes_cstubs_internals.h}` -I %{ocaml_where} $(< c_flags) $(< c_library_flags) -o %{targets}"))) ; Compiling flags rules + (rule - (targets c_library_flags c_flags) - (deps (:x ../config/discover.exe)) - (action (run %{x})) -) + (targets c_library_flags c_flags) + (deps + (:x ../config/discover.exe)) + (action + (run %{x}))) diff --git a/tests/Test_arg_info.ml b/tests/Test_arg_info.ml index 2c28e6d..773d78d 100644 --- a/tests/Test_arg_info.ml +++ b/tests/Test_arg_info.ml @@ -27,111 +27,106 @@ let func_name = "signal_name" let get_arg_info () = match Repository.find_by_name namespace func_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Function -> let callable_info = Callable_info.from_baseinfo base_info - in let info = Callable_info.get_arg callable_info 0 in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Function -> + let callable_info = Callable_info.from_baseinfo base_info in + let info = Callable_info.get_arg callable_info 0 in + Some info + | _ -> None) let arg_test fn = match get_arg_info () with | None -> assert_equal_string func_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_direction _ = arg_test (fun info -> let dir = Arg_info.get_direction info in - assert_equal ~printer:(fun d -> + assert_equal + ~printer:(fun d -> match d with | Bindings.Arg_info.In -> "In" | Bindings.Arg_info.Out -> "Out" - | Bindings.Arg_info.InOut -> "InOut") Bindings.Arg_info.In dir - ) + | Bindings.Arg_info.InOut -> "InOut") + Bindings.Arg_info.In dir) let test_get_closure _ = arg_test (fun info -> let closure = Arg_info.get_closure info in - assert_equal_int (-1) closure - ) + assert_equal_int (-1) closure) let test_get_destroy _ = arg_test (fun info -> let index = Arg_info.get_destroy info in - assert_equal_int (-1) index - ) + assert_equal_int (-1) index) let test_get_ownership_transfer _ = arg_test (fun info -> let transfer = Arg_info.get_ownership_transfer info in - assert_equal ~printer:(fun t -> + assert_equal + ~printer:(fun t -> match t with | Bindings.Arg_info.Nothing -> "nothing" | Bindings.Arg_info.Container -> "container" - | Bindings.Arg_info.Everything -> "everything" - ) Bindings.Arg_info.Nothing transfer - ) + | Bindings.Arg_info.Everything -> "everything") + Bindings.Arg_info.Nothing transfer) let test_may_be_null _ = arg_test (fun info -> let may_be_null = Arg_info.may_be_null info in - assert_equal_boolean false may_be_null - ) + assert_equal_boolean false may_be_null) let test_is_caller_allocates _ = arg_test (fun info -> let caller_allocates = Arg_info.is_caller_allocates info in - assert_equal_boolean false caller_allocates - ) + assert_equal_boolean false caller_allocates) let test_is_optional _ = arg_test (fun info -> let is_optional = Arg_info.is_optional info in - assert_equal_boolean false is_optional - ) + assert_equal_boolean false is_optional) let test_is_return_value _ = arg_test (fun info -> let is_return = Arg_info.is_return_value info in - assert_equal_boolean false is_return - ) + assert_equal_boolean false is_return) let test_is_skip _ = arg_test (fun info -> let is_skip = Arg_info.is_skip info in - assert_equal_boolean false is_skip - ) + assert_equal_boolean false is_skip) let test_get_scope _ = arg_test (fun info -> let scope = Arg_info.get_scope info in - assert_equal ~printer:(fun scope -> + assert_equal + ~printer:(fun scope -> match scope with | Bindings.Arg_info.Invalid -> "Invalid" | Bindings.Arg_info.Call -> "Call" | Bindings.Arg_info.Async -> "Async" - | Bindings.Arg_info.Notified -> "Notified" - ) Bindings.Arg_info.Invalid scope - ) + | Bindings.Arg_info.Notified -> "Notified") + Bindings.Arg_info.Invalid scope) let test_get_type _ = arg_test (fun info -> - let type_info = Arg_info.get_type info in - let type_name = Type_info.to_string type_info in - assert_equal_string "unknown" type_name - ) + let type_info = Arg_info.get_type info in + let type_name = Type_info.to_string type_info in + assert_equal_string "unknown" type_name) let tests = - "GObject Introspection ArgInfo tests" >::: - [ - "Arg_info get direction" >:: test_get_direction; - "Arg_info get closure" >:: test_get_closure; - "Arg_info get destroy" >:: test_get_destroy; - "Arg_info get ownership transfer" >:: test_get_ownership_transfer; - "Arg_info may be null" >:: test_may_be_null; - "Arg_info is caller allocates" >:: test_is_caller_allocates; - "Arg_info is optional" >:: test_is_optional; - "Arg_info is return value" >:: test_is_return_value; - "Arg_info is skip" >:: test_is_skip; - "Arg_info get scope" >:: test_get_scope; - "Arg_info get type" >:: test_get_type - ] + "GObject Introspection ArgInfo tests" + >::: [ + "Arg_info get direction" >:: test_get_direction; + "Arg_info get closure" >:: test_get_closure; + "Arg_info get destroy" >:: test_get_destroy; + "Arg_info get ownership transfer" >:: test_get_ownership_transfer; + "Arg_info may be null" >:: test_may_be_null; + "Arg_info is caller allocates" >:: test_is_caller_allocates; + "Arg_info is optional" >:: test_is_optional; + "Arg_info is return value" >:: test_is_return_value; + "Arg_info is skip" >:: test_is_skip; + "Arg_info get scope" >:: test_get_scope; + "Arg_info get type" >:: test_get_type; + ] diff --git a/tests/Test_base_info.ml b/tests/Test_base_info.ml index e72cc06..9b3828e 100644 --- a/tests/Test_base_info.ml +++ b/tests/Test_base_info.ml @@ -29,38 +29,41 @@ let test_equal _ = let rand_info = Repository.get_info namespace 10 in match Base_info.get_name rand_info with | None -> assert_equal_string "Base Info " "has no name" - | Some info_name -> - match Repository.find_by_name namespace info_name with - | None -> assert_equal_string info_name "No base info found" - | Some (info) -> let is_equal = Base_info.equal rand_info info in - assert_equal_boolean true is_equal + | Some info_name -> ( + match Repository.find_by_name namespace info_name with + | None -> assert_equal_string info_name "No base info found" + | Some info -> + let is_equal = Base_info.equal rand_info info in + assert_equal_boolean true is_equal) let test_get_namespace _ = match Repository.find_by_name namespace info_name with | None -> assert_equal_string info_name "No base info found" - | Some (base_info) -> let info_namespace = Base_info.get_namespace base_info - in assert_equal_string namespace info_namespace + | Some base_info -> + let info_namespace = Base_info.get_namespace base_info in + assert_equal_string namespace info_namespace let test_is_deprecated _ = - match Repository.find_by_name namespace info_name with + match Repository.find_by_name namespace info_name with | None -> assert_equal_string info_name "No base info found" - | Some (base_info) -> let is_deprecated = Base_info.is_deprecated base_info in - assert_equal_boolean false is_deprecated + | Some base_info -> + let is_deprecated = Base_info.is_deprecated base_info in + assert_equal_boolean false is_deprecated let test_get_container _ = - match Repository.find_by_name namespace info_name with + match Repository.find_by_name namespace info_name with | None -> assert_equal_string info_name "No base info found" | Some base_info -> ( match Base_info.get_container base_info with - | None -> assert_equal_boolean true true - | Some _ -> assert_equal_string "It should not " "return a container here" - ) + | None -> assert_equal_boolean true true + | Some _ -> assert_equal_string "It should not " "return a container here" + ) let tests = - "GObject Introspection BaseInfo tests" >::: - [ - "Base_info equal" >:: test_equal; - "Base_info get namespace" >:: test_get_namespace; - "Base_info is deprecated" >:: test_is_deprecated; - "Base_info get_container" >:: test_get_container - ] + "GObject Introspection BaseInfo tests" + >::: [ + "Base_info equal" >:: test_equal; + "Base_info get namespace" >:: test_get_namespace; + "Base_info is deprecated" >:: test_is_deprecated; + "Base_info get_container" >:: test_get_container; + ] diff --git a/tests/Test_callable_info.ml b/tests/Test_callable_info.ml index a572fca..48c74d4 100644 --- a/tests/Test_callable_info.ml +++ b/tests/Test_callable_info.ml @@ -27,73 +27,69 @@ let func_name = "signal_name" let get_callable_info () = match Repository.find_by_name namespace func_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Function -> let info = Callable_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Function -> + let info = Callable_info.from_baseinfo base_info in + Some info + | _ -> None) let callable_test fn = match get_callable_info () with | None -> assert_equal_string func_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_can_throw_gerror _ = callable_test (fun info -> let throw_error = Callable_info.can_throw_gerror info in - assert_equal_boolean false throw_error - ) + assert_equal_boolean false throw_error) let test_get_n_args _ = callable_test (fun info -> let n = Callable_info.get_n_args info in - assert_equal_int 1 n - ) + assert_equal_int 1 n) let test_get_return_attribute _ = callable_test (fun info -> match Callable_info.get_return_attribute info with | None -> assert_equal_boolean true true - | Some attribute -> assert_equal_string "This should not return a string" attribute - ) + | Some attribute -> + assert_equal_string "This should not return a string" attribute) let test_is_method _ = callable_test (fun info -> let is_method = Callable_info.is_method info in - assert_equal_boolean false is_method - ) + assert_equal_boolean false is_method) let test_may_return_null _ = callable_test (fun info -> let may_return_null = Callable_info.may_return_null info in - assert_equal_boolean false may_return_null - ) + assert_equal_boolean false may_return_null) let test_skip_return _ = callable_test (fun info -> let skip_return = Callable_info.skip_return info in - assert_equal_boolean false skip_return - ) + assert_equal_boolean false skip_return) let test_get_caller_owns _ = callable_test (fun info -> let transfer = Callable_info.get_caller_owns info in - assert_equal ~printer:(fun t -> + assert_equal + ~printer:(fun t -> match t with | Bindings.Arg_info.Nothing -> "nothing" | Bindings.Arg_info.Container -> "container" - | Bindings.Arg_info.Everything -> "everything" - ) Bindings.Arg_info.Nothing transfer - ) + | Bindings.Arg_info.Everything -> "everything") + Bindings.Arg_info.Nothing transfer) let tests = - "GObject Introspection CallableInfo tests" >::: - [ - "Callable_info can throw gerror" >:: test_can_throw_gerror; - "Callable_info get n args" >:: test_get_n_args; - "Callable_info get return attribute" >:: test_get_return_attribute; - "Callable_info is method" >:: test_is_method; - "Callable_info may return null" >:: test_may_return_null; - "Callable_info skip return" >:: test_skip_return; - "Callable_info get caller owns" >:: test_get_caller_owns - ] + "GObject Introspection CallableInfo tests" + >::: [ + "Callable_info can throw gerror" >:: test_can_throw_gerror; + "Callable_info get n args" >:: test_get_n_args; + "Callable_info get return attribute" >:: test_get_return_attribute; + "Callable_info is method" >:: test_is_method; + "Callable_info may return null" >:: test_may_return_null; + "Callable_info skip return" >:: test_skip_return; + "Callable_info get caller owns" >:: test_get_caller_owns; + ] diff --git a/tests/Test_constant_info.ml b/tests/Test_constant_info.ml index e4ec39b..f9ad001 100644 --- a/tests/Test_constant_info.ml +++ b/tests/Test_constant_info.ml @@ -28,41 +28,41 @@ let const_name = "SIGNAL_FLAGS_MASK" let get_constant_info () = match Repository.find_by_name namespace const_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Constant -> let const_info = Constant_info.from_baseinfo base_info in - Some const_info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Constant -> + let const_info = Constant_info.from_baseinfo base_info in + Some const_info + | _ -> None) let constant_test fn = match get_constant_info () with | None -> assert_equal_string const_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type _ = constant_test (fun info -> let type_info = Constant_info.get_type info in let str = Type_info.to_string type_info in - assert_equal_string "unknown" str ; + assert_equal_string "unknown" str; let tag = Type_info.get_tag type_info in - assert_equal ~printer:(fun tag -> - Bindings.Types.string_of_tag tag - ) Bindings.Types.Int32 tag - ) + assert_equal + ~printer:(fun tag -> Bindings.Types.string_of_tag tag) + Bindings.Types.Int32 tag) let test_get_value _ = constant_test (fun info -> let type_info = Constant_info.get_type info in match Type_info.get_tag type_info with - | Bindings.Types.Int32 -> let argument = Constant_info.get_value info in - let value = getf (!@argument) Types.v_int32 in - assert_equal_int 511 (Int32.to_int value) - | _ -> assert_equal_string "The tag should be " "Int32" - ) + | Bindings.Types.Int32 -> + let argument = Constant_info.get_value info in + let value = getf !@argument Types.v_int32 in + assert_equal_int 511 (Int32.to_int value) + | _ -> assert_equal_string "The tag should be " "Int32") let tests = - "GObject Introspection ConstantInfo tests" >::: - [ - "Constant_info get type" >:: test_get_type; - "Constant_info get value" >:: test_get_value - ] + "GObject Introspection ConstantInfo tests" + >::: [ + "Constant_info get type" >:: test_get_type; + "Constant_info get value" >:: test_get_value; + ] diff --git a/tests/Test_enum_info.ml b/tests/Test_enum_info.ml index b608939..ee8bfd0 100644 --- a/tests/Test_enum_info.ml +++ b/tests/Test_enum_info.ml @@ -27,69 +27,66 @@ let enum_name = "ResourceError" let get_enum_info () = match Repository.find_by_name namespace enum_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Enum -> let info = Enum_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Enum -> + let info = Enum_info.from_baseinfo base_info in + Some info + | _ -> None) let enum_test fn = match get_enum_info () with | None -> assert_equal_string enum_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_n_values _ = enum_test (fun info -> let n_values = Enum_info.get_n_values info in - assert_equal_int 2 n_values - ) + assert_equal_int 2 n_values) let test_get_n_methods _ = enum_test (fun info -> let n_methods = Enum_info.get_n_methods info in - assert_equal_int 1 n_methods - ) + assert_equal_int 1 n_methods) let test_get_method _ = enum_test (fun info -> let m = Enum_info.get_method info 0 in let name = Function_info.get_symbol m in - assert_equal_string "g_resource_error_quark" name - ) + assert_equal_string "g_resource_error_quark" name) let test_get_value _ = enum_test (fun info -> match Enum_info.get_value info 1 with | None -> assert_equal_string "No value " "found" - | Some value -> let value' = Value_info.get_value value in - let _ = assert_equal 1 (Int64.to_int value') in - let base = Value_info.to_baseinfo value in - match Base_info.get_name base with - | None -> () - | Some name -> assert_equal_string "internal" name - ) + | Some value -> ( + let value' = Value_info.get_value value in + let _ = assert_equal 1 (Int64.to_int value') in + let base = Value_info.to_baseinfo value in + match Base_info.get_name base with + | None -> () + | Some name -> assert_equal_string "internal" name)) let test_get_error_domain _ = enum_test (fun info -> match Enum_info.get_error_domain info with | None -> assert_equal_boolean true false - | Some error_domain -> assert_equal_string "g-resource-error-quark" error_domain - ) + | Some error_domain -> + assert_equal_string "g-resource-error-quark" error_domain) let test_get_storage_type _ = enum_test (fun info -> match Enum_info.get_storage_type info with | Bindings.Types.Uint32 -> assert_equal true true - | _ -> assert_equal_string "bad " "type" - ) + | _ -> assert_equal_string "bad " "type") let tests = - "GObject Introspection Enum_info tests" >::: - [ - "Enum_info get n values" >:: test_get_n_values; - "Enum_info get n methods" >:: test_get_n_methods; - "Enum_info get method" >:: test_get_method; - "Enum_info get value" >:: test_get_value; - "Enum_info get error domain" >:: test_get_error_domain; - "Enum_info get storage type" >:: test_get_storage_type - ] + "GObject Introspection Enum_info tests" + >::: [ + "Enum_info get n values" >:: test_get_n_values; + "Enum_info get n methods" >:: test_get_n_methods; + "Enum_info get method" >:: test_get_method; + "Enum_info get value" >:: test_get_value; + "Enum_info get error domain" >:: test_get_error_domain; + "Enum_info get storage type" >:: test_get_storage_type; + ] diff --git a/tests/Test_field_info.ml b/tests/Test_field_info.ml index fa0a253..7171431 100644 --- a/tests/Test_field_info.ml +++ b/tests/Test_field_info.ml @@ -27,54 +27,57 @@ let union_name = "Mutex" let get_union_info () = match Repository.find_by_name namespace union_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Union -> let info = Union_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Union -> + let info = Union_info.from_baseinfo base_info in + Some info + | _ -> None) let field_test fn = match get_union_info () with | None -> assert_equal_string union_name "No base info found" - | Some (info) -> fn (Union_info.get_field info 0) + | Some info -> fn (Union_info.get_field info 0) let test_get_flags _ = field_test (fun info -> let flags = Field_info.get_flags info in let rec check_flags = function | [] -> () - | f' :: q -> let _ = assert_equal ~printer:(fun f -> - match f with - | Bindings.Field_info.Is_readable -> "readable" - | Bindings.Field_info.Is_writable -> "writable" - ) Bindings.Field_info.Is_readable f' in check_flags q - in check_flags flags - ) + | f' :: q -> + let _ = + assert_equal + ~printer:(fun f -> + match f with + | Bindings.Field_info.Is_readable -> "readable" + | Bindings.Field_info.Is_writable -> "writable") + Bindings.Field_info.Is_readable f' + in + check_flags q + in + check_flags flags) let test_get_offset _ = field_test (fun info -> let offset = Field_info.get_offset info in - assert_equal_int 0 offset - ) + assert_equal_int 0 offset) let test_get_size _ = field_test (fun info -> let size = Field_info.get_size info in - assert_equal_int 0 size - ) + assert_equal_int 0 size) let test_get_type _ = field_test (fun info -> let info_type = Field_info.get_type info in let type_name = Type_info.to_string info_type in - assert_equal_string "unknown" type_name - ) + assert_equal_string "unknown" type_name) let tests = - "GObject Introspection FieldInfo tests" >::: - [ - "Field_info get flags" >:: test_get_flags; - "Field_info get offset" >:: test_get_offset; - "Field_info get size" >:: test_get_size; - "Field_info get type" >:: test_get_type - ] + "GObject Introspection FieldInfo tests" + >::: [ + "Field_info get flags" >:: test_get_flags; + "Field_info get offset" >:: test_get_offset; + "Field_info get size" >:: test_get_size; + "Field_info get type" >:: test_get_type; + ] diff --git a/tests/Test_function_info.ml b/tests/Test_function_info.ml index 7d20df0..97163b8 100644 --- a/tests/Test_function_info.ml +++ b/tests/Test_function_info.ml @@ -21,12 +21,14 @@ open OUnit2 open GObject_introspection let get_function_info namespace name = - match Repository.find_by_name namespace name with + match Repository.find_by_name namespace name with | None -> None - | Some (base_info) -> match Base_info.get_type base_info with - | Function -> let info = Function_info.from_baseinfo base_info in - Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Function -> + let info = Function_info.from_baseinfo base_info in + Some info + | _ -> None) let test_function_info namespace name fn = match get_function_info namespace name with @@ -39,27 +41,23 @@ let name = "signal_name" let test_get_symbol _ = test_function_info namespace name (fun info -> - assert_equal "g_signal_name" (Function_info.get_symbol info) - ) + assert_equal "g_signal_name" (Function_info.get_symbol info)) let test_get_property _ = test_function_info namespace name (fun info -> match Function_info.get_property info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "returns something" - ) + | Some _ -> assert_equal_string "It should not " "returns something") let test_get_vfunc _ = test_function_info namespace name (fun info -> match Function_info.get_vfunc info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "returns something" - ) + | Some _ -> assert_equal_string "It should not " "returns something") let test_get_empty_flags _ = test_function_info namespace name (fun info -> - assert_equal [] (Function_info.get_flags info) - ) + assert_equal [] (Function_info.get_flags info)) let namespace = "Gio" let typelib = Repository.require namespace () @@ -68,27 +66,31 @@ let name = "File" let test_get_flags _ = match Repository.find_by_name namespace name with | None -> assert_equal_string "It should " "returns an object for Gio::File" - | Some (base_info) -> match Base_info.get_type base_info with - | Interface -> begin - let info = Interface_info.from_baseinfo base_info in - match Interface_info.find_method info "set_attribute" with - | Some info' -> - let flags = Function_info.get_flags info' in - let len = List.length flags in - assert_equal_int 2 len; - assert_bool "It is a method" (List.mem Bindings.Function_info.Is_method flags); - assert_bool "Throws" (List.mem Bindings.Function_info.Throws flags) - | None -> assert_equal_string "Gio::File#set_attribute" "should exists" - end - | baseinfo_t -> - assert_equal_string "Gio::File should be an Interface instead of " (Bindings.Base_info.string_of_info_type baseinfo_t) + | Some base_info -> ( + match Base_info.get_type base_info with + | Interface -> ( + let info = Interface_info.from_baseinfo base_info in + match Interface_info.find_method info "set_attribute" with + | Some info' -> + let flags = Function_info.get_flags info' in + let len = List.length flags in + assert_equal_int 2 len; + assert_bool "It is a method" + (List.mem Bindings.Function_info.Is_method flags); + assert_bool "Throws" + (List.mem Bindings.Function_info.Throws flags) + | None -> + assert_equal_string "Gio::File#set_attribute" "should exists") + | baseinfo_t -> + assert_equal_string "Gio::File should be an Interface instead of " + (Bindings.Base_info.string_of_info_type baseinfo_t)) let tests = - "GObject Introspection FunctionInfo tests" >::: - [ - "Function_info get symbol" >:: test_get_symbol; - "Function_info get property" >:: test_get_property; - "Function_info get vfunc" >:: test_get_vfunc; - "Function_info get empty flags" >:: test_get_empty_flags; - "Function_info get flags" >:: test_get_flags; - ] + "GObject Introspection FunctionInfo tests" + >::: [ + "Function_info get symbol" >:: test_get_symbol; + "Function_info get property" >:: test_get_property; + "Function_info get vfunc" >:: test_get_vfunc; + "Function_info get empty flags" >:: test_get_empty_flags; + "Function_info get flags" >:: test_get_flags; + ] diff --git a/tests/Test_interface_info.ml b/tests/Test_interface_info.ml index 87713ec..0fd9725 100644 --- a/tests/Test_interface_info.ml +++ b/tests/Test_interface_info.ml @@ -27,52 +27,47 @@ let interface_name = "TlsServerConnection" let get_interface_info interface_name = match Repository.find_by_name namespace interface_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Interface -> - let interface_info = Interface_info.from_baseinfo base_info in - Some interface_info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Interface -> + let interface_info = Interface_info.from_baseinfo base_info in + Some interface_info + | _ -> None) let interface_test fn = match get_interface_info interface_name with | None -> assert_equal_string interface_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_n_prerequisites _ = interface_test (fun info -> let n = Interface_info.get_n_prerequisites info in - assert_equal_int 1 n - ) + assert_equal_int 1 n) let test_get_prerequisite _ = interface_test (fun info -> let info' = Interface_info.get_prerequisite info 0 in match Base_info.get_name info' with | None -> assert_equal_string "It should have " " a name" - | Some name -> assert_equal_string "TlsConnection" name - ) + | Some name -> assert_equal_string "TlsConnection" name) let test_get_n_properties _ = interface_test (fun info -> let n = Interface_info.get_n_properties info in - assert_equal_int 1 n - ) + assert_equal_int 1 n) let test_get_property _ = -interface_test (fun info -> + interface_test (fun info -> let info' = Interface_info.get_property info 0 in let base_info = Property_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " " a name" - | Some name -> assert_equal_string "authentication-mode" name - ) + | Some name -> assert_equal_string "authentication-mode" name) let test_get_n_methods _ = interface_test (fun info -> let n = Interface_info.get_n_methods info in - assert_equal_int 1 n - ) + assert_equal_int 1 n) let test_get_method _ = interface_test (fun info -> @@ -80,8 +75,7 @@ let test_get_method _ = let base_info = Function_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " " a name" - | Some name -> assert_equal_string "new" name - ) + | Some name -> assert_equal_string "new" name) let test_find_method _ = interface_test (fun info -> @@ -89,22 +83,20 @@ let test_find_method _ = match Interface_info.find_method info method_name with | None -> assert_equal_string "It should " "return an info" | Some info' -> - let symbol = Function_info.get_symbol info' in - assert_equal_string ("g_tls_server_connection_"^ method_name) symbol - ) + let symbol = Function_info.get_symbol info' in + assert_equal_string ("g_tls_server_connection_" ^ method_name) symbol) let volume_interface = "Volume" let volume_interface_test fn = match get_interface_info volume_interface with | None -> assert_equal_string interface_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_n_signals _ = volume_interface_test (fun info -> let n = Interface_info.get_n_signals info in - assert_equal_int 2 n - ) + assert_equal_int 2 n) let test_get_signal _ = volume_interface_test (fun info -> @@ -112,41 +104,38 @@ let test_get_signal _ = let base_info = Signal_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "changed" name - ) + | Some name -> assert_equal_string "changed" name) let test_find_signal _ = volume_interface_test (fun info -> let signal_name = "changed" in match Interface_info.find_signal info signal_name with | None -> assert_equal_string interface_name "No base info found" - | Some info' -> let base_info = Signal_info.to_baseinfo info' in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string signal_name name - ) + | Some info' -> ( + let base_info = Signal_info.to_baseinfo info' in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string signal_name name)) let test_get_n_constants _ = volume_interface_test (fun info -> let n = Interface_info.get_n_constants info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_get_iface_struct _ = volume_interface_test (fun info -> match Interface_info.get_iface_struct info with | None -> assert_equal_string "It would be " "great to have something" - | Some struct_info -> let base_info = Struct_info.to_baseinfo struct_info in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "VolumeIface" name - ) + | Some struct_info -> ( + let base_info = Struct_info.to_baseinfo struct_info in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string "VolumeIface" name)) let test_get_n_vfuncs _ = volume_interface_test (fun info -> let n = Interface_info.get_n_vfuncs info in - assert_equal_int 21 n - ) + assert_equal_int 21 n) let test_get_vfunc _ = volume_interface_test (fun info -> @@ -154,36 +143,35 @@ let test_get_vfunc _ = let base_info = VFunc_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "can_eject" name - ) + | Some name -> assert_equal_string "can_eject" name) let test_find_vfunc _ = volume_interface_test (fun info -> let vfunc_name = "can_eject" in match Interface_info.find_vfunc info vfunc_name with | None -> assert_equal_string interface_name "No base info found" - | Some info' -> let base_info = VFunc_info.to_baseinfo info' in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string name vfunc_name - ) + | Some info' -> ( + let base_info = VFunc_info.to_baseinfo info' in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string name vfunc_name)) let tests = - "GObject Introspection InterfaceInfo tests" >::: - [ - "Interface_info get n prerequisites" >:: test_get_n_prerequisites; - "Interface_info get prerequisiste" >:: test_get_prerequisite; - "Interface_info get n properties" >:: test_get_n_properties; - "Interface_info get property" >:: test_get_property; - "Interface_info get n methods" >:: test_get_n_methods; - "Interface_info get method" >:: test_get_method; - "Interface_info find method" >:: test_find_method; - "Interface_info get n signals" >:: test_get_n_signals; - "Interface_info get signal" >:: test_get_signal; - "Interface_info find signal" >:: test_find_signal; - "Interface_info get n constants" >:: test_get_n_constants; - "Interface_info get iface struct" >:: test_get_iface_struct; - "Interface_info get n vfuncs" >:: test_get_n_vfuncs; - "Interface_info get vfunc" >:: test_get_vfunc; - "Interface_info find vfunc" >:: test_find_vfunc - ] + "GObject Introspection InterfaceInfo tests" + >::: [ + "Interface_info get n prerequisites" >:: test_get_n_prerequisites; + "Interface_info get prerequisiste" >:: test_get_prerequisite; + "Interface_info get n properties" >:: test_get_n_properties; + "Interface_info get property" >:: test_get_property; + "Interface_info get n methods" >:: test_get_n_methods; + "Interface_info get method" >:: test_get_method; + "Interface_info find method" >:: test_find_method; + "Interface_info get n signals" >:: test_get_n_signals; + "Interface_info get signal" >:: test_get_signal; + "Interface_info find signal" >:: test_find_signal; + "Interface_info get n constants" >:: test_get_n_constants; + "Interface_info get iface struct" >:: test_get_iface_struct; + "Interface_info get n vfuncs" >:: test_get_n_vfuncs; + "Interface_info get vfunc" >:: test_get_vfunc; + "Interface_info find vfunc" >:: test_find_vfunc; + ] diff --git a/tests/Test_object_info.ml b/tests/Test_object_info.ml index 0694dbd..83afb10 100644 --- a/tests/Test_object_info.ml +++ b/tests/Test_object_info.ml @@ -27,122 +27,109 @@ let object_name = "Display" let test_from_baseinfo _ = match Repository.find_by_name namespace object_name with | None -> assert_equal_string object_name "No base info found" - | Some (base_info) -> assert_equal_boolean true ( - match Base_info.get_type base_info with - | Object -> true - | _ -> false ) + | Some base_info -> + assert_equal_boolean true + (match Base_info.get_type base_info with Object -> true | _ -> false) let get_object_info () = match Repository.find_by_name namespace object_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> let object_info = Object_info.from_baseinfo base_info in - Some object_info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> + let object_info = Object_info.from_baseinfo base_info in + Some object_info + | _ -> None) let object_test fn = match get_object_info () with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_abstract _ = object_test (fun info -> let is_abstract = Object_info.get_abstract info in - assert_equal_boolean false is_abstract - ) + assert_equal_boolean false is_abstract) let test_get_fundamental _ = object_test (fun info -> let is_fundamental = Object_info.get_fundamental info in - assert_equal_boolean false is_fundamental - ) + assert_equal_boolean false is_fundamental) let test_get_parent _ = object_test (fun info -> let parent = Object_info.get_parent info in match Base_info.get_name parent with | None -> assert_equal_string "It should have " "a name" - | Some parent_name -> assert_equal_string "Object" parent_name - ) + | Some parent_name -> assert_equal_string "Object" parent_name) let test_get_type_name _ = object_test (fun info -> let type_name = Object_info.get_type_name info in - assert_equal_string "GdkDisplay" type_name - ) + assert_equal_string "GdkDisplay" type_name) let test_get_type_init _ = object_test (fun info -> let type_init = Object_info.get_type_init info in - assert_equal_string "gdk_display_get_type" type_init - ) + assert_equal_string "gdk_display_get_type" type_init) let test_get_n_constants _ = object_test (fun info -> let n = Object_info.get_n_constants info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_get_n_fields _ = object_test (fun info -> let n = Object_info.get_n_fields info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_get_n_interfaces _ = object_test (fun info -> let n = Object_info.get_n_interfaces info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_get_n_methods _ = object_test (fun info -> let n = Object_info.get_n_methods info in - assert_equal_boolean true (n > 0) - ) + assert_equal_boolean true (n > 0)) let test_get_method _ = object_test (fun info -> let m = Object_info.get_method info 0 in let m_name = Function_info.get_symbol m in - assert_equal_string "gdk_display_get_default" m_name - ) + assert_equal_string "gdk_display_get_default" m_name) let test_find_method _ = object_test (fun info -> let m_name = "get_default" in match Object_info.find_method info m_name with | None -> assert_equal_string "It should find " "a method" - | Some info' -> let symbol = Function_info.get_symbol info' in - assert_equal_string ("gdk_display_" ^ m_name) symbol - ) + | Some info' -> + let symbol = Function_info.get_symbol info' in + assert_equal_string ("gdk_display_" ^ m_name) symbol) let test_get_n_properties _ = object_test (fun info -> let n = Object_info.get_n_properties info in - assert_equal_boolean true (n >= 0) - ) + assert_equal_boolean true (n >= 0)) let test_get_n_signals _ = object_test (fun info -> let n = Object_info.get_n_signals info in - assert_equal_boolean true (n >= 2) - ) + assert_equal_boolean true (n >= 2)) let test_get_n_vfuncs _ = object_test (fun info -> let n = Object_info.get_n_vfuncs info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_get_class_struct _ = object_test (fun info -> match Object_info.get_class_struct info with | None -> assert_equal_boolean true true - | Some info' -> let is_struct = Struct_info.is_gtype_struct info' in - assert_equal_boolean true is_struct - ) + | Some info' -> + let is_struct = Struct_info.is_gtype_struct info' in + assert_equal_boolean true is_struct) let namespace = "Gtk" let _ = Repository.require namespace () @@ -151,111 +138,100 @@ let object_name = "Window" let test_gtk_window_from_baseinfo _ = match Repository.find_by_name namespace object_name with | None -> assert_equal_string object_name "No base info found" - | Some (base_info) -> assert_equal_boolean true ( - match Base_info.get_type base_info with - | Object -> true - | _ -> false ) + | Some base_info -> + assert_equal_boolean true + (match Base_info.get_type base_info with Object -> true | _ -> false) let get_object_info () = match Repository.find_by_name namespace object_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> let object_info = Object_info.from_baseinfo base_info in - Some object_info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> + let object_info = Object_info.from_baseinfo base_info in + Some object_info + | _ -> None) let object_test fn = match get_object_info () with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_gtk_window_get_abstract _ = object_test (fun info -> let is_abstract = Object_info.get_abstract info in - assert_equal_boolean false is_abstract - ) + assert_equal_boolean false is_abstract) let test_gtk_window_get_fundamental _ = object_test (fun info -> let is_fundamental = Object_info.get_fundamental info in - assert_equal_boolean false is_fundamental - ) + assert_equal_boolean false is_fundamental) let test_gtk_window_get_parent _ = object_test (fun info -> let parent = Object_info.get_parent info in match Base_info.get_name parent with | None -> assert_equal_string "It should have " "a name" - | Some parent_name -> assert_equal_string "Bin" parent_name - ) + | Some parent_name -> assert_equal_string "Bin" parent_name) let test_gtk_window_get_type_name _ = object_test (fun info -> let type_name = Object_info.get_type_name info in - assert_equal_string "GtkWindow" type_name - ) + assert_equal_string "GtkWindow" type_name) let test_gtk_window_get_type_init _ = object_test (fun info -> let type_init = Object_info.get_type_init info in - assert_equal_string "gtk_window_get_type" type_init - ) + assert_equal_string "gtk_window_get_type" type_init) let test_gtk_window_get_n_constants _ = object_test (fun info -> let n = Object_info.get_n_constants info in - assert_equal_int 0 n - ) + assert_equal_int 0 n) let test_gtk_window_get_n_fields _ = object_test (fun info -> let n = Object_info.get_n_fields info in - assert_equal_boolean true (n > 0) - ) + assert_equal_boolean true (n > 0)) let test_gtk_window_get_n_interfaces _ = object_test (fun info -> let n = Object_info.get_n_interfaces info in - assert_equal_int 2 n - ) + assert_equal_int 2 n) let test_gtk_window_get_interface _ = - object_test (fun info -> + object_test (fun info -> let info' = Object_info.get_interface info 0 in let base_info' = Interface_info.to_baseinfo info' in match Base_info.get_name base_info' with | None -> assert_equal_string "It should have" " a name" - | Some interface_name -> assert_equal_string "ImplementorIface" interface_name - ) + | Some interface_name -> + assert_equal_string "ImplementorIface" interface_name) let test_gtk_window_get_n_methods _ = object_test (fun info -> let n = Object_info.get_n_methods info in - assert_equal_boolean true (n > 0) - ) + assert_equal_boolean true (n > 0)) let test_gtk_window_get_method _ = object_test (fun info -> let m = Object_info.get_method info 0 in let m_name = Function_info.get_symbol m in - assert_equal_string "gtk_window_new" m_name - ) + assert_equal_string "gtk_window_new" m_name) let test_gtk_window_find_method _ = object_test (fun info -> let m_name = "new" in match Object_info.find_method info m_name with | None -> assert_equal_string "It should find " "a method" - | Some info' -> let symbol = Function_info.get_symbol info' in - assert_equal_string ("gtk_window_" ^ m_name) symbol - ) + | Some info' -> + let symbol = Function_info.get_symbol info' in + assert_equal_string ("gtk_window_" ^ m_name) symbol) let test_gtk_window_get_n_properties _ = object_test (fun info -> let n = Object_info.get_n_properties info in - assert_equal_boolean true (n > 0) - ) + assert_equal_boolean true (n > 0)) let test_gtk_window_get_property _ = object_test (fun info -> @@ -263,14 +239,12 @@ let test_gtk_window_get_property _ = let base_prop = Property_info.to_baseinfo prop in match Base_info.get_name base_prop with | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "accept-focus" name - ) + | Some name -> assert_equal_string "accept-focus" name) let test_gtk_window_get_n_signals _ = object_test (fun info -> let n = Object_info.get_n_signals info in - assert_equal_boolean true (n >= 4) - ) + assert_equal_boolean true (n >= 4)) let test_gtk_window_get_signal _ = object_test (fun info -> @@ -278,25 +252,23 @@ let test_gtk_window_get_signal _ = let base_info = Signal_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "activate-default" name - ) + | Some name -> assert_equal_string "activate-default" name) let test_gtk_window_find_signal _ = object_test (fun info -> let signal_name = "activate-default" in match Object_info.find_signal info signal_name with | None -> assert_equal_string "It should have" " a signal" - | Some info' -> let base_info = Signal_info.to_baseinfo info' in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string signal_name name - ) + | Some info' -> ( + let base_info = Signal_info.to_baseinfo info' in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string signal_name name)) let test_gtk_window_get_n_vfuncs _ = object_test (fun info -> let n = Object_info.get_n_vfuncs info in - assert_equal_boolean true (n >= 4) - ) + assert_equal_boolean true (n >= 4)) let test_gtk_window_get_vfunc _ = object_test (fun info -> @@ -304,142 +276,153 @@ let test_gtk_window_get_vfunc _ = let base_info = VFunc_info.to_baseinfo info' in match Base_info.get_name base_info with | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string "activate_default" name - ) + | Some name -> assert_equal_string "activate_default" name) let test_gtk_window_find_vfunc _ = object_test (fun info -> let vfunc_name = "activate_default" in match Object_info.find_vfunc info vfunc_name with | None -> assert_equal_string object_name "No base info found" - | Some info' -> let base_info = VFunc_info.to_baseinfo info' in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string name vfunc_name - ) + | Some info' -> ( + let base_info = VFunc_info.to_baseinfo info' in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string name vfunc_name)) let test_gtk_window_find_vfunc_using_interfaces _ = object_test (fun info -> let vfunc_name = "activate_default" in - let (vfunc, implementor) = - Object_info.find_vfunc_using_interfaces info vfunc_name in - let _ = ( match implementor with - | None -> assert_equal true true - | Some info_implementor -> + let vfunc, implementor = + Object_info.find_vfunc_using_interfaces info vfunc_name + in + let _ = + match implementor with + | None -> assert_equal true true + | Some info_implementor -> ( let base_info = Object_info.to_baseinfo info_implementor in match Base_info.get_name base_info with | None -> assert_equal_string "It should " "have a name" - | Some name -> assert_equal_string "Window" name - ) - in match vfunc with + | Some name -> assert_equal_string "Window" name) + in + match vfunc with | None -> assert_equal_string "It should return " " a function info" - | Some info' -> let base_info = VFunc_info.to_baseinfo info' in - match Base_info.get_name base_info with - | None -> assert_equal_string "It should have " "a name" - | Some name -> assert_equal_string name vfunc_name - ) - + | Some info' -> ( + let base_info = VFunc_info.to_baseinfo info' in + match Base_info.get_name base_info with + | None -> assert_equal_string "It should have " "a name" + | Some name -> assert_equal_string name vfunc_name)) let test_gtk_window_get_class_struct _ = object_test (fun info -> match Object_info.get_class_struct info with | None -> assert_equal_boolean false true - | Some info' -> let is_struct = Struct_info.is_gtype_struct info' in - assert_equal_boolean true is_struct - ) + | Some info' -> + let is_struct = Struct_info.is_gtype_struct info' in + assert_equal_boolean true is_struct) let test_gtk_window_find_method_using_interfaces _ = object_test (fun info -> let method_name = "set_title" in - let (meth, implementor) = - Object_info.find_method_using_interfaces info method_name in - let _ = ( match implementor with - | None -> assert_equal true true - | Some info_implementor -> + let meth, implementor = + Object_info.find_method_using_interfaces info method_name + in + let _ = + match implementor with + | None -> assert_equal true true + | Some info_implementor -> ( let base_info = Object_info.to_baseinfo info_implementor in match Base_info.get_name base_info with | None -> assert_equal_string "It should " "have a name" - | Some name -> assert_equal_string "Window" name - ) - in match meth with + | Some name -> assert_equal_string "Window" name) + in + match meth with | None -> assert_equal_string "It should return " " a function info" - | Some info' -> let symbol = Function_info.get_symbol info' in - assert_equal_string ("gtk_window_" ^ method_name) symbol - ) + | Some info' -> + let symbol = Function_info.get_symbol info' in + assert_equal_string ("gtk_window_" ^ method_name) symbol) let test_gtk_window_get_ref_function _ = object_test (fun info -> match Object_info.get_ref_function info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "have any ref function" - ) + | Some _ -> assert_equal_string "It should not " "have any ref function") let test_gtk_window_get_unref_function _ = object_test (fun info -> match Object_info.get_unref_function info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "have any ref function" - ) + | Some _ -> assert_equal_string "It should not " "have any ref function") let test_gtk_window_get_set_value_function _ = object_test (fun info -> match Object_info.get_set_value_function info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "have any set value function" - ) + | Some _ -> + assert_equal_string "It should not " "have any set value function") let test_gtk_window_get_get_value_function _ = object_test (fun info -> match Object_info.get_get_value_function info with | None -> assert_equal true true - | Some _ -> assert_equal_string "It should not " "have any set value function" - ) + | Some _ -> + assert_equal_string "It should not " "have any set value function") let tests = - "GObject Introspection ObjectInfo tests" >::: - [ - "Object_info from baseinfo" >:: test_from_baseinfo; - "Object_info get abstract" >:: test_get_abstract; - "Object_info get fundamental" >:: test_get_fundamental; - "Object_info get parent" >:: test_get_parent; - "Object_info get type name" >:: test_get_type_name; - "Object_info get type init" >:: test_get_type_init; - "Object_info get n constants" >:: test_get_n_constants; - "Object_info get n fields" >:: test_get_n_fields; - "Object_info get n interfaces" >:: test_get_n_interfaces; - "Object_info get n methods" >:: test_get_n_methods; - "Object_info get method" >:: test_get_method; - "Object_info find method" >:: test_find_method; - "Object_info get n properties" >:: test_get_n_properties; - "Object_info get n signals" >:: test_get_n_signals; - "Object_info GtkWindow get n vfuncs" >:: test_get_n_vfuncs; - "Object_info GtkWindow get class struct" >:: test_get_class_struct; - "Object_info GtkWindow from baseinfo" >:: test_gtk_window_from_baseinfo; - "Object_info GtkWindow get abstract" >:: test_gtk_window_get_abstract; - "Object_info GtkWindow get fundamental" >:: test_gtk_window_get_fundamental; - "Object_info GtkWindow get parent" >:: test_gtk_window_get_parent; - "Object_info GtkWindow get type name" >:: test_gtk_window_get_type_name; - "Object_info GtkWindow get type init" >:: test_gtk_window_get_type_init; - "Object_info GtkWindow get n constants" >:: test_gtk_window_get_n_constants; - "Object_info GtkWindow get n fields" >:: test_gtk_window_get_n_fields; - "Object_info GtkWindow get n interfaces" >:: test_gtk_window_get_n_interfaces; - "Object_info GtkWindow get interface" >:: test_gtk_window_get_interface; - "Object_info GtkWindow get n methods" >:: test_gtk_window_get_n_methods; - "Object_info GtkWindow get method" >:: test_gtk_window_get_method; - "Object_info GtkWindow find method" >:: test_gtk_window_find_method; - "Object_info GtkWindow get n properties" >:: test_gtk_window_get_n_properties; - "Object_info GtkWindow get n signals" >:: test_gtk_window_get_n_signals; - "Object_info GtkWindow get signal" >:: test_gtk_window_get_signal; - "Object_info GtkWindow find signal" >:: test_gtk_window_find_signal; - "Object_info GtkWindow get n vfuncs" >:: test_gtk_window_get_n_vfuncs; - "Object_info GtkWindow get vfunc" >:: test_gtk_window_get_vfunc; - "Object_info GtkWindow find vfunc" >:: test_gtk_window_find_vfunc; - "Object_info GtkWindow find vfunc using interfaces" >:: test_gtk_window_find_vfunc_using_interfaces; - "Object_info GtkWindow get class struct" >:: test_gtk_window_get_class_struct; - "Object_info GtkWindow get property" >:: test_gtk_window_get_property; - "Object_info GtkWindow find method using interfaces" >:: test_gtk_window_find_method_using_interfaces; - "Object_info GtkWindow get ref function" >:: test_gtk_window_get_ref_function; - "Object_info GtkWindow get unref function" >:: test_gtk_window_get_unref_function; - "Object_info GtkWindow get set value function" >:: test_gtk_window_get_set_value_function; - "Object_info GtkWindow get get value function" >:: test_gtk_window_get_get_value_function - ] + "GObject Introspection ObjectInfo tests" + >::: [ + "Object_info from baseinfo" >:: test_from_baseinfo; + "Object_info get abstract" >:: test_get_abstract; + "Object_info get fundamental" >:: test_get_fundamental; + "Object_info get parent" >:: test_get_parent; + "Object_info get type name" >:: test_get_type_name; + "Object_info get type init" >:: test_get_type_init; + "Object_info get n constants" >:: test_get_n_constants; + "Object_info get n fields" >:: test_get_n_fields; + "Object_info get n interfaces" >:: test_get_n_interfaces; + "Object_info get n methods" >:: test_get_n_methods; + "Object_info get method" >:: test_get_method; + "Object_info find method" >:: test_find_method; + "Object_info get n properties" >:: test_get_n_properties; + "Object_info get n signals" >:: test_get_n_signals; + "Object_info GtkWindow get n vfuncs" >:: test_get_n_vfuncs; + "Object_info GtkWindow get class struct" >:: test_get_class_struct; + "Object_info GtkWindow from baseinfo" >:: test_gtk_window_from_baseinfo; + "Object_info GtkWindow get abstract" >:: test_gtk_window_get_abstract; + "Object_info GtkWindow get fundamental" + >:: test_gtk_window_get_fundamental; + "Object_info GtkWindow get parent" >:: test_gtk_window_get_parent; + "Object_info GtkWindow get type name" >:: test_gtk_window_get_type_name; + "Object_info GtkWindow get type init" >:: test_gtk_window_get_type_init; + "Object_info GtkWindow get n constants" + >:: test_gtk_window_get_n_constants; + "Object_info GtkWindow get n fields" >:: test_gtk_window_get_n_fields; + "Object_info GtkWindow get n interfaces" + >:: test_gtk_window_get_n_interfaces; + "Object_info GtkWindow get interface" >:: test_gtk_window_get_interface; + "Object_info GtkWindow get n methods" >:: test_gtk_window_get_n_methods; + "Object_info GtkWindow get method" >:: test_gtk_window_get_method; + "Object_info GtkWindow find method" >:: test_gtk_window_find_method; + "Object_info GtkWindow get n properties" + >:: test_gtk_window_get_n_properties; + "Object_info GtkWindow get n signals" >:: test_gtk_window_get_n_signals; + "Object_info GtkWindow get signal" >:: test_gtk_window_get_signal; + "Object_info GtkWindow find signal" >:: test_gtk_window_find_signal; + "Object_info GtkWindow get n vfuncs" >:: test_gtk_window_get_n_vfuncs; + "Object_info GtkWindow get vfunc" >:: test_gtk_window_get_vfunc; + "Object_info GtkWindow find vfunc" >:: test_gtk_window_find_vfunc; + "Object_info GtkWindow find vfunc using interfaces" + >:: test_gtk_window_find_vfunc_using_interfaces; + "Object_info GtkWindow get class struct" + >:: test_gtk_window_get_class_struct; + "Object_info GtkWindow get property" >:: test_gtk_window_get_property; + "Object_info GtkWindow find method using interfaces" + >:: test_gtk_window_find_method_using_interfaces; + "Object_info GtkWindow get ref function" + >:: test_gtk_window_get_ref_function; + "Object_info GtkWindow get unref function" + >:: test_gtk_window_get_unref_function; + "Object_info GtkWindow get set value function" + >:: test_gtk_window_get_set_value_function; + "Object_info GtkWindow get get value function" + >:: test_gtk_window_get_get_value_function; + ] diff --git a/tests/Test_property_info.ml b/tests/Test_property_info.ml index b1f1f97..c3282f0 100644 --- a/tests/Test_property_info.ml +++ b/tests/Test_property_info.ml @@ -27,72 +27,80 @@ let property_name = "accept-focus" let test_get_property_from_repo _ = match Repository.find_by_name namespace "Window" with | None -> assert_equal_string property_name "No base info found" - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> ( - let info = Object_info.from_baseinfo base_info in - let prop = Object_info.get_property info 0 in - let base_prop = Property_info.to_baseinfo prop in - match Base_info.get_type base_prop with - | Property -> assert_equal true true - | _ -> assert_equal_string "It should be a" "Property info" - ) - | _ -> assert_equal_string property_name "No base info found" + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> ( + let info = Object_info.from_baseinfo base_info in + let prop = Object_info.get_property info 0 in + let base_prop = Property_info.to_baseinfo prop in + match Base_info.get_type base_prop with + | Property -> assert_equal true true + | _ -> assert_equal_string "It should be a" "Property info") + | _ -> assert_equal_string property_name "No base info found") let get_property_info () = match Repository.find_by_name namespace "Window" with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> let info = Object_info.from_baseinfo base_info in - let prop = Object_info.get_property info 0 in - Some prop - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> + let info = Object_info.from_baseinfo base_info in + let prop = Object_info.get_property info 0 in + Some prop + | _ -> None) let property_test fn = match get_property_info () with | None -> assert_equal_string property_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_ownership_transfer _ = property_test (fun info -> let transfer = Property_info.get_ownership_transfer info in - assert_equal ~printer:(fun t -> + assert_equal + ~printer:(fun t -> match t with | Bindings.Arg_info.Nothing -> "nothing" | Bindings.Arg_info.Container -> "container" - | Bindings.Arg_info.Everything -> "everything" - ) Bindings.Arg_info.Nothing transfer - ) + | Bindings.Arg_info.Everything -> "everything") + Bindings.Arg_info.Nothing transfer) let test_get_type _ = property_test (fun info -> let info = Property_info.get_type info in let type_name = Type_info.to_string info in - assert_equal_string "unknown" type_name - ) + assert_equal_string "unknown" type_name) let test_get_flags _ = property_test (fun info -> let flags = Property_info.get_flags info in let n = List.length flags in let _ = assert_equal ~printer:string_of_int 3 n in - let flag_names = [ - Bindings.GParam.Readwrite; - Bindings.GParam.Writable; - Bindings.GParam.Readable] in - let _ = List.fold_left (fun acc flag -> - let _ = assert_equal ~printer:(fun f -> GParam.flag_to_string f) (List.nth flag_names acc) flag in - acc + 1 - ) 0 flags - in () - ) + let flag_names = + [ + Bindings.GParam.Readwrite; + Bindings.GParam.Writable; + Bindings.GParam.Readable; + ] + in + let _ = + List.fold_left + (fun acc flag -> + let _ = + assert_equal + ~printer:(fun f -> GParam.flag_to_string f) + (List.nth flag_names acc) flag + in + acc + 1) + 0 flags + in + ()) let tests = - "GObject Introspection InterfaceInfo tests" >::: - [ - "Property_info find from repo" >:: test_get_property_from_repo; - "Property_info get ownership transfer" >:: test_get_ownership_transfer; - "Property_info get type" >:: test_get_type; - "Property_info get flags" >:: test_get_flags - ] + "GObject Introspection InterfaceInfo tests" + >::: [ + "Property_info find from repo" >:: test_get_property_from_repo; + "Property_info get ownership transfer" >:: test_get_ownership_transfer; + "Property_info get type" >:: test_get_type; + "Property_info get flags" >:: test_get_flags; + ] diff --git a/tests/Test_registered_type_info.ml b/tests/Test_registered_type_info.ml index 725a4ba..eb59ddb 100644 --- a/tests/Test_registered_type_info.ml +++ b/tests/Test_registered_type_info.ml @@ -24,167 +24,172 @@ let get_enum_info namespace enum_name = let _ = Repository.require namespace () in match Repository.find_by_name namespace enum_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Enum -> let info = Enum_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Enum -> + let info = Enum_info.from_baseinfo base_info in + Some info + | _ -> None) let enum_test fn = let namespace = "Gio" in let enum_name = "ResourceError" in match get_enum_info namespace enum_name with | None -> assert_equal_string enum_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type_name_from_enum _ = enum_test (fun info -> let registered = Enum_info.to_registeredtypeinfo info in - match Registered_type_info.get_type_name registered with + match Registered_type_info.get_type_name registered with | None -> assert_equal_string "It should return " "a name" - | Some name -> assert_equal_string "GResourceError" name - ) + | Some name -> assert_equal_string "GResourceError" name) let get_interface_info namespace interface_name = let _ = Repository.require namespace () in match Repository.find_by_name namespace interface_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Interface -> let info = Interface_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Interface -> + let info = Interface_info.from_baseinfo base_info in + Some info + | _ -> None) let interface_test fn = let namespace = "Gio" in let interface_name = "TlsServerConnection" in match get_interface_info namespace interface_name with | None -> assert_equal_string interface_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type_name_from_interface _ = interface_test (fun info -> let registered = Interface_info.to_registeredtypeinfo info in - match Registered_type_info.get_type_name registered with + match Registered_type_info.get_type_name registered with | None -> assert_equal_string "It should return " "a name" - | Some name -> assert_equal_string "GTlsServerConnection" name - ) + | Some name -> assert_equal_string "GTlsServerConnection" name) let get_object_info namespace object_name = let _ = Repository.require namespace () in match Repository.find_by_name namespace object_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> let info = Object_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> + let info = Object_info.from_baseinfo base_info in + Some info + | _ -> None) let object_test fn = let namespace = "Gdk" in let object_name = "Display" in match get_object_info namespace object_name with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type_name_from_object _ = object_test (fun info -> let registered = Object_info.to_registeredtypeinfo info in - match Registered_type_info.get_type_name registered with + match Registered_type_info.get_type_name registered with | None -> assert_equal_string "It should return " "a name" - | Some name -> assert_equal_string "GdkDisplay" name - ) + | Some name -> assert_equal_string "GdkDisplay" name) let get_struct_info namespace struct_name = let _ = Repository.require namespace () in match Repository.find_by_name namespace struct_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Struct -> let info = Struct_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Struct -> + let info = Struct_info.from_baseinfo base_info in + Some info + | _ -> None) let struct_test fn = let namespace = "GObject" in let struct_name = "Value" in match get_struct_info namespace struct_name with | None -> assert_equal_string struct_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type_name_from_struct _ = struct_test (fun info -> let registered = Struct_info.to_registeredtypeinfo info in - match Registered_type_info.get_type_name registered with + match Registered_type_info.get_type_name registered with | None -> assert_equal_string "It should return " "a name" - | Some name -> assert_equal_string "GValue" name - ) + | Some name -> assert_equal_string "GValue" name) let get_union_info namespace union_name = let _ = Repository.require namespace () in match Repository.find_by_name namespace union_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Union -> let info = Union_info.from_baseinfo base_info - in Some info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Union -> + let info = Union_info.from_baseinfo base_info in + Some info + | _ -> None) let union_test fn = let namespace = "GLib" in let union_name = "Mutex" in match get_union_info namespace union_name with | None -> assert_equal_string union_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_type_name_from_union _ = union_test (fun info -> let registered = Union_info.to_registeredtypeinfo info in - match Registered_type_info.get_type_name registered with + match Registered_type_info.get_type_name registered with | None -> assert_equal_string "No type name" "No type name" - | Some name -> assert_equal_string "Mutex" name - ) + | Some name -> assert_equal_string "Mutex" name) let test_get_type_from_enum _ = enum_test (fun info -> let registered = Enum_info.to_registeredtypeinfo info in - match Registered_type_info.get_g_type registered with + match Registered_type_info.get_g_type registered with | None -> assert_equal_string "It should return " "a type" - | Some gtype -> - match Repository.find_by_gtype gtype with - | None -> assert_equal_string "It should return " "a base info" - | Some base_info -> match Base_info.get_name base_info with - | None -> assert_equal_string "It should return " "a name" - | Some name -> assert_equal_string "ResourceError" name - ) + | Some gtype -> ( + match Repository.find_by_gtype gtype with + | None -> assert_equal_string "It should return " "a base info" + | Some base_info -> ( + match Base_info.get_name base_info with + | None -> assert_equal_string "It should return " "a name" + | Some name -> assert_equal_string "ResourceError" name))) - (* TODO create a GType module GType.t GType.of_int64 , GType.to_int64, GType.typ *) +(* TODO create a GType module GType.t GType.of_int64 , GType.to_int64, GType.typ *) let test_get_type_init_from_union _ = union_test (fun info -> let registered = Union_info.to_registeredtypeinfo info in match Registered_type_info.get_type_init registered with | None -> assert_equal_string "No type init" "No type init" - | Some name -> assert_equal_string "It should not return" name - ) + | Some name -> assert_equal_string "It should not return" name) let test_get_type_init_from_enum _ = enum_test (fun info -> let registered = Enum_info.to_registeredtypeinfo info in match Registered_type_info.get_type_init registered with | None -> assert_equal_string "It should have a " "type init" - | Some name -> assert_equal_string "g_resource_error_get_type" name - ) + | Some name -> assert_equal_string "g_resource_error_get_type" name) let tests = - "GObject Introspection Registered_type_info tests" >::: - [ - "Registered_type_info get type name from enum" >:: test_get_type_name_from_enum; - "Registered_type_info get type name from interface" >:: test_get_type_name_from_interface; - "Registered_type_info get type name from object" >:: test_get_type_name_from_object; - "Registered_type_info get type name from struct" >:: test_get_type_name_from_struct; - "Registered_type_info get type name from union" >:: test_get_type_name_from_union; - "Registered_type_info get type from enum" >:: test_get_type_from_enum; - "Registered_type_info get type init from union" >:: test_get_type_init_from_union; - "Registered_type_info get type init from enum" >:: test_get_type_init_from_enum - ] + "GObject Introspection Registered_type_info tests" + >::: [ + "Registered_type_info get type name from enum" + >:: test_get_type_name_from_enum; + "Registered_type_info get type name from interface" + >:: test_get_type_name_from_interface; + "Registered_type_info get type name from object" + >:: test_get_type_name_from_object; + "Registered_type_info get type name from struct" + >:: test_get_type_name_from_struct; + "Registered_type_info get type name from union" + >:: test_get_type_name_from_union; + "Registered_type_info get type from enum" >:: test_get_type_from_enum; + "Registered_type_info get type init from union" + >:: test_get_type_init_from_union; + "Registered_type_info get type init from enum" + >:: test_get_type_init_from_enum; + ] diff --git a/tests/Test_repository.ml b/tests/Test_repository.ml index 8262e45..5f92fc4 100644 --- a/tests/Test_repository.ml +++ b/tests/Test_repository.ml @@ -35,7 +35,8 @@ let test_require_fail _ = let repository = Repository.get_default () in let namespace = "bad_namespace" in match Repository.require ~repository namespace () with - | Error message -> assert_equal_string "Unable to load namespace bad_namespace" message + | Error message -> + assert_equal_string "Unable to load namespace bad_namespace" message | Ok _ -> assert_equal_boolean true true let namespace = "Gio" @@ -44,12 +45,16 @@ let typelib = Repository.require ~repository namespace () let test_get_loaded_namespaces _ = let namespaces_check = "GLib GObject Gio" in - let namespaces = String.concat " " (Repository.get_loaded_namespaces ~repository ()) in + let namespaces = + String.concat " " (Repository.get_loaded_namespaces ~repository ()) + in assert_equal_string namespaces_check namespaces let test_get_dependencies _ = let dependencies_check = "GLib-2.0 GObject-2.0" in - let dependencies = String.concat " " (Repository.get_dependencies ~repository namespace) in + let dependencies = + String.concat " " (Repository.get_dependencies ~repository namespace) + in assert_equal_string dependencies_check dependencies let test_get_c_prefix _ = @@ -66,7 +71,9 @@ let test_get_typelib_path _ = let test_enumerate_versions _ = let versions_check = "2.0 2.0" in - let versions = String.concat " " (Repository.enumerate_versions ~repository namespace) in + let versions = + String.concat " " (Repository.enumerate_versions ~repository namespace) + in assert_equal_string versions_check versions let test_get_search_path _ = @@ -78,26 +85,25 @@ let test_prepend_search_path _ = let new_path = "/home/myhome" in let _ = Repository.prepend_search_path new_path in let paths = String.concat " " (Repository.get_search_path ()) in - let initial_paths = String.concat " " [new_path; initial_path] in + let initial_paths = String.concat " " [ new_path; initial_path ] in assert_equal_string initial_paths paths let test_find_by_name _ = let info_name = "Application" in match Repository.find_by_name ~repository namespace info_name with | None -> assert_equal_string info_name "No base info found" - | Some (base_info) -> match Base_info.get_name base_info with - | None -> assert_equal_string info_name "No name found" - | Some name -> assert_equal_string info_name name + | Some base_info -> ( + match Base_info.get_name base_info with + | None -> assert_equal_string info_name "No name found" + | Some name -> assert_equal_string info_name name) let test_get_n_infos _ = let n_infos = Repository.get_n_infos ~repository namespace in assert_equal_int 702 n_infos let test_get_info_out_of_bounds _ = - try ignore (Repository.get_info ~repository namespace 1500) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message + try ignore (Repository.get_info ~repository namespace 1500) with + | Failure message -> assert_equal_string "Array Index out of bounds" message | _ -> assert_equal_string "Bad exception" "Not a Failure" let test_get_info _ = @@ -113,26 +119,26 @@ let test_get_shared_library _ = | Some shared_lib -> assert_includes_string shared_lib "libgio-2.0" let tests = - "GObject Introspection Repository tests" >::: - [ - "Repository get default" >:: test_get_default; - "Repository require" >:: test_require; - "Repository require fail" >:: test_require_fail; - (* Disable because there is only one instance of Repository and those - * namespaces depends on the nampespaces loaded previously and can - * interfers with previous test. - * "Repository get loaded namespaces" >:: test_get_loaded_namespaces;*) - "Repository get c prefix" >:: test_get_c_prefix; - "Repository get version" >:: test_get_version; - (* Tests depend too much on system (ubuntu, arch, centos ...) - "Repository get typelib path" >:: test_get_typelib_path; - "Repository prepend search path" >:: test_prepend_search_path; - "Repository get search path" >:: test_get_search_path; - "Repository get dependencies" >:: test_get_dependencies; - "Repository get n infos" >:: test_get_n_infos *) - "Repository enumerate versions" >:: test_enumerate_versions; - "Repository find by name" >:: test_find_by_name; - "Repository get info out of bounds" >:: test_get_info_out_of_bounds; - "Repository get info" >:: test_get_info; - "Repository get shared library" >:: test_get_shared_library - ] + "GObject Introspection Repository tests" + >::: [ + "Repository get default" >:: test_get_default; + "Repository require" >:: test_require; + "Repository require fail" >:: test_require_fail; + (* Disable because there is only one instance of Repository and those + * namespaces depends on the nampespaces loaded previously and can + * interfers with previous test. + * "Repository get loaded namespaces" >:: test_get_loaded_namespaces;*) + "Repository get c prefix" >:: test_get_c_prefix; + "Repository get version" >:: test_get_version; + (* Tests depend too much on system (ubuntu, arch, centos ...) + "Repository get typelib path" >:: test_get_typelib_path; + "Repository prepend search path" >:: test_prepend_search_path; + "Repository get search path" >:: test_get_search_path; + "Repository get dependencies" >:: test_get_dependencies; + "Repository get n infos" >:: test_get_n_infos *) + "Repository enumerate versions" >:: test_enumerate_versions; + "Repository find by name" >:: test_find_by_name; + "Repository get info out of bounds" >:: test_get_info_out_of_bounds; + "Repository get info" >:: test_get_info; + "Repository get shared library" >:: test_get_shared_library; + ] diff --git a/tests/Test_repository_default.ml b/tests/Test_repository_default.ml index b19da0b..9dc0937 100644 --- a/tests/Test_repository_default.ml +++ b/tests/Test_repository_default.ml @@ -28,8 +28,7 @@ let test_require _ = let repository = Repository.get_default () in let namespace = "Gio" in match Repository.require ~repository namespace () with - | Error message -> - assert_equal_string "Unable to load namespace Gio" message + | Error message -> assert_equal_string "Unable to load namespace Gio" message | Ok _ -> assert_equal_boolean true true let test_require_fail _ = @@ -37,7 +36,7 @@ let test_require_fail _ = let namespace = "bad_namespace" in match Repository.require ~repository namespace () with | Error message -> - assert_equal_string "Unable to load namespace bad_namespace" message + assert_equal_string "Unable to load namespace bad_namespace" message | Ok _ -> assert_equal_boolean true true let namespace = "Gio" @@ -51,7 +50,9 @@ let test_get_loaded_namespaces _ = let test_get_dependencies _ = let dependencies_check = "GLib-2.0 GObject-2.0" in - let dependencies = String.concat " " (Repository.get_dependencies namespace) in + let dependencies = + String.concat " " (Repository.get_dependencies namespace) + in assert_equal_string dependencies_check dependencies let test_get_c_prefix _ = @@ -80,26 +81,25 @@ let test_prepend_search_path _ = let new_path = "/home/myhome" in let _ = Repository.prepend_search_path new_path in let paths = String.concat " " (Repository.get_search_path ()) in - let initial_paths = String.concat " " [new_path; initial_path] in + let initial_paths = String.concat " " [ new_path; initial_path ] in assert_equal_string initial_paths paths let test_find_by_name _ = let info_name = "Application" in match Repository.find_by_name namespace info_name with | None -> assert_equal_string info_name "No base info found" - | Some (base_info) -> match Base_info.get_name base_info with - | None -> assert_equal_string info_name "No name found" - | Some name -> assert_equal_string info_name name + | Some base_info -> ( + match Base_info.get_name base_info with + | None -> assert_equal_string info_name "No name found" + | Some name -> assert_equal_string info_name name) let test_get_n_infos _ = let n_infos = Repository.get_n_infos namespace in assert_equal_int 702 n_infos let test_get_info_out_of_bounds _ = - try ignore (Repository.get_info namespace 1500) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message + try ignore (Repository.get_info namespace 1500) with + | Failure message -> assert_equal_string "Array Index out of bounds" message | _ -> assert_equal_string "Bad exception" "Not a Failure" let test_get_info _ = @@ -115,26 +115,26 @@ let test_get_shared_library _ = | Some shared_lib -> assert_includes_string shared_lib "libgio-2.0" let tests = - "GObject Introspection Repository tests" >::: - [ - "Repository get default" >:: test_get_default; - "Repository require" >:: test_require; - "Repository require fail" >:: test_require_fail; - (* Disable because there is only one instance of Repository and those - * namespaces depends on the nampespaces loaded previously and can - * interfers with previous test. - * "Repository get loaded namespaces" >:: test_get_loaded_namespaces;*) - "Repository get c prefix" >:: test_get_c_prefix; - "Repository get version" >:: test_get_version; - (* Tests depend too much on system (ubuntu, arch, centos ...) - "Repository get typelib path" >:: test_get_typelib_path; - "Repository prepend search path" >:: test_prepend_search_path; - "Repository get search path" >:: test_get_search_path; - "Repository get dependencies" >:: test_get_dependencies; - "Repository get n infos" >:: test_get_n_infos *) - "Repository enumerate versions" >:: test_enumerate_versions; - "Repository find by name" >:: test_find_by_name; - "Repository get info out of bounds" >:: test_get_info_out_of_bounds; - "Repository get info" >:: test_get_info; - "Repository get shared library" >:: test_get_shared_library; - ] + "GObject Introspection Repository tests" + >::: [ + "Repository get default" >:: test_get_default; + "Repository require" >:: test_require; + "Repository require fail" >:: test_require_fail; + (* Disable because there is only one instance of Repository and those + * namespaces depends on the nampespaces loaded previously and can + * interfers with previous test. + * "Repository get loaded namespaces" >:: test_get_loaded_namespaces;*) + "Repository get c prefix" >:: test_get_c_prefix; + "Repository get version" >:: test_get_version; + (* Tests depend too much on system (ubuntu, arch, centos ...) + "Repository get typelib path" >:: test_get_typelib_path; + "Repository prepend search path" >:: test_prepend_search_path; + "Repository get search path" >:: test_get_search_path; + "Repository get dependencies" >:: test_get_dependencies; + "Repository get n infos" >:: test_get_n_infos *) + "Repository enumerate versions" >:: test_enumerate_versions; + "Repository find by name" >:: test_find_by_name; + "Repository get info out of bounds" >:: test_get_info_out_of_bounds; + "Repository get info" >:: test_get_info; + "Repository get shared library" >:: test_get_shared_library; + ] diff --git a/tests/Test_signal_info.ml b/tests/Test_signal_info.ml index c8a8247..ce02e03 100644 --- a/tests/Test_signal_info.ml +++ b/tests/Test_signal_info.ml @@ -28,63 +28,60 @@ let signal_name = "activate-default" let get_signal_info signal_name = match Repository.find_by_name namespace object_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> ( - let object_info = Object_info.from_baseinfo base_info in - match Object_info.find_signal object_info signal_name with - | None -> None - | Some info' -> Some info' - ) - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> ( + let object_info = Object_info.from_baseinfo base_info in + match Object_info.find_signal object_info signal_name with + | None -> None + | Some info' -> Some info') + | _ -> None) let signal_activate_default_test fn = match get_signal_info signal_name with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_true_stops_emit _ = signal_activate_default_test (fun info -> let stops = Signal_info.true_stops_emit info in - assert_equal_boolean false stops - ) + assert_equal_boolean false stops) let test_get_class_closure _ = signal_activate_default_test (fun info -> match Signal_info.get_class_closure info with | None -> assert_equal_boolean true true - | Some _ -> assert_equal_string "Class closure " " found" - ) + | Some _ -> assert_equal_string "Class closure " " found") let test_get_multiple_flags _ = signal_activate_default_test (fun info -> let flags = Signal_info.get_flags info in let len = List.length flags in let _ = assert_equal_int 2 len in - let _ = assert_bool "Run last" (List.mem Bindings.GSignal.Run_last flags) in - assert_bool "Action" (List.mem Bindings.GSignal.Action flags) - ) + let _ = + assert_bool "Run last" (List.mem Bindings.GSignal.Run_last flags) + in + assert_bool "Action" (List.mem Bindings.GSignal.Action flags)) let signal_name = "keys-changed" let signal_keys_changed_test fn = match get_signal_info signal_name with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_simple_flags _ = signal_keys_changed_test (fun info -> let flags = Signal_info.get_flags info in let len = List.length flags in let _ = assert_equal_int 1 len in - assert_bool "Run First" (List.mem Bindings.GSignal.Run_first flags) - ) + assert_bool "Run First" (List.mem Bindings.GSignal.Run_first flags)) let tests = - "GObject Introspection SignalInfo tests" >::: - [ - "Signal_info true stops emit" >:: test_true_stops_emit; - "GISingalInfo get class closure" >:: test_get_class_closure; - "Signal_info get multiple flags" >:: test_get_multiple_flags; - "Signal_info get simple flags" >:: test_get_simple_flags; - ] + "GObject Introspection SignalInfo tests" + >::: [ + "Signal_info true stops emit" >:: test_true_stops_emit; + "GISingalInfo get class closure" >:: test_get_class_closure; + "Signal_info get multiple flags" >:: test_get_multiple_flags; + "Signal_info get simple flags" >:: test_get_simple_flags; + ] diff --git a/tests/Test_struct_info.ml b/tests/Test_struct_info.ml index 2750469..c49ba4b 100644 --- a/tests/Test_struct_info.ml +++ b/tests/Test_struct_info.ml @@ -27,59 +27,52 @@ let struct_name = "Value" let test_baseinfo_get_type _ = match Repository.find_by_name namespace struct_name with | None -> assert_equal_string struct_name "No base info found" - | Some (base_info) -> assert_equal_boolean true ( - match Base_info.get_type base_info with - | Struct -> true - | _ -> false) + | Some base_info -> + assert_equal_boolean true + (match Base_info.get_type base_info with Struct -> true | _ -> false) let get_struct_info () = match Repository.find_by_name namespace struct_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Struct -> Some (Struct_info.from_baseinfo base_info) - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Struct -> Some (Struct_info.from_baseinfo base_info) + | _ -> None) let struct_test fn = match get_struct_info () with | None -> assert_equal_string struct_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_is_gtype_struct _ = struct_test (fun info -> - let is_struct = Struct_info.is_gtype_struct info in - assert_equal_boolean false is_struct - ) + let is_struct = Struct_info.is_gtype_struct info in + assert_equal_boolean false is_struct) let test_get_alignment _ = struct_test (fun info -> - let alignment = Struct_info.get_alignment info in - assert_equal_int 8 alignment - ) + let alignment = Struct_info.get_alignment info in + assert_equal_int 8 alignment) let test_get_size _ = struct_test (fun info -> - let size = Struct_info.get_size info in - assert_equal_int 24 size - ) + let size = Struct_info.get_size info in + assert_equal_int 24 size) let test_is_foreign _ = struct_test (fun info -> - let is_struct = Struct_info.is_foreign info in - assert_equal_boolean false is_struct - ) + let is_struct = Struct_info.is_foreign info in + assert_equal_boolean false is_struct) let test_get_n_fields _ = struct_test (fun info -> - let n_fields = Struct_info.get_n_fields info in - assert_equal_int 2 n_fields - ) + let n_fields = Struct_info.get_n_fields info in + assert_equal_int 2 n_fields) let test_get_n_methods _ = struct_test (fun info -> - let n_methods = Struct_info.get_n_methods info in - assert_equal_or_greater n_methods 62 - ) + let n_methods = Struct_info.get_n_methods info in + assert_equal_or_greater n_methods 62) let test_get_field _ = struct_test (fun info -> @@ -87,68 +80,69 @@ let test_get_field _ = let flags = Field_info.get_flags field in let rec check_flags = function | [] -> () - | f' :: q -> let _ = assert_equal ~printer:(fun f -> - match f with - | Bindings.Field_info.Is_readable -> "readable" - | Bindings.Field_info.Is_writable -> "writable" - ) Bindings.Field_info.Is_readable f' in check_flags q - in check_flags flags - ) + | f' :: q -> + let _ = + assert_equal + ~printer:(fun f -> + match f with + | Bindings.Field_info.Is_readable -> "readable" + | Bindings.Field_info.Is_writable -> "writable") + Bindings.Field_info.Is_readable f' + in + check_flags q + in + check_flags flags) let test_get_field_out_of_bounds _ = struct_test (fun info -> - try ignore(Struct_info.get_field info 300) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message - | _ -> assert_equal_string "Bad exception" "Not a Failure" - ) - + try ignore (Struct_info.get_field info 300) with + | Failure message -> + assert_equal_string "Array Index out of bounds" message + | _ -> assert_equal_string "Bad exception" "Not a Failure") let test_get_method _ = struct_test (fun info -> - let m = Struct_info.get_method info 0 in - let symbol = Function_info.get_symbol m in - assert_equal_string "g_value_copy" symbol - ) + let m = Struct_info.get_method info 0 in + let symbol = Function_info.get_symbol m in + assert_equal_string "g_value_copy" symbol) let test_get_method_out_of_bounds _ = struct_test (fun info -> - try ignore(Struct_info.get_method info 300) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message - | _ -> assert_equal_string "Bad exception" "Not a Failure" - ) + try ignore (Struct_info.get_method info 300) with + | Failure message -> + assert_equal_string "Array Index out of bounds" message + | _ -> assert_equal_string "Bad exception" "Not a Failure") let test_find_method _ = - struct_test (fun info -> match Struct_info.find_method info "copy" with - | None -> assert_equal_boolean false true - | Some fn_info -> let symbol = Function_info.get_symbol fn_info in - assert_equal_string "g_value_copy" symbol - ) + struct_test (fun info -> + match Struct_info.find_method info "copy" with + | None -> assert_equal_boolean false true + | Some fn_info -> + let symbol = Function_info.get_symbol fn_info in + assert_equal_string "g_value_copy" symbol) let test_find_method_bad_name _ = struct_test (fun info -> - match Struct_info.find_method info "Impossible" with - | None -> assert_equal_boolean true true - | Some _ -> assert_equal_string "Impossible" "Should not returns something" - ) + match Struct_info.find_method info "Impossible" with + | None -> assert_equal_boolean true true + | Some _ -> + assert_equal_string "Impossible" "Should not returns something") let tests = - "GObject Introspection StructInfo tests" >::: - [ - "Struct_info from BaseInfo" >:: test_baseinfo_get_type; - "Struct_info is gtype struct" >:: test_is_gtype_struct; - "Struct_info get alignment" >:: test_get_alignment; - "Struct_info get size" >:: test_get_size; - "Struct_info is foreign" >:: test_is_foreign; - "Struct_info get n fields" >:: test_get_n_fields; - "Struct_info get n methods" >:: test_get_n_methods; - "Struct_info get field" >:: test_get_field; - "Struct_info get field out of bounds" >:: test_get_field_out_of_bounds; - "Struct_info get method" >:: test_get_method; - "Struct_info get method out of bounds" >:: test_get_method_out_of_bounds; - "Struct_info find method" >:: test_find_method; - "Struct_info find method bad name" >:: test_find_method_bad_name - ] + "GObject Introspection StructInfo tests" + >::: [ + "Struct_info from BaseInfo" >:: test_baseinfo_get_type; + "Struct_info is gtype struct" >:: test_is_gtype_struct; + "Struct_info get alignment" >:: test_get_alignment; + "Struct_info get size" >:: test_get_size; + "Struct_info is foreign" >:: test_is_foreign; + "Struct_info get n fields" >:: test_get_n_fields; + "Struct_info get n methods" >:: test_get_n_methods; + "Struct_info get field" >:: test_get_field; + "Struct_info get field out of bounds" >:: test_get_field_out_of_bounds; + "Struct_info get method" >:: test_get_method; + "Struct_info get method out of bounds" + >:: test_get_method_out_of_bounds; + "Struct_info find method" >:: test_find_method; + "Struct_info find method bad name" >:: test_find_method_bad_name; + ] diff --git a/tests/Test_type_info.ml b/tests/Test_type_info.ml index 26de6d0..8aa168c 100644 --- a/tests/Test_type_info.ml +++ b/tests/Test_type_info.ml @@ -26,14 +26,16 @@ let fn_name = "signal_list_ids" let get_type_info () = match Repository.find_by_name namespace fn_name with - | None -> assert_equal_string fn_name "No base info found"; None - | Some (base_info) -> - match Base_info.get_type base_info with - | Function -> - let callable_info = Callable_info.from_baseinfo base_info in - let type_info = Callable_info.get_return_type callable_info in - Some type_info - | _ -> None + | None -> + assert_equal_string fn_name "No base info found"; + None + | Some base_info -> ( + match Base_info.get_type base_info with + | Function -> + let callable_info = Callable_info.from_baseinfo base_info in + let type_info = Callable_info.get_return_type callable_info in + Some type_info + | _ -> None) let type_test fn = match get_type_info () with @@ -43,95 +45,87 @@ let type_test fn = let test_to_string _ = type_test (fun info -> let str = Type_info.to_string info in - assert_equal_string "unknown" str - ) + assert_equal_string "unknown" str) let test_is_pointer _ = type_test (fun info -> let is_pointer = Type_info.is_pointer info in - assert_equal_boolean true is_pointer - ) + assert_equal_boolean true is_pointer) let test_get_tag _ = type_test (fun info -> let tag = Type_info.get_tag info in - assert_equal ~printer:(fun tag -> - Bindings.Types.string_of_tag tag - ) Bindings.Types.Array tag - ) + assert_equal + ~printer:(fun tag -> Bindings.Types.string_of_tag tag) + Bindings.Types.Array tag) let test_get_array_length _ = type_test (fun info -> let length = Type_info.get_array_length info in - assert_equal_int 1 length - ) + assert_equal_int 1 length) let test_get_array_fixed_size _ = type_test (fun info -> let size = Type_info.get_array_fixed_size info in - assert_equal_int (-1) size - ) + assert_equal_int (-1) size) let test_is_zero_terminated _ = type_test (fun info -> let zero_terminated = Type_info.is_zero_terminated info in - assert_equal_boolean false zero_terminated - ) + assert_equal_boolean false zero_terminated) let test_get_array_type _ = type_test (fun info -> match Type_info.get_array_type info with | None -> assert_equal_string "It should " "be an array" - | Some array_type -> assert_equal ~printer:(fun t -> - Bindings.Types.string_of_array_type t) - C array_type - ) + | Some array_type -> + assert_equal + ~printer:(fun t -> Bindings.Types.string_of_array_type t) + C array_type) let test_get_param_type _ = type_test (fun info -> - let param_type = Type_info.get_param_type info in - let tag = Type_info.get_tag param_type in - assert_equal ~printer:(fun tag -> - Bindings.Types.string_of_tag tag - ) Bindings.Types.Uint32 tag - ) + let param_type = Type_info.get_param_type info in + let tag = Type_info.get_tag param_type in + assert_equal + ~printer:(fun tag -> Bindings.Types.string_of_tag tag) + Bindings.Types.Uint32 tag) let test_get_interface_none _ = -type_test (fun info -> + type_test (fun info -> match Type_info.get_interface info with | None -> assert_equal true true - | _ -> assert_equal_string "This type info " "should not have interface" - ) + | _ -> assert_equal_string "This type info " "should not have interface") let test_get_interface _ = let name = "type_class_ref" in match Repository.find_by_name namespace name with | None -> assert_equal_string fn_name "No base info found" - | Some (base_info) -> - match Base_info.get_type base_info with - | Function -> - ( - let callable_info = Callable_info.from_baseinfo base_info in - let type_info = Callable_info.get_return_type callable_info in - match Type_info.get_interface type_info with - | None -> assert_equal_string "It should " "have an interface" - | Some interface -> match Base_info.get_name interface with - | None -> assert_equal_string "It should " "have a name" - | Some interface_name -> assert_equal_string "TypeClass" interface_name - ) - | _ -> assert_equal_string name "should be function type" + | Some base_info -> ( + match Base_info.get_type base_info with + | Function -> ( + let callable_info = Callable_info.from_baseinfo base_info in + let type_info = Callable_info.get_return_type callable_info in + match Type_info.get_interface type_info with + | None -> assert_equal_string "It should " "have an interface" + | Some interface -> ( + match Base_info.get_name interface with + | None -> assert_equal_string "It should " "have a name" + | Some interface_name -> + assert_equal_string "TypeClass" interface_name)) + | _ -> assert_equal_string name "should be function type") let tests = - "GObject Introspection TypeInfo tests" >::: - [ - "Type_info to string" >:: test_to_string; - "Type_info is pointer" >:: test_is_pointer; - "Type_info get tag" >:: test_get_tag; - "Type_info get array length" >:: test_get_array_length; - "Type_info get array fixed size" >:: test_get_array_fixed_size; - "Type_info get is zero terminated" >:: test_is_zero_terminated; - "Type_info get array type" >:: test_get_array_type; - "Type_info get param type" >:: test_get_param_type; - "Type_info get interface none" >:: test_get_interface_none; - "Type_info get interface" >:: test_get_interface - ] + "GObject Introspection TypeInfo tests" + >::: [ + "Type_info to string" >:: test_to_string; + "Type_info is pointer" >:: test_is_pointer; + "Type_info get tag" >:: test_get_tag; + "Type_info get array length" >:: test_get_array_length; + "Type_info get array fixed size" >:: test_get_array_fixed_size; + "Type_info get is zero terminated" >:: test_is_zero_terminated; + "Type_info get array type" >:: test_get_array_type; + "Type_info get param type" >:: test_get_param_type; + "Type_info get interface none" >:: test_get_interface_none; + "Type_info get interface" >:: test_get_interface; + ] diff --git a/tests/Test_union_info.ml b/tests/Test_union_info.ml index 5c31161..cd7add3 100644 --- a/tests/Test_union_info.ml +++ b/tests/Test_union_info.ml @@ -27,115 +27,110 @@ let union_name = "Mutex" let test_from_baseinfo _ = match Repository.find_by_name namespace union_name with | None -> assert_equal_string union_name "No base info found" - | Some (base_info) -> assert_equal_boolean true ( - match Base_info.get_type base_info with - | Union -> true - | _ -> false ) + | Some base_info -> + assert_equal_boolean true + (match Base_info.get_type base_info with Union -> true | _ -> false) let get_union_info () = match Repository.find_by_name namespace union_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Union -> let union_info = Union_info.from_baseinfo base_info in - Some union_info - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Union -> + let union_info = Union_info.from_baseinfo base_info in + Some union_info + | _ -> None) let union_test fn = match get_union_info () with | None -> assert_equal_string union_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_n_fields _ = union_test (fun info -> - let n = Union_info.get_n_fields info in - assert_equal_int 2 n - ) + let n = Union_info.get_n_fields info in + assert_equal_int 2 n) let test_get_size _ = union_test (fun info -> - let size = Union_info.get_size info in - assert_equal_int 8 size - ) + let size = Union_info.get_size info in + assert_equal_int 8 size) let test_get_alignment _ = union_test (fun info -> - let alignment = Union_info.get_alignment info in - assert_equal_boolean true (alignment = 4 || alignment = 8) - ) + let alignment = Union_info.get_alignment info in + assert_equal_boolean true (alignment = 4 || alignment = 8)) let test_get_n_methods _ = union_test (fun info -> - let n = Union_info.get_n_methods info in - assert_equal_int 5 n - ) + let n = Union_info.get_n_methods info in + assert_equal_int 5 n) let test_get_field _ = union_test (fun info -> - let field = Union_info.get_field info 0 in + let field = Union_info.get_field info 0 in let flags = Field_info.get_flags field in let rec check_flags = function | [] -> () - | f' :: q -> let _ = assert_equal ~printer:(fun f -> - match f with - | Bindings.Field_info.Is_readable -> "readable" - | Bindings.Field_info.Is_writable -> "writable" - ) Bindings.Field_info.Is_readable f' in check_flags q - in check_flags flags - ) + | f' :: q -> + let _ = + assert_equal + ~printer:(fun f -> + match f with + | Bindings.Field_info.Is_readable -> "readable" + | Bindings.Field_info.Is_writable -> "writable") + Bindings.Field_info.Is_readable f' + in + check_flags q + in + check_flags flags) let test_get_field_out_of_bounds _ = union_test (fun info -> - try ignore(Union_info.get_field info 3000) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message - | _ -> assert_equal_string "Bad exception" "Not a Failure" - ) + try ignore (Union_info.get_field info 3000) with + | Failure message -> + assert_equal_string "Array Index out of bounds" message + | _ -> assert_equal_string "Bad exception" "Not a Failure") let test_get_method _ = union_test (fun info -> - let m = Union_info.get_method info 0 in - let symbol = Function_info.get_symbol m in - assert_equal_string "g_mutex_clear" symbol - ) + let m = Union_info.get_method info 0 in + let symbol = Function_info.get_symbol m in + assert_equal_string "g_mutex_clear" symbol) let test_get_method_out_of_bounds _ = union_test (fun info -> - try ignore(Union_info.get_method info 300) - with - | Failure message -> assert_equal_string "Array Index out of bounds" - message - | _ -> assert_equal_string "Bad exception" "Not a Failure" - ) + try ignore (Union_info.get_method info 300) with + | Failure message -> + assert_equal_string "Array Index out of bounds" message + | _ -> assert_equal_string "Bad exception" "Not a Failure") let test_find_method _ = let function_name = "clear" in union_test (fun info -> match Union_info.find_method info function_name with | None -> assert_equal_boolean true false - | Some m -> let symbol = Function_info.get_symbol m in - assert_equal_string ("g_mutex_" ^ function_name) symbol - ) + | Some m -> + let symbol = Function_info.get_symbol m in + assert_equal_string ("g_mutex_" ^ function_name) symbol) let test_is_discriminated _ = union_test (fun info -> let is_discriminated = Union_info.is_discriminated info in - assert_equal_boolean false is_discriminated - ) + assert_equal_boolean false is_discriminated) let tests = - "GObject Introspection UnionInfo tests" >::: - [ - "Union_info from baseinfo" >:: test_from_baseinfo; - "Union_info get n fields" >:: test_get_n_fields; - "Union_info get size" >:: test_get_size; - "Union_info get alignment" >:: test_get_alignment; - "Union_info get n methods" >:: test_get_n_methods; - "Union_info get field" >:: test_get_field; - "Union_info get field out of bounds" >:: test_get_field_out_of_bounds; - "Union_info get method" >:: test_get_method; - "Union_info get method out of bounds" >:: test_get_method_out_of_bounds; - "Union_info find method" >:: test_find_method; - "Union_info is discriminated" >:: test_is_discriminated - ] + "GObject Introspection UnionInfo tests" + >::: [ + "Union_info from baseinfo" >:: test_from_baseinfo; + "Union_info get n fields" >:: test_get_n_fields; + "Union_info get size" >:: test_get_size; + "Union_info get alignment" >:: test_get_alignment; + "Union_info get n methods" >:: test_get_n_methods; + "Union_info get field" >:: test_get_field; + "Union_info get field out of bounds" >:: test_get_field_out_of_bounds; + "Union_info get method" >:: test_get_method; + "Union_info get method out of bounds" >:: test_get_method_out_of_bounds; + "Union_info find method" >:: test_find_method; + "Union_info is discriminated" >:: test_is_discriminated; + ] diff --git a/tests/Test_utils.ml b/tests/Test_utils.ml index 3559682..730f966 100644 --- a/tests/Test_utils.ml +++ b/tests/Test_utils.ml @@ -18,33 +18,28 @@ open OUnit2 -let assert_equal_string str1 str2 = - assert_equal ~printer: (fun s -> s) str1 str2 +let assert_equal_string str1 str2 = assert_equal ~printer:(fun s -> s) str1 str2 let assert_includes_string str1 str2 = let re = Str.regexp_string str2 in - let result = try - (Str.search_forward re str1 0) > -1 - with Not_found -> false + let result = + try Str.search_forward re str1 0 > -1 with Not_found -> false in assert_bool (Printf.sprintf "%s should have included %s" str1 str2) result let assert_equal_boolean bool1 bool2 = - assert_equal ~printer: (fun s -> string_of_bool s) bool1 bool2 + assert_equal ~printer:(fun s -> string_of_bool s) bool1 bool2 let assert_equal_int int1 int2 = - assert_equal ~printer: (fun s -> string_of_int s) int1 int2 + assert_equal ~printer:(fun s -> string_of_int s) int1 int2 let assert_equal_or_greater int1 int2 = - assert_equal ~printer: (fun _ -> - String.concat " " [string_of_int int1; - "is not >="; - string_of_int int2] - ) true (int1 >= int2) + assert_equal + ~printer:(fun _ -> + String.concat " " [ string_of_int int1; "is not >="; string_of_int int2 ]) + true (int1 >= int2) -let is_travis = try - bool_of_string (Sys.getenv "TRAVIS_TESTS") - with _ -> false +let is_travis = try bool_of_string (Sys.getenv "TRAVIS_TESTS") with _ -> false let assert_file_exists filename = assert_equal_boolean true (Sys.file_exists filename) @@ -52,10 +47,11 @@ let assert_file_exists filename = let file_content_to_string in_ch = let rec read_line acc = try - let line = input_line in_ch in read_line (line :: acc) - with - End_of_file -> acc - in let lines = List.rev (read_line []) in + let line = input_line in_ch in + read_line (line :: acc) + with End_of_file -> acc + in + let lines = List.rev (read_line []) in String.concat "\n" lines let check_file_and_content name content = diff --git a/tests/Test_version.ml b/tests/Test_version.ml index e82f2d2..3f903f0 100644 --- a/tests/Test_version.ml +++ b/tests/Test_version.ml @@ -7,19 +7,18 @@ let test_get_version _ = let major = Version.get_major_version () |> string_of_int in let minor = Version.get_minor_version () |> string_of_int in let micro = Version.get_micro_version () |> string_of_int in - let version = String.concat "." [major; minor; micro] in + let version = String.concat "." [ major; minor; micro ] in let run cmd = let inp = Unix.open_process_in cmd in let r = In_channel.input_lines inp in In_channel.close inp; List.hd r in - let modversion = run "pkg-config --libs gobject-introspection-1.0 --modversion" in + let modversion = + run "pkg-config --libs gobject-introspection-1.0 --modversion" + in assert_equal_string version modversion - let tests = - "GObject Introspection Version tests" >::: - [ - "Test get_version" >:: test_get_version; - ] + "GObject Introspection Version tests" + >::: [ "Test get_version" >:: test_get_version ] diff --git a/tests/Test_vfunc_info.ml b/tests/Test_vfunc_info.ml index 11a139c..4b62f9c 100644 --- a/tests/Test_vfunc_info.ml +++ b/tests/Test_vfunc_info.ml @@ -28,47 +28,49 @@ let vfunc_name = "activate_default" let get_vfunc_info () = match Repository.find_by_name namespace object_name with | None -> None - | Some (base_info) -> - match Base_info.get_type base_info with - | Object -> let object_info = Object_info.from_baseinfo base_info in - Object_info.find_vfunc object_info vfunc_name - | _ -> None + | Some base_info -> ( + match Base_info.get_type base_info with + | Object -> + let object_info = Object_info.from_baseinfo base_info in + Object_info.find_vfunc object_info vfunc_name + | _ -> None) let vfunc_test fn = match get_vfunc_info () with | None -> assert_equal_string object_name "No base info found" - | Some (info) -> fn info + | Some info -> fn info let test_get_offset _ = vfunc_test (fun info -> let offset = VFunc_info.get_offset info in - assert_equal_int 0xFFFF offset - ) + assert_equal_int 0xFFFF offset) let test_get_signal _ = vfunc_test (fun info -> match VFunc_info.get_signal info with | None -> assert_equal_boolean true true - | Some _ -> assert_equal_string "It should no return " "a callable info" - ) + | Some _ -> assert_equal_string "It should no return " "a callable info") let test_get_flags _ = vfunc_test (fun info -> let flags = VFunc_info.get_flags info in let rec check_flag = function | [] -> () - | flag :: remain ->let _ = assert_equal ~printer:(fun f -> - Bindings.VFunc_info.string_of_flag f - ) Bindings.VFunc_info.Must_override flag in - check_flag remain - in check_flag flags; - assert_equal [] flags - ) + | flag :: remain -> + let _ = + assert_equal + ~printer:(fun f -> Bindings.VFunc_info.string_of_flag f) + Bindings.VFunc_info.Must_override flag + in + check_flag remain + in + check_flag flags; + assert_equal [] flags) let tests = - "GObject Introspection VFuncInfo tests" >::: - [ - "VFunc_info get offset" >:: test_get_offset; - "VFunc_info get signal" >:: test_get_signal; - "VFunc_info get flags" >:: test_get_flags - ] + "GObject Introspection VFuncInfo tests" + >::: [ + "VFunc_info get offset" >:: test_get_offset; + "VFunc_info get signal" >:: test_get_signal; + "VFunc_info get flags" >:: test_get_flags; + ] diff --git a/tests/dune b/tests/dune index 5362640..8c21565 100644 --- a/tests/dune +++ b/tests/dune @@ -1,4 +1,3 @@ (test (name test) - (libraries GObject_introspection ounit2 ctypes ctypes.foreign stdio) -) + (libraries GObject_introspection ounit2 ctypes ctypes.foreign stdio)) diff --git a/tests/test.ml b/tests/test.ml index daa5168..d053b89 100644 --- a/tests/test.ml +++ b/tests/test.ml @@ -20,26 +20,24 @@ open OUnit2 let () = run_test_tt_main - ("GObjectIntrospection" >::: - [ - Test_repository_default.tests; - Test_repository.tests; - Test_base_info.tests; - Test_function_info.tests; - Test_struct_info.tests; - Test_union_info.tests; - Test_field_info.tests; - Test_enum_info.tests; - Test_callable_info.tests; - Test_arg_info.tests; - Test_type_info.tests; - Test_constant_info.tests; - Test_object_info.tests; - Test_interface_info.tests; - Test_property_info.tests; - Test_signal_info.tests; - Test_vfunc_info.tests; - Test_registered_type_info.tests; - (* Test_version.tests; *) - ] - ) + ("GObjectIntrospection" + >::: [ + Test_repository_default.tests; + Test_repository.tests; + Test_base_info.tests; + Test_function_info.tests; + Test_struct_info.tests; + Test_union_info.tests; + Test_field_info.tests; + Test_enum_info.tests; + Test_callable_info.tests; + Test_arg_info.tests; + Test_type_info.tests; + Test_constant_info.tests; + Test_object_info.tests; + Test_interface_info.tests; + Test_property_info.tests; + Test_signal_info.tests; + Test_vfunc_info.tests; + Test_registered_type_info.tests (* Test_version.tests; *); + ]) From e26c85150a6584a01621059342425f2ea7c1d387 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 17:18:45 +0100 Subject: [PATCH 05/15] Remove GPL text, there's COPYING --- README.md | 3 +- gpl-3.0.txt | 674 ---------------------------------------------------- 2 files changed, 1 insertion(+), 676 deletions(-) delete mode 100644 gpl-3.0.txt diff --git a/README.md b/README.md index 2b935e9..71e3e6a 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![Build Status](https://travis-ci.org/cedlemo/OCaml-GObject-Introspection.svg?branch=master)](https://travis-ci.org/cedlemo/OCaml-GObject-Introspection) -[![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) +[![License: GPL-3.0-or-later](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) # gobject-introspection OCaml package @@ -48,4 +48,3 @@ https://github.com/cedlemo/OCaml-GObject-Introspection/wiki#introduction - [Finished](https://github.com/cedlemo/OCaml-GObject-Introspection/wiki/#finished) - [Remains](https://github.com/cedlemo/OCaml-GObject-Introspection/wiki/#remains) - [Resources](https://github.com/cedlemo/OCaml-GObject-Introspection/wiki/#resources) - diff --git a/gpl-3.0.txt b/gpl-3.0.txt deleted file mode 100644 index 94a9ed0..0000000 --- a/gpl-3.0.txt +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. From 0055e7314846b780482e750d486e7238c8e24238 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonin=20D=C3=A9cimo?= Date: Sat, 11 Dec 2021 17:25:20 +0100 Subject: [PATCH 06/15] Remove auto-generated docs --- docs/Bindings/.dune-keep | 0 docs/Bindings/Arg_info/index.html | 2 - docs/Bindings/Base_info/index.html | 2 - docs/Bindings/Field_info/index.html | 2 - docs/Bindings/Function_info/index.html | 2 - docs/Bindings/GParam/index.html | 2 - docs/Bindings/GSignal/index.html | 2 - docs/Bindings/Types/index.html | 2 - docs/Bindings/VFunc_info/index.html | 2 - docs/Bindings/index.html | 2 - docs/Bindings__/.dune-keep | 0 docs/Bindings__/Arg_info/Enums/index.html | 2 - docs/Bindings__/Arg_info/index.html | 2 - docs/Bindings__/Base_info/Enums/index.html | 2 - docs/Bindings__/Base_info/index.html | 2 - docs/Bindings__/Field_info/Flags/index.html | 2 - docs/Bindings__/Field_info/index.html | 2 - .../Bindings__/Function_info/Flags/index.html | 2 - docs/Bindings__/Function_info/index.html | 2 - docs/Bindings__/GParam/Flags/index.html | 2 - docs/Bindings__/GParam/index.html | 2 - docs/Bindings__/GSignal/Flags/index.html | 2 - docs/Bindings__/GSignal/index.html | 2 - docs/Bindings__/Types/Enums/index.html | 2 - docs/Bindings__/Types/index.html | 2 - docs/Bindings__/Utils/index.html | 2 - docs/Bindings__/VFunc_info/Flags/index.html | 2 - docs/Bindings__/VFunc_info/index.html | 2 - docs/Bindings__/index.html | 2 - docs/Bindings__Arg_info/.dune-keep | 0 docs/Bindings__Arg_info/Enums/index.html | 2 - docs/Bindings__Arg_info/index.html | 2 - docs/Bindings__Base_info/.dune-keep | 0 docs/Bindings__Base_info/Enums/index.html | 2 - docs/Bindings__Base_info/index.html | 2 - docs/Bindings__Field_info/.dune-keep | 0 docs/Bindings__Field_info/Flags/index.html | 2 - docs/Bindings__Field_info/index.html | 2 - docs/Bindings__Function_info/.dune-keep | 0 docs/Bindings__Function_info/Flags/index.html | 2 - docs/Bindings__Function_info/index.html | 2 - docs/Bindings__GParam/.dune-keep | 0 docs/Bindings__GParam/Flags/index.html | 2 - docs/Bindings__GParam/index.html | 2 - docs/Bindings__GSignal/.dune-keep | 0 docs/Bindings__GSignal/Flags/index.html | 2 - docs/Bindings__GSignal/index.html | 2 - docs/Bindings__Types/.dune-keep | 0 docs/Bindings__Types/Enums/index.html | 2 - docs/Bindings__Types/index.html | 2 - docs/Bindings__Utils/.dune-keep | 0 docs/Bindings__Utils/index.html | 2 - docs/Bindings__VFunc_info/.dune-keep | 0 docs/Bindings__VFunc_info/Flags/index.html | 2 - docs/Bindings__VFunc_info/index.html | 2 - docs/GObject_introspection/.dune-keep | 0 .../GObject_introspection/Arg_info/index.html | 2 - .../Base_info/index.html | 2 - .../Bindings_stubs_arg_info/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_base_info/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_field_info/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_function_info/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_g_param/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_g_signal/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_types/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Bindings_stubs_vfunc_info/index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../Callable_info/index.html | 2 - .../Constant_info/index.html | 2 - .../Conversions/index.html | 2 - .../Enum_info/index.html | 2 - .../Field_info/index.html | 2 - .../Function_info/index.html | 2 - docs/GObject_introspection/GParam/index.html | 2 - docs/GObject_introspection/GSignal/index.html | 2 - .../Interface_info/index.html | 2 - .../Object_info/index.html | 2 - .../Property_info/index.html | 2 - .../Registered_type_info/index.html | 2 - .../Repository/index.html | 2 - .../Signal_info/index.html | 2 - .../Struct_info/index.html | 2 - .../Stubs/Arg_info/index.html | 2 - .../Stubs/Base_info/index.html | 2 - .../Stubs/Field_info/index.html | 2 - .../Stubs/Function_info/index.html | 2 - .../Stubs/GParam/index.html | 2 - .../Stubs/GSignal/index.html | 2 - .../Stubs/Types/index.html | 2 - .../Stubs/VFunc_info/index.html | 2 - docs/GObject_introspection/Stubs/index.html | 2 - .../Type_info/index.html | 2 - docs/GObject_introspection/Types/index.html | 2 - .../Union_info/index.html | 2 - docs/GObject_introspection/Utils/index.html | 2 - .../VFunc_info/index.html | 2 - .../Value_info/index.html | 2 - docs/GObject_introspection/Version/index.html | 2 - docs/GObject_introspection/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../module-type-FOREIGN/index.html | 2 - .../module-type-TYPE/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - docs/GObject_introspection__GParam/.dune-keep | 0 docs/GObject_introspection__GParam/index.html | 2 - .../GObject_introspection__GSignal/.dune-keep | 0 .../GObject_introspection__GSignal/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - docs/GObject_introspection__Stubs/.dune-keep | 0 .../Arg_info/index.html | 2 - .../Base_info/index.html | 2 - .../Field_info/index.html | 2 - .../Function_info/index.html | 2 - .../GParam/index.html | 2 - .../GSignal/index.html | 2 - .../Types/index.html | 2 - .../VFunc_info/index.html | 2 - docs/GObject_introspection__Stubs/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - docs/GObject_introspection__Types/.dune-keep | 0 docs/GObject_introspection__Types/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - docs/GObject_introspection__Utils/.dune-keep | 0 docs/GObject_introspection__Utils/index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../.dune-keep | 0 .../index.html | 2 - .../GObject_introspection__Version/.dune-keep | 0 .../GObject_introspection__Version/index.html | 2 - docs/index.html | 2 - docs/odoc.css | 764 ------------------ odoc.css | 237 ------ 207 files changed, 1321 deletions(-) delete mode 100644 docs/Bindings/.dune-keep delete mode 100644 docs/Bindings/Arg_info/index.html delete mode 100644 docs/Bindings/Base_info/index.html delete mode 100644 docs/Bindings/Field_info/index.html delete mode 100644 docs/Bindings/Function_info/index.html delete mode 100644 docs/Bindings/GParam/index.html delete mode 100644 docs/Bindings/GSignal/index.html delete mode 100644 docs/Bindings/Types/index.html delete mode 100644 docs/Bindings/VFunc_info/index.html delete mode 100644 docs/Bindings/index.html delete mode 100644 docs/Bindings__/.dune-keep delete mode 100644 docs/Bindings__/Arg_info/Enums/index.html delete mode 100644 docs/Bindings__/Arg_info/index.html delete mode 100644 docs/Bindings__/Base_info/Enums/index.html delete mode 100644 docs/Bindings__/Base_info/index.html delete mode 100644 docs/Bindings__/Field_info/Flags/index.html delete mode 100644 docs/Bindings__/Field_info/index.html delete mode 100644 docs/Bindings__/Function_info/Flags/index.html delete mode 100644 docs/Bindings__/Function_info/index.html delete mode 100644 docs/Bindings__/GParam/Flags/index.html delete mode 100644 docs/Bindings__/GParam/index.html delete mode 100644 docs/Bindings__/GSignal/Flags/index.html delete mode 100644 docs/Bindings__/GSignal/index.html delete mode 100644 docs/Bindings__/Types/Enums/index.html delete mode 100644 docs/Bindings__/Types/index.html delete mode 100644 docs/Bindings__/Utils/index.html delete mode 100644 docs/Bindings__/VFunc_info/Flags/index.html delete mode 100644 docs/Bindings__/VFunc_info/index.html delete mode 100644 docs/Bindings__/index.html delete mode 100644 docs/Bindings__Arg_info/.dune-keep delete mode 100644 docs/Bindings__Arg_info/Enums/index.html delete mode 100644 docs/Bindings__Arg_info/index.html delete mode 100644 docs/Bindings__Base_info/.dune-keep delete mode 100644 docs/Bindings__Base_info/Enums/index.html delete mode 100644 docs/Bindings__Base_info/index.html delete mode 100644 docs/Bindings__Field_info/.dune-keep delete mode 100644 docs/Bindings__Field_info/Flags/index.html delete mode 100644 docs/Bindings__Field_info/index.html delete mode 100644 docs/Bindings__Function_info/.dune-keep delete mode 100644 docs/Bindings__Function_info/Flags/index.html delete mode 100644 docs/Bindings__Function_info/index.html delete mode 100644 docs/Bindings__GParam/.dune-keep delete mode 100644 docs/Bindings__GParam/Flags/index.html delete mode 100644 docs/Bindings__GParam/index.html delete mode 100644 docs/Bindings__GSignal/.dune-keep delete mode 100644 docs/Bindings__GSignal/Flags/index.html delete mode 100644 docs/Bindings__GSignal/index.html delete mode 100644 docs/Bindings__Types/.dune-keep delete mode 100644 docs/Bindings__Types/Enums/index.html delete mode 100644 docs/Bindings__Types/index.html delete mode 100644 docs/Bindings__Utils/.dune-keep delete mode 100644 docs/Bindings__Utils/index.html delete mode 100644 docs/Bindings__VFunc_info/.dune-keep delete mode 100644 docs/Bindings__VFunc_info/Flags/index.html delete mode 100644 docs/Bindings__VFunc_info/index.html delete mode 100644 docs/GObject_introspection/.dune-keep delete mode 100644 docs/GObject_introspection/Arg_info/index.html delete mode 100644 docs/GObject_introspection/Base_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_arg_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_arg_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_arg_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_base_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_base_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_base_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_field_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_field_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_field_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_function_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_function_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_function_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_param/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_param/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_param/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_signal/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_signal/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_g_signal/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_types/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_types/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_types/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_vfunc_info/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection/Callable_info/index.html delete mode 100644 docs/GObject_introspection/Constant_info/index.html delete mode 100644 docs/GObject_introspection/Conversions/index.html delete mode 100644 docs/GObject_introspection/Enum_info/index.html delete mode 100644 docs/GObject_introspection/Field_info/index.html delete mode 100644 docs/GObject_introspection/Function_info/index.html delete mode 100644 docs/GObject_introspection/GParam/index.html delete mode 100644 docs/GObject_introspection/GSignal/index.html delete mode 100644 docs/GObject_introspection/Interface_info/index.html delete mode 100644 docs/GObject_introspection/Object_info/index.html delete mode 100644 docs/GObject_introspection/Property_info/index.html delete mode 100644 docs/GObject_introspection/Registered_type_info/index.html delete mode 100644 docs/GObject_introspection/Repository/index.html delete mode 100644 docs/GObject_introspection/Signal_info/index.html delete mode 100644 docs/GObject_introspection/Struct_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/Arg_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/Base_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/Field_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/Function_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/GParam/index.html delete mode 100644 docs/GObject_introspection/Stubs/GSignal/index.html delete mode 100644 docs/GObject_introspection/Stubs/Types/index.html delete mode 100644 docs/GObject_introspection/Stubs/VFunc_info/index.html delete mode 100644 docs/GObject_introspection/Stubs/index.html delete mode 100644 docs/GObject_introspection/Type_info/index.html delete mode 100644 docs/GObject_introspection/Types/index.html delete mode 100644 docs/GObject_introspection/Union_info/index.html delete mode 100644 docs/GObject_introspection/Utils/index.html delete mode 100644 docs/GObject_introspection/VFunc_info/index.html delete mode 100644 docs/GObject_introspection/Value_info/index.html delete mode 100644 docs/GObject_introspection/Version/index.html delete mode 100644 docs/GObject_introspection/index.html delete mode 100644 docs/GObject_introspection__Arg_info/.dune-keep delete mode 100644 docs/GObject_introspection__Arg_info/index.html delete mode 100644 docs/GObject_introspection__Base_info/.dune-keep delete mode 100644 docs/GObject_introspection__Base_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_arg_info/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_arg_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_arg_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_arg_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_base_info/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_base_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_base_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_base_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_field_info/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_field_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_field_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_field_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_function_info/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_function_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_function_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_function_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_param/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_param/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_param/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_param/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_signal/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_signal/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_signal/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_g_signal/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_types/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_types/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_types/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_types/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_vfunc_info/.dune-keep delete mode 100644 docs/GObject_introspection__Bindings_stubs_vfunc_info/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html delete mode 100644 docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-TYPE/index.html delete mode 100644 docs/GObject_introspection__Callable_info/.dune-keep delete mode 100644 docs/GObject_introspection__Callable_info/index.html delete mode 100644 docs/GObject_introspection__Constant_info/.dune-keep delete mode 100644 docs/GObject_introspection__Constant_info/index.html delete mode 100644 docs/GObject_introspection__Conversions/.dune-keep delete mode 100644 docs/GObject_introspection__Conversions/index.html delete mode 100644 docs/GObject_introspection__Enum_info/.dune-keep delete mode 100644 docs/GObject_introspection__Enum_info/index.html delete mode 100644 docs/GObject_introspection__Field_info/.dune-keep delete mode 100644 docs/GObject_introspection__Field_info/index.html delete mode 100644 docs/GObject_introspection__Function_info/.dune-keep delete mode 100644 docs/GObject_introspection__Function_info/index.html delete mode 100644 docs/GObject_introspection__GParam/.dune-keep delete mode 100644 docs/GObject_introspection__GParam/index.html delete mode 100644 docs/GObject_introspection__GSignal/.dune-keep delete mode 100644 docs/GObject_introspection__GSignal/index.html delete mode 100644 docs/GObject_introspection__Interface_info/.dune-keep delete mode 100644 docs/GObject_introspection__Interface_info/index.html delete mode 100644 docs/GObject_introspection__Object_info/.dune-keep delete mode 100644 docs/GObject_introspection__Object_info/index.html delete mode 100644 docs/GObject_introspection__Property_info/.dune-keep delete mode 100644 docs/GObject_introspection__Property_info/index.html delete mode 100644 docs/GObject_introspection__Registered_type_info/.dune-keep delete mode 100644 docs/GObject_introspection__Registered_type_info/index.html delete mode 100644 docs/GObject_introspection__Repository/.dune-keep delete mode 100644 docs/GObject_introspection__Repository/index.html delete mode 100644 docs/GObject_introspection__Signal_info/.dune-keep delete mode 100644 docs/GObject_introspection__Signal_info/index.html delete mode 100644 docs/GObject_introspection__Struct_info/.dune-keep delete mode 100644 docs/GObject_introspection__Struct_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/.dune-keep delete mode 100644 docs/GObject_introspection__Stubs/Arg_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/Base_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/Field_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/Function_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/GParam/index.html delete mode 100644 docs/GObject_introspection__Stubs/GSignal/index.html delete mode 100644 docs/GObject_introspection__Stubs/Types/index.html delete mode 100644 docs/GObject_introspection__Stubs/VFunc_info/index.html delete mode 100644 docs/GObject_introspection__Stubs/index.html delete mode 100644 docs/GObject_introspection__Type_info/.dune-keep delete mode 100644 docs/GObject_introspection__Type_info/index.html delete mode 100644 docs/GObject_introspection__Types/.dune-keep delete mode 100644 docs/GObject_introspection__Types/index.html delete mode 100644 docs/GObject_introspection__Union_info/.dune-keep delete mode 100644 docs/GObject_introspection__Union_info/index.html delete mode 100644 docs/GObject_introspection__Utils/.dune-keep delete mode 100644 docs/GObject_introspection__Utils/index.html delete mode 100644 docs/GObject_introspection__VFunc_info/.dune-keep delete mode 100644 docs/GObject_introspection__VFunc_info/index.html delete mode 100644 docs/GObject_introspection__Value_info/.dune-keep delete mode 100644 docs/GObject_introspection__Value_info/index.html delete mode 100644 docs/GObject_introspection__Version/.dune-keep delete mode 100644 docs/GObject_introspection__Version/index.html delete mode 100644 docs/index.html delete mode 100644 docs/odoc.css delete mode 100644 odoc.css diff --git a/docs/Bindings/.dune-keep b/docs/Bindings/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings/Arg_info/index.html b/docs/Bindings/Arg_info/index.html deleted file mode 100644 index 50ae3e1..0000000 --- a/docs/Bindings/Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Arg_info (gobject-introspection.Bindings.Arg_info)

Module Bindings.Arg_info

include Arg_info
type direction =
| In

in argument.

| Out

out argument.

| InOut

in and out argument.

The direction of a Arg_info.

val string_of_direction : direction -> string
type transfer =
| Nothing

transfer nothing from the callee (function or the type instance the property belongs to) to the caller. The callee retains the ownership of the transfer and the caller doesn't need to do anything to free up the resources of this transfer.

| Container

transfer the container (list, array, hash table) from the callee to the caller. The callee retains the ownership of the individual items in the container and the caller has to free up the container resources (g_list_free()/ g_hash_table_destroy() etc) of this transfer.

| Everything

transfer everything, eg the container and its contents from the callee to the caller. This is the case when the callee creates a copy of all the data it returns. The caller is responsible for cleaning up the container and item resources of this transfer.

val string_of_transfert : transfer -> string
type scope_type =
| Invalid

The argument is not of callback type.

| Call

The callback and associated user_data is only used during the call to this function.

| Async

The callback and associated user_data is only used until the callback is invoked, and the callback. is invoked always exactly once.

| Notified

The callback and and associated user_data is used until the caller is notfied via the destroy_notify.

Scope type of a Arg_info representing callback, determines how the callback is invoked and is used to decided when the invoke structs can be freed.

val string_of_scope_type : scope_type -> string
module Enums = Arg_info.Enums
\ No newline at end of file diff --git a/docs/Bindings/Base_info/index.html b/docs/Bindings/Base_info/index.html deleted file mode 100644 index 54e0556..0000000 --- a/docs/Bindings/Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Base_info (gobject-introspection.Bindings.Base_info)

Module Bindings.Base_info

include Base_info
type info_type =
| Invalid

invalid type

| Function

function, see Function_info

| Callback

callback, see Function_info

| Struct

struct, see Struct_info

| Boxed

boxed, see Struct_info or Union_info

| Enum

enum, see Enum_info

| Flags

flags, see Enum_info

| Object

object, see Object_info

| Interface

interface, see Interface_info

| Constant

contant, see Constant_info

| Invalid_0

deleted, used to be GI_INFO_TYPE_ERROR_DOMAIN.

| Union

union, see Union_info

| Value

enum value, see Value_info

| Signal

signal, see Signal_info

| Vfunc

virtual function, see VFunc_info

| Property

GObject property, see Property_info

| Field

struct or union field, see Field_info

| Arg

argument of a function or callback, see Arg_info

| Type

type information, see Type_info

| Unresolved

unresolved type, a type which is not present in the typelib, or any of its dependencies.

val string_of_info_type : info_type -> string
module Enums = Base_info.Enums
\ No newline at end of file diff --git a/docs/Bindings/Field_info/index.html b/docs/Bindings/Field_info/index.html deleted file mode 100644 index e069a2f..0000000 --- a/docs/Bindings/Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Field_info (gobject-introspection.Bindings.Field_info)

Module Bindings.Field_info

include Field_info
type flags =
| Is_readable

field is readable.

| Is_writable

field is writable.

Flags for a Field_info.

val string_of_flag : flags -> string
module Flags = Field_info.Flags
\ No newline at end of file diff --git a/docs/Bindings/Function_info/index.html b/docs/Bindings/Function_info/index.html deleted file mode 100644 index f9e0063..0000000 --- a/docs/Bindings/Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Function_info (gobject-introspection.Bindings.Function_info)

Module Bindings.Function_info

include Function_info
type flags =
| Is_method

is a method.

| Is_constructor

is a constructor.

| Is_getter

is a getter of a Property_info.

| Is_setter

is a setter of a Property_info.

| Wraps_vfunc

represents a virtual function.

| Throws

the function may throw an error.

Flags for a Function_info struct.

val string_of_flag : flags -> string
module Flags = Function_info.Flags
\ No newline at end of file diff --git a/docs/Bindings/GParam/index.html b/docs/Bindings/GParam/index.html deleted file mode 100644 index 2460106..0000000 --- a/docs/Bindings/GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GParam (gobject-introspection.Bindings.GParam)

Module Bindings.GParam

include GParam
type flags =
| Readable

the parameter is readable

| Writable

the parameter is writable

| Readwrite

alias for G_PARAM_READABLE | G_PARAM_WRITABLE

| Construct

the parameter will be set upon object construction

| Construct_only

the parameter can only be set upon object construction

| Lax_validation

upon parameter conversion (see g_param_value_convert()) strict validation is not required

| Static_name

the string used as name when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Static_nick

the string used as nick when constructing the parameter is guaranteed to remain valid and unmmodified for the lifetime of the parameter. Since 2.8

| Static_blurb

the string used as blurb when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Explicit_notify

calls to g_object_set_property() for this property will not automatically result in a "notify" signal being emitted: the implementation must call g_object_notify() themselves in case the property actually changes. Since: 2.42.

| Deprecated

the parameter is deprecated and will be removed in a future version. A warning will be generated if it is used while running with G_ENABLE_DIAGNOSTIC=1. Since 2.26

val string_of_flag : flags -> string
module Flags = GParam.Flags
\ No newline at end of file diff --git a/docs/Bindings/GSignal/index.html b/docs/Bindings/GSignal/index.html deleted file mode 100644 index d1d2105..0000000 --- a/docs/Bindings/GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GSignal (gobject-introspection.Bindings.GSignal)

Module Bindings.GSignal

include GSignal
type flags =
| Run_first

Invoke the object method handler in the first emission stage.

| Run_last

Invoke the object method handler in the third emission stage.

| Run_cleanup

Invoke the object method handler in the last emission stage.

| No_recurse

Signals being emitted for an object while currently being in emission for this very object will not be emitted recursively, but instead cause the first emission to be restarted.

| Detailed

This signal supports "::detail" appendices to the signal name upon handler connections and emissions.

| Action

Action signals are signals that may freely be emitted on alive objects from user code via g_signal_emit() and friends, without the need of being embedded into extra code that performs pre or post emission adjustments on the object. They can also be thought of as object methods which can be called generically by third-party code.

| No_hooks

No emissions hooks are supported for this signal.

| Must_collect

Varargs signal emission will always collect the arguments, even if there are no signal handlers connected. Since 2.30.

| Deprecated

The signal is deprecated and will be removed in a future version. A warning will be generated if it is connected while running with G_ENABLE_DIAGNOSTIC=1. Since 2.32.

Flags defined in the module Signals of the GObject library The signal flags are used to specify a signal's behaviour, the overall signal description outlines how especially the RUN flags control the stages of a signal emission.

val string_of_flag : flags -> string
module Flags = GSignal.Flags
\ No newline at end of file diff --git a/docs/Bindings/Types/index.html b/docs/Bindings/Types/index.html deleted file mode 100644 index b4ddc9f..0000000 --- a/docs/Bindings/Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Types (gobject-introspection.Bindings.Types)

Module Bindings.Types

include Types
type array_type =
| C

a C array, char for instance

| Array

a GArray array

| Ptr_array

a GPtrArray array

| Byte_array

a GByteArray array

The type of array in a GITypeInfo.

val string_of_array_type : array_type -> string
type tag =
| Void

void

| Boolean

boolean

| Int8

8-bit signed integer

| Uint8

8-bit unsigned integer

| Int16

16-bit signed integer

| Uint16

16-bit unsigned integer

| Int32

32-bit signed integer

| Uint32

32-bit unsigned integer

| Int64

64-bit signed integer

| Uint64

64-bit unsigned integer

| Float

float

| Double

double floating point

| GType

a GType

| Utf8

a UTF-8 encoded string

| Filename

a filename, encoded in the same encoding as the native filesystem is using.

| Array

an array

| Interface

an extended interface object

| GList

a GList

| GSList

a GSList

| GHash

a GHashTable

| Error

a GError

| Unichar

Unicode character

The type tag of a Type_info.

val string_of_tag : tag -> string
module Enums = Types.Enums
\ No newline at end of file diff --git a/docs/Bindings/VFunc_info/index.html b/docs/Bindings/VFunc_info/index.html deleted file mode 100644 index b5be2d7..0000000 --- a/docs/Bindings/VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -VFunc_info (gobject-introspection.Bindings.VFunc_info)

Module Bindings.VFunc_info

include VFunc_info
type flags =
| Must_chain_up

chains up to the parent type

| Must_override

overrides

| Must_not_override

does not override

| Throws

Includes a GError

val string_of_flag : flags -> string
module Flags = VFunc_info.Flags
\ No newline at end of file diff --git a/docs/Bindings/index.html b/docs/Bindings/index.html deleted file mode 100644 index 10d6678..0000000 --- a/docs/Bindings/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings (gobject-introspection.Bindings)

Module Bindings

module Base_info : sig ... end
module Function_info : sig ... end
module Types : sig ... end
module VFunc_info : sig ... end
module Arg_info : sig ... end
module Field_info : sig ... end
module GParam : sig ... end
module GSignal : sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/.dune-keep b/docs/Bindings__/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__/Arg_info/Enums/index.html b/docs/Bindings__/Arg_info/Enums/index.html deleted file mode 100644 index 85e28fe..0000000 --- a/docs/Bindings__/Arg_info/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__.Arg_info.Enums)

Module Arg_info.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_direction_in : int64 T.const
val gi_direction_out : int64 T.const
val gi_direction_inout : int64 T.const
val direction : direction T.typ
val gi_transfer_nothing : int64 T.const
val gi_transfer_container : int64 T.const
val gi_transfer_everything : int64 T.const
val transfer : transfer T.typ
val gi_scope_type_invalid : int64 T.const
val gi_scope_type_call : int64 T.const
val gi_scope_type_async : int64 T.const
val gi_scope_type_notified : int64 T.const
val scope_type : scope_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__/Arg_info/index.html b/docs/Bindings__/Arg_info/index.html deleted file mode 100644 index 66b8e24..0000000 --- a/docs/Bindings__/Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Arg_info (gobject-introspection.Bindings__.Arg_info)

Module Bindings__.Arg_info

type direction =
| In

in argument.

| Out

out argument.

| InOut

in and out argument.

The direction of a Arg_info.

val string_of_direction : direction -> string
type transfer =
| Nothing

transfer nothing from the callee (function or the type instance the property belongs to) to the caller. The callee retains the ownership of the transfer and the caller doesn't need to do anything to free up the resources of this transfer.

| Container

transfer the container (list, array, hash table) from the callee to the caller. The callee retains the ownership of the individual items in the container and the caller has to free up the container resources (g_list_free()/ g_hash_table_destroy() etc) of this transfer.

| Everything

transfer everything, eg the container and its contents from the callee to the caller. This is the case when the callee creates a copy of all the data it returns. The caller is responsible for cleaning up the container and item resources of this transfer.

val string_of_transfert : transfer -> string
type scope_type =
| Invalid

The argument is not of callback type.

| Call

The callback and associated user_data is only used during the call to this function.

| Async

The callback and associated user_data is only used until the callback is invoked, and the callback. is invoked always exactly once.

| Notified

The callback and and associated user_data is used until the caller is notfied via the destroy_notify.

Scope type of a Arg_info representing callback, determines how the callback is invoked and is used to decided when the invoke structs can be freed.

val string_of_scope_type : scope_type -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/Base_info/Enums/index.html b/docs/Bindings__/Base_info/Enums/index.html deleted file mode 100644 index 483165d..0000000 --- a/docs/Bindings__/Base_info/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__.Base_info.Enums)

Module Base_info.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_info_type_invalid : int64 T.const
val gi_info_type_function : int64 T.const
val gi_info_type_callback : int64 T.const
val gi_info_type_struct : int64 T.const
val gi_info_type_boxed : int64 T.const
val gi_info_type_enum : int64 T.const
val gi_info_type_flags : int64 T.const
val gi_info_type_object : int64 T.const
val gi_info_type_interface : int64 T.const
val gi_info_type_constant : int64 T.const
val gi_info_type_invalid_0 : int64 T.const
val gi_info_type_union : int64 T.const
val gi_info_type_value : int64 T.const
val gi_info_type_signal : int64 T.const
val gi_info_type_vfunc : int64 T.const
val gi_info_type_property : int64 T.const
val gi_info_type_field : int64 T.const
val gi_info_type_arg : int64 T.const
val gi_info_type_type : int64 T.const
val gi_info_type_unresolved : int64 T.const
val info_type : info_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__/Base_info/index.html b/docs/Bindings__/Base_info/index.html deleted file mode 100644 index 80ddb5f..0000000 --- a/docs/Bindings__/Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Base_info (gobject-introspection.Bindings__.Base_info)

Module Bindings__.Base_info

type info_type =
| Invalid

invalid type

| Function

function, see Function_info

| Callback

callback, see Function_info

| Struct

struct, see Struct_info

| Boxed

boxed, see Struct_info or Union_info

| Enum

enum, see Enum_info

| Flags

flags, see Enum_info

| Object

object, see Object_info

| Interface

interface, see Interface_info

| Constant

contant, see Constant_info

| Invalid_0

deleted, used to be GI_INFO_TYPE_ERROR_DOMAIN.

| Union

union, see Union_info

| Value

enum value, see Value_info

| Signal

signal, see Signal_info

| Vfunc

virtual function, see VFunc_info

| Property

GObject property, see Property_info

| Field

struct or union field, see Field_info

| Arg

argument of a function or callback, see Arg_info

| Type

type information, see Type_info

| Unresolved

unresolved type, a type which is not present in the typelib, or any of its dependencies.

val string_of_info_type : info_type -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/Field_info/Flags/index.html b/docs/Bindings__/Field_info/Flags/index.html deleted file mode 100644 index 73fe0cf..0000000 --- a/docs/Bindings__/Field_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__.Field_info.Flags)

Module Field_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_field_is_readable : int64 T.const
val gi_field_is_writable : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__/Field_info/index.html b/docs/Bindings__/Field_info/index.html deleted file mode 100644 index 7d60708..0000000 --- a/docs/Bindings__/Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Field_info (gobject-introspection.Bindings__.Field_info)

Module Bindings__.Field_info

type flags =
| Is_readable

field is readable.

| Is_writable

field is writable.

Flags for a Field_info.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/Function_info/Flags/index.html b/docs/Bindings__/Function_info/Flags/index.html deleted file mode 100644 index 6d7e693..0000000 --- a/docs/Bindings__/Function_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__.Function_info.Flags)

Module Function_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_function_is_method : int64 T.const
val gi_function_is_constructor : int64 T.const
val gi_function_is_getter : int64 T.const
val gi_function_is_setter : int64 T.const
val gi_function_wraps_vfunc : int64 T.const
val gi_function_throws : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__/Function_info/index.html b/docs/Bindings__/Function_info/index.html deleted file mode 100644 index 3adfe2c..0000000 --- a/docs/Bindings__/Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Function_info (gobject-introspection.Bindings__.Function_info)

Module Bindings__.Function_info

type flags =
| Is_method

is a method.

| Is_constructor

is a constructor.

| Is_getter

is a getter of a Property_info.

| Is_setter

is a setter of a Property_info.

| Wraps_vfunc

represents a virtual function.

| Throws

the function may throw an error.

Flags for a Function_info struct.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/GParam/Flags/index.html b/docs/Bindings__/GParam/Flags/index.html deleted file mode 100644 index c183916..0000000 --- a/docs/Bindings__/GParam/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__.GParam.Flags)

Module GParam.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val g_param_readable : int64 T.const
val g_param_writable : int64 T.const
val g_param_readwrite : int64 T.const
val g_param_construct : int64 T.const
val g_param_construct_only : int64 T.const
val g_param_lax_validation : int64 T.const
val g_param_static_name : int64 T.const
val g_param_static_nick : int64 T.const
val g_param_static_blurb : int64 T.const
val g_param_explicit_notify : int64 T.const
val g_param_deprecated : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__/GParam/index.html b/docs/Bindings__/GParam/index.html deleted file mode 100644 index 2886c45..0000000 --- a/docs/Bindings__/GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GParam (gobject-introspection.Bindings__.GParam)

Module Bindings__.GParam

type flags =
| Readable

the parameter is readable

| Writable

the parameter is writable

| Readwrite

alias for G_PARAM_READABLE | G_PARAM_WRITABLE

| Construct

the parameter will be set upon object construction

| Construct_only

the parameter can only be set upon object construction

| Lax_validation

upon parameter conversion (see g_param_value_convert()) strict validation is not required

| Static_name

the string used as name when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Static_nick

the string used as nick when constructing the parameter is guaranteed to remain valid and unmmodified for the lifetime of the parameter. Since 2.8

| Static_blurb

the string used as blurb when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Explicit_notify

calls to g_object_set_property() for this property will not automatically result in a "notify" signal being emitted: the implementation must call g_object_notify() themselves in case the property actually changes. Since: 2.42.

| Deprecated

the parameter is deprecated and will be removed in a future version. A warning will be generated if it is used while running with G_ENABLE_DIAGNOSTIC=1. Since 2.26

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/GSignal/Flags/index.html b/docs/Bindings__/GSignal/Flags/index.html deleted file mode 100644 index c321879..0000000 --- a/docs/Bindings__/GSignal/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__.GSignal.Flags)

Module GSignal.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val g_signal_run_first : int64 T.const
val g_signal_run_last : int64 T.const
val g_signal_run_cleanup : int64 T.const
val g_signal_no_recurse : int64 T.const
val g_signal_detailed : int64 T.const
val g_signal_action : int64 T.const
val g_signal_no_hooks : int64 T.const
val g_signal_must_collect : int64 T.const
val g_signal_deprecated : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__/GSignal/index.html b/docs/Bindings__/GSignal/index.html deleted file mode 100644 index 6ec892b..0000000 --- a/docs/Bindings__/GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GSignal (gobject-introspection.Bindings__.GSignal)

Module Bindings__.GSignal

type flags =
| Run_first

Invoke the object method handler in the first emission stage.

| Run_last

Invoke the object method handler in the third emission stage.

| Run_cleanup

Invoke the object method handler in the last emission stage.

| No_recurse

Signals being emitted for an object while currently being in emission for this very object will not be emitted recursively, but instead cause the first emission to be restarted.

| Detailed

This signal supports "::detail" appendices to the signal name upon handler connections and emissions.

| Action

Action signals are signals that may freely be emitted on alive objects from user code via g_signal_emit() and friends, without the need of being embedded into extra code that performs pre or post emission adjustments on the object. They can also be thought of as object methods which can be called generically by third-party code.

| No_hooks

No emissions hooks are supported for this signal.

| Must_collect

Varargs signal emission will always collect the arguments, even if there are no signal handlers connected. Since 2.30.

| Deprecated

The signal is deprecated and will be removed in a future version. A warning will be generated if it is connected while running with G_ENABLE_DIAGNOSTIC=1. Since 2.32.

Flags defined in the module Signals of the GObject library The signal flags are used to specify a signal's behaviour, the overall signal description outlines how especially the RUN flags control the stages of a signal emission.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/Types/Enums/index.html b/docs/Bindings__/Types/Enums/index.html deleted file mode 100644 index 6f21f86..0000000 --- a/docs/Bindings__/Types/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__.Types.Enums)

Module Types.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_type_tag_void : int64 T.const
val gi_type_tag_boolean : int64 T.const
val gi_type_tag_int8 : int64 T.const
val gi_type_tag_uint8 : int64 T.const
val gi_type_tag_int16 : int64 T.const
val gi_type_tag_uint16 : int64 T.const
val gi_type_tag_int32 : int64 T.const
val gi_type_tag_uint32 : int64 T.const
val gi_type_tag_int64 : int64 T.const
val gi_type_tag_uint64 : int64 T.const
val gi_type_tag_float : int64 T.const
val gi_type_tag_double : int64 T.const
val gi_type_tag_gtype : int64 T.const
val gi_type_tag_utf8 : int64 T.const
val gi_type_tag_filename : int64 T.const
val gi_type_tag_array : int64 T.const
val gi_type_tag_interface : int64 T.const
val gi_type_tag_glist : int64 T.const
val gi_type_tag_gslist : int64 T.const
val gi_type_tag_ghash : int64 T.const
val gi_type_tag_error : int64 T.const
val gi_type_tag_unichar : int64 T.const
val tag : tag T.typ
val gi_array_type_c : int64 T.const
val gi_array_type_array : int64 T.const
val gi_array_type_ptr_array : int64 T.const
val gi_array_type_byte_array : int64 T.const
val array_type : array_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__/Types/index.html b/docs/Bindings__/Types/index.html deleted file mode 100644 index 7afda61..0000000 --- a/docs/Bindings__/Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Types (gobject-introspection.Bindings__.Types)

Module Bindings__.Types

type array_type =
| C

a C array, char for instance

| Array

a GArray array

| Ptr_array

a GPtrArray array

| Byte_array

a GByteArray array

The type of array in a GITypeInfo.

val string_of_array_type : array_type -> string
type tag =
| Void

void

| Boolean

boolean

| Int8

8-bit signed integer

| Uint8

8-bit unsigned integer

| Int16

16-bit signed integer

| Uint16

16-bit unsigned integer

| Int32

32-bit signed integer

| Uint32

32-bit unsigned integer

| Int64

64-bit signed integer

| Uint64

64-bit unsigned integer

| Float

float

| Double

double floating point

| GType

a GType

| Utf8

a UTF-8 encoded string

| Filename

a filename, encoded in the same encoding as the native filesystem is using.

| Array

an array

| Interface

an extended interface object

| GList

a GList

| GSList

a GSList

| GHash

a GHashTable

| Error

a GError

| Unichar

Unicode character

The type tag of a Type_info.

val string_of_tag : tag -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/Utils/index.html b/docs/Bindings__/Utils/index.html deleted file mode 100644 index 87940c1..0000000 --- a/docs/Bindings__/Utils/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Utils (gobject-introspection.Bindings__.Utils)

Module Bindings__.Utils

val unexpected_value_for : string -> int64 -> 'a
\ No newline at end of file diff --git a/docs/Bindings__/VFunc_info/Flags/index.html b/docs/Bindings__/VFunc_info/Flags/index.html deleted file mode 100644 index 7f487ed..0000000 --- a/docs/Bindings__/VFunc_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__.VFunc_info.Flags)

Module VFunc_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_vfunc_must_chain_up : int64 T.const
val gi_vfunc_must_override : int64 T.const
val gi_vfunc_must_not_override : int64 T.const
val gi_vfunc_throws : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__/VFunc_info/index.html b/docs/Bindings__/VFunc_info/index.html deleted file mode 100644 index 6585f00..0000000 --- a/docs/Bindings__/VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -VFunc_info (gobject-introspection.Bindings__.VFunc_info)

Module Bindings__.VFunc_info

type flags =
| Must_chain_up

chains up to the parent type

| Must_override

overrides

| Must_not_override

does not override

| Throws

Includes a GError

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__/index.html b/docs/Bindings__/index.html deleted file mode 100644 index e52ce38..0000000 --- a/docs/Bindings__/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__ (gobject-introspection.Bindings__)

Module Bindings__

module Arg_info : sig ... end
module Base_info : sig ... end
module Field_info : sig ... end
module Function_info : sig ... end
module GParam : sig ... end
module GSignal : sig ... end
module Types : sig ... end
module Utils : sig ... end
module VFunc_info : sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Arg_info/.dune-keep b/docs/Bindings__Arg_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Arg_info/Enums/index.html b/docs/Bindings__Arg_info/Enums/index.html deleted file mode 100644 index 3c75547..0000000 --- a/docs/Bindings__Arg_info/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__Arg_info.Enums)

Module Bindings__Arg_info.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_direction_in : int64 T.const
val gi_direction_out : int64 T.const
val gi_direction_inout : int64 T.const
val direction : direction T.typ
val gi_transfer_nothing : int64 T.const
val gi_transfer_container : int64 T.const
val gi_transfer_everything : int64 T.const
val transfer : transfer T.typ
val gi_scope_type_invalid : int64 T.const
val gi_scope_type_call : int64 T.const
val gi_scope_type_async : int64 T.const
val gi_scope_type_notified : int64 T.const
val scope_type : scope_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__Arg_info/index.html b/docs/Bindings__Arg_info/index.html deleted file mode 100644 index 655670c..0000000 --- a/docs/Bindings__Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Arg_info (gobject-introspection.Bindings__Arg_info)

Module Bindings__Arg_info

type direction =
| In

in argument.

| Out

out argument.

| InOut

in and out argument.

The direction of a Arg_info.

val string_of_direction : direction -> string
type transfer =
| Nothing

transfer nothing from the callee (function or the type instance the property belongs to) to the caller. The callee retains the ownership of the transfer and the caller doesn't need to do anything to free up the resources of this transfer.

| Container

transfer the container (list, array, hash table) from the callee to the caller. The callee retains the ownership of the individual items in the container and the caller has to free up the container resources (g_list_free()/ g_hash_table_destroy() etc) of this transfer.

| Everything

transfer everything, eg the container and its contents from the callee to the caller. This is the case when the callee creates a copy of all the data it returns. The caller is responsible for cleaning up the container and item resources of this transfer.

val string_of_transfert : transfer -> string
type scope_type =
| Invalid

The argument is not of callback type.

| Call

The callback and associated user_data is only used during the call to this function.

| Async

The callback and associated user_data is only used until the callback is invoked, and the callback. is invoked always exactly once.

| Notified

The callback and and associated user_data is used until the caller is notfied via the destroy_notify.

Scope type of a Arg_info representing callback, determines how the callback is invoked and is used to decided when the invoke structs can be freed.

val string_of_scope_type : scope_type -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Base_info/.dune-keep b/docs/Bindings__Base_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Base_info/Enums/index.html b/docs/Bindings__Base_info/Enums/index.html deleted file mode 100644 index f1b06ff..0000000 --- a/docs/Bindings__Base_info/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__Base_info.Enums)

Module Bindings__Base_info.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_info_type_invalid : int64 T.const
val gi_info_type_function : int64 T.const
val gi_info_type_callback : int64 T.const
val gi_info_type_struct : int64 T.const
val gi_info_type_boxed : int64 T.const
val gi_info_type_enum : int64 T.const
val gi_info_type_flags : int64 T.const
val gi_info_type_object : int64 T.const
val gi_info_type_interface : int64 T.const
val gi_info_type_constant : int64 T.const
val gi_info_type_invalid_0 : int64 T.const
val gi_info_type_union : int64 T.const
val gi_info_type_value : int64 T.const
val gi_info_type_signal : int64 T.const
val gi_info_type_vfunc : int64 T.const
val gi_info_type_property : int64 T.const
val gi_info_type_field : int64 T.const
val gi_info_type_arg : int64 T.const
val gi_info_type_type : int64 T.const
val gi_info_type_unresolved : int64 T.const
val info_type : info_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__Base_info/index.html b/docs/Bindings__Base_info/index.html deleted file mode 100644 index 370dee5..0000000 --- a/docs/Bindings__Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Base_info (gobject-introspection.Bindings__Base_info)

Module Bindings__Base_info

type info_type =
| Invalid

invalid type

| Function

function, see Function_info

| Callback

callback, see Function_info

| Struct

struct, see Struct_info

| Boxed

boxed, see Struct_info or Union_info

| Enum

enum, see Enum_info

| Flags

flags, see Enum_info

| Object

object, see Object_info

| Interface

interface, see Interface_info

| Constant

contant, see Constant_info

| Invalid_0

deleted, used to be GI_INFO_TYPE_ERROR_DOMAIN.

| Union

union, see Union_info

| Value

enum value, see Value_info

| Signal

signal, see Signal_info

| Vfunc

virtual function, see VFunc_info

| Property

GObject property, see Property_info

| Field

struct or union field, see Field_info

| Arg

argument of a function or callback, see Arg_info

| Type

type information, see Type_info

| Unresolved

unresolved type, a type which is not present in the typelib, or any of its dependencies.

val string_of_info_type : info_type -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Field_info/.dune-keep b/docs/Bindings__Field_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Field_info/Flags/index.html b/docs/Bindings__Field_info/Flags/index.html deleted file mode 100644 index 614a3bb..0000000 --- a/docs/Bindings__Field_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__Field_info.Flags)

Module Bindings__Field_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_field_is_readable : int64 T.const
val gi_field_is_writable : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__Field_info/index.html b/docs/Bindings__Field_info/index.html deleted file mode 100644 index b8e889f..0000000 --- a/docs/Bindings__Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Field_info (gobject-introspection.Bindings__Field_info)

Module Bindings__Field_info

type flags =
| Is_readable

field is readable.

| Is_writable

field is writable.

Flags for a Field_info.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Function_info/.dune-keep b/docs/Bindings__Function_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Function_info/Flags/index.html b/docs/Bindings__Function_info/Flags/index.html deleted file mode 100644 index d0a2318..0000000 --- a/docs/Bindings__Function_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__Function_info.Flags)

Module Bindings__Function_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_function_is_method : int64 T.const
val gi_function_is_constructor : int64 T.const
val gi_function_is_getter : int64 T.const
val gi_function_is_setter : int64 T.const
val gi_function_wraps_vfunc : int64 T.const
val gi_function_throws : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__Function_info/index.html b/docs/Bindings__Function_info/index.html deleted file mode 100644 index a39fb2b..0000000 --- a/docs/Bindings__Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Function_info (gobject-introspection.Bindings__Function_info)

Module Bindings__Function_info

type flags =
| Is_method

is a method.

| Is_constructor

is a constructor.

| Is_getter

is a getter of a Property_info.

| Is_setter

is a setter of a Property_info.

| Wraps_vfunc

represents a virtual function.

| Throws

the function may throw an error.

Flags for a Function_info struct.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__GParam/.dune-keep b/docs/Bindings__GParam/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__GParam/Flags/index.html b/docs/Bindings__GParam/Flags/index.html deleted file mode 100644 index aa7a6ca..0000000 --- a/docs/Bindings__GParam/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__GParam.Flags)

Module Bindings__GParam.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val g_param_readable : int64 T.const
val g_param_writable : int64 T.const
val g_param_readwrite : int64 T.const
val g_param_construct : int64 T.const
val g_param_construct_only : int64 T.const
val g_param_lax_validation : int64 T.const
val g_param_static_name : int64 T.const
val g_param_static_nick : int64 T.const
val g_param_static_blurb : int64 T.const
val g_param_explicit_notify : int64 T.const
val g_param_deprecated : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__GParam/index.html b/docs/Bindings__GParam/index.html deleted file mode 100644 index 52ba61c..0000000 --- a/docs/Bindings__GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__GParam (gobject-introspection.Bindings__GParam)

Module Bindings__GParam

type flags =
| Readable

the parameter is readable

| Writable

the parameter is writable

| Readwrite

alias for G_PARAM_READABLE | G_PARAM_WRITABLE

| Construct

the parameter will be set upon object construction

| Construct_only

the parameter can only be set upon object construction

| Lax_validation

upon parameter conversion (see g_param_value_convert()) strict validation is not required

| Static_name

the string used as name when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Static_nick

the string used as nick when constructing the parameter is guaranteed to remain valid and unmmodified for the lifetime of the parameter. Since 2.8

| Static_blurb

the string used as blurb when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter. Since 2.8

| Explicit_notify

calls to g_object_set_property() for this property will not automatically result in a "notify" signal being emitted: the implementation must call g_object_notify() themselves in case the property actually changes. Since: 2.42.

| Deprecated

the parameter is deprecated and will be removed in a future version. A warning will be generated if it is used while running with G_ENABLE_DIAGNOSTIC=1. Since 2.26

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__GSignal/.dune-keep b/docs/Bindings__GSignal/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__GSignal/Flags/index.html b/docs/Bindings__GSignal/Flags/index.html deleted file mode 100644 index 310c5b3..0000000 --- a/docs/Bindings__GSignal/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__GSignal.Flags)

Module Bindings__GSignal.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val g_signal_run_first : int64 T.const
val g_signal_run_last : int64 T.const
val g_signal_run_cleanup : int64 T.const
val g_signal_no_recurse : int64 T.const
val g_signal_detailed : int64 T.const
val g_signal_action : int64 T.const
val g_signal_no_hooks : int64 T.const
val g_signal_must_collect : int64 T.const
val g_signal_deprecated : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__GSignal/index.html b/docs/Bindings__GSignal/index.html deleted file mode 100644 index f8c5b97..0000000 --- a/docs/Bindings__GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__GSignal (gobject-introspection.Bindings__GSignal)

Module Bindings__GSignal

type flags =
| Run_first

Invoke the object method handler in the first emission stage.

| Run_last

Invoke the object method handler in the third emission stage.

| Run_cleanup

Invoke the object method handler in the last emission stage.

| No_recurse

Signals being emitted for an object while currently being in emission for this very object will not be emitted recursively, but instead cause the first emission to be restarted.

| Detailed

This signal supports "::detail" appendices to the signal name upon handler connections and emissions.

| Action

Action signals are signals that may freely be emitted on alive objects from user code via g_signal_emit() and friends, without the need of being embedded into extra code that performs pre or post emission adjustments on the object. They can also be thought of as object methods which can be called generically by third-party code.

| No_hooks

No emissions hooks are supported for this signal.

| Must_collect

Varargs signal emission will always collect the arguments, even if there are no signal handlers connected. Since 2.30.

| Deprecated

The signal is deprecated and will be removed in a future version. A warning will be generated if it is connected while running with G_ENABLE_DIAGNOSTIC=1. Since 2.32.

Flags defined in the module Signals of the GObject library The signal flags are used to specify a signal's behaviour, the overall signal description outlines how especially the RUN flags control the stages of a signal emission.

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Types/.dune-keep b/docs/Bindings__Types/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Types/Enums/index.html b/docs/Bindings__Types/Enums/index.html deleted file mode 100644 index 0f49aec..0000000 --- a/docs/Bindings__Types/Enums/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enums (gobject-introspection.Bindings__Types.Enums)

Module Bindings__Types.Enums

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_type_tag_void : int64 T.const
val gi_type_tag_boolean : int64 T.const
val gi_type_tag_int8 : int64 T.const
val gi_type_tag_uint8 : int64 T.const
val gi_type_tag_int16 : int64 T.const
val gi_type_tag_uint16 : int64 T.const
val gi_type_tag_int32 : int64 T.const
val gi_type_tag_uint32 : int64 T.const
val gi_type_tag_int64 : int64 T.const
val gi_type_tag_uint64 : int64 T.const
val gi_type_tag_float : int64 T.const
val gi_type_tag_double : int64 T.const
val gi_type_tag_gtype : int64 T.const
val gi_type_tag_utf8 : int64 T.const
val gi_type_tag_filename : int64 T.const
val gi_type_tag_array : int64 T.const
val gi_type_tag_interface : int64 T.const
val gi_type_tag_glist : int64 T.const
val gi_type_tag_gslist : int64 T.const
val gi_type_tag_ghash : int64 T.const
val gi_type_tag_error : int64 T.const
val gi_type_tag_unichar : int64 T.const
val tag : tag T.typ
val gi_array_type_c : int64 T.const
val gi_array_type_array : int64 T.const
val gi_array_type_ptr_array : int64 T.const
val gi_array_type_byte_array : int64 T.const
val array_type : array_type T.typ
\ No newline at end of file diff --git a/docs/Bindings__Types/index.html b/docs/Bindings__Types/index.html deleted file mode 100644 index 8feb4c4..0000000 --- a/docs/Bindings__Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Types (gobject-introspection.Bindings__Types)

Module Bindings__Types

type array_type =
| C

a C array, char for instance

| Array

a GArray array

| Ptr_array

a GPtrArray array

| Byte_array

a GByteArray array

The type of array in a GITypeInfo.

val string_of_array_type : array_type -> string
type tag =
| Void

void

| Boolean

boolean

| Int8

8-bit signed integer

| Uint8

8-bit unsigned integer

| Int16

16-bit signed integer

| Uint16

16-bit unsigned integer

| Int32

32-bit signed integer

| Uint32

32-bit unsigned integer

| Int64

64-bit signed integer

| Uint64

64-bit unsigned integer

| Float

float

| Double

double floating point

| GType

a GType

| Utf8

a UTF-8 encoded string

| Filename

a filename, encoded in the same encoding as the native filesystem is using.

| Array

an array

| Interface

an extended interface object

| GList

a GList

| GSList

a GSList

| GHash

a GHashTable

| Error

a GError

| Unichar

Unicode character

The type tag of a Type_info.

val string_of_tag : tag -> string
module Enums : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/Bindings__Utils/.dune-keep b/docs/Bindings__Utils/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__Utils/index.html b/docs/Bindings__Utils/index.html deleted file mode 100644 index 155aeff..0000000 --- a/docs/Bindings__Utils/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__Utils (gobject-introspection.Bindings__Utils)

Module Bindings__Utils

val unexpected_value_for : string -> int64 -> 'a
\ No newline at end of file diff --git a/docs/Bindings__VFunc_info/.dune-keep b/docs/Bindings__VFunc_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/Bindings__VFunc_info/Flags/index.html b/docs/Bindings__VFunc_info/Flags/index.html deleted file mode 100644 index ee5dcb2..0000000 --- a/docs/Bindings__VFunc_info/Flags/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Flags (gobject-introspection.Bindings__VFunc_info.Flags)

Module Bindings__VFunc_info.Flags

Parameters

  • T : Cstubs.Types.TYPE

Signature

val gi_vfunc_must_chain_up : int64 T.const
val gi_vfunc_must_override : int64 T.const
val gi_vfunc_must_not_override : int64 T.const
val gi_vfunc_throws : int64 T.const
val flags : int64 T.typ
\ No newline at end of file diff --git a/docs/Bindings__VFunc_info/index.html b/docs/Bindings__VFunc_info/index.html deleted file mode 100644 index 5def113..0000000 --- a/docs/Bindings__VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings__VFunc_info (gobject-introspection.Bindings__VFunc_info)

Module Bindings__VFunc_info

type flags =
| Must_chain_up

chains up to the parent type

| Must_override

overrides

| Must_not_override

does not override

| Throws

Includes a GError

val string_of_flag : flags -> string
module Flags : functor (T : Cstubs.Types.TYPE) -> sig ... end
\ No newline at end of file diff --git a/docs/GObject_introspection/.dune-keep b/docs/GObject_introspection/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection/Arg_info/index.html b/docs/GObject_introspection/Arg_info/index.html deleted file mode 100644 index b264d9d..0000000 --- a/docs/GObject_introspection/Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Arg_info (gobject-introspection.GObject_introspection.Arg_info)

Module GObject_introspection.Arg_info

type t

Arg_info represents an argument. An argument is always part of a Callable_info.

val arginfo : t Ctypes.structure Ctypes.typ
val get_direction : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.direction

Obtain the direction of the argument. Check GIDirection for possible direction values.

val get_closure : t Ctypes.structure Ctypes.ptr -> int

Obtain the index of the user data argument. This is only valid for arguments which are callbacks. Returns index of the user data argument or -1 if there is none.

val get_destroy : t Ctypes.structure Ctypes.ptr -> int

Obtains the index of the GDestroyNotify argument. This is only valid for arguments which are callbacks. Returns index of the GDestroyNotify argument or -1 if there is none

val get_ownership_transfer : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

Obtain the ownership transfer for this argument. GITransfer contains a list of possible values.

val may_be_null : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the type of the argument includes the possibility of NULL. For 'in' values this means that NULL is a valid value. For 'out' values, this means that NULL may be returned. See also Arg_info.is_optional.

val is_caller_allocates : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is a pointer to a struct or object that will receive an output of a function. The default assumption for Arg_info.Out arguments which have allocation is that the callee allocates; if this is TRUE, then the caller must allocate.

val is_optional : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is optional. For 'out' arguments this means that you can pass NULL in order to ignore the result.

val is_return_value : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is a return value. It can either be a parameter or a return value.

val is_skip : t Ctypes.structure Ctypes.ptr -> bool

Obtain if an argument is only useful in C.

val get_scope : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.scope_type
val get_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr
val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to arg info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes arg info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Arg_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Arg_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Base_info/index.html b/docs/GObject_introspection/Base_info/index.html deleted file mode 100644 index 94b64d6..0000000 --- a/docs/GObject_introspection/Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Base_info (gobject-introspection.GObject_introspection.Base_info)

Module GObject_introspection.Base_info

type t

Base_info is the common base struct of all other *Info structs accessible through the Repository API. All other structs can be casted to a Base_info

val baseinfo : t Ctypes.structure Ctypes.typ
val base_info_ref : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Increases the reference count of underlying Base_info *info.

val base_info_unref : t Ctypes.structure Ctypes.ptr -> unit

Decreases the reference count of underlying Base_info *info . When its reference count drops to 0, the info is freed.

val get_name : t Ctypes.structure Ctypes.ptr -> string option

Obtain the name of the info . What the name represents depends on the GIInfoType of the info . For instance for Function_info it is the name of the function.

val equal : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr -> bool

Compare two Base_info. Using pointer comparison is not practical since many functions return different instances of Base_info that refers to the same part of the TypeLib; use this function instead to do Base_info comparisons.

val get_namespace : t Ctypes.structure Ctypes.ptr -> string

Obtain the namespace of info

val is_deprecated : t Ctypes.structure Ctypes.ptr -> bool

Obtain whether the info is represents a metadata which is deprecated or not.

val get_container : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr option

Obtain the container of the info . The container is the parent Base_info. For instance, the parent of a Function_info is an Object_info or Interface_info.

val get_type : t Ctypes.structure Ctypes.ptr -> Bindings.Base_info.info_type

Obtain the info type of the Base_info.

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_arg_info/index.html b/docs/GObject_introspection/Bindings_stubs_arg_info/index.html deleted file mode 100644 index 190c1b1..0000000 --- a/docs/GObject_introspection/Bindings_stubs_arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_arg_info (gobject-introspection.GObject_introspection.Bindings_stubs_arg_info)

Module GObject_introspection.Bindings_stubs_arg_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-FOREIGN/index.html deleted file mode 100644 index f24b735..0000000 --- a/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_arg_info.FOREIGN)

Module type Bindings_stubs_arg_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-TYPE/index.html deleted file mode 100644 index e08a745..0000000 --- a/docs/GObject_introspection/Bindings_stubs_arg_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_arg_info.TYPE)

Module type Bindings_stubs_arg_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_base_info/index.html b/docs/GObject_introspection/Bindings_stubs_base_info/index.html deleted file mode 100644 index d9366d0..0000000 --- a/docs/GObject_introspection/Bindings_stubs_base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_base_info (gobject-introspection.GObject_introspection.Bindings_stubs_base_info)

Module GObject_introspection.Bindings_stubs_base_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_base_info/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_base_info/module-type-FOREIGN/index.html deleted file mode 100644 index bddf532..0000000 --- a/docs/GObject_introspection/Bindings_stubs_base_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_base_info.FOREIGN)

Module type Bindings_stubs_base_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_base_info/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_base_info/module-type-TYPE/index.html deleted file mode 100644 index 81ba5a4..0000000 --- a/docs/GObject_introspection/Bindings_stubs_base_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_base_info.TYPE)

Module type Bindings_stubs_base_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_field_info/index.html b/docs/GObject_introspection/Bindings_stubs_field_info/index.html deleted file mode 100644 index 107711c..0000000 --- a/docs/GObject_introspection/Bindings_stubs_field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_field_info (gobject-introspection.GObject_introspection.Bindings_stubs_field_info)

Module GObject_introspection.Bindings_stubs_field_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_field_info/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_field_info/module-type-FOREIGN/index.html deleted file mode 100644 index ad45b59..0000000 --- a/docs/GObject_introspection/Bindings_stubs_field_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_field_info.FOREIGN)

Module type Bindings_stubs_field_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_field_info/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_field_info/module-type-TYPE/index.html deleted file mode 100644 index b2d8eba..0000000 --- a/docs/GObject_introspection/Bindings_stubs_field_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_field_info.TYPE)

Module type Bindings_stubs_field_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_function_info/index.html b/docs/GObject_introspection/Bindings_stubs_function_info/index.html deleted file mode 100644 index 08b2cdb..0000000 --- a/docs/GObject_introspection/Bindings_stubs_function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_function_info (gobject-introspection.GObject_introspection.Bindings_stubs_function_info)

Module GObject_introspection.Bindings_stubs_function_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_function_info/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_function_info/module-type-FOREIGN/index.html deleted file mode 100644 index acfae4e..0000000 --- a/docs/GObject_introspection/Bindings_stubs_function_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_function_info.FOREIGN)

Module type Bindings_stubs_function_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_function_info/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_function_info/module-type-TYPE/index.html deleted file mode 100644 index e8009be..0000000 --- a/docs/GObject_introspection/Bindings_stubs_function_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_function_info.TYPE)

Module type Bindings_stubs_function_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_param/index.html b/docs/GObject_introspection/Bindings_stubs_g_param/index.html deleted file mode 100644 index 224bc97..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_param/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_g_param (gobject-introspection.GObject_introspection.Bindings_stubs_g_param)

Module GObject_introspection.Bindings_stubs_g_param

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_param/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_g_param/module-type-FOREIGN/index.html deleted file mode 100644 index 913c809..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_param/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_g_param.FOREIGN)

Module type Bindings_stubs_g_param.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_param/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_g_param/module-type-TYPE/index.html deleted file mode 100644 index 1f97d22..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_param/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_g_param.TYPE)

Module type Bindings_stubs_g_param.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_signal/index.html b/docs/GObject_introspection/Bindings_stubs_g_signal/index.html deleted file mode 100644 index 7b81c14..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_signal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_g_signal (gobject-introspection.GObject_introspection.Bindings_stubs_g_signal)

Module GObject_introspection.Bindings_stubs_g_signal

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-FOREIGN/index.html deleted file mode 100644 index ce67a8e..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_g_signal.FOREIGN)

Module type Bindings_stubs_g_signal.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-TYPE/index.html deleted file mode 100644 index f4f0a15..0000000 --- a/docs/GObject_introspection/Bindings_stubs_g_signal/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_g_signal.TYPE)

Module type Bindings_stubs_g_signal.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_types/index.html b/docs/GObject_introspection/Bindings_stubs_types/index.html deleted file mode 100644 index 9ff3b16..0000000 --- a/docs/GObject_introspection/Bindings_stubs_types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_types (gobject-introspection.GObject_introspection.Bindings_stubs_types)

Module GObject_introspection.Bindings_stubs_types

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_types/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_types/module-type-FOREIGN/index.html deleted file mode 100644 index 72c0d7f..0000000 --- a/docs/GObject_introspection/Bindings_stubs_types/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_types.FOREIGN)

Module type Bindings_stubs_types.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_types/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_types/module-type-TYPE/index.html deleted file mode 100644 index eda1c6e..0000000 --- a/docs/GObject_introspection/Bindings_stubs_types/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_types.TYPE)

Module type Bindings_stubs_types.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_vfunc_info/index.html b/docs/GObject_introspection/Bindings_stubs_vfunc_info/index.html deleted file mode 100644 index ff40eca..0000000 --- a/docs/GObject_introspection/Bindings_stubs_vfunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Bindings_stubs_vfunc_info (gobject-introspection.GObject_introspection.Bindings_stubs_vfunc_info)

Module GObject_introspection.Bindings_stubs_vfunc_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html b/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html deleted file mode 100644 index fd714e4..0000000 --- a/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection.Bindings_stubs_vfunc_info.FOREIGN)

Module type Bindings_stubs_vfunc_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-TYPE/index.html b/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-TYPE/index.html deleted file mode 100644 index 3effed2..0000000 --- a/docs/GObject_introspection/Bindings_stubs_vfunc_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection.Bindings_stubs_vfunc_info.TYPE)

Module type Bindings_stubs_vfunc_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Callable_info/index.html b/docs/GObject_introspection/Callable_info/index.html deleted file mode 100644 index 367b5f0..0000000 --- a/docs/GObject_introspection/Callable_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Callable_info (gobject-introspection.GObject_introspection.Callable_info)

Module GObject_introspection.Callable_info

type t

Callable_info represents an entity which is callable. Currently a function (Function_info), virtual function, (VFunc_info) or callback (GICallbackInfo). A callable has a list of arguments (Arg_info), a return type, direction and a flag which decides if it returns null

val callableinfo : t Ctypes.structure Ctypes.typ
val can_throw_gerror : t Ctypes.structure Ctypes.ptr -> bool

Does the function throws an error.

val get_n_args : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of arguments (both IN and OUT) for this callable.

val get_return_attribute : t Ctypes.structure Ctypes.ptr -> string option

Retrieve an arbitrary attribute associated with the return value.

val is_method : t Ctypes.structure Ctypes.ptr -> bool

Determines if the callable info is a method. For VFunc_infos, GICallbackInfos, and Signal_infos, this is always true. Otherwise, this looks at the Function_info.Is_method flag on the Function_info. Concretely, this function returns whether Callable_info.get_n_args matches the number of arguments in the raw C method. For methods, there is one more C argument than is exposed by introspection: the "self" or "this" object.

val may_return_null : t Ctypes.structure Ctypes.ptr -> bool

See if a callable could return NULL.

val skip_return : t Ctypes.structure Ctypes.ptr -> bool

See if a callable's return value is only useful in C.

val get_arg : t Ctypes.structure Ctypes.ptr -> int -> Arg_info.t Ctypes.structure Ctypes.ptr

Obtain information about a particular argument of this callable.

val get_return_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr

Obtain the return type of a callable item as a Type_info.

val get_caller_owns : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

See whether the caller owns the return value of this callable. GITransfer contains a list of possible transfer values.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to callable info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Constant_info/index.html b/docs/GObject_introspection/Constant_info/index.html deleted file mode 100644 index 85ff55a..0000000 --- a/docs/GObject_introspection/Constant_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Constant_info (gobject-introspection.GObject_introspection.Constant_info)

Module GObject_introspection.Constant_info

type t

Constant_info represents a constant. A constant has a type associated which can be obtained by calling Constant_info.get_type and a value, which can be obtained by calling GIConstant.get_value.

val constantinfo : t Ctypes.structure Ctypes.typ
val get_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type of the constant as a Type_info.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to constant info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes constant info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Constant_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Constant_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val get_value : t Ctypes.structure Ctypes.ptr -> Types.argument_t Ctypes.union Ctypes.ptr

Obtain the value associated with the Constant_info and store it in the value parameter. argument needs to be allocated before passing it in. The size of the constant value stored in argument will be returned. Free the value with Constant_info.free_value.

\ No newline at end of file diff --git a/docs/GObject_introspection/Conversions/index.html b/docs/GObject_introspection/Conversions/index.html deleted file mode 100644 index 26757a5..0000000 --- a/docs/GObject_introspection/Conversions/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Conversions (gobject-introspection.GObject_introspection.Conversions)

Module GObject_introspection.Conversions

type carray_of_strings = char Ctypes.ptr Ctypes.ptr

C pointer of null terminated array of C strings

val carray_of_strings : carray_of_strings Ctypes.typ
val carray_of_strings_to_list : char Ctypes.ptr Ctypes.ptr -> string list

Converts C array of strings to OCaml list of strings

val carray_of_strings_to_array : carray_of_strings -> string array

Converts C array of strings to OCaml array of strings

type glist

GList struct

val glist : glist Ctypes.structure Ctypes.typ
val glist_data : (unit Ctypes_static.ptrglist Ctypes.structure) Ctypes.field
val glist_next : (glist Ctypes.structure Ctypes_static.ptr optionglist Ctypes.structure) Ctypes.field
val glist_prev : (glist Ctypes.structure Ctypes_static.ptr optionglist Ctypes.structure) Ctypes.field
val g_free : unit Ctypes_static.ptr -> unit
val g_free_t : (unit Ctypes_static.ptr -> unit) Ctypes.fn
val glist_free_full : glist Ctypes.structure Ctypes_static.ptr -> (unit Ctypes_static.ptr -> unit) -> unit
val g_list_next : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> glist Ctypes.structure Ctypes_static.ptr option

Get the next element of a glist

val g_list_data : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> unit Ctypes_static.ptr

Get the void ptr data of the current element

val glist_of_strings_to_list : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> string list

Transform a GList of strings to an OCaml list of strings

type gslist

GSList struct

val gslist : gslist Ctypes.structure Ctypes.typ
val gslist_data : (unit Ctypes_static.ptrgslist Ctypes.structure) Ctypes.field
val gslist_next : (gslist Ctypes.structure Ctypes_static.ptr optiongslist Ctypes.structure) Ctypes.field
val g_slist_next : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> gslist Ctypes.structure Ctypes_static.ptr option

Get the next element of a gslist

val g_slist_data : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> unit Ctypes_static.ptr

Get the void ptr data of the current element

val gslist_of_strings_to_list : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> string list

Transform a GSList of strings to an OCaml list of strings

\ No newline at end of file diff --git a/docs/GObject_introspection/Enum_info/index.html b/docs/GObject_introspection/Enum_info/index.html deleted file mode 100644 index f820210..0000000 --- a/docs/GObject_introspection/Enum_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Enum_info (gobject-introspection.GObject_introspection.Enum_info)

Module GObject_introspection.Enum_info

type t

A Enum_info represents an enumeration and a Value_info struct represents a value of an enumeration. The Enum_info contains a set of values and a type The Value_info is fetched by calling Enum_info.get_value on a Enum_info.

val enuminfo : t Ctypes.structure Ctypes.typ
val get_n_values : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of values this enumeration contains.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this enum type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> Function_info.t Ctypes.structure Ctypes.ptr

Obtain an enum type method at index n .

val get_value : t Ctypes.structure Ctypes.ptr -> int -> Value_info.t Ctypes.structure Ctypes.ptr option

Obtain a value for this enumeration.

val get_error_domain : t Ctypes.structure Ctypes.ptr -> string option

Obtain the string form of the quark for the error domain associated with this enum, if any.

val get_storage_type : t Ctypes.structure Ctypes.ptr -> Bindings.Types.tag

Obtain the tag of the type used for the enum in the C ABI. This will be a signed or unsigned integral type. Note that in the current implementation the width of the type is computed correctly, but the signed or unsigned nature of the type may not match the sign of the type used by the C compiler.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to enum info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to base info

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Enum_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to enum info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to registeredtype info

val from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Enum_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Field_info/index.html b/docs/GObject_introspection/Field_info/index.html deleted file mode 100644 index aaa1ac7..0000000 --- a/docs/GObject_introspection/Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Field_info (gobject-introspection.GObject_introspection.Field_info)

Module GObject_introspection.Field_info

type t

A Field_info struct represents a field of a struct (see Struct_info), union (see Union_info) or an object (see Object_info). The Field_info is fetched by calling Struct_info.get_field, Union_info.get_field or Object_info.get_field. A field has a size, type and a struct offset asssociated and a set of flags, which is currently GI_FIELD_IS_READABLE or GI_FIELD_IS_WRITABLE.

val fieldinfo : t Ctypes.structure Ctypes.typ
val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.Field_info.flags list

Obtain the flags for this Field_info. See Field_info.flags for possible flag values.

val get_offset : t Ctypes.structure Ctypes.ptr -> int

Obtain the offset in bits of the field member, this is relative to the beginning of the struct or union.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the size in bits of the field member, this is how much space you need to allocate to store the field.

val get_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type of a field as a Type_info.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to field info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes field info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Field_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Field_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Function_info/index.html b/docs/GObject_introspection/Function_info/index.html deleted file mode 100644 index 461f7c2..0000000 --- a/docs/GObject_introspection/Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Function_info (gobject-introspection.GObject_introspection.Function_info)

Module GObject_introspection.Function_info

type t

Function_info represents a function, method or constructor. To find out what kind of entity a Function_info represents, call Function_info.get_flags. See also Callable_info for information on how to retreive arguments and other metadata.

val functioninfo : t Ctypes.structure Ctypes.typ
val get_symbol : t Ctypes.structure Ctypes.ptr -> string

Obtain the symbol of the function. The symbol is the name of the exported function, suitable to be used as an argument to g_module_symbol().

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.Function_info.flags list

Obtain the Function_infoFlags for the info .

val get_property : t Ctypes.structure Ctypes.ptr -> Property_info.t Ctypes.structure Ctypes.ptr option

Obtain the property associated with this Function_info. Only Function_info with the flag GIFunction.Is_getter or GIFunction.Is_setter have a property set. For other cases, NULL will be returned.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the virtual function associated with this Function_info. Only Function_info with the flag Wraps_vfunc has a virtual function set. For other cases, None will be returned. In order to avoid circular call graph between Function_info and VFunc_info, this function will return a Callable_info. It is upto the user to use VFunc_info.from_callableinfo in order to have the VFunc_info.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to function info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes function info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to function info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes function info to callable info

val from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/GParam/index.html b/docs/GObject_introspection/GParam/index.html deleted file mode 100644 index 45caa93..0000000 --- a/docs/GObject_introspection/GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GParam (gobject-introspection.GObject_introspection.GParam)

Module GObject_introspection.GParam

val all_flags : (int64 * Bindings.GParam.flags) list
val flags_list : Bindings.GParam.flags list Ctypes.typ
val flag_to_string : Bindings.GParam.flags -> string
\ No newline at end of file diff --git a/docs/GObject_introspection/GSignal/index.html b/docs/GObject_introspection/GSignal/index.html deleted file mode 100644 index 8c0658e..0000000 --- a/docs/GObject_introspection/GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GSignal (gobject-introspection.GObject_introspection.GSignal)

Module GObject_introspection.GSignal

val all_flags : (int64 * Bindings.GSignal.flags) list
val flags_list : Bindings.GSignal.flags list Ctypes.typ
val flag_to_string : Bindings.GSignal.flags -> string
\ No newline at end of file diff --git a/docs/GObject_introspection/Interface_info/index.html b/docs/GObject_introspection/Interface_info/index.html deleted file mode 100644 index d1f2200..0000000 --- a/docs/GObject_introspection/Interface_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Interface_info (gobject-introspection.GObject_introspection.Interface_info)

Module GObject_introspection.Interface_info

type t

Interface_info represents a GInterface type. A GInterface has methods, fields, properties, signals, interfaces, constants, virtual functions and prerequisites.

val interfaceinfo : t Ctypes.structure Ctypes.typ
val get_n_prerequisites : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of prerequisites for this interface type. A prerequisites is another interface that needs to be implemented for interface, similar to an base class for GObjects.

val get_prerequisite : t Ctypes.structure Ctypes.ptr -> int -> Base_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type prerequisites index n .

val get_n_properties : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of properties that this interface type has.

val get_property : t Ctypes.structure Ctypes.ptr -> int -> Property_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type property at index n .

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this interface type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> Function_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type method at index n .

val find_method : t Ctypes.structure Ctypes.ptr -> string -> Function_info.t Ctypes.structure Ctypes.ptr option

Obtain a method of the interface type given a name . NULL will be returned if there's no method available with that name.

val get_n_signals : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of signals that this interface type has.

val get_signal : t Ctypes.structure Ctypes.ptr -> int -> Signal_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type signal at index n .

val find_signal : t Ctypes.structure Ctypes.ptr -> string -> Signal_info.t Ctypes.structure Ctypes.ptr option

Find a signal of the interface

val get_n_constants : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of constants that this interface type has.

val get_constant : t Ctypes.structure Ctypes.ptr -> int -> Constant_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type constant at index n .

val get_iface_struct : t Ctypes.structure Ctypes.ptr -> Struct_info.t Ctypes.structure Ctypes.ptr option

Returns the layout C structure associated with this GInterface.

val get_n_vfuncs : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of virtual functions that this interface type has.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> int -> VFunc_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type virtual function at index n .

val find_vfunc : t Ctypes.structure Ctypes.ptr -> string -> VFunc_info.t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name . See the documentation for g_object_info_find_vfunc() for more information on virtuals.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to interface info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes interface info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Interface_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to enum info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to registeredtype info

val from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Interface_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Object_info/index.html b/docs/GObject_introspection/Object_info/index.html deleted file mode 100644 index 5298d1a..0000000 --- a/docs/GObject_introspection/Object_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Object_info (gobject-introspection.GObject_introspection.Object_info)

Module GObject_introspection.Object_info

type t

Object_info represents a GObject. This doesn't represent a specific instance of a GObject, instead this represent the object type (eg class). A GObject has methods, fields, properties, signals, interfaces, constants and virtual functions.

val objectinfo : t Ctypes.structure Ctypes.typ
val get_abstract : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the object type is an abstract type, eg if it cannot be instantiated

val get_fundamental : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the object type is of a fundamental type which is not G_TYPE_OBJECT. This is mostly for supporting GstMiniObject.

val get_parent : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Obtain the parent of the object type.

val get_type_name : t Ctypes.structure Ctypes.ptr -> string

Obtain the name of the objects class/type.

val get_type_init : t Ctypes.structure Ctypes.ptr -> string

Obtain the function which when called will return the GType function for which this object type is registered.

val get_n_constants : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of constants that this object type has.

val get_constant : t Ctypes.structure Ctypes.ptr -> int -> Constant_info.t Ctypes.structure Ctypes.ptr

Obtain an object type constant at index n .

val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields that this object type has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> Field_info.t Ctypes.structure Ctypes.ptr

Obtain an object type field at index n .

val get_n_interfaces : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of interfaces that this object type has.

val get_interface : t Ctypes.structure Ctypes.ptr -> int -> Interface_info.t Ctypes.structure Ctypes.ptr

Obtain an object type interface at index n .

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this object type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> Function_info.t Ctypes.structure Ctypes.ptr

Obtain an object type method at index n .

val find_method : t Ctypes.structure Ctypes.ptr -> string -> Function_info.t Ctypes.structure Ctypes.ptr option

Obtain a method of the object type given a name . None will be returned if there's no method available with that name.

val get_n_properties : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of properties that this object type has.

val get_property : t Ctypes.structure Ctypes.ptr -> int -> Property_info.t Ctypes.structure Ctypes.ptr

Obtain an object type property at index n .

val get_n_signals : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of signals that this object type has.

val get_signal : t Ctypes.structure Ctypes.ptr -> int -> Signal_info.t Ctypes.structure Ctypes.ptr

Obtain an object type signal at index n .

val find_signal : t Ctypes.structure Ctypes.ptr -> string -> Signal_info.t Ctypes.structure Ctypes.ptr option

Find a signal with a name.

val get_n_vfuncs : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of virtual functions that this object type has.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> int -> VFunc_info.t Ctypes.structure Ctypes.ptr

Obtain an object type virtual function at index n .

val find_vfunc : t Ctypes.structure Ctypes.ptr -> string -> VFunc_info.t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name . Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method associated for a virtual. If there is one, it may be retrieved using VFunc_info.get_invoker, otherwise None will be returned. See the documentation for VFunc_info.get_invoker for more information on invoking virtuals.

val get_class_struct : t Ctypes.structure Ctypes.ptr -> Struct_info.t Ctypes.structure Ctypes.ptr option

Every GObject has two structures; an instance structure and a class structure. This function returns the metadata for the class structure. It returns a Struct_info.t or None.

val find_method_using_interfaces : t Ctypes.structure Ctypes.ptr -> string -> Function_info.t Ctypes.structure Ctypes.ptr option * t Ctypes.structure Ctypes.ptr option

Obtain a method of the object given a name , searching both the object info and any interfaces it implements. None will be returned if there's no method available with that name. Note that this function does *not* search parent classes; you will have to chain up if that's desired.

val get_ref_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to ref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoRefFunction, to fetch the function pointer see Object_info.get_ref_function.

val get_unref_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to unref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoUnrefFunction, to fetch the function pointer see Object_info.get_unref_function.

val get_set_value_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to convert set a GValue giving an object instance pointer of this object type. I's mainly used fundamental types. The type signature for the symbol is Object_infoSetValueFunction, to fetch the function pointer see Object_info.get_set_value_function.

val get_get_value_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to convert an object instance pointer of this object type to a GValue. I's mainly used fundamental types. The type signature for the symbol is Object_infoGetValueFunction, to fetch the function pointer see Object_info.get_get_value_function.

val find_vfunc_using_interfaces : t Ctypes.structure Ctypes.ptr -> string -> VFunc_info.t Ctypes.structure Ctypes.ptr option * t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name , searching both the object info and any interfaces it implements. Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method associated for a virtual. If there is one, it may be retrieved using g_vfunc_info_get_invoker(), otherwise None will be returned. Note that this function does *not* search parent classes; you will have to chain up if that's desired.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to object info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes object info to base info

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Object_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to object info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes object info to registeredtype info

val from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Object_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Property_info/index.html b/docs/GObject_introspection/Property_info/index.html deleted file mode 100644 index 05af611..0000000 --- a/docs/GObject_introspection/Property_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Property_info (gobject-introspection.GObject_introspection.Property_info)

Module GObject_introspection.Property_info

type t

Property_info represents a property. A property belongs to either a Object_info or a Interface_info.

val propertyinfo : t Ctypes.structure Ctypes.typ
val get_ownership_transfer : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

Obtain the ownership transfer for this property. See GITransfer for more information about transfer values.

val get_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for the property info .

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.GParam.flags list

Obtain the flags for this property info. See GParamFlags for more information about possible flag values.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to property info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes property info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Property_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Property_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Registered_type_info/index.html b/docs/GObject_introspection/Registered_type_info/index.html deleted file mode 100644 index f6d251c..0000000 --- a/docs/GObject_introspection/Registered_type_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Registered_type_info (gobject-introspection.GObject_introspection.Registered_type_info)

Module GObject_introspection.Registered_type_info

type t
val registeredtypeinfo : t Ctypes.structure Ctypes.typ
val get_type_name : t Ctypes.structure Ctypes.ptr -> string option

Obtain the type name of the struct within the GObject type system. This type can be passed to g_type_name() to get a #GType.

val get_g_type : t Ctypes.structure Ctypes.ptr -> Repository.gtype option

Obtain the gtype for this registered type or None which a special meaning. It means that either there is no type information associated with this info or that the shared library which provides the type_init function for this info cannot be called.

val get_type_init : t Ctypes.structure Ctypes.ptr -> string option

Obtain the type init function for info . The type init function is the function which will register the GType within the GObject type system. Usually this is not called by langauge bindings or applications, use Registered_type_info.get_g_type directly instead.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to registeredtype info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Registered_type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Repository/index.html b/docs/GObject_introspection/Repository/index.html deleted file mode 100644 index c7515b9..0000000 --- a/docs/GObject_introspection/Repository/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Repository (gobject-introspection.GObject_introspection.Repository)

Module GObject_introspection.Repository

type repository
type typelib
val get_default : unit -> repository

Returns the singleton process-global default Repository.

val require : ?⁠repository:repository -> string -> ?⁠version:string -> unit -> (typelib, string) Stdlib.result

Force the namespace namespace_ to be loaded if it isn't already. If namespace_ is not loaded, this function will search for a ".typelib" file using the repository search path. In addition, a version version of namespace may be specified. If version is not specified, the latest will be used).

val get_loaded_namespaces : ?⁠repository:repository -> unit -> string list

Return the list of currently loaded namespaces.

val get_dependencies : ?⁠repository:repository -> string -> string list

Return an list of all (transitive) versioned dependencies for namespace_ . Returned strings are of the form namespace-version. Note: namespace_ must have already been loaded using a function such as Repository.require before calling this function. To get only the immediate dependencies for namespace_ , use Repository.get_immediate_dependencies.

val get_c_prefix : ?⁠repository:repository -> string -> string

This function returns the "C prefix", or the C level namespace associated with the given introspection namespace. Each C symbol starts with this prefix, as well each GType in the library. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val get_version : ?⁠repository:repository -> string -> string

This function returns the loaded version associated with the given namespace namespace_ . Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val get_typelib_path : ?⁠repository:repository -> string -> string

If namespace namespace_ is loaded, return the full path to the .typelib file it was loaded from. If the typelib for namespace namespace_ was included in a shared library, return the special string "<builtin>".

val enumerate_versions : ?⁠repository:repository -> string -> string list

Obtain an unordered list of versions (either currently loaded or available) for namespace_ in this repository .

val get_search_path : unit -> string list

Returns the current search path Repository will use when loading typelib files. The list is internal to GIRespository and should not be freed, nor should its string elements.

val prepend_search_path : string -> unit

Prepends directory to the typelib search path. See Repository.get_search_path.

val find_by_name : ?⁠repository:repository -> string -> string -> Base_info.t Ctypes.structure Ctypes.ptr option

Searches for a particular entry in a namespace. Before calling this function for a particular namespace, you must call Repository.require once to load the namespace, or otherwise ensure the namespace has already been loaded.

val get_n_infos : ?⁠repository:repository -> string -> int

This function returns the number of metadata entries in given namespace namespace_ . The namespace must have already been loaded before calling this function.

val get_info : ?⁠repository:repository -> string -> int -> Base_info.t Ctypes.structure Ctypes.ptr

This function returns a particular metadata entry in the given namespace namespace_ . The namespace must have already been loaded before calling this function. See Repository.get_n_infos to find the maximum number of entries.

val get_shared_library : ?⁠repository:repository -> string -> string option

This function returns a comma-separated list of paths to the shared C libraries associated with the given namespace namespace_ . There may be no shared library path associated, in which case this function will return NULL. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val prepend_library_path : string -> unit

Prepends directory to the search path that is used to search shared libraries referenced by imported namespaces. Multiple calls to this function all contribute to the final list of paths. The list of paths is unique and shared for all Repository instances across the process, but it doesn't affect namespaces imported before the call. If the library is not found in the directories configured in this way, loading will fall back to the system library path (ie. LD_LIBRARY_PATH and DT_RPATH in ELF systems). See the documentation of your dynamic linker for full details.

type gtype = int64
val gtype : int64 Ctypes.typ
val find_by_gtype : ?⁠repository:repository -> gtype -> Base_info.t Ctypes.structure Ctypes.ptr option

Searches all loaded namespaces for a particular #GType. Note that in order to locate the metadata, the namespace corresponding to the type must first have been loaded. There is currently no mechanism for determining the namespace which corresponds to an arbitrary GType - thus, this function will operate most reliably when you know the GType to originate from be from a loaded namespace.

\ No newline at end of file diff --git a/docs/GObject_introspection/Signal_info/index.html b/docs/GObject_introspection/Signal_info/index.html deleted file mode 100644 index 9fcadec..0000000 --- a/docs/GObject_introspection/Signal_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Signal_info (gobject-introspection.GObject_introspection.Signal_info)

Module GObject_introspection.Signal_info

type t

Signal_info represents a signal. It's a sub-struct of Callable_info and contains a set of flags and a class closure. See Callable_info for information on how to retreive arguments and other metadata from the signal.

val signalinfo : t Ctypes.structure Ctypes.typ
val true_stops_emit : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the returning true in the signal handler will stop the emission of the signal.

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.GSignal.flags list

Obtain the flags for this signal info. See GSignalFlags for more information about possible flag values.

val get_class_closure : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the class closure for this signal if one is set. The class closure is a virtual function on the type that the signal belongs to. If the signal lacks a closure None will be returned. In order to avoid circular call graph between Signal_info and VFunc_info, this function will return a Callable_info. It is upto the user to use GIVSignalInfo.from_callableinfo in order to have the VFunc_info.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to signal info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes signal info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Signal_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to signal info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes signal info to callable info

val from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Signal_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Struct_info/index.html b/docs/GObject_introspection/Struct_info/index.html deleted file mode 100644 index b33bdce..0000000 --- a/docs/GObject_introspection/Struct_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Struct_info (gobject-introspection.GObject_introspection.Struct_info)

Module GObject_introspection.Struct_info

type t

Struct_info represents a generic C structure type. A structure has methods and fields.

val structinfo : t Ctypes.structure Ctypes.typ
val is_gtype_struct : t Ctypes.structure Ctypes.ptr -> bool

Return true if this structure represents the "class structure" for some GObject or GInterface. This function is mainly useful to hide this kind of structure from generated public APIs.

val get_alignment : t Ctypes.structure Ctypes.ptr -> int

Obtain the required alignment of the structure.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the total size of the structure.

val is_foreign : t Ctypes.structure Ctypes.ptr -> bool

No doc yet

val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields this structure has.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods this structure has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> Field_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for field with specified index.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> Function_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for method with specified index.

val find_method : t Ctypes.structure Ctypes.ptr -> string -> Function_info.t Ctypes.structure Ctypes.ptr option

Obtain the type information for method named name .

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to struct info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes struct info to registeredtype info

val from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/Arg_info/index.html b/docs/GObject_introspection/Stubs/Arg_info/index.html deleted file mode 100644 index 83a91b3..0000000 --- a/docs/GObject_introspection/Stubs/Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Arg_info (gobject-introspection.GObject_introspection.Stubs.Arg_info)

Module Stubs.Arg_info

val gi_direction_in : int64 Bindings_stubs_arg_info.const
val gi_direction_out : int64 Bindings_stubs_arg_info.const
val gi_direction_inout : int64 Bindings_stubs_arg_info.const
val direction : Bindings__Arg_info.direction GObject_introspection.Bindings_stubs_arg_info.typ
val gi_transfer_nothing : int64 Bindings_stubs_arg_info.const
val gi_transfer_container : int64 Bindings_stubs_arg_info.const
val gi_transfer_everything : int64 Bindings_stubs_arg_info.const
val transfer : Bindings__Arg_info.transfer GObject_introspection.Bindings_stubs_arg_info.typ
val gi_scope_type_invalid : int64 Bindings_stubs_arg_info.const
val gi_scope_type_call : int64 Bindings_stubs_arg_info.const
val gi_scope_type_async : int64 Bindings_stubs_arg_info.const
val gi_scope_type_notified : int64 Bindings_stubs_arg_info.const
val scope_type : Bindings__Arg_info.scope_type GObject_introspection.Bindings_stubs_arg_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/Base_info/index.html b/docs/GObject_introspection/Stubs/Base_info/index.html deleted file mode 100644 index e7a831b..0000000 --- a/docs/GObject_introspection/Stubs/Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Base_info (gobject-introspection.GObject_introspection.Stubs.Base_info)

Module Stubs.Base_info

val gi_info_type_invalid : int64 Bindings_stubs_base_info.const
val gi_info_type_function : int64 Bindings_stubs_base_info.const
val gi_info_type_callback : int64 Bindings_stubs_base_info.const
val gi_info_type_struct : int64 Bindings_stubs_base_info.const
val gi_info_type_boxed : int64 Bindings_stubs_base_info.const
val gi_info_type_enum : int64 Bindings_stubs_base_info.const
val gi_info_type_flags : int64 Bindings_stubs_base_info.const
val gi_info_type_object : int64 Bindings_stubs_base_info.const
val gi_info_type_interface : int64 Bindings_stubs_base_info.const
val gi_info_type_constant : int64 Bindings_stubs_base_info.const
val gi_info_type_invalid_0 : int64 Bindings_stubs_base_info.const
val gi_info_type_union : int64 Bindings_stubs_base_info.const
val gi_info_type_value : int64 Bindings_stubs_base_info.const
val gi_info_type_signal : int64 Bindings_stubs_base_info.const
val gi_info_type_vfunc : int64 Bindings_stubs_base_info.const
val gi_info_type_property : int64 Bindings_stubs_base_info.const
val gi_info_type_field : int64 Bindings_stubs_base_info.const
val gi_info_type_arg : int64 Bindings_stubs_base_info.const
val gi_info_type_type : int64 Bindings_stubs_base_info.const
val gi_info_type_unresolved : int64 Bindings_stubs_base_info.const
val info_type : Bindings__Base_info.info_type GObject_introspection.Bindings_stubs_base_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/Field_info/index.html b/docs/GObject_introspection/Stubs/Field_info/index.html deleted file mode 100644 index d6ab7e3..0000000 --- a/docs/GObject_introspection/Stubs/Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Field_info (gobject-introspection.GObject_introspection.Stubs.Field_info)

Module Stubs.Field_info

val gi_field_is_readable : int64 Bindings_stubs_field_info.const
val gi_field_is_writable : int64 Bindings_stubs_field_info.const
val flags : int64 GObject_introspection.Bindings_stubs_field_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/Function_info/index.html b/docs/GObject_introspection/Stubs/Function_info/index.html deleted file mode 100644 index c3c405b..0000000 --- a/docs/GObject_introspection/Stubs/Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Function_info (gobject-introspection.GObject_introspection.Stubs.Function_info)

Module Stubs.Function_info

val gi_function_is_method : int64 Bindings_stubs_function_info.const
val gi_function_is_constructor : int64 Bindings_stubs_function_info.const
val gi_function_is_getter : int64 Bindings_stubs_function_info.const
val gi_function_is_setter : int64 Bindings_stubs_function_info.const
val gi_function_wraps_vfunc : int64 Bindings_stubs_function_info.const
val gi_function_throws : int64 Bindings_stubs_function_info.const
val flags : int64 GObject_introspection.Bindings_stubs_function_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/GParam/index.html b/docs/GObject_introspection/Stubs/GParam/index.html deleted file mode 100644 index 0c851c1..0000000 --- a/docs/GObject_introspection/Stubs/GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GParam (gobject-introspection.GObject_introspection.Stubs.GParam)

Module Stubs.GParam

val g_param_readable : int64 Bindings_stubs_g_param.const
val g_param_writable : int64 Bindings_stubs_g_param.const
val g_param_readwrite : int64 Bindings_stubs_g_param.const
val g_param_construct : int64 Bindings_stubs_g_param.const
val g_param_construct_only : int64 Bindings_stubs_g_param.const
val g_param_lax_validation : int64 Bindings_stubs_g_param.const
val g_param_static_name : int64 Bindings_stubs_g_param.const
val g_param_static_nick : int64 Bindings_stubs_g_param.const
val g_param_static_blurb : int64 Bindings_stubs_g_param.const
val g_param_explicit_notify : int64 Bindings_stubs_g_param.const
val g_param_deprecated : int64 Bindings_stubs_g_param.const
val flags : int64 GObject_introspection.Bindings_stubs_g_param.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/GSignal/index.html b/docs/GObject_introspection/Stubs/GSignal/index.html deleted file mode 100644 index db979f6..0000000 --- a/docs/GObject_introspection/Stubs/GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GSignal (gobject-introspection.GObject_introspection.Stubs.GSignal)

Module Stubs.GSignal

val g_signal_run_first : int64 Bindings_stubs_g_signal.const
val g_signal_run_last : int64 Bindings_stubs_g_signal.const
val g_signal_run_cleanup : int64 Bindings_stubs_g_signal.const
val g_signal_no_recurse : int64 Bindings_stubs_g_signal.const
val g_signal_detailed : int64 Bindings_stubs_g_signal.const
val g_signal_action : int64 Bindings_stubs_g_signal.const
val g_signal_no_hooks : int64 Bindings_stubs_g_signal.const
val g_signal_must_collect : int64 Bindings_stubs_g_signal.const
val g_signal_deprecated : int64 Bindings_stubs_g_signal.const
val flags : int64 GObject_introspection.Bindings_stubs_g_signal.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/Types/index.html b/docs/GObject_introspection/Stubs/Types/index.html deleted file mode 100644 index bba9138..0000000 --- a/docs/GObject_introspection/Stubs/Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Types (gobject-introspection.GObject_introspection.Stubs.Types)

Module Stubs.Types

val gi_type_tag_void : int64 Bindings_stubs_types.const
val gi_type_tag_boolean : int64 Bindings_stubs_types.const
val gi_type_tag_int8 : int64 Bindings_stubs_types.const
val gi_type_tag_uint8 : int64 Bindings_stubs_types.const
val gi_type_tag_int16 : int64 Bindings_stubs_types.const
val gi_type_tag_uint16 : int64 Bindings_stubs_types.const
val gi_type_tag_int32 : int64 Bindings_stubs_types.const
val gi_type_tag_uint32 : int64 Bindings_stubs_types.const
val gi_type_tag_int64 : int64 Bindings_stubs_types.const
val gi_type_tag_uint64 : int64 Bindings_stubs_types.const
val gi_type_tag_float : int64 Bindings_stubs_types.const
val gi_type_tag_double : int64 Bindings_stubs_types.const
val gi_type_tag_gtype : int64 Bindings_stubs_types.const
val gi_type_tag_utf8 : int64 Bindings_stubs_types.const
val gi_type_tag_filename : int64 Bindings_stubs_types.const
val gi_type_tag_array : int64 Bindings_stubs_types.const
val gi_type_tag_interface : int64 Bindings_stubs_types.const
val gi_type_tag_glist : int64 Bindings_stubs_types.const
val gi_type_tag_gslist : int64 Bindings_stubs_types.const
val gi_type_tag_ghash : int64 Bindings_stubs_types.const
val gi_type_tag_error : int64 Bindings_stubs_types.const
val gi_type_tag_unichar : int64 Bindings_stubs_types.const
val tag : Bindings__Types.tag GObject_introspection.Bindings_stubs_types.typ
val gi_array_type_c : int64 Bindings_stubs_types.const
val gi_array_type_array : int64 Bindings_stubs_types.const
val gi_array_type_ptr_array : int64 Bindings_stubs_types.const
val gi_array_type_byte_array : int64 Bindings_stubs_types.const
val array_type : Bindings__Types.array_type GObject_introspection.Bindings_stubs_types.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/VFunc_info/index.html b/docs/GObject_introspection/Stubs/VFunc_info/index.html deleted file mode 100644 index 80a6485..0000000 --- a/docs/GObject_introspection/Stubs/VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -VFunc_info (gobject-introspection.GObject_introspection.Stubs.VFunc_info)

Module Stubs.VFunc_info

val gi_vfunc_must_chain_up : int64 Bindings_stubs_vfunc_info.const
val gi_vfunc_must_override : int64 Bindings_stubs_vfunc_info.const
val gi_vfunc_must_not_override : int64 Bindings_stubs_vfunc_info.const
val gi_vfunc_throws : int64 Bindings_stubs_vfunc_info.const
val flags : int64 GObject_introspection.Bindings_stubs_vfunc_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/Stubs/index.html b/docs/GObject_introspection/Stubs/index.html deleted file mode 100644 index 1019a66..0000000 --- a/docs/GObject_introspection/Stubs/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Stubs (gobject-introspection.GObject_introspection.Stubs)

Module GObject_introspection.Stubs

module Base_info : sig ... end
module Function_info : sig ... end
module Types : sig ... end
module VFunc_info : sig ... end
module Arg_info : sig ... end
module Field_info : sig ... end
module GParam : sig ... end
module GSignal : sig ... end
\ No newline at end of file diff --git a/docs/GObject_introspection/Type_info/index.html b/docs/GObject_introspection/Type_info/index.html deleted file mode 100644 index 83d7fc6..0000000 --- a/docs/GObject_introspection/Type_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Type_info (gobject-introspection.GObject_introspection.Type_info)

Module GObject_introspection.Type_info

type t

Type_info represents a type. You can retrieve a type info from an argument (see Arg_info), a function return value (see Function_info), a field (see Field_info), a property (see Property_info), a constant (see Constant_info) or for a union discriminator (see Union_info). A type can either be a of a basic type which is a standard C primitive type or an interface type. For interface types you need to call Type_info.get_interface to get a reference to the base info for that interface.

val typeinfo : t Ctypes.structure Ctypes.typ
val to_string : t Ctypes.structure Ctypes.ptr -> string

Obtain a string representation of type.

val is_pointer : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the type is passed as a reference. Note that the types of GI_DIRECTION_OUT and GI_DIRECTION_INOUT parameters will only be pointers if the underlying type being transferred is a pointer (i.e. only if the type of the C function’s formal parameter is a pointer to a pointer).

val get_tag : t Ctypes.structure Ctypes.ptr -> Bindings.Types.tag

Obtain the type tag for the type. See GITypeTag for a list of type tags.

val get_array_length : t Ctypes.structure Ctypes.ptr -> int

Obtain the array length of the type. The type tag must be a GIType.array or -1 will returned.

val get_array_fixed_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the fixed array size of the type. The type tag must be a GIType.array or -1 will returned.

val is_zero_terminated : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the last element of the array is NULL. The type tag must be a GIType.array or FALSE will returned.

val get_array_type : t Ctypes.structure Ctypes.ptr -> Bindings.Types.array_type option

Obtain the array type for this type. See GIArrayType for a list of possible values. If the type tag of this type is not array, None will be returned.

val unsafe_get_param_type : t Ctypes.structure Ctypes.ptr -> int -> t Ctypes.structure Ctypes.ptr

Obtain the parameter type n. It is used to get the parameter type of generic * container. For example if the current Type_info.t is an array, a GList, a * GSList or an Hash, you have to use this in order to get the Type_info.t of * the data of the container. * Basicaly it is done with Type_info.get_param_type type_info 0 . * https://github.com/GNOME/pygobject/blob/288bd2957916568666c3d5d27e8c868d67b7e8c9/gi/pygi-argument.c#L526 * https://github.com/ruby-gnome2/ruby-gnome2/blob/ec4160b4f4c5432c6ff8a9e962e7ffeacfd48869/gobject-introspection/ext/gobject-introspection/rb-gi-argument.c#L928 * This function is unsafe meanings that it is your responsability to not use * a number out of bounds.

val get_param_type : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

This is just an alias to Type_info.unsage_get_param_type with the index set to 0.

val get_interface : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr option

For types which have Types.Interface such as GObjects and boxed values, this function returns full information about the referenced type. You can then inspect the type of the returned Base_info to further query whether it is a concrete GObject, a GInterface, a structure, etc. using Base_info.get_type.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to typeinfo.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes typeinfo to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Types/index.html b/docs/GObject_introspection/Types/index.html deleted file mode 100644 index f710d2c..0000000 --- a/docs/GObject_introspection/Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Types (gobject-introspection.GObject_introspection.Types)

Module GObject_introspection.Types

type argument_t
val argument : argument_t Ctypes.union Ctypes.typ
val v_boolean : (bool, argument_t Ctypes.union) Ctypes.field
val v_int8 : (int, argument_t Ctypes.union) Ctypes.field
val v_uint8 : (Unsigned.uint8, argument_t Ctypes.union) Ctypes.field
val v_int16 : (int, argument_t Ctypes.union) Ctypes.field
val v_uint16 : (Unsigned.uint16, argument_t Ctypes.union) Ctypes.field
val v_int32 : (int32, argument_t Ctypes.union) Ctypes.field
val v_uint32 : (Unsigned.uint32, argument_t Ctypes.union) Ctypes.field
val v_int64 : (int64, argument_t Ctypes.union) Ctypes.field
val v_uint64 : (Unsigned.uint64, argument_t Ctypes.union) Ctypes.field
val v_float : (float, argument_t Ctypes.union) Ctypes.field
val v_double : (float, argument_t Ctypes.union) Ctypes.field
val v_short : (int, argument_t Ctypes.union) Ctypes.field
val v_ushort : (Unsigned.ushort, argument_t Ctypes.union) Ctypes.field
val v_int : (int, argument_t Ctypes.union) Ctypes.field
val v_uint : (Unsigned.uint, argument_t Ctypes.union) Ctypes.field
val v_long : (Signed.long, argument_t Ctypes.union) Ctypes.field
val v_ulong : (Unsigned.ulong, argument_t Ctypes.union) Ctypes.field
val v_ssize : (PosixTypes.ssize_t, argument_t Ctypes.union) Ctypes.field
val v_size : (PosixTypes.size_t, argument_t Ctypes.union) Ctypes.field
val v_string : (string, argument_t Ctypes.union) Ctypes.field
val v_pointer : (unit Ctypes_static.ptr optionargument_t Ctypes.union) Ctypes.field
\ No newline at end of file diff --git a/docs/GObject_introspection/Union_info/index.html b/docs/GObject_introspection/Union_info/index.html deleted file mode 100644 index a64a551..0000000 --- a/docs/GObject_introspection/Union_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Union_info (gobject-introspection.GObject_introspection.Union_info)

Module GObject_introspection.Union_info

type t

Union_info represents a union type. A union has methods and fields. Unions can optionally have a discriminator, which is a field deciding what type of real union fields is valid for specified instance.

val unioninfo : t Ctypes.structure Ctypes.typ
val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields this union has.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the total size of the union.

val get_alignment : t Ctypes.structure Ctypes.ptr -> int

Obtain the required alignment of the union.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods this union has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> Field_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for field with specified index.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> Function_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for method with specified index.

val find_method : t Ctypes.structure Ctypes.ptr -> string -> Function_info.t Ctypes.structure Ctypes.ptr option

Obtain the type information for method named name .

val is_discriminated : t Ctypes.structure Ctypes.ptr -> bool

Return true if this union contains discriminator field.

val get_discriminator_offset : t Ctypes.structure Ctypes.ptr -> int

Returns offset of the discriminator field in the structure.

val get_discriminator_type : t Ctypes.structure Ctypes.ptr -> Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type information of the union discriminator.

val get_discriminator : t Ctypes.structure Ctypes.ptr -> int -> Constant_info.t Ctypes.structure Ctypes.ptr

Obtain discriminator value assigned for n-th union field, i.e. n-th union field is the active one if discriminator contains this constant.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to union info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes union info to base info

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Union_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to union info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes union info to registeredtype info

val from_registeredtypeinfo : Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Union_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Utils/index.html b/docs/GObject_introspection/Utils/index.html deleted file mode 100644 index 44b4170..0000000 --- a/docs/GObject_introspection/Utils/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Utils (gobject-introspection.GObject_introspection.Utils)

Module GObject_introspection.Utils

val flags_list_of_int64 : (int64 * 'a) list -> int64 -> 'a list
val int64_of_flags_list : (int64 * 'a) list -> 'a list -> int64
val generate_flags_list_view : int64 Ctypes.typ -> (int64 * 'a) list -> 'a list Ctypes.typ
\ No newline at end of file diff --git a/docs/GObject_introspection/VFunc_info/index.html b/docs/GObject_introspection/VFunc_info/index.html deleted file mode 100644 index d9961bd..0000000 --- a/docs/GObject_introspection/VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -VFunc_info (gobject-introspection.GObject_introspection.VFunc_info)

Module GObject_introspection.VFunc_info

type t

GIVfuncInfo represents a virtual function. A property belongs to either a Object_info or a Interface_info.

val vfuncinfo : t Ctypes.structure Ctypes.typ
val get_offset : t Ctypes.structure Ctypes.ptr -> int

Obtain the offset of the function pointer in the class struct. The value 0xFFFF indicates that the struct offset is unknown.

val get_signal : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the signal for the virtual function if one is set. The signal comes from the object or interface to which this virtual function belongs. In order to avoid circular call graph between VFunc_info and Signal_info, this function will return a Callable_info. It is upto the user to use Signal_info.from_callableinfo in order to have the Signal_info.

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.VFunc_info.flags list

Obtain the flags for this virtual function info. See VFunc_infoFlags for more information about possible flag values.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to vfunc info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes vfunc info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a VFunc_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to vfunc info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes vfunc info to callable info

val from_callableinfo : Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a VFunc_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Value_info/index.html b/docs/GObject_introspection/Value_info/index.html deleted file mode 100644 index d748203..0000000 --- a/docs/GObject_introspection/Value_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Value_info (gobject-introspection.GObject_introspection.Value_info)

Module GObject_introspection.Value_info

type t

Represents a enum value of a Enum_info.

val valueinfo : t Ctypes.structure Ctypes.typ
val get_value : t Ctypes.structure Ctypes.ptr -> int64

Obtain the enumeration value of the Value_info.

val cast_from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to enum info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection/Version/index.html b/docs/GObject_introspection/Version/index.html deleted file mode 100644 index 6955646..0000000 --- a/docs/GObject_introspection/Version/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Version (gobject-introspection.GObject_introspection.Version)

Module GObject_introspection.Version

val get_major_version : unit -> int

* Returns the major version number of the girepository library. (e.g. in version 1.58.2 this is 1.) *

val get_minor_version : unit -> int

* Returns the minor version number of the girepository library. (e.g. in version 1.58.2 this is 58.) *

val get_micro_version : unit -> int

* Returns the micro version number of the girepository library. (e.g. in version 1.58.2 this is 2.) *

\ No newline at end of file diff --git a/docs/GObject_introspection/index.html b/docs/GObject_introspection/index.html deleted file mode 100644 index f1f2ba6..0000000 --- a/docs/GObject_introspection/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection (gobject-introspection.GObject_introspection)

Module GObject_introspection

module Arg_info : sig ... end
module Base_info : sig ... end
module Bindings_stubs_arg_info : sig ... end
module Bindings_stubs_base_info : sig ... end
module Bindings_stubs_field_info : sig ... end
module Bindings_stubs_function_info : sig ... end
module Bindings_stubs_g_param : sig ... end
module Bindings_stubs_g_signal : sig ... end
module Bindings_stubs_types : sig ... end
module Bindings_stubs_vfunc_info : sig ... end
module Callable_info : sig ... end
module Constant_info : sig ... end
module Conversions : sig ... end
module Enum_info : sig ... end
module Field_info : sig ... end
module Function_info : sig ... end
module GParam : sig ... end
module GSignal : sig ... end
module Interface_info : sig ... end
module Object_info : sig ... end
module Property_info : sig ... end
module Registered_type_info : sig ... end
module Repository : sig ... end
module Signal_info : sig ... end
module Struct_info : sig ... end
module Stubs : sig ... end
module Type_info : sig ... end
module Types : sig ... end
module Union_info : sig ... end
module Utils : sig ... end
module VFunc_info : sig ... end
module Value_info : sig ... end
module Version : sig ... end
\ No newline at end of file diff --git a/docs/GObject_introspection__Arg_info/.dune-keep b/docs/GObject_introspection__Arg_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Arg_info/index.html b/docs/GObject_introspection__Arg_info/index.html deleted file mode 100644 index ff63fb8..0000000 --- a/docs/GObject_introspection__Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Arg_info (gobject-introspection.GObject_introspection__Arg_info)

Module GObject_introspection__Arg_info

Arg_info — Struct representing an argument

type t

Arg_info represents an argument. An argument is always part of a Callable_info.

val arginfo : t Ctypes.structure Ctypes.typ
val get_direction : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.direction

Obtain the direction of the argument. Check GIDirection for possible direction values.

val get_closure : t Ctypes.structure Ctypes.ptr -> int

Obtain the index of the user data argument. This is only valid for arguments which are callbacks. Returns index of the user data argument or -1 if there is none.

val get_destroy : t Ctypes.structure Ctypes.ptr -> int

Obtains the index of the GDestroyNotify argument. This is only valid for arguments which are callbacks. Returns index of the GDestroyNotify argument or -1 if there is none

val get_ownership_transfer : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

Obtain the ownership transfer for this argument. GITransfer contains a list of possible values.

val may_be_null : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the type of the argument includes the possibility of NULL. For 'in' values this means that NULL is a valid value. For 'out' values, this means that NULL may be returned. See also Arg_info.is_optional.

val is_caller_allocates : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is a pointer to a struct or object that will receive an output of a function. The default assumption for Arg_info.Out arguments which have allocation is that the callee allocates; if this is TRUE, then the caller must allocate.

val is_optional : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is optional. For 'out' arguments this means that you can pass NULL in order to ignore the result.

val is_return_value : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the argument is a return value. It can either be a parameter or a return value.

val is_skip : t Ctypes.structure Ctypes.ptr -> bool

Obtain if an argument is only useful in C.

val get_scope : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.scope_type
val get_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr
val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to arg info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes arg info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Arg_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Arg_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Base_info/.dune-keep b/docs/GObject_introspection__Base_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Base_info/index.html b/docs/GObject_introspection__Base_info/index.html deleted file mode 100644 index c80f6fe..0000000 --- a/docs/GObject_introspection__Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Base_info (gobject-introspection.GObject_introspection__Base_info)

Module GObject_introspection__Base_info

type t

Base_info is the common base struct of all other *Info structs accessible through the Repository API. All other structs can be casted to a Base_info

val baseinfo : t Ctypes.structure Ctypes.typ
val base_info_ref : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Increases the reference count of underlying Base_info *info.

val base_info_unref : t Ctypes.structure Ctypes.ptr -> unit

Decreases the reference count of underlying Base_info *info . When its reference count drops to 0, the info is freed.

val get_name : t Ctypes.structure Ctypes.ptr -> string option

Obtain the name of the info . What the name represents depends on the GIInfoType of the info . For instance for Function_info it is the name of the function.

val equal : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr -> bool

Compare two Base_info. Using pointer comparison is not practical since many functions return different instances of Base_info that refers to the same part of the TypeLib; use this function instead to do Base_info comparisons.

val get_namespace : t Ctypes.structure Ctypes.ptr -> string

Obtain the namespace of info

val is_deprecated : t Ctypes.structure Ctypes.ptr -> bool

Obtain whether the info is represents a metadata which is deprecated or not.

val get_container : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr option

Obtain the container of the info . The container is the parent Base_info. For instance, the parent of a Function_info is an Object_info or Interface_info.

val get_type : t Ctypes.structure Ctypes.ptr -> Bindings.Base_info.info_type

Obtain the info type of the Base_info.

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_arg_info/.dune-keep b/docs/GObject_introspection__Bindings_stubs_arg_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_arg_info/index.html b/docs/GObject_introspection__Bindings_stubs_arg_info/index.html deleted file mode 100644 index ac48931..0000000 --- a/docs/GObject_introspection__Bindings_stubs_arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_arg_info (gobject-introspection.GObject_introspection__Bindings_stubs_arg_info)

Module GObject_introspection__Bindings_stubs_arg_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-FOREIGN/index.html deleted file mode 100644 index b7617c3..0000000 --- a/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_arg_info.FOREIGN)

Module type GObject_introspection__Bindings_stubs_arg_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-TYPE/index.html deleted file mode 100644 index a77aaa6..0000000 --- a/docs/GObject_introspection__Bindings_stubs_arg_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_arg_info.TYPE)

Module type GObject_introspection__Bindings_stubs_arg_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_base_info/.dune-keep b/docs/GObject_introspection__Bindings_stubs_base_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_base_info/index.html b/docs/GObject_introspection__Bindings_stubs_base_info/index.html deleted file mode 100644 index 8564bdd..0000000 --- a/docs/GObject_introspection__Bindings_stubs_base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_base_info (gobject-introspection.GObject_introspection__Bindings_stubs_base_info)

Module GObject_introspection__Bindings_stubs_base_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_base_info/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_base_info/module-type-FOREIGN/index.html deleted file mode 100644 index 73484fc..0000000 --- a/docs/GObject_introspection__Bindings_stubs_base_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_base_info.FOREIGN)

Module type GObject_introspection__Bindings_stubs_base_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_base_info/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_base_info/module-type-TYPE/index.html deleted file mode 100644 index a81a377..0000000 --- a/docs/GObject_introspection__Bindings_stubs_base_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_base_info.TYPE)

Module type GObject_introspection__Bindings_stubs_base_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_field_info/.dune-keep b/docs/GObject_introspection__Bindings_stubs_field_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_field_info/index.html b/docs/GObject_introspection__Bindings_stubs_field_info/index.html deleted file mode 100644 index b4c8d17..0000000 --- a/docs/GObject_introspection__Bindings_stubs_field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_field_info (gobject-introspection.GObject_introspection__Bindings_stubs_field_info)

Module GObject_introspection__Bindings_stubs_field_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_field_info/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_field_info/module-type-FOREIGN/index.html deleted file mode 100644 index bcca202..0000000 --- a/docs/GObject_introspection__Bindings_stubs_field_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_field_info.FOREIGN)

Module type GObject_introspection__Bindings_stubs_field_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_field_info/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_field_info/module-type-TYPE/index.html deleted file mode 100644 index 7baf2f9..0000000 --- a/docs/GObject_introspection__Bindings_stubs_field_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_field_info.TYPE)

Module type GObject_introspection__Bindings_stubs_field_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_function_info/.dune-keep b/docs/GObject_introspection__Bindings_stubs_function_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_function_info/index.html b/docs/GObject_introspection__Bindings_stubs_function_info/index.html deleted file mode 100644 index 8fb6f24..0000000 --- a/docs/GObject_introspection__Bindings_stubs_function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_function_info (gobject-introspection.GObject_introspection__Bindings_stubs_function_info)

Module GObject_introspection__Bindings_stubs_function_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_function_info/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_function_info/module-type-FOREIGN/index.html deleted file mode 100644 index 425c372..0000000 --- a/docs/GObject_introspection__Bindings_stubs_function_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_function_info.FOREIGN)

Module type GObject_introspection__Bindings_stubs_function_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_function_info/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_function_info/module-type-TYPE/index.html deleted file mode 100644 index e610bb4..0000000 --- a/docs/GObject_introspection__Bindings_stubs_function_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_function_info.TYPE)

Module type GObject_introspection__Bindings_stubs_function_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_param/.dune-keep b/docs/GObject_introspection__Bindings_stubs_g_param/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_g_param/index.html b/docs/GObject_introspection__Bindings_stubs_g_param/index.html deleted file mode 100644 index c2ba5af..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_param/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_g_param (gobject-introspection.GObject_introspection__Bindings_stubs_g_param)

Module GObject_introspection__Bindings_stubs_g_param

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_param/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_g_param/module-type-FOREIGN/index.html deleted file mode 100644 index 1a7c586..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_param/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_g_param.FOREIGN)

Module type GObject_introspection__Bindings_stubs_g_param.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_param/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_g_param/module-type-TYPE/index.html deleted file mode 100644 index 8ca4eeb..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_param/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_g_param.TYPE)

Module type GObject_introspection__Bindings_stubs_g_param.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_signal/.dune-keep b/docs/GObject_introspection__Bindings_stubs_g_signal/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_g_signal/index.html b/docs/GObject_introspection__Bindings_stubs_g_signal/index.html deleted file mode 100644 index 58efc25..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_signal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_g_signal (gobject-introspection.GObject_introspection__Bindings_stubs_g_signal)

Module GObject_introspection__Bindings_stubs_g_signal

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-FOREIGN/index.html deleted file mode 100644 index 711c56a..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_g_signal.FOREIGN)

Module type GObject_introspection__Bindings_stubs_g_signal.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-TYPE/index.html deleted file mode 100644 index 15a0aad..0000000 --- a/docs/GObject_introspection__Bindings_stubs_g_signal/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_g_signal.TYPE)

Module type GObject_introspection__Bindings_stubs_g_signal.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_types/.dune-keep b/docs/GObject_introspection__Bindings_stubs_types/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_types/index.html b/docs/GObject_introspection__Bindings_stubs_types/index.html deleted file mode 100644 index 6efe418..0000000 --- a/docs/GObject_introspection__Bindings_stubs_types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_types (gobject-introspection.GObject_introspection__Bindings_stubs_types)

Module GObject_introspection__Bindings_stubs_types

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_types/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_types/module-type-FOREIGN/index.html deleted file mode 100644 index e97dba9..0000000 --- a/docs/GObject_introspection__Bindings_stubs_types/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_types.FOREIGN)

Module type GObject_introspection__Bindings_stubs_types.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_types/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_types/module-type-TYPE/index.html deleted file mode 100644 index 4a6a89c..0000000 --- a/docs/GObject_introspection__Bindings_stubs_types/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_types.TYPE)

Module type GObject_introspection__Bindings_stubs_types.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_vfunc_info/.dune-keep b/docs/GObject_introspection__Bindings_stubs_vfunc_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Bindings_stubs_vfunc_info/index.html b/docs/GObject_introspection__Bindings_stubs_vfunc_info/index.html deleted file mode 100644 index 12b9c4d..0000000 --- a/docs/GObject_introspection__Bindings_stubs_vfunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Bindings_stubs_vfunc_info (gobject-introspection.GObject_introspection__Bindings_stubs_vfunc_info)

Module GObject_introspection__Bindings_stubs_vfunc_info

include Ctypes
type ('a, 'b) pointer = ('a'b) Ctypes_static.pointer
type 'a ptr = ('a[ `C ]) pointer
type 'a ocaml = 'a Ctypes_static.ocaml
type 'a carray = 'a Ctypes_static.carray
type 'a bigarray_class = 'a Ctypes_static.bigarray_class
val genarray : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Genarray.t; carray : 'a carray; dims : int array; element : 'a; layout : 'l; > bigarray_class
val array1 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array1.t; carray : 'a carray; dims : int; element : 'a; layout : 'l; > bigarray_class
val array2 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array2.t; carray : 'a carray carray; dims : int * int; element : 'a; layout : 'l; > bigarray_class
val array3 : < ba_repr : 'b; bigarray : ('a'b'l) Bigarray.Array3.t; carray : 'a carray carray carray; dims : int * int * int; element : 'a; layout : 'l; > bigarray_class
type ('a, 'kind) structured = ('a'kind) Ctypes_static.structured
type 'a structure = ('a[ `Struct ]) structured
type 'a union = ('a[ `Union ]) structured
type ('a, 't) field = ('a't) Ctypes_static.field
type 'a abstract = 'a Ctypes_static.abstract
type 'a typ = 'a Ctypes_static.typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr = Ctypes.Intptr
val intptr_t : Intptr.t typ
module Ptrdiff = Ctypes.Ptrdiff
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr = Ctypes.Uintptr
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
val sizeof : 'a typ -> int
val alignment : 'a typ -> int
val format_typ : ?⁠name:string -> Stdlib.Format.formatter -> 'a typ -> unit
val format_fn : ?⁠name:string -> Stdlib.Format.formatter -> 'a fn -> unit
val string_of_typ : ?⁠name:string -> 'a typ -> string
val string_of_fn : ?⁠name:string -> 'a fn -> string
val format : 'a typ -> Stdlib.Format.formatter -> 'a -> unit
val string_of : 'a typ -> 'a -> string
val null : unit ptr
val (!@) : 'a ptr -> 'a
val (<-@) : 'a ptr -> 'a -> unit
val (+@) : ('a'b) pointer -> int -> ('a'b) pointer
val (-@) : ('a'b) pointer -> int -> ('a'b) pointer
val ptr_diff : ('a'b) pointer -> ('a'b) pointer -> int
val from_voidp : 'a typ -> unit ptr -> 'a ptr
val to_voidp : 'a ptr -> unit ptr
val allocate : ?⁠finalise:('a ptr -> unit) -> 'a typ -> 'a -> 'a ptr
val allocate_n : ?⁠finalise:('a ptr -> unit) -> 'a typ -> count:int -> 'a ptr
val ptr_compare : 'a ptr -> 'a ptr -> int
val is_null : 'a ptr -> bool
val reference_type : 'a ptr -> 'a typ
val ptr_of_raw_address : nativeint -> unit ptr
val funptr_of_raw_address : nativeint -> (unit -> unit) Ctypes_static.static_funptr
val raw_address_of_ptr : unit ptr -> nativeint
val string_from_ptr : char ptr -> length:int -> string
val ocaml_string_start : string -> string ocaml
val ocaml_bytes_start : Stdlib.Bytes.t -> Stdlib.Bytes.t ocaml
module CArray = Ctypes.CArray
val bigarray_start : < ba_repr : 'c; bigarray : 'b; carray : 'd; dims : 'e; element : 'a; layout : 'l; > bigarray_class -> 'b -> 'a ptr
val bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val fortran_bigarray_of_ptr : < ba_repr : 'f; bigarray : 'b; carray : 'c; dims : 'i; element : 'a; layout : Bigarray.fortran_layout; > bigarray_class -> 'i -> ('a'f) Bigarray.kind -> 'a ptr -> 'b
val array_of_bigarray : < ba_repr : 'a; bigarray : 'b; carray : 'c; dims : 'd; element : 'e; layout : Bigarray.c_layout; > bigarray_class -> 'b -> 'c
val bigarray_of_array : < ba_repr : 'f; bigarray : 'b; carray : 'c carray; dims : 'i; element : 'a; layout : Bigarray.c_layout; > bigarray_class -> ('a'f) Bigarray.kind -> 'c carray -> 'b
val make : ?⁠finalise:(('a'b) structured -> unit) -> ('a'b) structured typ -> ('a'b) structured
val setf : ('b'c) structured -> ('a('b'c) structured) field -> 'a -> unit
val getf : ('b'c) structured -> ('a('b'c) structured) field -> 'a
val (@.) : ('b'c) structured -> ('a('b'c) structured) field -> 'a ptr
val (|->) : ('b'c) structured ptr -> ('a('b'c) structured) field -> 'a ptr
val offsetof : ('a'b structure) field -> int
val field_type : ('a'b) field -> 'a typ
val field_name : ('a'b) field -> string
val addr : ('a'b) structured -> ('a'b) structured ptr
val coerce : 'a typ -> 'b typ -> 'a -> 'b
val coerce_fn : 'a fn -> 'b fn -> 'a -> 'b
module type FOREIGN = sig ... end
module type TYPE = sig ... end
module Root = Ctypes.Root
exception Unsupported of string
exception ModifyingSealedType of string
exception IncompleteType
type uncoercible_info = Ctypes.uncoercible_info
exception Uncoercible of uncoercible_info
val lift : 'a -> 'a
val field : t a. 't Ctypes_static.typ -> string -> 'a Ctypes_static.typ -> ('a't) Ctypes_static.field
val seal : a. 'a Ctypes_static.typ -> unit
type 'a const = 'a
val constant : string -> 'a Ctypes_static.typ -> 'a
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64) list -> 'a Cstubs_internals.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html b/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html deleted file mode 100644 index 8b7cfda..0000000 --- a/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-FOREIGN/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -FOREIGN (gobject-introspection.GObject_introspection__Bindings_stubs_vfunc_info.FOREIGN)

Module type GObject_introspection__Bindings_stubs_vfunc_info.FOREIGN

type 'a fn
type 'a return
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a return fn
type 'a result
val foreign : string -> ('a -> 'b) fn -> ('a -> 'b) result
val foreign_value : string -> 'a typ -> 'a ptr result
\ No newline at end of file diff --git a/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-TYPE/index.html b/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-TYPE/index.html deleted file mode 100644 index fe4a4fb..0000000 --- a/docs/GObject_introspection__Bindings_stubs_vfunc_info/module-type-TYPE/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -TYPE (gobject-introspection.GObject_introspection__Bindings_stubs_vfunc_info.TYPE)

Module type GObject_introspection__Bindings_stubs_vfunc_info.TYPE

type 'a typ
val void : unit typ
val char : char typ
val schar : int typ
val short : int typ
val int : int typ
val long : Signed.long typ
val llong : Signed.llong typ
val nativeint : nativeint typ
val int8_t : int typ
val int16_t : int typ
val int32_t : int32 typ
val int64_t : int64 typ
module Intptr : Signed.S
val intptr_t : Intptr.t typ
module Ptrdiff : Signed.S
val ptrdiff_t : Ptrdiff.t typ
val camlint : int typ
val uchar : Unsigned.uchar typ
val bool : bool typ
val uint8_t : Unsigned.uint8 typ
val uint16_t : Unsigned.uint16 typ
val uint32_t : Unsigned.uint32 typ
val uint64_t : Unsigned.uint64 typ
val size_t : Unsigned.size_t typ
val ushort : Unsigned.ushort typ
val sint : Signed.sint typ
val uint : Unsigned.uint typ
val ulong : Unsigned.ulong typ
val ullong : Unsigned.ullong typ
module Uintptr : Unsigned.S
val uintptr_t : Uintptr.t typ
val float : float typ
val double : float typ
val ldouble : LDouble.t typ
val complex32 : Stdlib.Complex.t typ
val complex64 : Stdlib.Complex.t typ
val complexld : ComplexL.t typ
val ptr : 'a typ -> 'a Ctypes_static.ptr typ
val ptr_opt : 'a typ -> 'a Ctypes_static.ptr option typ
val string : string typ
val string_opt : string option typ
val ocaml_string : string Ctypes_static.ocaml typ
val ocaml_bytes : Stdlib.Bytes.t Ctypes_static.ocaml typ
val array : int -> 'a typ -> 'a Ctypes_static.carray typ
val bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.c_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val fortran_bigarray : < ba_repr : 'b; bigarray : 'bigarray; carray : 'c; dims : 'dims; element : 'a; layout : Bigarray.fortran_layout; > Ctypes_static.bigarray_class -> 'dims -> ('a'b) Bigarray.kind -> 'bigarray typ
val typ_of_bigarray_kind : ('a'b) Bigarray.kind -> 'a typ
type ('a, 't) field
val structure : string -> 's Ctypes_static.structure typ
val union : string -> 's Ctypes_static.union typ
val field : ('s[< `Struct | `Union ] as b) Ctypes_static.structured typ -> string -> 'a typ -> ('a('s'b) Ctypes_static.structured) field
val seal : ('a[< `Struct | `Union ]) Ctypes_static.structured typ -> unit
val view : ?⁠format_typ:((Stdlib.Format.formatter -> unit) -> Stdlib.Format.formatter -> unit) -> ?⁠format:(Stdlib.Format.formatter -> 'b -> unit) -> read:('a -> 'b) -> write:('b -> 'a) -> 'a typ -> 'b typ
val typedef : 'a typ -> string -> 'a typ
val abstract : name:string -> size:int -> alignment:int -> 'a Ctypes_static.abstract typ
val lift_typ : 'a Ctypes_static.typ -> 'a typ
type 'a fn = 'a Ctypes_static.fn
val (@->) : 'a typ -> 'b fn -> ('a -> 'b) fn
val returning : 'a typ -> 'a fn
type 'a static_funptr = 'a Ctypes_static.static_funptr
val static_funptr : 'a fn -> 'a Ctypes_static.static_funptr typ
type 'a const
val constant : string -> 'a typ -> 'a const
val enum : string -> ?⁠typedef:bool -> ?⁠unexpected:(int64 -> 'a) -> ('a * int64 const) list -> 'a typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Callable_info/.dune-keep b/docs/GObject_introspection__Callable_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Callable_info/index.html b/docs/GObject_introspection__Callable_info/index.html deleted file mode 100644 index 734dc5a..0000000 --- a/docs/GObject_introspection__Callable_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Callable_info (gobject-introspection.GObject_introspection__Callable_info)

Module GObject_introspection__Callable_info

Callable_info — Struct representing a callable.

type t

Callable_info represents an entity which is callable. Currently a function (Function_info), virtual function, (VFunc_info) or callback (GICallbackInfo). A callable has a list of arguments (Arg_info), a return type, direction and a flag which decides if it returns null

val callableinfo : t Ctypes.structure Ctypes.typ
val can_throw_gerror : t Ctypes.structure Ctypes.ptr -> bool

Does the function throws an error.

val get_n_args : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of arguments (both IN and OUT) for this callable.

val get_return_attribute : t Ctypes.structure Ctypes.ptr -> string option

Retrieve an arbitrary attribute associated with the return value.

val is_method : t Ctypes.structure Ctypes.ptr -> bool

Determines if the callable info is a method. For VFunc_infos, GICallbackInfos, and Signal_infos, this is always true. Otherwise, this looks at the Function_info.Is_method flag on the Function_info. Concretely, this function returns whether Callable_info.get_n_args matches the number of arguments in the raw C method. For methods, there is one more C argument than is exposed by introspection: the "self" or "this" object.

val may_return_null : t Ctypes.structure Ctypes.ptr -> bool

See if a callable could return NULL.

val skip_return : t Ctypes.structure Ctypes.ptr -> bool

See if a callable's return value is only useful in C.

val get_arg : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Arg_info.t Ctypes.structure Ctypes.ptr

Obtain information about a particular argument of this callable.

val get_return_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr

Obtain the return type of a callable item as a Type_info.

val get_caller_owns : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

See whether the caller owns the return value of this callable. GITransfer contains a list of possible transfer values.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to callable info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Constant_info/.dune-keep b/docs/GObject_introspection__Constant_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Constant_info/index.html b/docs/GObject_introspection__Constant_info/index.html deleted file mode 100644 index 82af529..0000000 --- a/docs/GObject_introspection__Constant_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Constant_info (gobject-introspection.GObject_introspection__Constant_info)

Module GObject_introspection__Constant_info

Constant_info — Struct representing a constant

type t

Constant_info represents a constant. A constant has a type associated which can be obtained by calling Constant_info.get_type and a value, which can be obtained by calling GIConstant.get_value.

val constantinfo : t Ctypes.structure Ctypes.typ
val get_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type of the constant as a Type_info.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to constant info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes constant info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Constant_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Constant_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val get_value : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Types.argument_t Ctypes.union Ctypes.ptr

Obtain the value associated with the Constant_info and store it in the value parameter. argument needs to be allocated before passing it in. The size of the constant value stored in argument will be returned. Free the value with Constant_info.free_value.

\ No newline at end of file diff --git a/docs/GObject_introspection__Conversions/.dune-keep b/docs/GObject_introspection__Conversions/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Conversions/index.html b/docs/GObject_introspection__Conversions/index.html deleted file mode 100644 index aa31599..0000000 --- a/docs/GObject_introspection__Conversions/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Conversions (gobject-introspection.GObject_introspection__Conversions)

Module GObject_introspection__Conversions

Conversions functions

type carray_of_strings = char Ctypes.ptr Ctypes.ptr

C pointer of null terminated array of C strings

val carray_of_strings : carray_of_strings Ctypes.typ
val carray_of_strings_to_list : char Ctypes.ptr Ctypes.ptr -> string list

Converts C array of strings to OCaml list of strings

val carray_of_strings_to_array : carray_of_strings -> string array

Converts C array of strings to OCaml array of strings

type glist

GList struct

val glist : glist Ctypes.structure Ctypes.typ
val glist_data : (unit Ctypes_static.ptrglist Ctypes.structure) Ctypes.field
val glist_next : (glist Ctypes.structure Ctypes_static.ptr optionglist Ctypes.structure) Ctypes.field
val glist_prev : (glist Ctypes.structure Ctypes_static.ptr optionglist Ctypes.structure) Ctypes.field
val g_free : unit Ctypes_static.ptr -> unit
val g_free_t : (unit Ctypes_static.ptr -> unit) Ctypes.fn
val glist_free_full : glist Ctypes.structure Ctypes_static.ptr -> (unit Ctypes_static.ptr -> unit) -> unit
val g_list_next : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> glist Ctypes.structure Ctypes_static.ptr option

Get the next element of a glist

val g_list_data : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> unit Ctypes_static.ptr

Get the void ptr data of the current element

val glist_of_strings_to_list : (glist[ `Struct ]) Ctypes.structured Ctypes.ptr -> string list

Transform a GList of strings to an OCaml list of strings

type gslist

GSList struct

val gslist : gslist Ctypes.structure Ctypes.typ
val gslist_data : (unit Ctypes_static.ptrgslist Ctypes.structure) Ctypes.field
val gslist_next : (gslist Ctypes.structure Ctypes_static.ptr optiongslist Ctypes.structure) Ctypes.field
val g_slist_next : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> gslist Ctypes.structure Ctypes_static.ptr option

Get the next element of a gslist

val g_slist_data : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> unit Ctypes_static.ptr

Get the void ptr data of the current element

val gslist_of_strings_to_list : (gslist[ `Struct ]) Ctypes.structured Ctypes.ptr -> string list

Transform a GSList of strings to an OCaml list of strings

\ No newline at end of file diff --git a/docs/GObject_introspection__Enum_info/.dune-keep b/docs/GObject_introspection__Enum_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Enum_info/index.html b/docs/GObject_introspection__Enum_info/index.html deleted file mode 100644 index fa1f06d..0000000 --- a/docs/GObject_introspection__Enum_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Enum_info (gobject-introspection.GObject_introspection__Enum_info)

Module GObject_introspection__Enum_info

Enum_info — Structs representing an enumeration and its values

type t

A Enum_info represents an enumeration and a Value_info struct represents a value of an enumeration. The Enum_info contains a set of values and a type The Value_info is fetched by calling Enum_info.get_value on a Enum_info.

val enuminfo : t Ctypes.structure Ctypes.typ
val get_n_values : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of values this enumeration contains.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this enum type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr

Obtain an enum type method at index n .

val get_value : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Value_info.t Ctypes.structure Ctypes.ptr option

Obtain a value for this enumeration.

val get_error_domain : t Ctypes.structure Ctypes.ptr -> string option

Obtain the string form of the quark for the error domain associated with this enum, if any.

val get_storage_type : t Ctypes.structure Ctypes.ptr -> Bindings.Types.tag

Obtain the tag of the type used for the enum in the C ABI. This will be a signed or unsigned integral type. Note that in the current implementation the width of the type is computed correctly, but the signed or unsigned nature of the type may not match the sign of the type used by the C compiler.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to enum info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to base info

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Enum_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to enum info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to registeredtype info

val from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Enum_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Enum_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Field_info/.dune-keep b/docs/GObject_introspection__Field_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Field_info/index.html b/docs/GObject_introspection__Field_info/index.html deleted file mode 100644 index d546fcd..0000000 --- a/docs/GObject_introspection__Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Field_info (gobject-introspection.GObject_introspection__Field_info)

Module GObject_introspection__Field_info

Field_info — Struct representing a struct or union field

type t

A Field_info struct represents a field of a struct (see Struct_info), union (see Union_info) or an object (see Object_info). The Field_info is fetched by calling Struct_info.get_field, Union_info.get_field or Object_info.get_field. A field has a size, type and a struct offset asssociated and a set of flags, which is currently GI_FIELD_IS_READABLE or GI_FIELD_IS_WRITABLE.

val fieldinfo : t Ctypes.structure Ctypes.typ
val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.Field_info.flags list

Obtain the flags for this Field_info. See Field_info.flags for possible flag values.

val get_offset : t Ctypes.structure Ctypes.ptr -> int

Obtain the offset in bits of the field member, this is relative to the beginning of the struct or union.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the size in bits of the field member, this is how much space you need to allocate to store the field.

val get_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type of a field as a Type_info.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to field info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes field info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Field_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Field_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Function_info/.dune-keep b/docs/GObject_introspection__Function_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Function_info/index.html b/docs/GObject_introspection__Function_info/index.html deleted file mode 100644 index b3a75c8..0000000 --- a/docs/GObject_introspection__Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Function_info (gobject-introspection.GObject_introspection__Function_info)

Module GObject_introspection__Function_info

Function_info — Struct representing a function.

type t

Function_info represents a function, method or constructor. To find out what kind of entity a Function_info represents, call Function_info.get_flags. See also Callable_info for information on how to retreive arguments and other metadata.

val functioninfo : t Ctypes.structure Ctypes.typ
val get_symbol : t Ctypes.structure Ctypes.ptr -> string

Obtain the symbol of the function. The symbol is the name of the exported function, suitable to be used as an argument to g_module_symbol().

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.Function_info.flags list

Obtain the Function_infoFlags for the info .

val get_property : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Property_info.t Ctypes.structure Ctypes.ptr option

Obtain the property associated with this Function_info. Only Function_info with the flag GIFunction.Is_getter or GIFunction.Is_setter have a property set. For other cases, NULL will be returned.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the virtual function associated with this Function_info. Only Function_info with the flag Wraps_vfunc has a virtual function set. For other cases, None will be returned. In order to avoid circular call graph between Function_info and VFunc_info, this function will return a Callable_info. It is upto the user to use VFunc_info.from_callableinfo in order to have the VFunc_info.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to function info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes function info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to function info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes function info to callable info

val from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Function_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a Function_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__GParam/.dune-keep b/docs/GObject_introspection__GParam/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__GParam/index.html b/docs/GObject_introspection__GParam/index.html deleted file mode 100644 index 9541216..0000000 --- a/docs/GObject_introspection__GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__GParam (gobject-introspection.GObject_introspection__GParam)

Module GObject_introspection__GParam

val all_flags : (int64 * Bindings.GParam.flags) list
val flags_list : Bindings.GParam.flags list Ctypes.typ
val flag_to_string : Bindings.GParam.flags -> string
\ No newline at end of file diff --git a/docs/GObject_introspection__GSignal/.dune-keep b/docs/GObject_introspection__GSignal/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__GSignal/index.html b/docs/GObject_introspection__GSignal/index.html deleted file mode 100644 index c3d6870..0000000 --- a/docs/GObject_introspection__GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__GSignal (gobject-introspection.GObject_introspection__GSignal)

Module GObject_introspection__GSignal

val all_flags : (int64 * Bindings.GSignal.flags) list
val flags_list : Bindings.GSignal.flags list Ctypes.typ
val flag_to_string : Bindings.GSignal.flags -> string
\ No newline at end of file diff --git a/docs/GObject_introspection__Interface_info/.dune-keep b/docs/GObject_introspection__Interface_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Interface_info/index.html b/docs/GObject_introspection__Interface_info/index.html deleted file mode 100644 index 22773b3..0000000 --- a/docs/GObject_introspection__Interface_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Interface_info (gobject-introspection.GObject_introspection__Interface_info)

Module GObject_introspection__Interface_info

Interface_info — Struct representing a GInterface

type t

Interface_info represents a GInterface type. A GInterface has methods, fields, properties, signals, interfaces, constants, virtual functions and prerequisites.

val interfaceinfo : t Ctypes.structure Ctypes.typ
val get_n_prerequisites : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of prerequisites for this interface type. A prerequisites is another interface that needs to be implemented for interface, similar to an base class for GObjects.

val get_prerequisite : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type prerequisites index n .

val get_n_properties : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of properties that this interface type has.

val get_property : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Property_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type property at index n .

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this interface type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type method at index n .

val find_method : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr option

Obtain a method of the interface type given a name . NULL will be returned if there's no method available with that name.

val get_n_signals : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of signals that this interface type has.

val get_signal : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Signal_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type signal at index n .

val find_signal : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Signal_info.t Ctypes.structure Ctypes.ptr option

Find a signal of the interface

val get_n_constants : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of constants that this interface type has.

val get_constant : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Constant_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type constant at index n .

val get_iface_struct : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Struct_info.t Ctypes.structure Ctypes.ptr option

Returns the layout C structure associated with this GInterface.

val get_n_vfuncs : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of virtual functions that this interface type has.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.VFunc_info.t Ctypes.structure Ctypes.ptr

Obtain an interface type virtual function at index n .

val find_vfunc : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.VFunc_info.t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name . See the documentation for g_object_info_find_vfunc() for more information on virtuals.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to interface info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes interface info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Interface_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to enum info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to registeredtype info

val from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Interface_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Interface_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Object_info/.dune-keep b/docs/GObject_introspection__Object_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Object_info/index.html b/docs/GObject_introspection__Object_info/index.html deleted file mode 100644 index 8d5c317..0000000 --- a/docs/GObject_introspection__Object_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Object_info (gobject-introspection.GObject_introspection__Object_info)

Module GObject_introspection__Object_info

Object_info — Struct representing a GObject

type t

Object_info represents a GObject. This doesn't represent a specific instance of a GObject, instead this represent the object type (eg class). A GObject has methods, fields, properties, signals, interfaces, constants and virtual functions.

val objectinfo : t Ctypes.structure Ctypes.typ
val get_abstract : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the object type is an abstract type, eg if it cannot be instantiated

val get_fundamental : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the object type is of a fundamental type which is not G_TYPE_OBJECT. This is mostly for supporting GstMiniObject.

val get_parent : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Obtain the parent of the object type.

val get_type_name : t Ctypes.structure Ctypes.ptr -> string

Obtain the name of the objects class/type.

val get_type_init : t Ctypes.structure Ctypes.ptr -> string

Obtain the function which when called will return the GType function for which this object type is registered.

val get_n_constants : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of constants that this object type has.

val get_constant : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Constant_info.t Ctypes.structure Ctypes.ptr

Obtain an object type constant at index n .

val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields that this object type has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Field_info.t Ctypes.structure Ctypes.ptr

Obtain an object type field at index n .

val get_n_interfaces : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of interfaces that this object type has.

val get_interface : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Interface_info.t Ctypes.structure Ctypes.ptr

Obtain an object type interface at index n .

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods that this object type has.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr

Obtain an object type method at index n .

val find_method : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr option

Obtain a method of the object type given a name . None will be returned if there's no method available with that name.

val get_n_properties : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of properties that this object type has.

val get_property : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Property_info.t Ctypes.structure Ctypes.ptr

Obtain an object type property at index n .

val get_n_signals : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of signals that this object type has.

val get_signal : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Signal_info.t Ctypes.structure Ctypes.ptr

Obtain an object type signal at index n .

val find_signal : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Signal_info.t Ctypes.structure Ctypes.ptr option

Find a signal with a name.

val get_n_vfuncs : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of virtual functions that this object type has.

val get_vfunc : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.VFunc_info.t Ctypes.structure Ctypes.ptr

Obtain an object type virtual function at index n .

val find_vfunc : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.VFunc_info.t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name . Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method associated for a virtual. If there is one, it may be retrieved using VFunc_info.get_invoker, otherwise None will be returned. See the documentation for VFunc_info.get_invoker for more information on invoking virtuals.

val get_class_struct : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Struct_info.t Ctypes.structure Ctypes.ptr option

Every GObject has two structures; an instance structure and a class structure. This function returns the metadata for the class structure. It returns a Struct_info.t or None.

val find_method_using_interfaces : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr option * t Ctypes.structure Ctypes.ptr option

Obtain a method of the object given a name , searching both the object info and any interfaces it implements. None will be returned if there's no method available with that name. Note that this function does *not* search parent classes; you will have to chain up if that's desired.

val get_ref_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to ref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoRefFunction, to fetch the function pointer see Object_info.get_ref_function.

val get_unref_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to unref this object type. It's mainly used fundamental types. The type signature for the symbol is Object_infoUnrefFunction, to fetch the function pointer see Object_info.get_unref_function.

val get_set_value_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to convert set a GValue giving an object instance pointer of this object type. I's mainly used fundamental types. The type signature for the symbol is Object_infoSetValueFunction, to fetch the function pointer see Object_info.get_set_value_function.

val get_get_value_function : t Ctypes.structure Ctypes.ptr -> string option

Obtain the symbol name of the function that should be called to convert an object instance pointer of this object type to a GValue. I's mainly used fundamental types. The type signature for the symbol is Object_infoGetValueFunction, to fetch the function pointer see Object_info.get_get_value_function.

val find_vfunc_using_interfaces : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.VFunc_info.t Ctypes.structure Ctypes.ptr option * t Ctypes.structure Ctypes.ptr option

Locate a virtual function slot with name name , searching both the object info and any interfaces it implements. Note that the namespace for virtuals is distinct from that of methods; there may or may not be a concrete method associated for a virtual. If there is one, it may be retrieved using g_vfunc_info_get_invoker(), otherwise None will be returned. Note that this function does *not* search parent classes; you will have to chain up if that's desired.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to object info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes object info to base info

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Object_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to object info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes object info to registeredtype info

val from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Object_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Object_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Property_info/.dune-keep b/docs/GObject_introspection__Property_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Property_info/index.html b/docs/GObject_introspection__Property_info/index.html deleted file mode 100644 index c0afa07..0000000 --- a/docs/GObject_introspection__Property_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Property_info (gobject-introspection.GObject_introspection__Property_info)

Module GObject_introspection__Property_info

Property_info — Struct representing a property

type t

Property_info represents a property. A property belongs to either a Object_info or a Interface_info.

val propertyinfo : t Ctypes.structure Ctypes.typ
val get_ownership_transfer : t Ctypes.structure Ctypes.ptr -> Bindings.Arg_info.transfer

Obtain the ownership transfer for this property. See GITransfer for more information about transfer values.

val get_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for the property info .

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.GParam.flags list

Obtain the flags for this property info. See GParamFlags for more information about possible flag values.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to property info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes property info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Property_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Property_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Registered_type_info/.dune-keep b/docs/GObject_introspection__Registered_type_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Registered_type_info/index.html b/docs/GObject_introspection__Registered_type_info/index.html deleted file mode 100644 index 00080a1..0000000 --- a/docs/GObject_introspection__Registered_type_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Registered_type_info (gobject-introspection.GObject_introspection__Registered_type_info)

Module GObject_introspection__Registered_type_info

Registered_type_info — Struct representing a struct with a GType.

type t
val registeredtypeinfo : t Ctypes.structure Ctypes.typ
val get_type_name : t Ctypes.structure Ctypes.ptr -> string option

Obtain the type name of the struct within the GObject type system. This type can be passed to g_type_name() to get a #GType.

val get_g_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Repository.gtype option

Obtain the gtype for this registered type or None which a special meaning. It means that either there is no type information associated with this info or that the shared library which provides the type_init function for this info cannot be called.

val get_type_init : t Ctypes.structure Ctypes.ptr -> string option

Obtain the type init function for info . The type init function is the function which will register the GType within the GObject type system. Usually this is not called by langauge bindings or applications, use Registered_type_info.get_g_type directly instead.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to registeredtype info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Registered_type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Repository/.dune-keep b/docs/GObject_introspection__Repository/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Repository/index.html b/docs/GObject_introspection__Repository/index.html deleted file mode 100644 index 8a31b0b..0000000 --- a/docs/GObject_introspection__Repository/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Repository (gobject-introspection.GObject_introspection__Repository)

Module GObject_introspection__Repository

Repository — GObject Introspection repository manager module Repository is used to manage repositories of namespaces. Namespaces are represented on disk by type libraries (.typelib files).

type repository
type typelib
val get_default : unit -> repository

Returns the singleton process-global default Repository.

val require : ?⁠repository:repository -> string -> ?⁠version:string -> unit -> (typelib, string) Stdlib.result

Force the namespace namespace_ to be loaded if it isn't already. If namespace_ is not loaded, this function will search for a ".typelib" file using the repository search path. In addition, a version version of namespace may be specified. If version is not specified, the latest will be used).

val get_loaded_namespaces : ?⁠repository:repository -> unit -> string list

Return the list of currently loaded namespaces.

val get_dependencies : ?⁠repository:repository -> string -> string list

Return an list of all (transitive) versioned dependencies for namespace_ . Returned strings are of the form namespace-version. Note: namespace_ must have already been loaded using a function such as Repository.require before calling this function. To get only the immediate dependencies for namespace_ , use Repository.get_immediate_dependencies.

val get_c_prefix : ?⁠repository:repository -> string -> string

This function returns the "C prefix", or the C level namespace associated with the given introspection namespace. Each C symbol starts with this prefix, as well each GType in the library. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val get_version : ?⁠repository:repository -> string -> string

This function returns the loaded version associated with the given namespace namespace_ . Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val get_typelib_path : ?⁠repository:repository -> string -> string

If namespace namespace_ is loaded, return the full path to the .typelib file it was loaded from. If the typelib for namespace namespace_ was included in a shared library, return the special string "<builtin>".

val enumerate_versions : ?⁠repository:repository -> string -> string list

Obtain an unordered list of versions (either currently loaded or available) for namespace_ in this repository .

val get_search_path : unit -> string list

Returns the current search path Repository will use when loading typelib files. The list is internal to GIRespository and should not be freed, nor should its string elements.

val prepend_search_path : string -> unit

Prepends directory to the typelib search path. See Repository.get_search_path.

val find_by_name : ?⁠repository:repository -> string -> string -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr option

Searches for a particular entry in a namespace. Before calling this function for a particular namespace, you must call Repository.require once to load the namespace, or otherwise ensure the namespace has already been loaded.

val get_n_infos : ?⁠repository:repository -> string -> int

This function returns the number of metadata entries in given namespace namespace_ . The namespace must have already been loaded before calling this function.

val get_info : ?⁠repository:repository -> string -> int -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

This function returns a particular metadata entry in the given namespace namespace_ . The namespace must have already been loaded before calling this function. See Repository.get_n_infos to find the maximum number of entries.

val get_shared_library : ?⁠repository:repository -> string -> string option

This function returns a comma-separated list of paths to the shared C libraries associated with the given namespace namespace_ . There may be no shared library path associated, in which case this function will return NULL. Note: The namespace must have already been loaded using a function such as Repository.require before calling this function.

val prepend_library_path : string -> unit

Prepends directory to the search path that is used to search shared libraries referenced by imported namespaces. Multiple calls to this function all contribute to the final list of paths. The list of paths is unique and shared for all Repository instances across the process, but it doesn't affect namespaces imported before the call. If the library is not found in the directories configured in this way, loading will fall back to the system library path (ie. LD_LIBRARY_PATH and DT_RPATH in ELF systems). See the documentation of your dynamic linker for full details.

type gtype = int64
val gtype : int64 Ctypes.typ
val find_by_gtype : ?⁠repository:repository -> gtype -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr option

Searches all loaded namespaces for a particular #GType. Note that in order to locate the metadata, the namespace corresponding to the type must first have been loaded. There is currently no mechanism for determining the namespace which corresponds to an arbitrary GType - thus, this function will operate most reliably when you know the GType to originate from be from a loaded namespace.

\ No newline at end of file diff --git a/docs/GObject_introspection__Signal_info/.dune-keep b/docs/GObject_introspection__Signal_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Signal_info/index.html b/docs/GObject_introspection__Signal_info/index.html deleted file mode 100644 index 7fd17df..0000000 --- a/docs/GObject_introspection__Signal_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Signal_info (gobject-introspection.GObject_introspection__Signal_info)

Module GObject_introspection__Signal_info

Signal_info — Struct representing a signal.

type t

Signal_info represents a signal. It's a sub-struct of Callable_info and contains a set of flags and a class closure. See Callable_info for information on how to retreive arguments and other metadata from the signal.

val signalinfo : t Ctypes.structure Ctypes.typ
val true_stops_emit : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the returning true in the signal handler will stop the emission of the signal.

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.GSignal.flags list

Obtain the flags for this signal info. See GSignalFlags for more information about possible flag values.

val get_class_closure : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the class closure for this signal if one is set. The class closure is a virtual function on the type that the signal belongs to. If the signal lacks a closure None will be returned. In order to avoid circular call graph between Signal_info and VFunc_info, this function will return a Callable_info. It is upto the user to use GIVSignalInfo.from_callableinfo in order to have the VFunc_info.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to signal info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes signal info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Signal_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to signal info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes signal info to callable info

val from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Signal_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a Signal_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Struct_info/.dune-keep b/docs/GObject_introspection__Struct_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Struct_info/index.html b/docs/GObject_introspection__Struct_info/index.html deleted file mode 100644 index 0ed8dae..0000000 --- a/docs/GObject_introspection__Struct_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Struct_info (gobject-introspection.GObject_introspection__Struct_info)

Module GObject_introspection__Struct_info

Struct_info — Module representing a C structure

type t

Struct_info represents a generic C structure type. A structure has methods and fields.

val structinfo : t Ctypes.structure Ctypes.typ
val is_gtype_struct : t Ctypes.structure Ctypes.ptr -> bool

Return true if this structure represents the "class structure" for some GObject or GInterface. This function is mainly useful to hide this kind of structure from generated public APIs.

val get_alignment : t Ctypes.structure Ctypes.ptr -> int

Obtain the required alignment of the structure.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the total size of the structure.

val is_foreign : t Ctypes.structure Ctypes.ptr -> bool

No doc yet

val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields this structure has.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods this structure has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Field_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for field with specified index.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for method with specified index.

val find_method : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr option

Obtain the type information for method named name .

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to struct info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes struct info to registeredtype info

val from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/.dune-keep b/docs/GObject_introspection__Stubs/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Stubs/Arg_info/index.html b/docs/GObject_introspection__Stubs/Arg_info/index.html deleted file mode 100644 index 6056eed..0000000 --- a/docs/GObject_introspection__Stubs/Arg_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Arg_info (gobject-introspection.GObject_introspection__Stubs.Arg_info) \ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/Base_info/index.html b/docs/GObject_introspection__Stubs/Base_info/index.html deleted file mode 100644 index 1bb0d33..0000000 --- a/docs/GObject_introspection__Stubs/Base_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Base_info (gobject-introspection.GObject_introspection__Stubs.Base_info)

Module GObject_introspection__Stubs.Base_info

val gi_info_type_invalid : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_function : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_callback : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_struct : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_boxed : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_enum : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_flags : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_object : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_interface : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_constant : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_invalid_0 : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_union : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_value : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_signal : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_vfunc : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_property : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_field : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_arg : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_type : int64 GObject_introspection.Bindings_stubs_base_info.const
val gi_info_type_unresolved : int64 GObject_introspection.Bindings_stubs_base_info.const
val info_type : Bindings__Base_info.info_type GObject_introspection.Bindings_stubs_base_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/Field_info/index.html b/docs/GObject_introspection__Stubs/Field_info/index.html deleted file mode 100644 index 15d4401..0000000 --- a/docs/GObject_introspection__Stubs/Field_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Field_info (gobject-introspection.GObject_introspection__Stubs.Field_info)

Module GObject_introspection__Stubs.Field_info

val gi_field_is_readable : int64 GObject_introspection.Bindings_stubs_field_info.const
val gi_field_is_writable : int64 GObject_introspection.Bindings_stubs_field_info.const
val flags : int64 GObject_introspection.Bindings_stubs_field_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/Function_info/index.html b/docs/GObject_introspection__Stubs/Function_info/index.html deleted file mode 100644 index 402d79d..0000000 --- a/docs/GObject_introspection__Stubs/Function_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Function_info (gobject-introspection.GObject_introspection__Stubs.Function_info)

Module GObject_introspection__Stubs.Function_info

val gi_function_is_method : int64 GObject_introspection.Bindings_stubs_function_info.const
val gi_function_is_constructor : int64 GObject_introspection.Bindings_stubs_function_info.const
val gi_function_is_getter : int64 GObject_introspection.Bindings_stubs_function_info.const
val gi_function_is_setter : int64 GObject_introspection.Bindings_stubs_function_info.const
val gi_function_wraps_vfunc : int64 GObject_introspection.Bindings_stubs_function_info.const
val gi_function_throws : int64 GObject_introspection.Bindings_stubs_function_info.const
val flags : int64 GObject_introspection.Bindings_stubs_function_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/GParam/index.html b/docs/GObject_introspection__Stubs/GParam/index.html deleted file mode 100644 index 69f18a7..0000000 --- a/docs/GObject_introspection__Stubs/GParam/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GParam (gobject-introspection.GObject_introspection__Stubs.GParam)

Module GObject_introspection__Stubs.GParam

val g_param_readable : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_writable : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_readwrite : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_construct : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_construct_only : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_lax_validation : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_static_name : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_static_nick : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_static_blurb : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_explicit_notify : int64 GObject_introspection.Bindings_stubs_g_param.const
val g_param_deprecated : int64 GObject_introspection.Bindings_stubs_g_param.const
val flags : int64 GObject_introspection.Bindings_stubs_g_param.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/GSignal/index.html b/docs/GObject_introspection__Stubs/GSignal/index.html deleted file mode 100644 index 878f6a7..0000000 --- a/docs/GObject_introspection__Stubs/GSignal/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GSignal (gobject-introspection.GObject_introspection__Stubs.GSignal) \ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/Types/index.html b/docs/GObject_introspection__Stubs/Types/index.html deleted file mode 100644 index 8b4fca3..0000000 --- a/docs/GObject_introspection__Stubs/Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -Types (gobject-introspection.GObject_introspection__Stubs.Types)

Module GObject_introspection__Stubs.Types

val gi_type_tag_void : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_boolean : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_int8 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_uint8 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_int16 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_uint16 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_int32 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_uint32 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_int64 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_uint64 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_float : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_double : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_gtype : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_utf8 : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_filename : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_array : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_interface : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_glist : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_gslist : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_ghash : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_error : int64 GObject_introspection.Bindings_stubs_types.const
val gi_type_tag_unichar : int64 GObject_introspection.Bindings_stubs_types.const
val tag : Bindings__Types.tag GObject_introspection.Bindings_stubs_types.typ
val gi_array_type_c : int64 GObject_introspection.Bindings_stubs_types.const
val gi_array_type_array : int64 GObject_introspection.Bindings_stubs_types.const
val gi_array_type_ptr_array : int64 GObject_introspection.Bindings_stubs_types.const
val gi_array_type_byte_array : int64 GObject_introspection.Bindings_stubs_types.const
val array_type : Bindings__Types.array_type GObject_introspection.Bindings_stubs_types.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/VFunc_info/index.html b/docs/GObject_introspection__Stubs/VFunc_info/index.html deleted file mode 100644 index 60fc651..0000000 --- a/docs/GObject_introspection__Stubs/VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -VFunc_info (gobject-introspection.GObject_introspection__Stubs.VFunc_info)

Module GObject_introspection__Stubs.VFunc_info

val gi_vfunc_must_chain_up : int64 GObject_introspection.Bindings_stubs_vfunc_info.const
val gi_vfunc_must_override : int64 GObject_introspection.Bindings_stubs_vfunc_info.const
val gi_vfunc_must_not_override : int64 GObject_introspection.Bindings_stubs_vfunc_info.const
val gi_vfunc_throws : int64 GObject_introspection.Bindings_stubs_vfunc_info.const
val flags : int64 GObject_introspection.Bindings_stubs_vfunc_info.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__Stubs/index.html b/docs/GObject_introspection__Stubs/index.html deleted file mode 100644 index c3e2735..0000000 --- a/docs/GObject_introspection__Stubs/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Stubs (gobject-introspection.GObject_introspection__Stubs)

Module GObject_introspection__Stubs

module Base_info : sig ... end
module Function_info : sig ... end
module Types : sig ... end
module VFunc_info : sig ... end
module Arg_info : sig ... end
module Field_info : sig ... end
module GParam : sig ... end
module GSignal : sig ... end
\ No newline at end of file diff --git a/docs/GObject_introspection__Type_info/.dune-keep b/docs/GObject_introspection__Type_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Type_info/index.html b/docs/GObject_introspection__Type_info/index.html deleted file mode 100644 index cfdc747..0000000 --- a/docs/GObject_introspection__Type_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Type_info (gobject-introspection.GObject_introspection__Type_info)

Module GObject_introspection__Type_info

Type_info — Struct representing a type

type t

Type_info represents a type. You can retrieve a type info from an argument (see Arg_info), a function return value (see Function_info), a field (see Field_info), a property (see Property_info), a constant (see Constant_info) or for a union discriminator (see Union_info). A type can either be a of a basic type which is a standard C primitive type or an interface type. For interface types you need to call Type_info.get_interface to get a reference to the base info for that interface.

val typeinfo : t Ctypes.structure Ctypes.typ
val to_string : t Ctypes.structure Ctypes.ptr -> string

Obtain a string representation of type.

val is_pointer : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the type is passed as a reference. Note that the types of GI_DIRECTION_OUT and GI_DIRECTION_INOUT parameters will only be pointers if the underlying type being transferred is a pointer (i.e. only if the type of the C function’s formal parameter is a pointer to a pointer).

val get_tag : t Ctypes.structure Ctypes.ptr -> Bindings.Types.tag

Obtain the type tag for the type. See GITypeTag for a list of type tags.

val get_array_length : t Ctypes.structure Ctypes.ptr -> int

Obtain the array length of the type. The type tag must be a GIType.array or -1 will returned.

val get_array_fixed_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the fixed array size of the type. The type tag must be a GIType.array or -1 will returned.

val is_zero_terminated : t Ctypes.structure Ctypes.ptr -> bool

Obtain if the last element of the array is NULL. The type tag must be a GIType.array or FALSE will returned.

val get_array_type : t Ctypes.structure Ctypes.ptr -> Bindings.Types.array_type option

Obtain the array type for this type. See GIArrayType for a list of possible values. If the type tag of this type is not array, None will be returned.

val unsafe_get_param_type : t Ctypes.structure Ctypes.ptr -> int -> t Ctypes.structure Ctypes.ptr

Obtain the parameter type n. It is used to get the parameter type of generic * container. For example if the current Type_info.t is an array, a GList, a * GSList or an Hash, you have to use this in order to get the Type_info.t of * the data of the container. * Basicaly it is done with Type_info.get_param_type type_info 0 . * https://github.com/GNOME/pygobject/blob/288bd2957916568666c3d5d27e8c868d67b7e8c9/gi/pygi-argument.c#L526 * https://github.com/ruby-gnome2/ruby-gnome2/blob/ec4160b4f4c5432c6ff8a9e962e7ffeacfd48869/gobject-introspection/ext/gobject-introspection/rb-gi-argument.c#L928 * This function is unsafe meanings that it is your responsability to not use * a number out of bounds.

val get_param_type : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

This is just an alias to Type_info.unsage_get_param_type with the index set to 0.

val get_interface : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr option

For types which have Types.Interface such as GObjects and boxed values, this function returns full information about the referenced type. You can then inspect the type of the returned Base_info to further query whether it is a concrete GObject, a GInterface, a structure, etc. using Base_info.get_type.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to typeinfo.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes typeinfo to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Type_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Type_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Types/.dune-keep b/docs/GObject_introspection__Types/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Types/index.html b/docs/GObject_introspection__Types/index.html deleted file mode 100644 index 32fed7b..0000000 --- a/docs/GObject_introspection__Types/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Types (gobject-introspection.GObject_introspection__Types)

Module GObject_introspection__Types

common types

type argument_t
val argument : argument_t Ctypes.union Ctypes.typ
val v_boolean : (bool, argument_t Ctypes.union) Ctypes.field
val v_int8 : (int, argument_t Ctypes.union) Ctypes.field
val v_uint8 : (Unsigned.uint8, argument_t Ctypes.union) Ctypes.field
val v_int16 : (int, argument_t Ctypes.union) Ctypes.field
val v_uint16 : (Unsigned.uint16, argument_t Ctypes.union) Ctypes.field
val v_int32 : (int32, argument_t Ctypes.union) Ctypes.field
val v_uint32 : (Unsigned.uint32, argument_t Ctypes.union) Ctypes.field
val v_int64 : (int64, argument_t Ctypes.union) Ctypes.field
val v_uint64 : (Unsigned.uint64, argument_t Ctypes.union) Ctypes.field
val v_float : (float, argument_t Ctypes.union) Ctypes.field
val v_double : (float, argument_t Ctypes.union) Ctypes.field
val v_short : (int, argument_t Ctypes.union) Ctypes.field
val v_ushort : (Unsigned.ushort, argument_t Ctypes.union) Ctypes.field
val v_int : (int, argument_t Ctypes.union) Ctypes.field
val v_uint : (Unsigned.uint, argument_t Ctypes.union) Ctypes.field
val v_long : (Signed.long, argument_t Ctypes.union) Ctypes.field
val v_ulong : (Unsigned.ulong, argument_t Ctypes.union) Ctypes.field
val v_ssize : (PosixTypes.ssize_t, argument_t Ctypes.union) Ctypes.field
val v_size : (PosixTypes.size_t, argument_t Ctypes.union) Ctypes.field
val v_string : (string, argument_t Ctypes.union) Ctypes.field
val v_pointer : (unit Ctypes_static.ptr optionargument_t Ctypes.union) Ctypes.field
\ No newline at end of file diff --git a/docs/GObject_introspection__Union_info/.dune-keep b/docs/GObject_introspection__Union_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Union_info/index.html b/docs/GObject_introspection__Union_info/index.html deleted file mode 100644 index dccf864..0000000 --- a/docs/GObject_introspection__Union_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Union_info (gobject-introspection.GObject_introspection__Union_info)

Module GObject_introspection__Union_info

Union_info — Module representing a C structure

type t

Union_info represents a union type. A union has methods and fields. Unions can optionally have a discriminator, which is a field deciding what type of real union fields is valid for specified instance.

val unioninfo : t Ctypes.structure Ctypes.typ
val get_n_fields : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of fields this union has.

val get_size : t Ctypes.structure Ctypes.ptr -> int

Obtain the total size of the union.

val get_alignment : t Ctypes.structure Ctypes.ptr -> int

Obtain the required alignment of the union.

val get_n_methods : t Ctypes.structure Ctypes.ptr -> int

Obtain the number of methods this union has.

val get_field : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Field_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for field with specified index.

val get_method : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr

Obtain the type information for method with specified index.

val find_method : t Ctypes.structure Ctypes.ptr -> string -> GObject_introspection.Function_info.t Ctypes.structure Ctypes.ptr option

Obtain the type information for method named name .

val is_discriminated : t Ctypes.structure Ctypes.ptr -> bool

Return true if this union contains discriminator field.

val get_discriminator_offset : t Ctypes.structure Ctypes.ptr -> int

Returns offset of the discriminator field in the structure.

val get_discriminator_type : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Type_info.t Ctypes.structure Ctypes.ptr

Obtain the type information of the union discriminator.

val get_discriminator : t Ctypes.structure Ctypes.ptr -> int -> GObject_introspection.Constant_info.t Ctypes.structure Ctypes.ptr

Obtain discriminator value assigned for n-th union field, i.e. n-th union field is the active one if discriminator contains this constant.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to union info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes union info to base info

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Union_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes registeredtype info to union info.

val cast_to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes union info to registeredtype info

val from_registeredtypeinfo : GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Union_info.t from a Registered_type_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

val to_registeredtypeinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Registered_type_info.t Ctypes.structure Ctypes.ptr

Return a Registered_type_info.t form a Union_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Registered_type_info.registeredtypeinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Utils/.dune-keep b/docs/GObject_introspection__Utils/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Utils/index.html b/docs/GObject_introspection__Utils/index.html deleted file mode 100644 index 6203a37..0000000 --- a/docs/GObject_introspection__Utils/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Utils (gobject-introspection.GObject_introspection__Utils)

Module GObject_introspection__Utils

val flags_list_of_int64 : (int64 * 'a) list -> int64 -> 'a list
val int64_of_flags_list : (int64 * 'a) list -> 'a list -> int64
val generate_flags_list_view : int64 Ctypes.typ -> (int64 * 'a) list -> 'a list Ctypes.typ
\ No newline at end of file diff --git a/docs/GObject_introspection__VFunc_info/.dune-keep b/docs/GObject_introspection__VFunc_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__VFunc_info/index.html b/docs/GObject_introspection__VFunc_info/index.html deleted file mode 100644 index 7a0322e..0000000 --- a/docs/GObject_introspection__VFunc_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__VFunc_info (gobject-introspection.GObject_introspection__VFunc_info)

Module GObject_introspection__VFunc_info

VFunc_info — Struct representing a virtual function.

type t

GIVfuncInfo represents a virtual function. A property belongs to either a Object_info or a Interface_info.

val vfuncinfo : t Ctypes.structure Ctypes.typ
val get_offset : t Ctypes.structure Ctypes.ptr -> int

Obtain the offset of the function pointer in the class struct. The value 0xFFFF indicates that the struct offset is unknown.

val get_signal : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr option

Obtain the signal for the virtual function if one is set. The signal comes from the object or interface to which this virtual function belongs. In order to avoid circular call graph between VFunc_info and Signal_info, this function will return a Callable_info. It is upto the user to use Signal_info.from_callableinfo in order to have the Signal_info.

val get_flags : t Ctypes.structure Ctypes.ptr -> Bindings.VFunc_info.flags list

Obtain the flags for this virtual function info. See VFunc_infoFlags for more information about possible flag values.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to vfunc info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes vfunc info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a VFunc_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val cast_from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes callable info to vfunc info.

val cast_to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes vfunc info to callable info

val from_callableinfo : GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a VFunc_info.t from a Callable_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_callableinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Callable_info.t Ctypes.structure Ctypes.ptr

Return a Callable_info.t from a VFunc_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Value_info/.dune-keep b/docs/GObject_introspection__Value_info/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Value_info/index.html b/docs/GObject_introspection__Value_info/index.html deleted file mode 100644 index 43e2833..0000000 --- a/docs/GObject_introspection__Value_info/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Value_info (gobject-introspection.GObject_introspection__Value_info)

Module GObject_introspection__Value_info

Value_info — Struct representing a value

type t

Represents a enum value of a Enum_info.

val valueinfo : t Ctypes.structure Ctypes.typ
val get_value : t Ctypes.structure Ctypes.ptr -> int64

Obtain the enumeration value of the Value_info.

val cast_from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes base info to enum info.

val cast_to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Just cast OCaml Ctypes enum info to base info

val add_unref_finaliser : t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Add unref of the C underlying structure whith Gc.finalise.

val from_baseinfo : GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr -> t Ctypes.structure Ctypes.ptr

Return a Struct_info.t from a Base_info.t, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

val to_baseinfo : t Ctypes.structure Ctypes.ptr -> GObject_introspection.Base_info.t Ctypes.structure Ctypes.ptr

Return a Base_info.t form a Struct_info, the underlying C structure ref count is increased and the value is Gc.finalis"ed" with Base_info.baseinfo_unref.

\ No newline at end of file diff --git a/docs/GObject_introspection__Version/.dune-keep b/docs/GObject_introspection__Version/.dune-keep deleted file mode 100644 index e69de29..0000000 diff --git a/docs/GObject_introspection__Version/index.html b/docs/GObject_introspection__Version/index.html deleted file mode 100644 index c952628..0000000 --- a/docs/GObject_introspection__Version/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -GObject_introspection__Version (gobject-introspection.GObject_introspection__Version)

Module GObject_introspection__Version

val get_major_version : unit -> int

* Returns the major version number of the girepository library. (e.g. in version 1.58.2 this is 1.) *

val get_minor_version : unit -> int

* Returns the minor version number of the girepository library. (e.g. in version 1.58.2 this is 58.) *

val get_micro_version : unit -> int

* Returns the micro version number of the girepository library. (e.g. in version 1.58.2 this is 2.) *

\ No newline at end of file diff --git a/docs/index.html b/docs/index.html deleted file mode 100644 index 7bc1e00..0000000 --- a/docs/index.html +++ /dev/null @@ -1,2 +0,0 @@ - -index (gobject-introspection.index)

gobject-introspection index

Library gobject-introspection

The entry point of this library is the module: GObject_introspection.

Library gobject-introspection.bindings

The entry point of this library is the module: Bindings.

\ No newline at end of file diff --git a/docs/odoc.css b/docs/odoc.css deleted file mode 100644 index c80edff..0000000 --- a/docs/odoc.css +++ /dev/null @@ -1,764 +0,0 @@ -@charset "UTF-8"; -/* Copyright (c) 2016 The odoc contributors. All rights reserved. - Distributed under the ISC license, see terms at the end of the file. - odoc 1.4.2 */ - -/* Fonts */ -@import url('https://fonts.googleapis.com/css?family=Fira+Mono:400,500'); -@import url('https://fonts.googleapis.com/css?family=Noticia+Text:400,400i,700'); -@import url('https://fonts.googleapis.com/css?family=Fira+Sans:400,400i,500,500i,600,600i,700,700i'); - - -/* Reset a few things. */ - -html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, article, aside, canvas, details, embed, figure, figcaption, footer, header, hgroup, menu, nav, output, ruby, section, summary, time, mark, audio, video { - margin: 0; - padding: 0; - border: 0; - font-size: inherit; - font: inherit; - line-height: inherit; - vertical-align: baseline; - text-align: inherit; - color: inherit; - background: transparent; -} - -table { - border-collapse: collapse; - border-spacing: 0; -} - -*, *:before, *:after { - box-sizing: border-box; -} - -html { - font-size: 15px; -} - -body { - font-family: "Fira Sans", Helvetica, Arial, sans-serif; - text-align: left; - color: #333; - background: #FFFFFF; -} - -.content { - max-width: 90ex; - margin-left: calc(10vw + 20ex); - margin-right: 4ex; - margin-top: 20px; - margin-bottom: 50px; - font-family: "Noticia Text", Georgia, serif; - line-height: 1.5; -} - -.content>header { - margin-bottom: 30px; -} - -.content>header nav { - font-family: "Fira Sans", Helvetica, Arial, sans-serif; -} - -/* Basic markup elements */ - -b, strong { - font-weight: 500; -} - -i, em { - font-style: italic; -} - -sup { - vertical-align: super; -} - -sub { - vertical-align: sub; -} - -sup, sub { - font-size: 12px; - line-height: 0; - margin-left: 0.2ex; -} - -pre { - margin-top: 0.8em; - margin-bottom: 1.2em; -} - -p, ul, ol { - margin-top: 0.5em; - margin-bottom: 1em; -} -ul, ol { - list-style-position: outside -} - -ul>li { - margin-left: 22px; -} - -ol>li { - margin-left: 27.2px; -} - -li>*:first-child { - margin-top: 0 -} - -/* Text alignements, this should be forbidden. */ - -.left { - text-align: left; -} - -.right { - text-align: right; -} - -.center { - text-align: center; -} - -/* Links and anchors */ - -a { - text-decoration: none; - color: #2C5CBD; -} - -a:hover { - box-shadow: 0 1px 0 0 #2C5CBD; -} - -/* Linked highlight */ -*:target { - background-color: rgba(187,239,253,0.3) !important; - box-shadow: 0 0px 0 1px rgba(187,239,253,0.8) !important; - border-radius: 1px; -} - -*:hover>a.anchor { - visibility: visible; -} - -a.anchor:before { - content: "#" -} - -a.anchor:hover { - box-shadow: none; - text-decoration: none; - color: #555; -} - -a.anchor { - visibility: hidden; - position: absolute; - /* top: 0px; */ - /* margin-left: -3ex; */ - margin-left: -1.3em; - font-weight: normal; - font-style: normal; - padding-right: 0.4em; - padding-left: 0.4em; - /* To remain selectable */ - color: #d5d5d5; -} - -.spec > a.anchor { - margin-left: -2.3em; - padding-right: 0.9em; -} - -.xref-unresolved { - color: #2C5CBD; -} -.xref-unresolved:hover { - box-shadow: 0 1px 0 0 #CC6666; -} - -/* Section and document divisions. - Until at least 4.03 many of the modules of the stdlib start at .h7, - we restart the sequence there like h2 */ - -h1, h2, h3, h4, h5, h6, .h7, .h8, .h9, .h10 { - font-family: "Fira Sans", Helvetica, Arial, sans-serif; - font-weight: 400; - margin: 0.5em 0 0.5em 0; - padding-top: 0.1em; - line-height: 1.2; - overflow-wrap: break-word; -} - -h1 { - font-weight: 500; - font-size: 2.441em; - margin-top: 1.214em; -} - -h1 { - font-weight: 500; - font-size: 1.953em; - box-shadow: 0 1px 0 0 #ddd; -} - -h2 { - font-size: 1.563em; -} - -h3 { - font-size: 1.25em; -} - -small, .font_small { - font-size: 0.8em; -} - -h1 code, h1 tt { - font-size: inherit; - font-weight: inherit; -} - -h2 code, h2 tt { - font-size: inherit; - font-weight: inherit; -} - -h3 code, h3 tt { - font-size: inherit; - font-weight: inherit; -} - -h3 code, h3 tt { - font-size: inherit; - font-weight: inherit; -} - -h4 { - font-size: 1.12em; -} - - -/* Preformatted and code */ - -tt, code, pre { - font-family: "Fira Mono", courier; - font-weight: 400; -} - -pre { - padding: 0.1em; - border: 1px solid #eee; - border-radius: 5px; - overflow-x: auto; -} - -p code, li code { - background-color: #f6f8fa; - color: #0d2b3e; - border-radius: 3px; - padding: 0 0.3ex; -} - -p a > code { - color: #2C5CBD; -} - -/* Code blocks (e.g. Examples) */ - -pre code { - font-size: 0.893rem; -} - -/* Code lexemes */ - -.keyword { - font-weight: 500; -} - -/* Module member specification */ - -.spec:not(.include), .spec.include details summary { - background-color: #f6f8fa; - border-radius: 3px; - border-left: 4px solid #5c9cf5; - border-right: 5px solid transparent; - padding: 0.35em 0.5em; -} - -.spec.include details summary:hover { - background-color: #ebeff2; -} - -dl, div.spec, .doc, aside { - margin-bottom: 20px; -} - -dl > dd { - padding: 0.5em; -} - -dd> :first-child { - margin-top: 0; -} - -dl:last-child, dd> :last-child, aside:last-child, article:last-child { - margin-bottom: 0; -} - -dt+dt { - margin-top: 15px; -} - -section+section, section > header + dl { - margin-top: 25px; -} - -.spec.type .variant { - margin-left: 2ch; -} -.spec.type .variant p { - margin: 0; - font-style: italic; -} -.spec.type .record { - margin-left: 2ch; -} -.spec.type .record p { - margin: 0; - font-style: italic; -} - -div.def { - margin-top: 0; - text-indent: -2ex; - padding-left: 2ex; -} - -div.def+div.doc { - margin-left: 1ex; - margin-top: 2.5px -} - -div.doc>*:first-child { - margin-top: 0; -} - -/* The elements other than heading should be wrapped in