예제 #1
0
        public static GeneratedServiceType For(Type serviceType, IContainer container)
        {
            var assembly      = new GeneratedAssembly(new GenerationRules("LamarRest"));
            var generatedType = new GeneratedServiceType(assembly, serviceType);

            container.CompileWithInlineServices(assembly);

            return(generatedType);
        }
예제 #2
0
        public static GeneratedServiceType For(Type serviceType, IContainer container)
        {
            var assembly      = new GeneratedAssembly(new GenerationRules("LamarRest"));
            var generatedType = new GeneratedServiceType(assembly, serviceType);

            var services = container.CreateServiceVariableSource();

            new AssemblyGenerator().Compile(assembly, services);

            return(generatedType);
        }