aboutsummaryrefslogtreecommitdiffstats
path: root/src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c
diff options
context:
space:
mode:
authorYuta Doi <yuta-d@witz-inc.co.jp>2018-07-11 16:21:37 +0900
committerYuta Doi <yuta-d@witz-inc.co.jp>2018-07-12 00:27:30 +0000
commit67f414f67ee22ddf40003d1be3fa1d0cb13deb8f (patch)
tree407f01c2af124c97f38d79403b808828b6ea527f /src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c
parent99b6f4d2fcd421d3a760a88a67e511fb6fc98068 (diff)
Add policy table generated by ZIPC for EXAMPLE
To PolicyManager, add the source code of policy table which is generated by ZIPC for EXAMPLE. If use this example, please comment out line 84 and uncomment line 85 in CMakeLists.txt as follows: #set(USE_STM_NAME stub) set(USE_STM_NAME zipc) If try to show split layout, please rename from roles.db.split to roles.db in src/policy_manager/db/. Bug-AGL: SPEC-1537 Change-Id: I4b35f148313e0c5a12c59ed1c2f8eb6fbcf3ea6b Signed-off-by: Yuta Doi <yuta-d@witz-inc.co.jp>
Diffstat (limited to 'src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c')
-rw-r--r--src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c53
1 files changed, 53 insertions, 0 deletions
diff --git a/src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c b/src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c
new file mode 100644
index 0000000..94807f8
--- /dev/null
+++ b/src/policy_manager/stm/zipc/src/StateTransitionor/RestrictionMode/ZREM_RestrictionMode_func.c
@@ -0,0 +1,53 @@
+/************************************************************/
+/* ZREM_RestrictionMode_func.c */
+/* Function and variable source file */
+/* ZIPC Designer Version 1.2.0 */
+/************************************************************/
+#include "../ZST_include.h"
+
+/*************************************************************
+ Function definition
+*************************************************************/
+
+/*
+ * @name stm_rem_start_activity_restriction_mode_1_on
+ */
+void stm_rem_start_activity_restriction_mode_1_on() {
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].state = StmRestrictionModeSttNo1On;
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].changed = STM_TRUE;
+}
+
+/*
+ * @name stm_rem_start_activity_restriction_mode_2_on
+ */
+void stm_rem_start_activity_restriction_mode_2_on() {
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].state = StmRestrictionModeSttNo2On;
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].changed = STM_TRUE;
+}
+
+/*
+ * @name stm_rem_start_activity_restriction_mode_off
+ */
+void stm_rem_start_activity_restriction_mode_off() {
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].state = StmRestrictionModeSttNoOff;
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].changed = STM_TRUE;
+}
+
+/*
+ * @name stm_rem_initialize_variable
+ */
+void stm_rem_initialize_variable() {
+ g_stm_prv_state.mode[StmModeNoRestrictionMode].state = StmRestrictionModeSttNoOff;
+ g_stm_prv_state.mode[StmModeNoRestrictionMode].changed = STM_FALSE;
+
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].state = StmRestrictionModeSttNoOff;
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].changed = STM_FALSE;
+}
+
+/*
+ * @name stm_rem_start_stm
+ */
+void stm_rem_start_stm() {
+ g_stm_prv_state.mode[StmModeNoRestrictionMode].state = g_stm_crr_state.mode[StmModeNoRestrictionMode].state;
+ g_stm_crr_state.mode[StmModeNoRestrictionMode].changed = STM_FALSE;
+}