architecture

How to avoid many 'if's' and provide runtime params on execution

拈花ヽ惹草 提交于 2019-12-24 14:28:40
问题 I am trying to avoid lots of if's and use an OOP way to execute different executions. the execution is determined by ACTION integer which I get from an API on runtime. I though about command pattern and this is how it looks: I created on Spring configuration a hashmap: @Bean public HashMap<Integer, Command> hashmapCommands() { HashMap<Integer, Command> supportedCommands = new HashMap<>(); supportedCommands.put(command.action.getId(), myCommand()); .. } @Bean public Command MyCommand() {

Where view models inside Web project of n-tier application should be placed?

杀马特。学长 韩版系。学妹 提交于 2019-12-24 14:18:10
问题 Let's assume we have an ASP.NET MVC web application with following tiers: Business logic Entities (business domain and database POCOs) Common (resources, consts) Data access (database EF queries, EDMX EF models and so on) Web application (MVC web application) We're using view models approach. Currently view models are placed in Entities layer. Data access queries returns view models (due to efficiency issues, so we avoid using mapper). Web layer references all other layers. Data access

C++ Make a Program Write Over Itself

ぐ巨炮叔叔 提交于 2019-12-24 12:57:35
问题 I posted a question on a similar topic a couple days ago (and one a couple years ago), but I decided to go ahead and get started. I am trying to inject C++ code into C++ code (in a somewhat portable manner using no os specific features and trying to be compiler/toolchain independent manner). I basically want to do this in an attempt to do runtime C++ scripts. I wrote a small test program (its really just kinda thrown together and hacky): Main.cpp: #include <stdlib.h> #include <iostream>

ModelView to ModelView communication

末鹿安然 提交于 2019-12-24 12:43:10
问题 Please, what do you suggest is the best (in terms of architectural quality) approach to the following scenario: ModelViewA (parent) - requires collection from ModelViewB to display data - access collection multiple times even when the collection remains unchanged ModelViewB (child) - holds collection of items. The collection conceptually belongs to ModelViewB and is primarily modified within this (model)view. However, ModelViewA can also modify the collection The current approach I take is

best WSO2-ESB solution for banking application

亡梦爱人 提交于 2019-12-24 12:34:17
问题 we are a co-banking solutions company. currently we are developing a solution and we hope to use WSO2-ESB in our solution to manage our services this is the brief scenario of our project,.... we have a oracle application server that generate various services.there are two kind of services 1.services that can be access from outside users 2.services that can be access by inhouse users. ****also security is more concerned my questions are, 1.how to use WSO2-ESB in this scenario..?? 2.is it one

Android Client-Server architecture: GCM versus webservice

我的未来我决定 提交于 2019-12-24 12:01:04
问题 I have an Android application with a local database that contains information about pictures stored on the device. I want to create a server with pictures that could be provided on demand to all devices that have my application installed. So my application can provide local pictures or pictures from my server and also needs some information related to those pictures. I analyzed GCM and it great for message communication, but since the size of the message is limited to 4kb I can't send the

Where does DTOS as InputModel / ViewModel Fit in Layered Archicture

笑着哭i 提交于 2019-12-24 11:34:31
问题 I'm trying to understand where does InputModel and ViewModels fit at the 4 Layer Architecture. Presentation | Application | Domain | Infrastructure Given that the Application Layer takes care about exchange data beteween Presentation Layer and Domain Layer, I supposed that, they must live inside this layer, as well the adapter to convert It back to Domain Entity and vice versa. InputModels, also know as Commands, in ASP.NET MVC they can coincide with ViewModels. Makes no sense to me

convert of the object (image) to another object (Byte) in three layers(3-tier)

我的未来我决定 提交于 2019-12-24 09:37:28
问题 Conversions can be done in the first layer ( UI ) ? 回答1: For these kind of operations I personally create a Utils class/namespace under project namespace ( myProjectNamespace.Utils ). A ststic class with public static members for conversions, formatting, calculations... Put this class in BLL (Business Logic Layer) most of the time but sometimes you need different Utils for different layers. 回答2: Assuming an image is an input - inputs usually come into a system through: The frontend interface

VALID_ARCHS = arm64 armv7 armv7s not generating any armv7s

僤鯓⒐⒋嵵緔 提交于 2019-12-24 09:20:27
问题 I'm having a question about the compilation on iOS. I'm generating a framework and it used to generate arm64, armv7 and armv7s (+ simulators with lipo and fun). The thing is, armv7s is not present in the binary anymore. Architectures in the fat file are: i386 x86_64 armv7 arm64 But I clearly asks in my XCConfig for VALID_ARCHS = arm64 armv7 armv7s. I verified that the XCConfig was indeed used and not overridden. I tried various google search but most of the time we find people not

Proper .NET DLL structure for app

给你一囗甜甜゛ 提交于 2019-12-24 07:47:36
问题 ...if there is such a thing. Here's an image of two approachs for structuring DLLs/references in a .NET application: http://www.experts-exchange.com/images/t80668/compArch.png. The app can be a website (it is in this case) or a winform. Each box represents a DLL. For the winform app, just replace "webcontrols" with "winformcomponents". The first (top) image is what I like. You might want to extend "some" of the base web controls and directly use others. The 2nd image makes you extend any web