rte_argparse(3)
β¨ rte_argparse(3) β¨
okay bestie, this one's a C struct from DPDK β it's literally the manual page rte_argparse(3) from the Library Functions Manual, and it's giving "config object for the argparse thing" energy. buckle up π
πΈ SYNOPSIS πΈ
#include <rte_argparse.h>
π Data Fields π
const char * prog_nameconst char * usageconst char * descriptorconst char * epilogbool exit_on_errorbool ignore_non_flag_argsrte_arg_parser_t callbackvoid * opaquevoid(* print_help )(const struct rte_argparse *obj)void * reserved [15]struct rte_argparse_arg args []
π¦ Detailed Description π¦
so this struct is the whole vibe holder β it's a structure used to hold argparse's configuration. that's it, that's the job, and it slays at it β¨
Definition at line 149 of file rte_argparse.h.
π Field Documentation π
π const char* prog_name
the program name, bestie. Must not be NULL. like, do not pass NULL here, fr fr.
Definition at line 151 of file rte_argparse.h.
π const char* usage
how you're supposed to use the program. also must not be NULL β the parser needs its little instruction manual π«Ά
Definition at line 153 of file rte_argparse.h.
π const char* descriptor
this one explains what the program actually does. lowkey optional β could be NULL π
Definition at line 155 of file rte_argparse.h.
π const char* epilog
the text that sits at the bottom of the help output. also could be NULL, so no pressure π
Definition at line 157 of file rte_argparse.h.
π bool exit_on_error
whether it exits when there's an error. that's the whole thing. β¨
Definition at line 159 of file rte_argparse.h.
π bool ignore_non_flag_args
okay this one: it makes the parser behave like getopt and move non-flag args to the end, ignoring them otherwise. and the important bit β if this flag is specified, no positional args are allowed. so pick your lane, bestie π¨
Definition at line 163 of file rte_argparse.h.
π rte_arg_parser_t callback
your very own user callback for parsing arguments. main character energy, honestly π
Definition at line 167 of file rte_argparse.h.
π void* opaque
an opaque pointer that gets used to invoke the callback. classic iykyk situation π«Ά
Definition at line 169 of file rte_argparse.h.
π void(* print_help) (const struct rte_argparse *obj)
a function pointer for printing usage when -h is passed. and if this is NULL, the default printing function will be used β so you're covered either way, no cap π
Definition at line 174 of file rte_argparse.h.
π void* reserved[15]
reserved field, used for future extension. literally just sitting there being mysterious for later π§
Definition at line 176 of file rte_argparse.h.
π struct rte_argparse_arg args[]
the arguments configuration. and this is the non-negotiable part: it must be ended with ARGPARSE_ARG_END(). don't forget the terminator, bestie, the parser will simply not know when to stop π
Definition at line 178 of file rte_argparse.h.
β Author β
generated automatically by Doxygen for DPDK from the source code β so nobody hand-wrote this, it just spawned fully formed like a little documentation butterfly π¦
and that's the whole page!! π this was DPDK, Version 26.03.0 β rte_argparse(3), out. slay, bye bestie ππ
π¦ where this page comes from
- nixos 26.05: dpdk 26.03
- nixpkgs unstable: dpdk 26.03
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms