1 | /* sysstates.inl |
---|
2 | * |
---|
3 | * This file contains the inline implementation of routines regarding the |
---|
4 | * system state. |
---|
5 | * |
---|
6 | * COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994. |
---|
7 | * On-Line Applications Research Corporation (OAR). |
---|
8 | * All rights assigned to U.S. Government, 1994. |
---|
9 | * |
---|
10 | * This material may be reproduced by or for the U.S. Government pursuant |
---|
11 | * to the copyright license under the clause at DFARS 252.227-7013. This |
---|
12 | * notice must appear in all copies of this file and its derivatives. |
---|
13 | * |
---|
14 | * $Id$ |
---|
15 | */ |
---|
16 | |
---|
17 | #ifndef __SYSTEM_STATE_inl |
---|
18 | #define __SYSTEM_STATE_inl |
---|
19 | |
---|
20 | /*PAGE |
---|
21 | * |
---|
22 | * _System_state_Set |
---|
23 | */ |
---|
24 | |
---|
25 | STATIC INLINE void _System_state_Set ( |
---|
26 | System_state_Codes state |
---|
27 | ) |
---|
28 | { |
---|
29 | _System_state_Current = state; |
---|
30 | } |
---|
31 | |
---|
32 | /*PAGE |
---|
33 | * |
---|
34 | * _System_state_Get |
---|
35 | */ |
---|
36 | |
---|
37 | STATIC INLINE System_state_Codes _System_state_Get ( void ) |
---|
38 | { |
---|
39 | return _System_state_Current; |
---|
40 | } |
---|
41 | |
---|
42 | /*PAGE |
---|
43 | * |
---|
44 | * _System_state_Is_before_initialization |
---|
45 | */ |
---|
46 | |
---|
47 | STATIC INLINE boolean _System_state_Is_before_initialization ( |
---|
48 | System_state_Codes state |
---|
49 | ) |
---|
50 | { |
---|
51 | return (state == SYSTEM_STATE_BEFORE_INITIALIZATION); |
---|
52 | } |
---|
53 | |
---|
54 | /*PAGE |
---|
55 | * |
---|
56 | * _System_state_Is_before_multitasking |
---|
57 | */ |
---|
58 | |
---|
59 | STATIC INLINE boolean _System_state_Is_before_multitasking ( |
---|
60 | System_state_Codes state |
---|
61 | ) |
---|
62 | { |
---|
63 | return (state == SYSTEM_STATE_BEFORE_MULTITASKING); |
---|
64 | } |
---|
65 | |
---|
66 | /*PAGE |
---|
67 | * |
---|
68 | * _System_state_Is_begin_multitasking |
---|
69 | */ |
---|
70 | |
---|
71 | STATIC INLINE boolean _System_state_Is_begin_multitasking ( |
---|
72 | System_state_Codes state |
---|
73 | ) |
---|
74 | { |
---|
75 | return (state == SYSTEM_STATE_BEGIN_MULTITASKING); |
---|
76 | } |
---|
77 | |
---|
78 | /*PAGE |
---|
79 | * |
---|
80 | * _System_state_Is_up |
---|
81 | */ |
---|
82 | |
---|
83 | STATIC INLINE boolean _System_state_Is_up ( |
---|
84 | System_state_Codes state |
---|
85 | ) |
---|
86 | { |
---|
87 | return (state == SYSTEM_STATE_UP); |
---|
88 | } |
---|
89 | |
---|
90 | /*PAGE |
---|
91 | * |
---|
92 | * _System_state_Is_failed |
---|
93 | */ |
---|
94 | |
---|
95 | STATIC INLINE boolean _System_state_Is_failed ( |
---|
96 | System_state_Codes state |
---|
97 | ) |
---|
98 | { |
---|
99 | return (state == SYSTEM_STATE_FAILED); |
---|
100 | } |
---|
101 | |
---|
102 | #endif |
---|
103 | /* end of include file */ |
---|