Questions about problem solving and planning for a solution through software design.

learn more… | top users | synonyms (1)

12
votes
4answers
659 views

What are the Advantages of a “Combined” Getter/Setter VS Individual Methods?

This is what I call a "combined" getter/setter method (from jQuery): var foo = $("<div>This is my HTML</div>"), myText; myText = foo.text(); // myHTML now equals "This is my HTML" ...
0
votes
3answers
159 views

What will be the better way to access information from another object

I have a page Object, which has Paragraph and Image object Collections And each paragraph has only image_id(s) that are assigned to a paragraph. All other information about image is stored in ...
3
votes
1answer
458 views

Can an entire software infrastructure stack be built entirely from source in-house? Is it practical and sustainable?

I'm a big fan of using open source software but I mostly use community binary releases for the job. I'm wondering about companies that go the extra degree and build everything they use in their ...
0
votes
2answers
271 views

php - auto populate the model member variable from database table

I am stuck with a very old large website which I need to do some modifications. I can't use or integrate a new MVC framework due to current site is outdated with some custom coding done long time ago. ...
4
votes
3answers
219 views

Establishing an API to provide end-user apps/scripts access to multiple types of databases

Question and Context I am currently working on a project where the main question is, how do we insert an API between the database and end-users who may develop applications/scripts of their own that ...
15
votes
3answers
1k views

Does the state Pattern violate Liskov Substitution Principle?

This image is taken from Applying Domain-Driven Design and Patterns: With Examples in C# and .NET This is the class diagram for the State Pattern where a SalesOrder can have different states during ...
7
votes
2answers
2k views

What are the cons of using XML for GUI development? [closed]

I'm hoping this question fits within the scope of Programmers SE and that it's not too open ended. I've always hated GUI design. I don't mean to offend anyone, but I've hated CSS/HTML, I've hated ...
5
votes
3answers
487 views

How can I create and manage permissions more dynamically?

I want to implement a security system into my web-based Intranet application which allows security administrators to 'fine-tune' exactly what type of access a user/role has to an object. For example, ...
2
votes
4answers
117 views

Feature organization / authentication? [closed]

Let's say I have a product that has different features, or different feature access depending on things (i.e Premium User, Beta, Demo, Logged-in User, etc..). What's the best way to organize a system ...
1
vote
1answer
243 views

Why does Java MessageDigest.getInstance() have a String as a parameter?

I presume it's that way so it could be extended with custom algorithms, but wouldn't it be more convenient to apply, let's say, factory method pattern here and avoid the whole NoSuchAlgorithmException ...
9
votes
8answers
669 views

Past If statements Arrays, loops… Now what?

I gave up on programming a little over a year ago when I kept hitting this wall. I am revisiting the subject because I want to create basic Android application. But I feel that my limited knowledge ...
2
votes
1answer
593 views

DB Schema for packaging products / services together under a single pric / Offer

I'm trying to 'conceive' the business logic of this website that have many activities, that the users can build their "combo" and get discounts depending on their choices and how long they are willing ...
-1
votes
3answers
892 views

Is software design important to programmers? [closed]

I am studying software engineering, just finished the requirements course and going for more. I don't know how important software design is (in real world and actual projects) in later SDLC phases. ...
5
votes
3answers
196 views

How do I design a DAL when I have to deal with relationships?

Say I'm developing a bug tracker, where a ticket belongs to at most one milestone, and a milestone can have many tickets. When a milestone is deleted (from the database), all tickets associated with ...
21
votes
9answers
3k views

Are there any programming languages that follow a minimalist development approach?

I find it that when languages are considered the same as commercial software, there is always a constant need to add new features to justify new releases. Can there be or are there languages where ...
3
votes
1answer
1k views

C++ Design: Functional Programming vs OOP

Design Question Recently, I've been doing more and more FP in C++, mostly in the form of function templates and lambdas, and heavy overloading of a single function name. I really like FP for some ...
4
votes
2answers
554 views

WCF service as a proxy for publishing real-time data to a WPF/MVVM clients

I've been tasked with creating a dashboard application to show real time updates for our servers. The raw data comes in from an XML file on our intranet which I need to parse and present to the user. ...
0
votes
1answer
309 views

Scientific software design [closed]

I asked this question over at stackoverflow and it was suggested a tighter form be posted here. Many early career numerical researchers face the prospect of having to create performance critical ...
3
votes
1answer
524 views

Encapsulate bitmap (*.bmp) as C++ class

How would you implement / design a class which has to represent a bitmap? I'm stuck at handling the different possible color modes and I keep thinking that this should be somehow implementable using ...
4
votes
1answer
216 views

Acceptance tests for large multi-step online form

I have to extend/fix a large online form written by other developer. There is a lot of code, mixing PHP and JS. It's kind of write-only style of coding and I want to redo it completely, but currently ...
13
votes
2answers
1k views

Advantages and disadvantages of structuring all code via classes and compiling to classes (like Java)

Edit: my language allows for multiple inheritance, unlike Java. I've started designing and developing my own programming language for educational, recreational, and potentially useful purposes. At ...
3
votes
2answers
177 views

Can a designer start an open source project? [closed]

I appreciate you can't start an open source project with just an idea but would just a design be enough? Has anyone ever seen that done where a designer posts a design and developers join to start the ...
2
votes
2answers
372 views

Desktop application, dependency injection

I am thinking of applying a real dependency injection library to my toy C#/GTK# desktop application. I chose NInject, but I think this is irrelevant to my question. There is a database object, a main ...
10
votes
3answers
3k views

Should I use a config file or database for storing business rules?

I have recently been reading The Pragmatic Programmer which states that: Details mess up our pristine code—especially if they change frequently. Every time we have to go in and change the code to ...
1
vote
2answers
122 views

Interface extension

Suppose that I have an input stream interface, which defines a method for reading data. I also have a seekable interface which defines a method for seeking. A natural way of defining a input file is ...
16
votes
8answers
3k views

Why does Clang/LLVM warn me about using default in a switch statement where all enumerated cases are covered?

Consider the following enum and switch statement: typedef enum { MaskValueUno, MaskValueDos } testingMask; void myFunction(testingMask theMask) { switch theMask { case ...
4
votes
1answer
113 views

Design pattern for isomorphic trees

I want to create a data structure to work with isomorphic tree. I don't search for a "algorithms" or methods to check if two or more trees are isomorphic each other. Just to create various trees with ...
2
votes
2answers
105 views

share code between check and process methods

My job is to refactor an old library for GIS vector data processing. The main class encapsulates a collection of building outlines, and offers different methods for checking data consistency. Those ...
5
votes
3answers
6k views

Is there a difference between a component and a module

I have a little problem with the terms module and component. In my mind, a module are bundled classes, which are only accesable via a well defined interface. They hide all implementation details and ...
1
vote
2answers
910 views

Interaction of a GUI-based App and Windows Service

I am working on personal project that will be designed to help manage my media library, specifically recordings created by Windows Media Center. So I am going to have the following parts to this ...
18
votes
3answers
2k views

Does TDD lead to the good design? [duplicate]

I'm in transition from "writing unit tests" state to TDD. I saw as Johannes Brodwall creates quite acceptable design from avoiding any of architecture phase before. I'll ask him soon if it was real ...
3
votes
4answers
647 views

Help parsing long (3.5mil lines) text file, line by line and storing data, need a strategy

This is a question about solving a particular problem I am struggling with, I am parsing a long list of text data, line by line for a business app in PHP (cron script on the CLI). The file follows ...
4
votes
3answers
8k views

When should we use weak entities when modelling a database?

This is basically a question about what are weak entities? When should we use them? How should they be modeled? What is the main difference between normal entities and weak entities? Does weak ...
3
votes
1answer
176 views

On Developing Web Services with Global State

I'm new to web programming. I'm more experienced and comfortable with client-side code. Recently, I've been dabbling in web programming through Python's Google App Engine. I ran into some difficulty ...
3
votes
4answers
246 views

How can I better manage far-reaching changes in my code?

In my work (writing scientific software in C++), I often get asked by the people who use the software to get their work done to add some functionality or change the way things are done and organized ...
4
votes
3answers
543 views

What is the best practice, point of view of well experienced developers [closed]

My manager pushes me to use his self defined best practices. All of these practices are based on is own assumptions. I disagree with them and I would like to have some feedback of well experienced ...
4
votes
2answers
5k views

How to design a scalable notification system? [closed]

I need to write a notification system manager. Here is my requirements: I need to be able to send a Notification on different platforms, which may be totally different (for exemple, I need to be ...
3
votes
1answer
124 views

Is there a rule of thumb for what a bing map's zoom setting should be based on how many miles you want to display?

If a map contains pushpins/waypoints that span only a couple of miles, the map should be zoomed way in and show a lot of detail. If the pushpins/waypoints instead cover vast areas, such as hundreds or ...
0
votes
1answer
508 views

Client-Server connection response timeout issues

User creates a folder in client and in the client-side code I hit an API to the server to make this persistent for that user. But in some cases, my server is so busy that the request timesout. The ...
3
votes
4answers
358 views

Representing complex object dependencies

I have several classes with a reasonably complex (but acyclic) dependency graph. All the dependencies are of the form: class X instance contains an attribute of class Y. All such attributes are set ...
5
votes
1answer
1k views

Is this an acceptable approach to undo/redo in Python?

I'm making an application (wxPython) to process some data from Excel documents. I want the user to be able to undo and redo actions, even gigantic actions like processing the contents of 10 000 cells ...
2
votes
3answers
205 views

Rest Design concerning user login

To be as restful as possible, is a user login better designed using a GET or a POST on a REST webservice? And why?
0
votes
1answer
90 views

Best setup/workflow for distributed team to integrated DSVC with fragmented huge .NET site?

So we have a team with 2 developers one manager. The dev server sits in a home office and the live server sits in a rack somewhere handled by the larger part of my company. We have freedom to do as we ...
2
votes
1answer
1k views

Can a flow diagram have more than one start?

I'm drawing a flow diagram which should visualize the communication between 4 services I created. Now I've got a question I'm not quite sure about. There are two ways the services could be started. ...
3
votes
2answers
788 views

null values vs “empty” singleton for optional fields

First of all I'm developing a parser for an XML-based format for 3D graphics called XGL. But this question can be applied to any situation when you have fields in your class that are optional i.e. the ...
0
votes
2answers
68 views

Advice on reconciling discordant data

Let me support my question with a quick scenario. We're writing an app for family meal planning. We'll produce daily plans with a target calorie goal and meals to achieve it for our nuclear family. ...
4
votes
6answers
1k views

How to do dependency Injection and conditional object creation based on type?

I have a service endpoint initialized using DI. It is of the following style. This end point is used across the app. public class CustomerService : ICustomerService { private IValidationService ...
2
votes
3answers
689 views

Software design for non object oriented paradigm

I'm currently working on a project where I'm writing the firmware for an electronic system in C, and have been asked to produce documentation on the development/evolution of the software for the ...
6
votes
6answers
1k views

OOP Design: relationship between entity classes

I have at first sight a simple issue but can't wrap my head around on how to solve. I have an abstract class Compound. A Compound is made up of Structures. Then there is also a Container which holds 1 ...
2
votes
1answer
504 views

How to design software when using BDD?

I'm working on a project right now and it's my first project using BDD. Up till now, the user stories have proven themselves a very valuable weapon to understand requirements and to specify the ...