aboutsummaryrefslogtreecommitdiff
path: root/examples/basic
diff options
context:
space:
mode:
Diffstat (limited to 'examples/basic')
-rw-r--r--examples/basic/src/bootstrap.cpp16
-rw-r--r--examples/basic/src/bootstrap.hpp2
2 files changed, 9 insertions, 9 deletions
diff --git a/examples/basic/src/bootstrap.cpp b/examples/basic/src/bootstrap.cpp
index 104cf51..507cde7 100644
--- a/examples/basic/src/bootstrap.cpp
+++ b/examples/basic/src/bootstrap.cpp
@@ -12,15 +12,15 @@
#include "hero.hpp"
#include "sword.hpp"
-auto bootstrap() -> yacppdic::Container
+auto bootstrap() -> yacppdic::DIContainer
{
- auto container = yacppdic::Container();
+ auto di_container = yacppdic::DIContainer();
- container.bind<IHero>().to<Hero>();
- container.bind<IWeapon>().to<Sword>();
- container.bind<IEnemyCreator>().to<EnemyCreator>();
+ di_container.bind<IHero>().to<Hero>();
+ di_container.bind<IWeapon>().to<Sword>();
+ di_container.bind<IEnemyCreator>().to<EnemyCreator>();
- container.bind<IEnemyFactory>()
+ di_container.bind<IEnemyFactory>()
.to_factory(
[]()
{
@@ -29,7 +29,7 @@ auto bootstrap() -> yacppdic::Container
)
.when_tagged<SMALL_ENEMY_TAG>();
- container.bind<IEnemyFactory>()
+ di_container.bind<IEnemyFactory>()
.to_factory(
[]()
{
@@ -38,5 +38,5 @@ auto bootstrap() -> yacppdic::Container
)
.when_tagged<BIG_ENEMY_TAG>();
- return container;
+ return di_container;
}
diff --git a/examples/basic/src/bootstrap.hpp b/examples/basic/src/bootstrap.hpp
index 9febbd9..964a3d7 100644
--- a/examples/basic/src/bootstrap.hpp
+++ b/examples/basic/src/bootstrap.hpp
@@ -2,4 +2,4 @@
#include <yacppdic/container.hpp>
-auto bootstrap() -> yacppdic::Container;
+auto bootstrap() -> yacppdic::DIContainer;