erl_nif.h
Include dependency graph for erl_nif.h:
![digraph {
graph [bgcolor="#00000000"]
node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
edge [color="#1414CE"]
"3" [label="assert.h" tooltip="assert.h"]
"6" [label="stdint.h" tooltip="stdint.h"]
"2" [label="term_typedef.h" tooltip="term_typedef.h"]
"4" [label="limits.h" tooltip="limits.h"]
"1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif.h" fillcolor="#BFBFBF"]
"5" [label="inttypes.h" tooltip="inttypes.h"]
"2" -> "3" [dir=forward tooltip="include"]
"2" -> "4" [dir=forward tooltip="include"]
"2" -> "5" [dir=forward tooltip="include"]
"2" -> "6" [dir=forward tooltip="include"]
"1" -> "2" [dir=forward tooltip="include"]
}](../../../_images/graphviz-eb54052af2f019fd3ea2682ccb2feed1490ea07b.png)
This graph shows which files directly or indirectly include erl_nif.h:
![digraph {
graph [bgcolor="#00000000"]
node [shape=rectangle style=filled fillcolor="#FFFFFF" font=Helvetica padding=2]
edge [color="#1414CE"]
"10" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.c"]
"47" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.c"]
"9" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bif.h"]
"57" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.h"]
"56" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.c"]
"55" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.h"]
"31" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/platform_nifs.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/platform_nifs.h"]
"18" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.c"]
"50" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.h"]
"46" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.h"]
"25" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/inet.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/inet.c"]
"24" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/inet.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/inet.h"]
"44" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.h"]
"59" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/exportedfunction.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/exportedfunction.h"]
"2" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/context.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/context.c"]
"8" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/context.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/context.h"]
"42" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.c"]
"43" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.h"]
"21" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets.c"]
"58" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets.h"]
"61" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h"]
"33" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.c"]
"32" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.h"]
"19" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.c"]
"53" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.h"]
"45" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/mailbox.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/mailbox.c"]
"11" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.c"]
"30" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/module.h"]
"5" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/avmpack.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/avmpack.c"]
"4" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/avmpack.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/avmpack.h"]
"29" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.c"]
"54" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.h"]
"1" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif.h" fillcolor="#BFBFBF"]
"27" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.c"]
"17" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_ssl.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_ssl.c"]
"23" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.h"]
"39" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_ssl.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_ssl.h"]
"41" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/portnifloader.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/portnifloader.c"]
"40" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/portnifloader.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/portnifloader.h"]
"20" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.c"]
"52" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.h"]
"28" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_crypto.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_crypto.c"]
"36" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_crypto.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_crypto.h"]
"26" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_net.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_net.c"]
"49" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets_hashtable.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets_hashtable.c"]
"37" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_net.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_net.h"]
"48" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets_hashtable.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/ets_hashtable.h"]
"15" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif_priv.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif_priv.h"]
"34" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/sys.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/sys.h"]
"7" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.c"]
"35" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.h"]
"13" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.c"]
"12" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.h"]
"6" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/globalcontext.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/globalcontext.c"]
"3" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/globalcontext.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/globalcontext.h"]
"14" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.c"]
"16" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_socket.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_socket.c"]
"51" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.h"]
"38" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_socket.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/otp_socket.h"]
"22" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.c"]
"60" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.h"]
"9" -> "10" [dir=back tooltip="include"]
"9" -> "11" [dir=back tooltip="include"]
"9" -> "7" [dir=back tooltip="include"]
"57" -> "10" [dir=back tooltip="include"]
"57" -> "2" [dir=back tooltip="include"]
"57" -> "47" [dir=back tooltip="include"]
"57" -> "14" [dir=back tooltip="include"]
"57" -> "7" [dir=back tooltip="include"]
"57" -> "16" [dir=back tooltip="include"]
"57" -> "19" [dir=back tooltip="include"]
"55" -> "56" [dir=back tooltip="include"]
"55" -> "22" [dir=back tooltip="include"]
"55" -> "27" [dir=back tooltip="include"]
"55" -> "7" [dir=back tooltip="include"]
"31" -> "7" [dir=back tooltip="include"]
"50" -> "6" [dir=back tooltip="include"]
"50" -> "7" [dir=back tooltip="include"]
"50" -> "16" [dir=back tooltip="include"]
"50" -> "18" [dir=back tooltip="include"]
"46" -> "10" [dir=back tooltip="include"]
"46" -> "47" [dir=back tooltip="include"]
"46" -> "21" [dir=back tooltip="include"]
"46" -> "6" [dir=back tooltip="include"]
"46" -> "27" [dir=back tooltip="include"]
"46" -> "7" [dir=back tooltip="include"]
"46" -> "28" [dir=back tooltip="include"]
"46" -> "26" [dir=back tooltip="include"]
"46" -> "16" [dir=back tooltip="include"]
"46" -> "17" [dir=back tooltip="include"]
"46" -> "42" [dir=back tooltip="include"]
"46" -> "43" [dir=back tooltip="include"]
"46" -> "18" [dir=back tooltip="include"]
"46" -> "20" [dir=back tooltip="include"]
"46" -> "33" [dir=back tooltip="include"]
"24" -> "25" [dir=back tooltip="include"]
"24" -> "26" [dir=back tooltip="include"]
"24" -> "16" [dir=back tooltip="include"]
"24" -> "17" [dir=back tooltip="include"]
"44" -> "6" [dir=back tooltip="include"]
"44" -> "45" [dir=back tooltip="include"]
"44" -> "7" [dir=back tooltip="include"]
"44" -> "16" [dir=back tooltip="include"]
"59" -> "9" [dir=back tooltip="include"]
"59" -> "30" [dir=back tooltip="include"]
"59" -> "35" [dir=back tooltip="include"]
"59" -> "31" [dir=back tooltip="include"]
"59" -> "50" [dir=back tooltip="include"]
"8" -> "9" [dir=back tooltip="include"]
"8" -> "2" [dir=back tooltip="include"]
"8" -> "12" [dir=back tooltip="include"]
"8" -> "15" [dir=back tooltip="include"]
"8" -> "21" [dir=back tooltip="include"]
"8" -> "22" [dir=back tooltip="include"]
"8" -> "6" [dir=back tooltip="include"]
"8" -> "23" [dir=back tooltip="include"]
"8" -> "14" [dir=back tooltip="include"]
"8" -> "11" [dir=back tooltip="include"]
"8" -> "30" [dir=back tooltip="include"]
"8" -> "7" [dir=back tooltip="include"]
"8" -> "35" [dir=back tooltip="include"]
"8" -> "28" [dir=back tooltip="include"]
"8" -> "26" [dir=back tooltip="include"]
"8" -> "16" [dir=back tooltip="include"]
"8" -> "17" [dir=back tooltip="include"]
"8" -> "42" [dir=back tooltip="include"]
"8" -> "43" [dir=back tooltip="include"]
"8" -> "40" [dir=back tooltip="include"]
"8" -> "19" [dir=back tooltip="include"]
"8" -> "20" [dir=back tooltip="include"]
"8" -> "44" [dir=back tooltip="include"]
"8" -> "32" [dir=back tooltip="include"]
"8" -> "29" [dir=back tooltip="include"]
"43" -> "25" [dir=back tooltip="include"]
"43" -> "7" [dir=back tooltip="include"]
"43" -> "26" [dir=back tooltip="include"]
"43" -> "16" [dir=back tooltip="include"]
"43" -> "17" [dir=back tooltip="include"]
"43" -> "42" [dir=back tooltip="include"]
"58" -> "21" [dir=back tooltip="include"]
"58" -> "3" [dir=back tooltip="include"]
"58" -> "7" [dir=back tooltip="include"]
"61" -> "10" [dir=back tooltip="include"]
"32" -> "33" [dir=back tooltip="include"]
"53" -> "6" [dir=back tooltip="include"]
"53" -> "14" [dir=back tooltip="include"]
"53" -> "17" [dir=back tooltip="include"]
"53" -> "19" [dir=back tooltip="include"]
"53" -> "20" [dir=back tooltip="include"]
"53" -> "54" [dir=back tooltip="include"]
"30" -> "9" [dir=back tooltip="include"]
"30" -> "11" [dir=back tooltip="include"]
"30" -> "7" [dir=back tooltip="include"]
"30" -> "31" [dir=back tooltip="include"]
"30" -> "32" [dir=back tooltip="include"]
"30" -> "34" [dir=back tooltip="include"]
"30" -> "29" [dir=back tooltip="include"]
"4" -> "5" [dir=back tooltip="include"]
"4" -> "6" [dir=back tooltip="include"]
"4" -> "7" [dir=back tooltip="include"]
"54" -> "10" [dir=back tooltip="include"]
"54" -> "55" [dir=back tooltip="include"]
"54" -> "2" [dir=back tooltip="include"]
"54" -> "8" [dir=back tooltip="include"]
"54" -> "47" [dir=back tooltip="include"]
"54" -> "57" [dir=back tooltip="include"]
"54" -> "21" [dir=back tooltip="include"]
"54" -> "58" [dir=back tooltip="include"]
"54" -> "49" [dir=back tooltip="include"]
"54" -> "48" [dir=back tooltip="include"]
"54" -> "59" [dir=back tooltip="include"]
"54" -> "60" [dir=back tooltip="include"]
"54" -> "3" [dir=back tooltip="include"]
"54" -> "25" [dir=back tooltip="include"]
"54" -> "27" [dir=back tooltip="include"]
"54" -> "23" [dir=back tooltip="include"]
"54" -> "14" [dir=back tooltip="include"]
"54" -> "11" [dir=back tooltip="include"]
"54" -> "30" [dir=back tooltip="include"]
"54" -> "7" [dir=back tooltip="include"]
"54" -> "28" [dir=back tooltip="include"]
"54" -> "26" [dir=back tooltip="include"]
"54" -> "16" [dir=back tooltip="include"]
"54" -> "17" [dir=back tooltip="include"]
"54" -> "61" [dir=back tooltip="include"]
"54" -> "43" [dir=back tooltip="include"]
"54" -> "50" [dir=back tooltip="include"]
"54" -> "32" [dir=back tooltip="include"]
"54" -> "29" [dir=back tooltip="include"]
"1" -> "2" [dir=back tooltip="include"]
"1" -> "3" [dir=back tooltip="include"]
"1" -> "51" [dir=back tooltip="include"]
"1" -> "17" [dir=back tooltip="include"]
"1" -> "20" [dir=back tooltip="include"]
"1" -> "52" [dir=back tooltip="include"]
"23" -> "24" [dir=back tooltip="include"]
"23" -> "27" [dir=back tooltip="include"]
"23" -> "7" [dir=back tooltip="include"]
"23" -> "28" [dir=back tooltip="include"]
"23" -> "26" [dir=back tooltip="include"]
"23" -> "16" [dir=back tooltip="include"]
"23" -> "17" [dir=back tooltip="include"]
"23" -> "18" [dir=back tooltip="include"]
"23" -> "29" [dir=back tooltip="include"]
"39" -> "17" [dir=back tooltip="include"]
"40" -> "41" [dir=back tooltip="include"]
"52" -> "6" [dir=back tooltip="include"]
"52" -> "53" [dir=back tooltip="include"]
"52" -> "20" [dir=back tooltip="include"]
"36" -> "28" [dir=back tooltip="include"]
"37" -> "26" [dir=back tooltip="include"]
"48" -> "21" [dir=back tooltip="include"]
"48" -> "49" [dir=back tooltip="include"]
"15" -> "2" [dir=back tooltip="include"]
"15" -> "6" [dir=back tooltip="include"]
"15" -> "14" [dir=back tooltip="include"]
"15" -> "16" [dir=back tooltip="include"]
"15" -> "17" [dir=back tooltip="include"]
"15" -> "18" [dir=back tooltip="include"]
"15" -> "19" [dir=back tooltip="include"]
"15" -> "20" [dir=back tooltip="include"]
"34" -> "2" [dir=back tooltip="include"]
"34" -> "6" [dir=back tooltip="include"]
"34" -> "11" [dir=back tooltip="include"]
"34" -> "7" [dir=back tooltip="include"]
"34" -> "16" [dir=back tooltip="include"]
"34" -> "20" [dir=back tooltip="include"]
"35" -> "11" [dir=back tooltip="include"]
"35" -> "7" [dir=back tooltip="include"]
"35" -> "28" [dir=back tooltip="include"]
"35" -> "36" [dir=back tooltip="include"]
"35" -> "26" [dir=back tooltip="include"]
"35" -> "37" [dir=back tooltip="include"]
"35" -> "16" [dir=back tooltip="include"]
"35" -> "38" [dir=back tooltip="include"]
"35" -> "17" [dir=back tooltip="include"]
"35" -> "39" [dir=back tooltip="include"]
"35" -> "40" [dir=back tooltip="include"]
"35" -> "18" [dir=back tooltip="include"]
"12" -> "13" [dir=back tooltip="include"]
"12" -> "14" [dir=back tooltip="include"]
"3" -> "4" [dir=back tooltip="include"]
"3" -> "2" [dir=back tooltip="include"]
"3" -> "8" [dir=back tooltip="include"]
"3" -> "46" [dir=back tooltip="include"]
"3" -> "48" [dir=back tooltip="include"]
"3" -> "6" [dir=back tooltip="include"]
"3" -> "14" [dir=back tooltip="include"]
"3" -> "11" [dir=back tooltip="include"]
"3" -> "30" [dir=back tooltip="include"]
"3" -> "7" [dir=back tooltip="include"]
"3" -> "28" [dir=back tooltip="include"]
"3" -> "26" [dir=back tooltip="include"]
"3" -> "37" [dir=back tooltip="include"]
"3" -> "16" [dir=back tooltip="include"]
"3" -> "38" [dir=back tooltip="include"]
"3" -> "17" [dir=back tooltip="include"]
"3" -> "39" [dir=back tooltip="include"]
"3" -> "42" [dir=back tooltip="include"]
"3" -> "43" [dir=back tooltip="include"]
"3" -> "40" [dir=back tooltip="include"]
"3" -> "18" [dir=back tooltip="include"]
"3" -> "50" [dir=back tooltip="include"]
"3" -> "44" [dir=back tooltip="include"]
"3" -> "33" [dir=back tooltip="include"]
"3" -> "34" [dir=back tooltip="include"]
"51" -> "15" [dir=back tooltip="include"]
"51" -> "21" [dir=back tooltip="include"]
"51" -> "24" [dir=back tooltip="include"]
"51" -> "45" [dir=back tooltip="include"]
"51" -> "14" [dir=back tooltip="include"]
"51" -> "7" [dir=back tooltip="include"]
"51" -> "16" [dir=back tooltip="include"]
"51" -> "43" [dir=back tooltip="include"]
"51" -> "19" [dir=back tooltip="include"]
"51" -> "52" [dir=back tooltip="include"]
"51" -> "33" [dir=back tooltip="include"]
"51" -> "54" [dir=back tooltip="include"]
"38" -> "16" [dir=back tooltip="include"]
"38" -> "17" [dir=back tooltip="include"]
"60" -> "22" [dir=back tooltip="include"]
"60" -> "11" [dir=back tooltip="include"]
"60" -> "7" [dir=back tooltip="include"]
}](../../../_images/graphviz-20fa86ba1d3c39731dc78def80402599c17cbc0d.png)
Public API for nifs, compatible with Erlang/OTP API.
Typedefs
-
typedef term ERL_NIF_TERM
A term.
-
typedef int32_t ErlNifPid
a pid
We currently only handle local pids.
-
typedef struct ResourceType ErlNifResourceType
Opaque resource type.
-
typedef uint64_t ErlNifMonitor
Opaque monitor type.
-
typedef int ErlNifEvent
Selectable event.
-
typedef void ErlNifResourceStop(ErlNifEnv *caller_env, void *obj, ErlNifEvent event, int is_direct_call)
Select stop callback.
-
typedef void ErlNifResourceDown(ErlNifEnv *caller_env, void *obj, ErlNifPid *pid, ErlNifMonitor *mon)
Resource monitor callback.
Enums
-
enum ErlNifSelectFlags
enif_select mode flags
ERL_NIF_SELECT_CANCEL which was introduced with OTP-22, is unimplemented.
Values:
-
enumerator ERL_NIF_SELECT_READ = 1
-
enumerator ERL_NIF_SELECT_WRITE = 2
-
enumerator ERL_NIF_SELECT_STOP = 4
-
enumerator ERL_NIF_SELECT_READ = 1
-
enum [anonymous]
enif_select result flags
ERL_NIF_SELECT_CANCEL which was introduced with OTP-22, is unimplemented.
Values:
-
enumerator ERL_NIF_SELECT_STOP_CALLED = 1
-
enumerator ERL_NIF_SELECT_STOP_SCHEDULED = 2
-
enumerator ERL_NIF_SELECT_INVALID_EVENT = -1
-
enumerator ERL_NIF_SELECT_FAILED = -2
-
enumerator ERL_NIF_SELECT_BADARG = -3
-
enumerator ERL_NIF_SELECT_STOP_CALLED = 1
Functions
-
ErlNifResourceType *enif_init_resource_type(ErlNifEnv *env, const char *name, const ErlNifResourceTypeInit *init, ErlNifResourceFlags flags, ErlNifResourceFlags *tried)
Create or take over (code upgrade) a resource type.
- Parameters:
env – the current environment
init – a structure describing the callbacks. Callbacks can be NULL if not used.
name – name of the resource (copied)
flags –
ERL_NIF_RT_CREATE
orERL_NIF_RT_TAKEOVER
to create or take over.tried – on output, updated to
ERL_NIF_RT_CREATE
orERL_NIF_RT_TAKEOVER
depending on what has been done. On failure, updated to flags. Can be NULL.
- Returns:
the resource type or
NULL
on failure.
-
void *enif_alloc_resource(ErlNifResourceType *type, unsigned size)
Allocate a resource for given type for
size
bytes.- Parameters:
type – a trype created by
enif_init_resource_type
.size – the size in bytes.
- Returns:
a pointer or
NULL
on failure.
-
int enif_get_resource(ErlNifEnv *env, ERL_NIF_TERM t, ErlNifResourceType *type, void **objp)
Get a pointer to a resource from a term representing it.
- Parameters:
env – the current environment
t – the term
type – the resource type
objp – on output the pointer to the resource
- Returns:
true
on success,false
on failure, if term is not a resource of typetype
-
int enif_keep_resource(void *resource)
Increment reference count of a resource.
- Parameters:
resource – the resource to keep
- Returns:
true
.
-
int enif_release_resource(void *resource)
Decrement reference count of a resource.
- Parameters:
resource – the resource to release
- Returns:
true
.
-
ERL_NIF_TERM enif_make_resource(ErlNifEnv *env, void *obj)
create a term from a resource
the term can be later passed to
enif_get_resource
. The resource is typically released (by callingenif_release_resource
) just after calling this function to “transfer ownership” to Erlang code so that it will be destroyed when garbage collected.- Parameters:
env – current environment
obj – resource
- Returns:
a new term representing the resource
-
int enif_select(ErlNifEnv *env, ErlNifEvent event, enum ErlNifSelectFlags mode, void *obj, const ErlNifPid *pid, ERL_NIF_TERM ref)
Run a POSIX-like select on a given object (event) and send a message when the object is readable or writable.
Actual implementation is platform dependent and platforms may not implement this feature.
On
generic_unix
, this is currently implemented using whatsys_poll_events
uses, namelykqueue(2)
(if available) orpoll(2)
. Please note thatkqueue(2)
andpoll(2)
behave differently for some objects, for example for vnodes and EOF.On
esp32
, this is currently implemented usingpoll(2)
.- Parameters:
env – current environment
event – event object (typically a file descriptor)
mode – select mode (
ERL_NIF_SELECT_READ
and/orERL_NIF_SELECT_WRITE
) optionally withERL_NIF_SELECT_CANCEL
to cancel, orERL_NIF_SELECT_STOP
to stop.obj – resource object working as a container of the event object.
pid – process id to send a message to or NULL to use the current process (from
env
)ref – reference object used in sent messages or
undefined
atom.
- Returns:
a negative value on failure, 0 or flags on success.
-
int enif_monitor_process(ErlNifEnv *env, void *obj, const ErlNifPid *target_pid, ErlNifMonitor *mon)
Monitor a process by using a resource object.
The monitor is automatically removed after being triggered or if the associated resource is deallocated.
- Parameters:
env – current environment
obj – resource to use for monitor
target_pid – process to monitor
mon – on output, monitor object (can be NULL)
- Returns:
0 on success, <0 if no down callback is provided with resource (badarg), >0 if the process is no longer alive
-
int enif_demonitor_process(ErlNifEnv *caller_env, void *obj, const ErlNifMonitor *mon)
Unmonitor a process.
- Parameters:
caller_env – current environment
obj – resource used by monitor
mon – monitor
- Returns:
0 on success
-
int enif_compare_monitors(const ErlNifMonitor *monitor1, const ErlNifMonitor *monitor2)
compare two monitors
- Parameters:
monitor1 – first monitor
monitor2 – second monitor
- Returns:
0 if equals, < 0 if
monitor1
<monitor2
, > 0 ifmonitor1
>monitor2
.
-
struct ErlNifResourceTypeInit
- #include <erl_nif.h>
Resource callbacks.
Members should be set to 0, 1 or 2 depending on provided callbacks. Callbacks can also be NULL if not used.
Public Members
-
int members
-
ErlNifResourceDtor *dtor
-
ErlNifResourceStop *stop
-
ErlNifResourceDown *down
-
int members