aboutsummaryrefslogtreecommitdiffstats
path: root/yage/entity/component.cpp
blob: 4c0eae82083db4871dd6069ba0f02ab0f119bb8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include "component.h"

#include <memory>

namespace yage
{

GroupId BaseComponent::group_id_counter_ = 0;

ComponentGroup &ComponentGroup::add(std::unique_ptr<BaseComponent> &&component)
{
    components_.push_back(std::move(component));
    return *this;
}

ComponentGroup::Container::iterator ComponentGroup::begin() {
    return components_.begin();
}

ComponentGroup::Container::iterator ComponentGroup::end() {
    return components_.end();
}

} // namespace yage