fix: improve doc link navigation and tree display
- Fix link resolution with proper relative/absolute path handling - Improve link styling with underline decoration - Hide leaf nodes from tree, only show directories - Fix log file path for packaged app
This commit is contained in:
36
docs/api/core/event/end.md
Normal file
36
docs/api/core/event/end.md
Normal file
@@ -0,0 +1,36 @@
|
||||
# Event::end
|
||||
|
||||
```cpp
|
||||
Iterator end();
|
||||
```
|
||||
|
||||
获取结束迭代器。
|
||||
|
||||
**描述**
|
||||
|
||||
返回订阅列表的结束迭代器,用于范围for循环遍历所有订阅的回调。
|
||||
|
||||
**返回:** `Iterator` - 指向末尾的迭代器(等价于 `std::vector<Listener>::iterator`)
|
||||
|
||||
**复杂度:** O(1)
|
||||
|
||||
**示例:**
|
||||
|
||||
```cpp
|
||||
#include <XCEngine/Core/Event.h>
|
||||
|
||||
using namespace XCEngine::Core;
|
||||
|
||||
Event<int> event;
|
||||
event.Subscribe([](int v) { printf("Callback: %d\n", v); });
|
||||
|
||||
// 遍历所有订阅
|
||||
for (auto& [id, callback] : event) {
|
||||
callback(42);
|
||||
}
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [Event 总览](event.md) - 返回类总览
|
||||
- [begin](begin.md) - 获取开始迭代器
|
||||
Reference in New Issue
Block a user