X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=cli%2Fcli.hpp;h=6c080e86de65683883d520661ecc728ac8a1ae2a;hb=4c5f6fa4d7474bc2a13a6c00bd3f4ac47ff56920;hp=8e43277422f1a8883897ec3680288f2844411ad2;hpb=5cc28b0393274f17682c000c114c3f6ffa280e68;p=apitrace diff --git a/cli/cli.hpp b/cli/cli.hpp index 8e43277..6c080e8 100644 --- a/cli/cli.hpp +++ b/cli/cli.hpp @@ -28,15 +28,25 @@ #ifndef _APITRACE_CLI_HPP_ #define _APITRACE_CLI_HPP_ -#define APITRACE_DUMP_SYNOPSIS "Dump given trace(s) to standard output." -void -apitrace_dump_usage(const char *argv0); +struct Command { + const char *name; + const char *synopsis; -int -apitrace_dump_command(int argc, char *argv[], int first_command_arg); + typedef void (*Usage) (void); + Usage usage; -void -usage(void); + typedef int (*Function) (int argc, char *argv[]); + Function function; +}; + +extern const Command diff_command; +extern const Command diff_state_command; +extern const Command diff_images_command; +extern const Command dump_command; +extern const Command pickle_command; +extern const Command repack_command; +extern const Command trace_command; +extern const Command trim_command; #endif /* _APITRACE_CLI_HPP_ */