architecture

Constructing two objects that need each other

为君一笑 提交于 2019-12-27 03:27:30
问题 A puzzling architectural question: You have two symmetrical classes A and B . Each A / B object may privately produce a value of type IA / IB using the A.CreateIA() / B.CreateIB() methods. These values are needed by the opposite classes - A needs IB and B needs IA . The goal is to write the PairMaker.MakePair() function that constructs an interlinks a pair of A and B objects . You also have to write appropriate constructors for the A and B classes. A and B classes are in different assemblies

Constructing two objects that need each other

给你一囗甜甜゛ 提交于 2019-12-27 03:27:12
问题 A puzzling architectural question: You have two symmetrical classes A and B . Each A / B object may privately produce a value of type IA / IB using the A.CreateIA() / B.CreateIB() methods. These values are needed by the opposite classes - A needs IB and B needs IA . The goal is to write the PairMaker.MakePair() function that constructs an interlinks a pair of A and B objects . You also have to write appropriate constructors for the A and B classes. A and B classes are in different assemblies

which architecture is good for implementing in this project? [closed]

﹥>﹥吖頭↗ 提交于 2019-12-27 02:09:08
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . i am new in architecture .I have a MVC web application project and I want to use EF code FIRST .I want to use an architecture for this project.I want to use DDD(domain driven design) but it is for large project. i want a simple of DDD that support this things in my project: 1-repository pattern 2-IOC 3-service

Design Patterns - what to use when the return type is different

别来无恙 提交于 2019-12-25 16:51:57
问题 How would you architect this solution where you have different type of search, like web, image etc. So in effect the input is same but the result are different according to search type selected I can think of Strategy n Factory to handle input and select different search algorithm but how to handle return type? Thanks in advance 回答1: You can either have a BaseSearchResult kind of class or have the result interfaced , so that different types of search classes can return same type of result.

How can we implement the Builder design pattern using boost::mpl? [closed]

百般思念 提交于 2019-12-25 14:30:07
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 2 years ago . I have three classes which adhere to the same concept class but differ on the underlying data structure used for storage. As an illustration take the three classes given below. template< typename T > class A{ std::vector<T> storage; //etc }; template<> class A<bool>{ boost:

How to design code architecture when overlapping objects exist?

依然范特西╮ 提交于 2019-12-25 11:47:12
问题 I have 1 main Master screen (MVC) and 4 other screens that share ~80% of graphic objects. They differ in some label texts, a button with action and some other 20% graphics. Thinking in terms of clean object oriented code architecture, I have started to implement those screens as separate UIViewControllers. But I didn't like having pointers to those 4 MVCs and a duplication of some methods, so I rewrited the code into one UIViewController. Most of graphic objects are UIImageViews that I put on

AngularJS: Server Side Architecture

你。 提交于 2019-12-25 09:19:10
问题 Within our corporate intranet, we have a few end-point service platforms like BPM, document management system, etc. These end-point services expose REST API. We develop web applications using AngularJS as front end. There are two options on how we can make calls from AngualJS to these end-point services. Option 1: Given these end-point services expose REST, call these REST API directly from AngualrJS. Option 2: Introduce a middle layer (on an application server like WebLogic or Tomcat). Build

WPF Design Considerations Using WebBrowser Control

人走茶凉 提交于 2019-12-25 08:26:14
问题 I have to build a program that will allow me to track from a system different trigger points being hit. When a trigger has been hit within another system a web service is called, this web service will log to a database the following: Affiliate Id Trigger Id Reference Code My program is to read this data and invoke a call to affiliates websites for affiliate tracking. The only trouble is, these sites do not offer any nice web service or form post, it is done via tracking pixels (images created

What did I get wrong, DI or Design, and how should I go about it?

北战南征 提交于 2019-12-25 07:58:52
问题 To make a long story short, the application that I am currently writing ought to impersonate the current logged in user. It's an application to manage information inquiries. Because of NHibernate.ISessionFactory not allowing more flexibility at the level of its connection string, I need to build the connection dynamically using the current user credentials. (By the way, I'm not complaining against NH, it's a wonderful that I use on each project.) So, I need to force authentication at start up

Reusing the common layout in android application

依然范特西╮ 提交于 2019-12-25 07:26:58
问题 I am trying to make an application that has the following design. Login->Dashboard Dashboard has a #navigationdrawer having a listview ,of which every item opens a fragment. Dashboard has a view pager of two pages. Page 1 : listview Page2: search bar. Till now this is in place. Problem statement : The #page2 is constant it has to appear on every fragment ,but #page1 changes for every fragment . Can someone help me achieve this. I am not getting how to do it. 回答1: I think you should use search