コード例 #1
0
 private void tryCreateBuildPlan(Type pluginType, InstanceRef instanceRef, Policies policies,
                                 ProfileReport report)
 {
     try
     {
         instanceRef.Instance.ResolveBuildPlan(pluginType, policies);
     }
     catch (StructureMapException e)
     {
         _buildPlanFailureIds.Add(instanceRef.Instance.Id);
         e.Instances.Fill(instanceRef.Instance.Id);
         report.AddError(pluginType, instanceRef.Instance, e);
     }
 }
コード例 #2
0
        private void tryBuildInstance(Type pluginType, Instance instance, IPipelineGraph pipeline, ProfileReport report)
        {
            var session = new BuildSession(pipeline, instance.Name);

            try
            {
                var @object = session.FindObject(pluginType, instance);
                validate(pluginType, instance, @object, report);
            }
            catch (StructureMapException ex)
            {
                ex.Instances.Each(x => _buildPlanFailureIds.Fill(x));

                report.AddError(pluginType, instance, ex);
            }
        }
コード例 #3
0
 private void tryCreateBuildPlan(Type pluginType, InstanceRef instanceRef, Policies policies,
     ProfileReport report)
 {
     try
     {
         instanceRef.Instance.ResolveBuildPlan(pluginType, policies);
     }
     catch (StructureMapException e)
     {
         _buildPlanFailureIds.Add(instanceRef.Instance.Id);
         e.Instances.Fill(instanceRef.Instance.Id);
         report.AddError(pluginType, instanceRef.Instance, e);
     }
 }
コード例 #4
0
        private void tryBuildInstance(Type pluginType, Instance instance, IPipelineGraph pipeline, ProfileReport report)
        {
            var session = new BuildSession(pipeline, instance.Name);

            try
            {
                var @object = session.FindObject(pluginType, instance);
                validate(pluginType, instance, @object, report);
            }
            catch (StructureMapException ex)
            {
                ex.Instances.Each(x => _buildPlanFailureIds.Fill(x));

                report.AddError(pluginType, instance, ex);
            }
        }