Borrowed container implementation owned by a domain adapter. 更多...
#include <Container.h>
类 | |
| class | PreparedState |
| Detached state prepared for an atomic container replacement. 更多... | |
Public 成员函数 | |
| virtual | ~IContainer ()=default |
| virtual const ContainerDescriptor & | descriptor () const noexcept=0 |
| Return immutable container metadata. | |
| virtual Result< ContainerSnapshot > | snapshot () const =0 |
| Return current lossless state without retaining adapter pointers. | |
| virtual Result< void > | validateInsert (const ContainerObject &object, std::optional< SlotIndex > destination, std::optional< MembershipId > ignoredObject=std::nullopt) const =0 |
| Validate insertion while optionally ignoring one moved object. | |
| virtual Result< std::unique_ptr< PreparedState > > | prepare (const ContainerSnapshot &expected, const ContainerSnapshot &candidate)=0 |
Prepare an exact replacement from expected to candidate. | |
详细描述
Borrowed container implementation owned by a domain adapter.
在文件 Container.h 第 287 行定义.
构造及析构函数说明
◆ ~IContainer()
|
virtualdefault |
成员函数说明
◆ descriptor()
|
pure virtualnoexcept |
Return immutable container metadata.
在 eve::building::BuildingGarrisonContainerAdapter, eve::card::CardContainerAdapter, eve::inventory::InventoryContainerAdapter , 以及 eve::vehicle::VehicleSeatContainerAdapter 内被实现.
◆ prepare()
|
pure virtual |
Prepare an exact replacement from expected to candidate.
- 参数
-
expected Snapshot observed during transfer preflight. candidate Fully constructed post-transfer snapshot.
- 返回
- A detached state whose commit and rollback operations cannot fail; no observable state may change before commit.
- 备注
- The adapter must reject a stale
expectedsnapshot. The adapter is borrowed and must outlive the returned state; the caller must externally serialize access to the adapter.
在 eve::building::BuildingGarrisonContainerAdapter, eve::card::CardContainerAdapter, eve::inventory::InventoryContainerAdapter , 以及 eve::vehicle::VehicleSeatContainerAdapter 内被实现.
◆ snapshot()
|
pure virtual |
Return current lossless state without retaining adapter pointers.
在 eve::building::BuildingGarrisonContainerAdapter, eve::card::CardContainerAdapter, eve::inventory::InventoryContainerAdapter , 以及 eve::vehicle::VehicleSeatContainerAdapter 内被实现.
◆ validateInsert()
|
pure virtual |
Validate insertion while optionally ignoring one moved object.
在 eve::building::BuildingGarrisonContainerAdapter, eve::card::CardContainerAdapter, eve::inventory::InventoryContainerAdapter , 以及 eve::vehicle::VehicleSeatContainerAdapter 内被实现.
该类的文档由以下文件生成:
- src/engine/common/Container.h