Strict process-local catalogue for versioned story-event content. 更多...
#include <StoryEvent.h>
静态 Public 成员函数 | |
| static eve::Result< int > | replaceFromJsonStrict (const std::string &json) |
| Validate and atomically replace every story-event definition. | |
| static void | clear () |
| Clear all definitions on the owning content thread without invoking callbacks. | |
| static int | count () |
| Return the committed definition count on the owning content thread. | |
| static bool | contains (const std::string &eventId) |
| Return whether an exact stable event id exists in the current catalogue. | |
| static const StoryEventDefinition * | find (const std::string &eventId) |
| Find one definition for immediate synchronous inspection. | |
详细描述
Strict process-local catalogue for versioned story-event content.
在文件 StoryEvent.h 第 37 行定义.
成员函数说明
◆ clear()
|
static |
Clear all definitions on the owning content thread without invoking callbacks.
在文件 StoryEvent.cpp 第 186 行定义.
引用了 definitions.
被这些函数引用 eve::rpg::RPG::clearStoryEvents().
◆ contains()
|
static |
Return whether an exact stable event id exists in the current catalogue.
在文件 StoryEvent.cpp 第 188 行定义.
引用了 definitions.
被这些函数引用 eve::rpg::RPG::hasStoryEvent().
◆ count()
|
static |
Return the committed definition count on the owning content thread.
在文件 StoryEvent.cpp 第 187 行定义.
引用了 definitions.
被这些函数引用 eve::rpg::RPG::getStoryEventCount().
◆ find()
|
static |
Find one definition for immediate synchronous inspection.
- 返回
- Borrowed nullable definition owned by the catalogue. @lifetime Invalidated by clear() or successful replacement; do not retain across either call. @thread Query on the owning content/simulation thread.
在文件 StoryEvent.cpp 第 189 行定义.
引用了 definitions , 以及 found.
被这些函数引用 eve::rpg::StoryEventSession::begin().
◆ replaceFromJsonStrict()
|
static |
Validate and atomically replace every story-event definition.
- 参数
-
json UTF-8 eve.rpg.story-eventsversion 1 document.
- 返回
- Committed event count, or a structured failure preserving the prior catalogue.
- 备注
- Unknown fields and invalid command shapes are rejected before publication. @thread Call on the owning content/simulation thread; no synchronization is performed. @reentrancy No callbacks or scripts are invoked.
在文件 StoryEvent.cpp 第 58 行定义.
引用了 eve::rpg::StoryEventStep::actorId, eve::AlreadyExists, definitions, eve::rpg::Dialogue, duration, eve::rpg::StoryEventStep::duration, eve::Diagnostic::error(), events, eve::Result< T >::failure(), index, eve::InvalidArgument, key, eve::rpg::StoryEventStep::kind, eve::rpg::Message, eve::rpg::Move, eve::json::Document::parse(), eve::ParseError, path, reference, eve::rpg::StoryEventStep::reference, root, size, steps, eve::Result< T >::success(), eve::UnknownVersion, value, eve::rpg::Wait, x, eve::rpg::StoryEventStep::x, y , 以及 eve::rpg::StoryEventStep::y.
该类的文档由以下文件生成:
- src/modules/rpg/StoryEvent.h
- src/modules/rpg/StoryEvent.cpp