mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-03-22 10:34:30 +08:00
- 添加协程上下文、句柄、调度器和作用域管理类 - 实现协程等待指令包括 WaitForSeconds、WaitUntil 和 WaitWhile - 创建协程系统和全局协程作用域管理器 - 定义协程相关抽象接口 ICoroutineScheduler、ICoroutineScope 等 - 升级 Meziantou.Analyzer 依赖版本至 2.0.283 - 升级 Meziantou.Polyfill 依赖版本至 1.0.100
17 lines
374 B
C#
17 lines
374 B
C#
namespace GFramework.Game.Abstractions.coroutine;
|
|
|
|
/// <summary>
|
|
/// 协程作用域接口,用于管理协程的生命周期
|
|
/// </summary>
|
|
public interface ICoroutineScope
|
|
{
|
|
/// <summary>
|
|
/// 获取协程是否处于活动状态
|
|
/// </summary>
|
|
bool IsActive { get; }
|
|
|
|
/// <summary>
|
|
/// 取消协程执行
|
|
/// </summary>
|
|
void Cancel();
|
|
} |