public static ConsoleEnvironment BuildEnvironment() { var store = new InMemoryStore(); var blueprints = new InMemoryBlueprintLibrary(); blueprints.Register("model-t", new CarPart("wheel",4), new CarPart("engine",1), new CarPart("chassis",1)); var fas = new FactoryApplicationService(store, blueprints); return new ConsoleEnvironment { Events = store, FactoryAppService = fas, Handlers = ConsoleActions.Actions, Blueprints = blueprints }; }
public static ConsoleEnvironment BuildEnvironment() { var store = new InMemoryStore(); var blueprints = new InMemoryBlueprintLibrary(); blueprints.Register("model-t", new CarPart("wheel", 4), new CarPart("engine", 1), new CarPart("chassis", 1)); var fas = new FactoryApplicationService(store, blueprints); return(new ConsoleEnvironment { Events = store, FactoryAppService = fas, Handlers = ConsoleActions.Actions, Blueprints = blueprints }); }