NeoMutt  2021-10-29-43-g6b8931
Teaching an old dog new tricks
DOXYGEN
command.h
Go to the documentation of this file.
1 
23 #ifndef MUTT_CORE_COMMAND_H
24 #define MUTT_CORE_COMMAND_H
25 
26 #include <stdint.h>
27 
28 struct Buffer;
29 
34 {
38  MUTT_CMD_FINISH = 1
39 };
40 
46 struct Command
47 {
48  const char *name;
49 
61  enum CommandResult (*parse)(struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err);
62 
63  intptr_t data;
64 };
65 
66 #endif /* MUTT_CORE_COMMAND_H */
CommandResult
Error codes for command_t parse functions.
Definition: command.h:34
@ MUTT_CMD_SUCCESS
Success: Command worked.
Definition: command.h:37
@ MUTT_CMD_ERROR
Error: Can't help the user.
Definition: command.h:35
@ MUTT_CMD_WARNING
Warning: Help given to the user.
Definition: command.h:36
@ MUTT_CMD_FINISH
Finish: Stop processing this file.
Definition: command.h:38
String manipulation buffer.
Definition: buffer.h:34
enum CommandResult(* parse)(struct Buffer *buf, struct Buffer *s, intptr_t data, struct Buffer *err)
Definition: command.h:61
intptr_t data
Data or flags to pass to the command.
Definition: command.h:63
const char * name
Name of the command.
Definition: command.h:48