载入中...
搜索中...
未找到
EditorDiskAssetCatalog.cpp
浏览该文件的文档.
14Result<DiskAssetScanResult> scanError(EditorStatus status, const char* rule, std::string message) {
26DiskAssetCatalog::DiskAssetCatalog(std::filesystem::path projectRoot, MemoryAssetDatabase* database)
33std::filesystem::path DiskAssetCatalog::resolveContent(const std::filesystem::path& relative) const {
43Result<void> DiskAssetCatalog::writeSidecar(const std::filesystem::path& contentRelativePath, AssetGuid guid,
47 return eve::editing::failed<void>(EditorStatus::Rejected, RuleId("editor.asset.sidecar-invalid"),
57 return eve::editing::failed<void>(EditorStatus::Failed, RuleId("editor.asset.sidecar-directory"), ec.message());
73 return eve::editing::failed<void>(EditorStatus::Failed, RuleId("editor.asset.sidecar-replace"), ec.message());
83 if (!std::filesystem::exists(contentRoot_)) return eve::editing::applied<DiskAssetScanResult>(std::move(result));
UUID-backed identifier adapter for legacy textual boundaries.
Definition Identity.h:314
const std::string & value() const noexcept
Returns the exact legacy or canonical compatibility spelling.
Definition Identity.h:362
bool empty() const noexcept
True when no compatibility spelling has been assigned.
Definition Identity.h:374
Result< DiskAssetScanResult > scan()
Scan every sidecar and atomically publish valid records.
Definition EditorDiskAssetCatalog.cpp:77
Result< void > writeSidecar(const std::filesystem::path &contentRelativePath, AssetGuid guid, std::string typeId, std::uint32_t schemaVersion=1)
Create/replace a sidecar for a Content-relative source file.
Definition EditorDiskAssetCatalog.cpp:43
DiskAssetCatalog(std::filesystem::path projectRoot, MemoryAssetDatabase *database)
Create a host-driven disk asset catalog.
Definition EditorDiskAssetCatalog.cpp:26
Result< DiskAssetScanResult > poll()
Rescan and report only content/sidecar fingerprints that changed.
Definition EditorDiskAssetCatalog.cpp:142
Thread-neutral in-memory asset index used by editor hosts and tests.
Definition EditorAssetDatabase.h:71
Result< AssetRecord > publish(AssetRecord record, std::vector< AssetDependency > dependencies={})
Atomically publish one validated record and its dependencies.
Definition EditorAssetDatabase.cpp:19
Diagnostic ruleDiagnostic(eve::DiagnosticCode code, RuleId rule, DiagnosticSeverity severity, std::string message)
Build a common diagnostic carrying an open editing rule identity.
Definition EditingResult.h:25
Definition ActionPreviewController.cpp:6
eve::editing::Value EditorValue
Compatibility alias for the UI-independent authoring value tree.
Definition EditorValue.h:8
@ InvalidArgument
@ NotFound
@ Conflict
Value snapshot stored by the editor asset index.
Definition EditorAssetDatabase.h:18
std::uint32_t schemaVersion
Definition EditorAssetDatabase.h:22
Result of one disk asset sidecar scan/poll.
Definition EditorDiskAssetCatalog.h:13
std::vector< EditorDiagnostic > diagnostics
Definition EditorDiskAssetCatalog.h:16