コード例 #1
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance <AuthorizationBehavior>();

            instance.Ctor <IAuthorizationNode>().Is(this);

            if (_failure != null)
            {
                instance.Ctor <IAuthorizationFailureHandler>().Is(_failure);
            }

            return(instance);
        }
コード例 #2
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance<BehaviorTracer>();
            instance.Ctor<BehaviorNode>().Is(Next);

            return instance;
        }
コード例 #3
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance<AntiForgeryBehavior>();
            instance.Ctor<string>().Is(_salt);

            return instance;
        }
コード例 #4
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance<ExceptionHandlerBehavior>();
            instance.Ctor<HandlerChain>().Is(_chain);

            return instance;
        }
コード例 #5
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance <ExceptionHandlerBehavior>();

            instance.Ctor <HandlerChain>().Is(_chain);

            return(instance);
        }
コード例 #6
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance <BehaviorTracer>();

            instance.Ctor <BehaviorNode>().Is(Next);

            return(instance);
        }
コード例 #7
0
        protected override IConfiguredInstance buildInstance()
        {
            var instance = new SmartInstance <AntiForgeryBehavior>();

            instance.Ctor <string>().Is(_salt);

            return(instance);
        }
コード例 #8
0
 public StructureMapConstructorArgumentMapping(IMapping <TInterface, TImplementation> mapping, SmartInstance <TImplementation> argMapping)
 {
     _mapping    = mapping;
     _argMapping = argMapping.Ctor <TArg>();
 }
コード例 #9
0
ファイル: SMSelectorExpression.cs プロジェクト: juandrn/NetXP
 public void InjectInstance <T>(T instance)
 {
     use.Ctor <T>().Is(o => instance);
 }