public GetCityResponse GetCity(GetCityRequest request) { CityView view = new CityView(ObjectFactory.Create<IReadModelStore>()); CityDto dto = view.Load(request.CityId); GetCityResponse response = new GetCityResponse(); response.City = dto; return response; }
public CityFacade(IReadModelStore readModelStore) : base(readModelStore) {} public GetCityListResponse GetCityList(GetCityListRequest request) { CityView view = new CityView(ObjectFactory.Create<IReadModelStore>()); List<CityDto> list = view.GetList(request.Filter); GetCityListResponse response = new GetCityListResponse(); response.CityList = list; return response; }