Skip to main content

RemoveComponentCommand.ixx File

Deferred command for removing a component from an entity. More...

Included Headers

#include <memory>

Namespaces Index

namespacehelios
namespaceecs
namespacecommands

Classes Index

structRemoveComponentCommand<TComponent>

Deferred command that removes a component of type TComponent from an entity. More...

Description

Deferred command for removing a component from an entity.

File Listing

The file content with the documentation metadata removed is:

1
5module;
6
7#include <memory>
8
9export module helios.ecs.commands:RemoveComponentCommand;
10
11export namespace helios::ecs::commands {
12
13
22 template<typename TComponent>
24
26 using Handle_type = TComponent::Handle_type;
27
29 using Component_type = TComponent;
30
33
35 TComponent component;
36
43 requires std::default_initializable<TComponent>
44 : handle(handle), component() {}
45
53 template<typename ...TArgs>
54 requires std::constructible_from<TComponent, TArgs...>
55 explicit RemoveComponentCommand(Handle_type handle, TArgs&& ...args)
56 : handle(handle), component(std::forward<TArgs>(args)...) {}
57
58 };
59
60};

Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.