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

learn more… | top users | synonyms (1)

1
vote
2answers
517 views

Recommended Abstraction to transfer data over a nework than byte[] array?

I was curious, why do we prefer byte[] array to transfer data over the network and not anything else? Or if I am missing anything, what are the other ways to transfer the data over a network.
-3
votes
1answer
148 views

How do you call the discipline which consist of making the right choice of language/paradigm/class diagrams? [closed]

As a physicist, I've learnt programming on my own. But I would like to know the name of the discipline (like algorithmics is the discipline of designing algorithms) which consists of : making the ...
1
vote
4answers
604 views

How to figure out design pattern for this particular solution?

While working on a project I've come up with some design solution. I am having a hard time relating it to any general design pattern or analyzing this situation in details. This is also prohibiting me ...
2
votes
5answers
2k views

How to handle assumptions while designing any system?

I have been going through various system design examples to understand how we approach any system design question. Here is what I have understood till now. Know the system first and find out how it ...
1
vote
1answer
329 views

MyListActivity, MyCursorAdapter, MyViewHolder — nested classes or not?

I am using several activities based on the ListActivity. All of them display information from different SQLite queries, and all of them use the ViewHolder optimization. The cursor adapter have to be ...
3
votes
3answers
738 views

Alternative inheritance paradigms in object-oriented design

My apologies if a variation of this question has been asked before, but due to its nature it is hard to search for. I am having a discussion with a colleague about object-oriented design, and it ...
82
votes
16answers
36k views

Is it wrong to use a boolean parameter to determine behavior?

I have seen a practice from time to time that "feels" wrong, but I can't quite articulate what is wrong about it. Or maybe it's just my prejudice. Here goes: A developer defines a method with a ...
22
votes
12answers
2k views

SOLID vs. Avoiding Premature Abstraction

I understand what SOLID is supposed to accomplish and use it regularly in situations where modularity is important and its goals are clearly useful. However, two things prevent me from applying it ...
2
votes
2answers
415 views

Refactored to a fancy global variable?

I am currently refactoring an application that i built in JavaScript. The application uses a starting hour and a total working hour count in order to construct a timetable for daily, weekly and ...
1
vote
2answers
991 views

Better design for a generic doubly linked list around which I plan to make different wrappers?

I am currently writing a C code for a doubly linked list(dll) around which I want to write wrapers for implementing stack, queues etc. instead of writing separate codes for all of them. I'll be ...
3
votes
1answer
167 views

When to fracture a web application design into multiple products

Have you had this problem? You are building a complex web application for a target market, and after a while you reach a point in complexity where you can't decide if you are building more than one ...
1
vote
1answer
213 views

Law of Demeter issues with complex class design

I've posted questions pertaining to this issue before, but they've all tackled different aspects of the problem (Just so you know that I'm not reposting the same question to get more answers). So, in ...
0
votes
1answer
395 views

Code design: is this specific case of monkeypatching in python acceptable?

I'm using python to do some research tasks. I have a class hierarchy for "tools", where each object is an instance of a particular tool. They all share some functionality and have many similarities in ...
4
votes
2answers
1k views

Publish/subscribe, observer pattern implementation question

I'm developing desktop application in java/swing. I have a component that is registered as a subscriber to many panels and gets messages (my custom event) from them. That component is something like ...
0
votes
1answer
527 views

What design do I follow to convert my classic ASP pages to a Java Enterprise Web Application? [closed]

There are so many Java technologies that it is difficult for me to know where to start. I understand JSP and Servlets. I know what http servers to use. Real basic stuff. What I don't understand is ...
1
vote
3answers
1k views

How to document program flow so the outcome looks professional? [closed]

I have designed a simple website on paper. Now I want to produce a professional-looking document for my customer to approve. How can I do this? I've tried Visio, but it seems horribly ...
2
votes
2answers
264 views

How to formalize feature requests

I'm new to developing software and have been handling feature requests for an internal web-app I built. Sometimes the feature requests are straight-forward and require minimal business logic for me ...
12
votes
3answers
2k views

How to create better OO code in a relational database driven application where the database is poorly designed

I am writing a Java web application that consists mainly of a bunch of similar pages in which every page has several tables and a filter that applies to those tables. The data on these tables comes ...
7
votes
3answers
5k views

How to handle complex views (consisting of several parts) in MVC web application

Lets say I am writing a blog web application using MVC pattern. Typical layout for the main page of the blog application is - some kind of a post index in the main part, and aside there are some ...
3
votes
2answers
417 views

How to keep my Activity code readable and maintainable?

I have written a rather small App with only one activity. From my understanding an activity has to be seen as kind of a view and controller in one class. But even for a little app, with 3 dialogs ...
3
votes
2answers
496 views

Can classes violate Single Responsibility if they delegate internal tasks?

I have two classes Output and Timeline, neither of which violate SR, but the two of them are linked together. So what I'd like to do is have a class called Elco (there's a reason behind the name) that ...
1
vote
0answers
558 views

Is OAuth (2.0) is the right choice to make WCF WebService secure?

I have WCF webservice which serves to various mobile application. This was implemented with typical HTTPS/SSL. But there are some cases like Replay Attack needs to be considered in the security ...
-1
votes
4answers
509 views

Am I required to memorize coding in a work space or can I fall onto references to provide me edge to finishing my development? [duplicate]

I would like to know if I am expected to memorize coding in a workspace or am I allow to fall into references whenever I am unsure. In a week of non-stop self learning, I feel I can understand the ...
7
votes
6answers
957 views

Design guidelines for this scenario in C#?

I have to create a validation system(I don't want to use Data Annotation or any other system) for my C# application using .Net Compact Framework, where I have an object which contains many other ...
2
votes
4answers
164 views

Subclassing to change default settings?

I have a class called Timeline. I want to allow several defaults in my code, such as a Timeline with a Start event (The details are not needed. All that matters is that I have a class, and I want to ...
75
votes
16answers
5k views

Should we design programs to randomly kill themselves? [closed]

In a nutshell, should we design death into our programs, processes, and threads at a low level, for the good of the overall system? Failures happen. Processes die. We plan for disaster and ...
28
votes
5answers
2k views

Design in one team, coding in another

I will be involved in a project where all the software design is made by a local team and these designs are sent to an offshore team for coding. This is the first time I face a project with this ...
43
votes
10answers
3k views

Clarify the Single Responsibility Principle

The Single Responsibility Principle states that a class should do one and only one thing. Some cases are pretty clear cut. Others, though, are difficult because what looks like "one thing" when ...
6
votes
4answers
363 views

Are the technologies used in an application part of the architecture, or do they represent implementation/detailed design details?

When designing and writing documentation for a project an architecture needs to be clearly defined: what are the high-level modules of the system, what are their responsibilities, how do they ...
13
votes
5answers
830 views

What happened to Alan Cooper's Unified File Model?

For a long time Alan Cooper (in the 3 versions of his book "About Face") has been promoting a "unified file model" to, among other things, dispense with what he calls the most idiotic message box ever ...
5
votes
2answers
396 views

Does increasing the number of classes increase code complexity? [duplicate]

To illustrate the question, let's say we have two programmers of comparable skill that both solve the same problem. The code they turn out has roughly the same lines of code, but one programmer uses 5 ...
1
vote
5answers
1k views

Decoupling Components - Design

I have created a a number of non-trivial scripts in Python that do some long running reporting. At first these reports started off as scripts with a config file. Then I added in the a database ...
4
votes
4answers
481 views

Law of Demeter causing subclassing indecision and conflict with Single Responsibility

This is my situation: I have a class called CueList, which is basically a wrapper around ArrayList. I have another class called TimeTicker that alerts all the Tickable (interface) in its list that a ...
2
votes
1answer
740 views

Is there a factory pattern to prevent multiple instances for same object (instance that is Equal) good design?

I have a number of objects storing state. There are essentially two types of fields. The ones that uniquely define what the object is (what node, what edge etc), and the others that store state ...
1
vote
3answers
701 views

Monitoring App: Client side or Server Side?

I have a monitoring web application which has a .Net Backend and a Silverlight frontend. The application crunchs big chunks of data, process them and presentates to user. Then user can interact with ...
2
votes
2answers
335 views

How to structure a class in python

I have come to python from C++ (I also know a little Java). I am writing code to exercise a server so I basically use http methods to send a load of requests to the server. As part of my code I ...
3
votes
4answers
855 views

How to practice ATDD if design is not yet emerged from TDD?

Despite being very stakeholders friendly, ATDD aimed to provide a "stop" line when a feature has just been done. This avoids wasting time to add non-focused (and sometimes useless) code. That's why ...
0
votes
1answer
323 views

Version-control friendly, append-only file format: “binary” or “text”?

I'm designing an append-only ("journaled") file format, and I'd like it to be friendly towards being stored in VCS (git/Mercurial/...). On one hand, I'd like if after each change, only delta ...
2
votes
1answer
698 views

Modern practices for stored procedure-based applications

I work in a fairly large and old solution that has many entry points for different kinds of clients, with web sites for public access, web sites for internal access, some web sites and web services ...
6
votes
3answers
573 views

Where to load and store settings from a file?

I think this question should apply to most programs that load settings from a file. My question is from a programming point of view, and it is really how to deal with the loading of settings from a ...
1
vote
1answer
186 views

Component design: getting cohesion right

I currently have a set of components named DataValues, ValueParsers, ValueFormatters and ValueValidators. The first one defines an abstract base class DataValue and contains a whole load of ...
2
votes
1answer
287 views

TDD / one test representing the whole scenario ? or should I split it? [duplicate]

While practicing TDD, I came across this specification: A user should be created with its password hashed, be persisted and an activation token should be returned. Should my first unit test, (aiming ...
1
vote
1answer
900 views
-1
votes
1answer
516 views

Compile and run submissions of online judge in the same or separate server?

I am going to make an online judge platform. I have looked for some online judge platforms on the Internet for reference (I mean the platforms which have the source code available, and can be hosted ...
1
vote
1answer
265 views

Do Flexibility and Inconsistency,Unsafety Overlap?

I was lately doing some research about different programming languages. I was interested particularly to learn unique features of popular programming languages and situations where these assets shine. ...
4
votes
1answer
1k views

Mixing Fowlers Transaction Script and Domain Model

I am developing a large application where the previous developer used Martin Fowlers Transaction Script pattern. The requirements are becoming more complex and it is becoming a bit of a maintenance ...
7
votes
3answers
1k views

Using a Directory Service instead of a Database

I've just started working on an existing application that uses an LDAP directory service as its object store instead of a database. Many of my coworkers have been commenting how an application should ...
1
vote
4answers
268 views

Provide both RESTful interfaces and Java ones?

I am writing a RESTful service in Java, of course it's typical HTTP based interface. I am wondering should the service provide Java interface which has same semantic to the RESTful interface? I think ...
2
votes
2answers
385 views

Event based logging. Is it a good idea and is it ok to pass a handle to a “logged” object?

Hi I have fairly complex program that is doing computations in a quite large loop. I want to log some basic statistic about the run to be able to analyze its performance over time and vs loop number. ...
5
votes
1answer
6k views

What is the general format of a Software Design Specification?

I'm trying to document a piece of software I wrote in detail. An SAS is too high level and doesn't cover the API. I found several examples of an SDS online, but I don't see a trend in their format. ...