% % File generated by XTT2 Web Editor % % HeaRT case % % % Copyright (C) 2006-2016 by the HeKatE Project % % HeaRT has been developed by the HeKatE Project, % see http://hekate.ia.agh.edu.pl % % This file is part of HeaRT. % % HeaRT 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 3 of the License, or % (at your option) any later version. % % HeaRT 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 HeaRT. If not, see . % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% TYPES DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%%%% xtype [name: tariff_type, domain: [free,pay], ordered: no, base: symbolic ]. xtype [name: daytype_type, domain: [weekend,workday], ordered: no, base: symbolic ]. xtype [name: location_type, domain: [free_zone,pay_zone,closed_zone], ordered: no, base: symbolic ]. xtype [name: hour_type, domain: [0.000 to 23.000], scale: 1, base: numeric ]. xtype [name: day_type, domain: [mon/1,tue/2,wed/3,thu/4,fri/5,sat/6,sun/7], ordered: yes, base: symbolic ]. xtype [name: reminder_type, domain: [start_parking_fee,stop_parking_fee,do_not_park,free_to_park], ordered: no, base: symbolic ]. %%%%%%%%%%%%%%%%%%%%%%%%% ATTRIBUTES DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%%%% xattr [name: location, type: location_type, class: simple, comm: in, abbrev: loc ]. xattr [name: hour, type: hour_type, class: simple, comm: in, abbrev: hour_att ]. xattr [name: daytype, type: daytype_type, class: simple, comm: in, abbrev: dt_att ]. xattr [name: tariff, type: tariff_type, class: simple, comm: out, abbrev: tariff_att ]. xattr [name: day, type: day_type, class: simple, comm: in, abbrev: day_att ]. xattr [name: notification, type: reminder_type, class: simple, comm: out, abbrev: notif_att ]. %%%%%%%%%%%%%%%%%%%%%%%% TABLE SCHEMAS DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%% %! Position: 356,136 xschm daytype: [day] ==> [daytype]. %! Position: 709,135 xschm tariff: [hour,daytype] ==> [tariff]. %! Position: 357,347 xschm parkingReminder: [location,tariff] ==> [notification]. %%%%%%%%%%%%%%%%%%%%%%%%%%%% RULES DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%% xrule daytype/0: [ day in [mon to fri] ] ==> [ daytype set workday ].#1 xrule daytype/1: [ day in [sat,sun] ] ==> [ daytype set weekend ].#1 xrule tariff/2: [ hour in [10 to 19], daytype eq workday ] ==> [ tariff set pay ].#1 xrule tariff/3: [ hour eq any, daytype eq weekend ] ==> [ tariff set free ].#1 xrule tariff/4: [ hour in [20 to 23,0 to 9], daytype eq workday ] ==> [ tariff set free ].#1 xrule parkingReminder/8: [ location eq free_zone, tariff eq any ] ==> [ notification set free_to_park ].#1 xrule parkingReminder/9: [ location eq pay_zone, tariff eq free ] ==> [ notification set free_to_park ].#1 xrule parkingReminder/10: [ location eq pay_zone, tariff eq pay ] ==> [ notification set start_parking_fee ].#1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % File generated by XTT2 Web Editor %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%