/* * network-inador-events.h * This file is part of Network-inador * * Copyright (C) 2024 - Félix Arreola Rodríguez * * Network-inador is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * Network-inador is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Network-inador; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, * Boston, MA 02110-1301 USA */ #ifndef __NETWORK_INADOR_EVENTS_H__ #define __NETWORK_INADOR_EVENTS_H__ #include typedef struct _NetworkInadorHandle NetworkInadorHandle; typedef struct _Interface Interface; typedef struct _InterfaceDHCPClientInfo InterfaceDHCPClientInfo; typedef struct _IPAddr IPAddr; typedef struct _Route Route; typedef void (*NetworkInadorDHCPEventCB) (NetworkInadorHandle *handle, Interface *iface, InterfaceDHCPClientInfo *dhcp_info, void *data); typedef void (*NetworkInadorInterfaceAddEventCB) (NetworkInadorHandle *handle, Interface *iface, void *data); typedef void (*NetworkInadorInterfaceUpdateEventCB) (NetworkInadorHandle *handle, Interface *iface, void *data); typedef void (*NetworkInadorInterfaceDeleteEventCB) (NetworkInadorHandle *handle, uint32_t index, void *data); typedef void (*NetworkInadorIPAddEventCB) (NetworkInadorHandle *handle, IPAddr *addr, void *data); typedef void (*NetworkInadorIPDelEventCB) (NetworkInadorHandle *handle, IPAddr *addr, void *data); typedef void (*NetworkInadorRouteAddEventCB) (NetworkInadorHandle *handle, Route *route, void *data); typedef void (*NetworkInadorRouteUpdateEventCB) (NetworkInadorHandle *handle, Route *route, void *data); typedef void (*NetworkInadorRouteDelEventCB) (NetworkInadorHandle *handle, Route *route, void *data); typedef void (*NetworkInadorRouteTableAddEventCB) (NetworkInadorHandle *handle, uint32_t table_index, const char *table_name, void *data); typedef void (*NetworkInadorRouteTableDelEventCB) (NetworkInadorHandle *handle, uint32_t table_index, void *data); /* Pendiente notificar rutas */ void network_manager_add_watch_dhcp (NetworkInadorHandle *handle, NetworkInadorDHCPEventCB cb, void *data); void network_manager_add_watch_interface_added (NetworkInadorHandle *handle, NetworkInadorInterfaceAddEventCB cb, void *data); void network_manager_add_watch_interface_updated (NetworkInadorHandle *handle, NetworkInadorInterfaceUpdateEventCB cb, void *data); void network_manager_add_watch_interface_deleted (NetworkInadorHandle *handle, NetworkInadorInterfaceDeleteEventCB cb, void *data); void network_manager_add_watch_ip_added (NetworkInadorHandle *handle, NetworkInadorIPAddEventCB cb, void *data); void network_manager_add_watch_ip_deleted (NetworkInadorHandle *handle, NetworkInadorIPDelEventCB cb, void *data); void network_manager_add_watch_route_added (NetworkInadorHandle *handle, NetworkInadorRouteAddEventCB cb, void *data); void network_manager_add_watch_route_updated (NetworkInadorHandle *handle, NetworkInadorRouteUpdateEventCB cb, void *data); void network_manager_add_watch_route_deleted (NetworkInadorHandle *handle, NetworkInadorRouteDelEventCB cb, void *data); void network_manager_add_watch_route_table_added (NetworkInadorHandle *handle, NetworkInadorRouteTableAddEventCB cb, void *data); void network_manager_add_watch_route_table_deleted (NetworkInadorHandle *handle, NetworkInadorRouteTableDelEventCB cb, void *data); #endif /* __NETWORK_INADOR_EVENTS_H__ */