示例#1
0
        private static DbModel BuildModel(IMetadataProvider metadataProvider, IClrTypeProvider clrTypeProvider)
        {
            BoundedContextElement context;

            metadataProvider.TryGetMetadata(BuildContextId(), out context);

            var configurator = new DbModelBuilderConfigurator(metadataProvider, clrTypeProvider);
            var builder      = configurator.Configure(context);

            return(builder.Build(EffortProvider));
        }
示例#2
0
        protected static DbModel BuildModel(BoundedContextElement context)
        {
            var metadataProvider = CreateMetadataProvider(MockSource(context));
            var clrTypeProvider = new EmitClrTypeResolver(metadataProvider);
            clrTypeProvider.Build();

            var configurator = new DbModelBuilderConfigurator(metadataProvider, clrTypeProvider);

            var builder = configurator.Configure(context);
            var model = builder.Build(EffortProvider);

            model.Dump();

            return model;
        }
示例#3
0
        protected static DbModel BuildModel(BoundedContextElement context)
        {
            var metadataProvider = CreateMetadataProvider(MockSource(context));
            var clrTypeProvider  = new EmitClrTypeResolver(metadataProvider);

            clrTypeProvider.Build();

            var configurator = new DbModelBuilderConfigurator(metadataProvider, clrTypeProvider);

            var builder = configurator.Configure(context);
            var model   = builder.Build(EffortProvider);

            model.Dump();

            return(model);
        }