2 * Copyright (c) 2016 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #ifndef __STC_MONITOR_CONTEXT_H__
18 #define __STC_MONITOR_CONTEXT_H__
20 #include "stc-manager.h"
24 time_t month_start_ts;
28 } reset_time_limits_context_s;
31 struct nfacct_rule *counter;
33 gboolean data_limit_exceeded;
34 } classid_bytes_context_s;
37 * @brief structure to store system info
40 int contr_sock; /**< socket used for getting kernel counters */
41 guint contr_timer_id; /**< timer id for periodically getting kernel counters */
42 guint contr_gsource_id;
43 stc_data_counter_s du_curr; /**< current data usage */
44 GHashTable *rstns; /**< restriction rules */
45 gboolean rstns_updated;
46 GHashTable *apps; /**< monitored applications */
47 gboolean apps_updated;
48 gboolean background_state;
55 #endif /* __STC_MONITOR_CONTEXT_H__ */