1 /* Icinga 2 | (c) 2012 Icinga GmbH | GPLv2+ */
3 #include "icinga/customvarobject.hpp"
4 #include "base/function.hpp"
11 class TimePeriod : CustomVarObject
13 [config] String display_name {
15 if (m_DisplayName.IsEmpty())
21 [config] Dictionary::Ptr ranges;
22 [config, required] Function::Ptr update;
23 [config] bool prefer_includes {
24 default {{{ return true; }}}
26 [config, required] array(name(TimePeriod)) excludes {
27 default {{{ return new Array(); }}}
29 [config, required] array(name(TimePeriod)) includes {
30 default {{{ return new Array(); }}}
32 [state, no_user_modify] Value valid_begin;
33 [state, no_user_modify] Value valid_end;
34 [state, no_user_modify] Array::Ptr segments;
35 [no_storage] bool is_inside {
40 validator TimePeriod {