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);
        }
Example #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);
        }