docs: update resources API docs
This commit is contained in:
29
docs/api/resources/resourcepath/setpath.md
Normal file
29
docs/api/resources/resourcepath/setpath.md
Normal file
@@ -0,0 +1,29 @@
|
||||
# ResourcePath::SetPath
|
||||
|
||||
```cpp
|
||||
void SetPath(const Containers::String& path)
|
||||
```
|
||||
|
||||
设置路径字符串。
|
||||
|
||||
**详细描述:**
|
||||
|
||||
更新内部存储的路径字符串。
|
||||
|
||||
**参数:**
|
||||
- `path` - 新的路径字符串
|
||||
|
||||
**复杂度:** O(n),n 为路径长度
|
||||
|
||||
**示例:**
|
||||
|
||||
```cpp
|
||||
ResourcePath path;
|
||||
path.SetPath("textures/player.png");
|
||||
Containers::String name = path.GetFileName(); // "player.png"
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [ResourcePath 总览](resourcepath.md) - 返回类总览
|
||||
- [GetPath](getpath.md) - 获取路径
|
||||
Reference in New Issue
Block a user