2 * @file writeable_backend.h
4 * @brief Interface of writeable_backend_t.
9 * Copyright (C) 2007 Martin Willi
10 * Hochschule fuer Technik Rapperswil
12 * This program is free software; you can redistribute it and/or modify it
13 * under the terms of the GNU General Public License as published by the
14 * Free Software Foundation; either version 2 of the License, or (at your
15 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
19 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
23 #ifndef WRITEABLE_BACKEND_H_
24 #define WRITEABLE_BACKEND_H_
26 typedef struct writeable_backend_t writeable_backend_t
;
29 #include <config/backends/backend.h>
32 * @brief A writeable backend extends backend_t by modification functions.
35 * - writeable_backend_create()
39 struct writeable_backend_t
{
42 * Implements backend_t interface
47 * @brief Add a peer_config to the backend.
49 * @param this calling object
50 * @param config peer_config to add to the backend
52 void (*add_cfg
)(writeable_backend_t
*this, peer_cfg_t
*config
);
55 * @brief Create an iterator over all peer configs.
57 * @param this calling object
58 * @return iterator over peer configs
60 iterator_t
* (*create_iterator
)(writeable_backend_t
*this);
63 #endif /* WRITEABLE_BACKEND_H_ */