Added ITA Start/Stop Angel attributes to split bulk data into multiple attributes
[strongswan.git] / src / libimcv / plugins / imv_os / imv_os_state.h
1 /*
2 * Copyright (C) 2012 Andreas Steffen
3 * HSR Hochschule fuer Technik Rapperswil
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * for more details.
14 */
15
16 /**
17 *
18 * @defgroup imv_os_state_t imv_os_state
19 * @{ @ingroup imv_os_state
20 */
21
22 #ifndef IMV_OS_STATE_H_
23 #define IMV_OS_STATE_H_
24
25 #include <imv/imv_state.h>
26 #include <library.h>
27
28 typedef struct imv_os_state_t imv_os_state_t;
29
30 /**
31 * Internal state of an imv_os_t connection instance
32 */
33 struct imv_os_state_t {
34
35 /**
36 * imv_state_t interface
37 */
38 imv_state_t interface;
39
40 /**
41 * Set OS Product Information
42 *
43 * @param name OS name
44 * @param version OS version
45 */
46 void (*set_info)(imv_os_state_t *this, chunk_t name, chunk_t version);
47
48 /**
49 * Get OS Product Information
50 *
51 * @result OS name & version
52 */
53 char* (*get_info)(imv_os_state_t *this);
54
55 /**
56 * Set/reset OS Installed Packages request status
57 *
58 * @param set TRUE to set, FALSE to clear
59 */
60 void (*set_package_request)(imv_os_state_t *this, bool set);
61
62 /**
63 * Get OS Installed Packages request status
64 *
65 * @result TRUE if set, FALSE if unset
66 */
67 bool (*get_package_request)(imv_os_state_t *this);
68
69 /**
70 * Increase/Decrease the ITA Angel count
71 *
72 * @param start TRUE increases and FALSE decreases count by one
73 */
74 void (*set_angel_count)(imv_os_state_t *this, bool start);
75
76 /**
77 * Get the ITA Angel count
78 *
79 * @result ITA Angel count
80 */
81 int (*get_angel_count)(imv_os_state_t *this);
82
83 };
84
85 /**
86 * Create an imv_os_state_t instance
87 *
88 * @param id connection ID
89 */
90 imv_state_t* imv_os_state_create(TNC_ConnectionID id);
91
92 #endif /** IMV_OS_STATE_H_ @}*/