MCPcopy Create free account
hub / github.com/Simple-XX/SimpleKernel / GetStateId

Method GetStateId

src/task/include/task_fsm.hpp:181–183  ·  view source on GitHub ↗

* @brief 获取当前状态 ID(线程安全) * @return etl::fsm_state_id_t 当前状态 ID * @note 使用 acquire 语义从 atomic 缓存读取, * 无需持有与 Receive() 相同的锁即可安全调用 */

Source from the content-addressed store, hash-verified

179 * 无需持有与 Receive() 相同的锁即可安全调用
180 */
181 [[nodiscard]] auto GetStateId() const -> etl::fsm_state_id_t {
182 return cached_state_.load(std::memory_order_acquire);
183 }
184
185 /// @name 构造/析构函数
186 /// @{

Callers 1

GetStatusMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected