Sauce-0.10.1
A C++ Dependency Injection Framework
|
Names the binding. More...
#include <sauce/binder.h>
Public Member Functions | |
ToInstanceClause< Dependency > | toInstance (IfacePtr iface) |
template<typename Method > | |
ToMethodClause< Dependency, Method > | toMethod (Method method) |
template<typename Signature > | |
ToMethodNamingClause< Dependency, Signature > | toMethodNaming (typename ToMethodNamingClause< Dependency, Signature >::Method method) |
template<typename SetDependency > | |
ToMethodNamingClause< Dependency, void(Iface::*)(SetDependency)> | setting (typename ToMethodNamingClause< Dependency, void(Iface::*)(SetDependency)>::Method method, std::string name=unnamed()) |
template<typename Iface , typename Name > | |
ToMethodNamingClause< Dependency, void(Iface::*)(Named< Iface, Name >)> | setting (typename ToMethodNamingClause< Dependency, void(Iface::*)(Named< Iface, Name >)>::Method method) |
template<typename Scope > | |
InClause< Dependency, Scope > | in () |
template<typename Ctor > | |
ToClause< Dependency, NoScope, Ctor > | to () |
template<typename ProviderCtor > | |
ToProviderClause< ProviderDependency, NoScope, ProviderCtor > | toProvider () |
![]() | |
Clause< Dependency > & | naming (unsigned int position, std::string const name) |
void | setState (ClauseStatePtr state) |
Additional Inherited Members | |
![]() | |
virtual void | onComplete () |
Clause (ClauseStatePtr state) | |
ClauseStatePtr | getState () |
template<typename Next > | |
Next | pass (Next next) |
void | setDynamicName (std::string const name) |
template<typename Exception > | |
void | throwLater (Exception) |
void | bindDynamicDependencyName (unsigned int position, std::string const name) |
Names the binding.
There are two kinds of names: static and dynamic. Static names are given by template parameter type tags. Dynamic ones are string arguments. Each binding can use only one kind, but bindings using both kinds can be mixed in the same module.