Files
lcdproc/server/commands/command_list.h
T
mmdolze a151ee0fc4 Mega change to the LCDd's header files:
1. Use <stdbool.h> if it is available but keep a compatibility shim in
   shared/defines.h in case it is not.
2. Unbreak the circular header dependencies (mostly):
   2a. client.c and client.h may NOT depend on 'struct Menu'. Use a void pointer
       and casts instead.
   2b. Separate the data type definitions in client.h and screen.h from
       function prototypes which may require other data structures. This makes
       header dependencies much more easy to maintain. Usually the data types
       should have been moved to their own files but I (mmdolze) chose to
       separate them using different header guards.
   2c. Remove many now unused header includes.
Apply (old BSD-) style on menuscreens.c.
2012-02-22 22:25:32 +00:00

34 lines
886 B
C

/** \file server/commands/command_list.h
* Declares client command dispatcher function.
*/
/* This file is part of LCDd, the lcdproc server.
*
* This file is released under the GNU General Public License.
* Refer to the COPYING file distributed with this package.
*
* Copyright (c) 1999, William Ferrell, Selene Scriven
*/
#ifndef COMMANDS_COMMAND_LIST_H
#define COMMANDS_COMMAND_LIST_H
#include "client.h"
/**
* The function list for clients is stored in a table, and the items each
* point to a function to call, defined below.
*/
typedef int (*CommandFunc) (Client *c, int argc, char **argv);
/** Defines an entry in the command table */
typedef struct client_function {
char *keyword; /**< Command string in the protocol */
CommandFunc function; /**< Pointer to the associated function */
} client_function;
CommandFunc get_command_function(char *cmd);
#endif