proto-shell: move script handler dump code to handler.c
[project/netifd.git] / handler.h
1 /*
2  * netifd - network interface daemon
3  * Copyright (C) 2012-2013 Felix Fietkau <nbd@openwrt.org>
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2
7  * as published by the Free Software Foundation
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU General Public License for more details.
13  */
14 #ifndef __NETIFD_HANDLER_H
15 #define __NETIFD_HANDLER_H
16
17 #include <libubox/blobmsg_json.h>
18
19 typedef void (*script_dump_cb)(const char *name, json_object *obj);
20
21 int netifd_open_subdir(const char *name);
22 void netifd_init_script_handlers(int dir_fd, script_dump_cb cb);
23
24 #endif