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"]
    "5" [label="stdint.h" tooltip="stdint.h"]
    "2" [label="term_typedef.h" tooltip="term_typedef.h"]
    "3" [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"]
    "4" [label="inttypes.h" tooltip="inttypes.h"]
    "2" -> "3" [dir=forward tooltip="include"]
    "2" -> "4" [dir=forward tooltip="include"]
    "2" -> "5" [dir=forward tooltip="include"]
    "1" -> "2" [dir=forward tooltip="include"]
}

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"]
    "37" [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"]
    "43" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/dictionary.h"]
    "42" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.c"]
    "41" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/bitstring.h"]
    "26" [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"]
    "38" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/posix_nifs.h"]
    "36" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.c"]
    "35" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/defaultatoms.h"]
    "16" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.c"]
    "33" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/scheduler.h"]
    "44" [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"]
    "31" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.c"]
    "32" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/port.h"]
    "46" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/overflow_helpers.h"]
    "28" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/stacktrace.c"]
    "27" [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"]
    "48" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/refc_binary.h"]
    "34" [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"]
    "25" [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"]
    "24" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/term.c"]
    "40" [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"]
    "23" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.c"]
    "22" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/interop.h"]
    "20" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.c"]
    "47" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/resources.h"]
    "17" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif_priv.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/erl_nif_priv.h"]
    "29" [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"]
    "30" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/nifs.h"]
    "12" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/opcodesswitch.h"]
    "14" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/debug.c"]
    "13" [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"]
    "15" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.c"]
    "39" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.h" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/memory.h"]
    "21" [label="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.c" tooltip="/home/runner/work/AtomVM/AtomVM/src/libAtomVM/externalterm.c"]
    "45" [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"]
    "9" -> "12" [dir=back tooltip="include"]
    "43" -> "10" [dir=back tooltip="include"]
    "43" -> "2" [dir=back tooltip="include"]
    "43" -> "37" [dir=back tooltip="include"]
    "43" -> "15" [dir=back tooltip="include"]
    "43" -> "7" [dir=back tooltip="include"]
    "43" -> "19" [dir=back tooltip="include"]
    "41" -> "42" [dir=back tooltip="include"]
    "41" -> "23" [dir=back tooltip="include"]
    "41" -> "12" [dir=back tooltip="include"]
    "26" -> "7" [dir=back tooltip="include"]
    "38" -> "6" [dir=back tooltip="include"]
    "38" -> "7" [dir=back tooltip="include"]
    "38" -> "18" [dir=back tooltip="include"]
    "35" -> "10" [dir=back tooltip="include"]
    "35" -> "36" [dir=back tooltip="include"]
    "35" -> "37" [dir=back tooltip="include"]
    "35" -> "6" [dir=back tooltip="include"]
    "35" -> "23" [dir=back tooltip="include"]
    "35" -> "7" [dir=back tooltip="include"]
    "35" -> "12" [dir=back tooltip="include"]
    "35" -> "31" [dir=back tooltip="include"]
    "35" -> "32" [dir=back tooltip="include"]
    "35" -> "18" [dir=back tooltip="include"]
    "35" -> "20" [dir=back tooltip="include"]
    "35" -> "28" [dir=back tooltip="include"]
    "33" -> "34" [dir=back tooltip="include"]
    "33" -> "7" [dir=back tooltip="include"]
    "33" -> "12" [dir=back tooltip="include"]
    "33" -> "16" [dir=back tooltip="include"]
    "44" -> "9" [dir=back tooltip="include"]
    "44" -> "25" [dir=back tooltip="include"]
    "44" -> "30" [dir=back tooltip="include"]
    "44" -> "12" [dir=back tooltip="include"]
    "44" -> "26" [dir=back tooltip="include"]
    "44" -> "38" [dir=back tooltip="include"]
    "8" -> "9" [dir=back tooltip="include"]
    "8" -> "2" [dir=back tooltip="include"]
    "8" -> "13" [dir=back tooltip="include"]
    "8" -> "17" [dir=back tooltip="include"]
    "8" -> "21" [dir=back tooltip="include"]
    "8" -> "6" [dir=back tooltip="include"]
    "8" -> "22" [dir=back tooltip="include"]
    "8" -> "15" [dir=back tooltip="include"]
    "8" -> "11" [dir=back tooltip="include"]
    "8" -> "25" [dir=back tooltip="include"]
    "8" -> "7" [dir=back tooltip="include"]
    "8" -> "30" [dir=back tooltip="include"]
    "8" -> "31" [dir=back tooltip="include"]
    "8" -> "32" [dir=back tooltip="include"]
    "8" -> "19" [dir=back tooltip="include"]
    "8" -> "20" [dir=back tooltip="include"]
    "8" -> "33" [dir=back tooltip="include"]
    "8" -> "27" [dir=back tooltip="include"]
    "8" -> "24" [dir=back tooltip="include"]
    "32" -> "7" [dir=back tooltip="include"]
    "32" -> "31" [dir=back tooltip="include"]
    "46" -> "10" [dir=back tooltip="include"]
    "27" -> "12" [dir=back tooltip="include"]
    "27" -> "28" [dir=back tooltip="include"]
    "48" -> "6" [dir=back tooltip="include"]
    "48" -> "15" [dir=back tooltip="include"]
    "48" -> "19" [dir=back tooltip="include"]
    "48" -> "20" [dir=back tooltip="include"]
    "48" -> "40" [dir=back tooltip="include"]
    "25" -> "9" [dir=back tooltip="include"]
    "25" -> "11" [dir=back tooltip="include"]
    "25" -> "7" [dir=back tooltip="include"]
    "25" -> "12" [dir=back tooltip="include"]
    "25" -> "26" [dir=back tooltip="include"]
    "25" -> "27" [dir=back tooltip="include"]
    "25" -> "29" [dir=back tooltip="include"]
    "4" -> "5" [dir=back tooltip="include"]
    "4" -> "6" [dir=back tooltip="include"]
    "4" -> "7" [dir=back tooltip="include"]
    "40" -> "41" [dir=back tooltip="include"]
    "40" -> "2" [dir=back tooltip="include"]
    "40" -> "8" [dir=back tooltip="include"]
    "40" -> "37" [dir=back tooltip="include"]
    "40" -> "43" [dir=back tooltip="include"]
    "40" -> "44" [dir=back tooltip="include"]
    "40" -> "45" [dir=back tooltip="include"]
    "40" -> "3" [dir=back tooltip="include"]
    "40" -> "23" [dir=back tooltip="include"]
    "40" -> "22" [dir=back tooltip="include"]
    "40" -> "15" [dir=back tooltip="include"]
    "40" -> "11" [dir=back tooltip="include"]
    "40" -> "25" [dir=back tooltip="include"]
    "40" -> "7" [dir=back tooltip="include"]
    "40" -> "46" [dir=back tooltip="include"]
    "40" -> "32" [dir=back tooltip="include"]
    "40" -> "38" [dir=back tooltip="include"]
    "40" -> "27" [dir=back tooltip="include"]
    "40" -> "24" [dir=back tooltip="include"]
    "1" -> "2" [dir=back tooltip="include"]
    "1" -> "3" [dir=back tooltip="include"]
    "1" -> "39" [dir=back tooltip="include"]
    "1" -> "20" [dir=back tooltip="include"]
    "1" -> "47" [dir=back tooltip="include"]
    "22" -> "23" [dir=back tooltip="include"]
    "22" -> "7" [dir=back tooltip="include"]
    "22" -> "18" [dir=back tooltip="include"]
    "22" -> "24" [dir=back tooltip="include"]
    "47" -> "6" [dir=back tooltip="include"]
    "47" -> "48" [dir=back tooltip="include"]
    "47" -> "20" [dir=back tooltip="include"]
    "17" -> "2" [dir=back tooltip="include"]
    "17" -> "6" [dir=back tooltip="include"]
    "17" -> "15" [dir=back tooltip="include"]
    "17" -> "18" [dir=back tooltip="include"]
    "17" -> "19" [dir=back tooltip="include"]
    "17" -> "20" [dir=back tooltip="include"]
    "29" -> "2" [dir=back tooltip="include"]
    "29" -> "6" [dir=back tooltip="include"]
    "29" -> "11" [dir=back tooltip="include"]
    "29" -> "7" [dir=back tooltip="include"]
    "29" -> "20" [dir=back tooltip="include"]
    "29" -> "16" [dir=back tooltip="include"]
    "30" -> "11" [dir=back tooltip="include"]
    "30" -> "7" [dir=back tooltip="include"]
    "30" -> "12" [dir=back tooltip="include"]
    "30" -> "18" [dir=back tooltip="include"]
    "12" -> "2" [dir=back tooltip="include"]
    "12" -> "11" [dir=back tooltip="include"]
    "13" -> "14" [dir=back tooltip="include"]
    "13" -> "15" [dir=back tooltip="include"]
    "13" -> "12" [dir=back tooltip="include"]
    "13" -> "16" [dir=back tooltip="include"]
    "3" -> "4" [dir=back tooltip="include"]
    "3" -> "2" [dir=back tooltip="include"]
    "3" -> "8" [dir=back tooltip="include"]
    "3" -> "35" [dir=back tooltip="include"]
    "3" -> "6" [dir=back tooltip="include"]
    "3" -> "11" [dir=back tooltip="include"]
    "3" -> "25" [dir=back tooltip="include"]
    "3" -> "7" [dir=back tooltip="include"]
    "3" -> "31" [dir=back tooltip="include"]
    "3" -> "32" [dir=back tooltip="include"]
    "3" -> "18" [dir=back tooltip="include"]
    "3" -> "38" [dir=back tooltip="include"]
    "3" -> "33" [dir=back tooltip="include"]
    "3" -> "28" [dir=back tooltip="include"]
    "3" -> "29" [dir=back tooltip="include"]
    "39" -> "17" [dir=back tooltip="include"]
    "39" -> "34" [dir=back tooltip="include"]
    "39" -> "15" [dir=back tooltip="include"]
    "39" -> "32" [dir=back tooltip="include"]
    "39" -> "19" [dir=back tooltip="include"]
    "39" -> "40" [dir=back tooltip="include"]
    "45" -> "21" [dir=back tooltip="include"]
    "45" -> "11" [dir=back tooltip="include"]
    "45" -> "7" [dir=back tooltip="include"]
}

Typedefs

typedef struct ErlNifEnv ErlNifEnv
typedef term ERL_NIF_TERM
typedef int32_t ErlNifPid
typedef struct ResourceType ErlNifResourceType
typedef uint64_t ErlNifMonitor
typedef int ErlNifEvent
typedef void ErlNifResourceDtor(ErlNifEnv *caller_env, void *obj)
typedef void ErlNifResourceStop(ErlNifEnv *caller_env, void *obj, ErlNifEvent event, int is_direct_call)
typedef void ErlNifResourceDown(ErlNifEnv *caller_env, void *obj, ErlNifPid *pid, ErlNifMonitor *mon)

Enums

enum ErlNifResourceFlags

Values:

enumerator ERL_NIF_RT_CREATE
enum ErlNifSelectFlags

Values:

enumerator ERL_NIF_SELECT_READ
enumerator ERL_NIF_SELECT_WRITE
enumerator ERL_NIF_SELECT_STOP
enum [anonymous]

Values:

enumerator ERL_NIF_SELECT_STOP_CALLED
enumerator ERL_NIF_SELECT_STOP_SCHEDULED
enumerator ERL_NIF_SELECT_INVALID_EVENT
enumerator ERL_NIF_SELECT_FAILED
enumerator ERL_NIF_SELECT_BADARG

Functions

ErlNifResourceType *enif_init_resource_type(ErlNifEnv *env, const char *name, const ErlNifResourceTypeInit *init, ErlNifResourceFlags flags, ErlNifResourceFlags *tried)
void *enif_alloc_resource(ErlNifResourceType *type, unsigned size)
int enif_get_resource(ErlNifEnv *env, ERL_NIF_TERM t, ErlNifResourceType *type, void **objp)
int enif_keep_resource(void *resource)
int enif_release_resource(void *resource)
ERL_NIF_TERM enif_make_resource(ErlNifEnv *env, void *obj)
int enif_select(ErlNifEnv *env, ErlNifEvent event, enum ErlNifSelectFlags mode, void *obj, const ErlNifPid *pid, ERL_NIF_TERM ref)
int enif_monitor_process(ErlNifEnv *env, void *obj, const ErlNifPid *target_pid, ErlNifMonitor *mon)
int enif_demonitor_process(ErlNifEnv *caller_env, void *obj, const ErlNifMonitor *mon)
int enif_compare_monitors(const ErlNifMonitor *monitor1, const ErlNifMonitor *monitor2)
struct ErlNifResourceTypeInit

Public Members

int members
ErlNifResourceDtor *dtor
ErlNifResourceStop *stop
ErlNifResourceDown *down