design

Tips for avoiding second system syndrome

Lately I have seen our development team getting dangerously close to the 'second system syndrome' type ideas while we are planning the next version of our product. While I'm all for making improvements and undoing some of the mistakes of our past, I would hate to see us stuck in an endless loop of rewriting and never launching anything....

Silverlight and corporate designs

In the near future I want / will design an intranet application, which should be mainly based on Silverlight (version 4). There is the prerequisite, that this application should use he corporate design of my company. This corporate design is quite complex. Templates (HTML / Javascript) for that already exist, but there is no enforcement...

Design of a Bot class capable of returning Answer objects for all sorts of Question objects.

I'm trying to build a GraphBot class that can answer different questions about about an associated graph such as path length, shortest path between two vertices, number of paths passing through a given vertex etc. I'd like to be able to add new questions without changing any code inside the Bot, it is only responsible for receiving the ...

Options for handling a frequently changing data form

What are some possible designs to deal with frequently changing data forms? I have a basic CRUD web application where the main data entry form changes yearly. So each record should be tied to a specific version of the form. This requirement is kind of new, so the existing application was not built with this in mind. I'm looking for dif...

What can you do in the ant Task.init() method?

I'm developing a few custom ant tasks that all need to initialize the same objects. I wanted to initialize those object's in a common superclass that extends from Task, in the init() method. But I see from the lifecycle of an ant task that init() gets called before the tasks child elements and attributes are set. So all of the data I ...

Java GUI Design - "Wasted" Inheritance?

I am new to GUI design and am struggling a little to decide whether my intended use of inheritance is acceptable (I am familiar with the general concept of favouring composition). For example, if I have a GUI that will feature 3 JToolBars (two toolbars at the top and a status bar at the bottom) as I see it I have 2 obvious options: Si...

jquery UI tabs - drag & drop between tabs? design issue

so my company is finally going to rewrite some pages using jquery. They wanted some sort of a search panel, and when the user clicks on a search result (it could be a plan, a project, an invoice), the result details will open in a new tab. all is good. each search result can contain documents and they want to be able to drag a document ...

Design Question - OO food application

Say I have a number of usercontrols, each usercontrol inside a tabitem, inside a window. For example, let say this is a food collection application. Then we have tabs Fruit, Vegetables and Snacks. Each tab will show a list of food of that subject, and allow the user to add, delete, modify the food in each section. The food is stored in ...

Server-client app: how to check if client hasn't been silently disconnected because of a crash?

In my system clients register through web service on a server and then communicate by peer to peer communication only among clients, without server. When client signs out, he informs server that he's leaving. But if he signs out because of any crash or unexpected situation, server will not be informed. How do you normally handle such sit...

design pattern for food ordering app in silverlight 3.0

All, Are there any design patterns that I can use for an food ordering application? I intend to use silverlight 3.0 with .net, c# The concept of operations is as follows: application presents the menu (pictures and text) on the screen. patron selects what they want. For example, burger, fries and a coke. application will show the or...

Ordering the rows of a database table

I have a table feeds that contains a collection of code-description rows. e.g. Key | Value | Url fb | facebook | http://www.facebook.com tw | twitter | http://twitter.com ff | friendfeed | http://friendfeed.com A REST endpoint returns the contents of this table as a JSON array & it is displayed ...

Linq to Sql design and MVP

I'm experimenting with LinqToSql and the MVP pattern and having trouble setting on a good design. I'm using Asp.net 3.5 (not MVC) Here is a example public interface IMyBusinessCardView { string Field1 { get; set; } string Field2 { get; set; } string Field15 { get; set; } } public class MyBusinessCardPresenter { private...

My Account link in most e-commerce sites . reason to have one before log in ?

I am developing a new e-commerce website in java. My index page has links such as Login etc. I had gone through other e-commerce sites such as ebay where they have option of My Account. My question is before signing in to the account ,why do they need this link My Account. what is the significance of this. can any web designer let me kno...

Good books on designing applications making use of the Spring Framework?

Like the title suggests, I am looking for a good read on Java application design that leverages Spring. When I read different examples on the internet or the Spring official documentation, I had this feeling that every author out there presumes that you are good with patterns. Buzz words like DAO, Singleton and etc are used a lot. As an ...

OOP design problem

What is good design in this simple case: Let's say I have a base class Car with a method FillTank(Fuel fuel) where fuel is also a base class which have several leaf classes, diesel, ethanol etc. On my leaf car class DieselCar.FillTank(Fuel fuel) only a certain type of fuel is allowed (no surprises there:)). Now here is my concern, acco...

How to design this particular finite state machine?

Hey peeps, I am trying to get my head around how to design the following system, which I think can be defined as a finite state machine: Say we have a pile of 16 building blocks (towers, walls, gates) together forming a castle. The player can drag the blocks to 16 places on a floorplan and if done right they will see the whole castle....

unobtrusive javascript pain points to beware of

I have recently started learning unobtrusive JavaScript. Using JQuery its really fun. However with this thinking of writing JavaScript code has come a real long way from traditional ways. Also adding quick onclick="fun()" is helpful sometimes and as the application grows 100% unobtrusive code "sometimes" become difficult to write. Like ...

Best strategy to convert array output to an object?

I'm taking array output from a command-line program and parsing it into a PHP object. Consider this example of a very simple way to do this: $output = explode("\n", shell_exec(myProg)); $obj = new MyObject(); $offset_field1 = 0; $offset_field2 = 1; $obj->Field1 = $output[$offset_field1]; $obj->Field2 = $output[$offset_field2]; This ...

Design of classes

Hi Can anyone point me to a good resource for designing object-oriented classes from context diagrams? Thanks. ...

Simple JS slideshow that will work with N entries

I would like to create a simple javascript slideshow that allows a user to click 'Previous' or 'Next' and have the element slide in from the right or left depending. Content will be coming in from a CMS, so it's not 'hard-coded' persay. My markup would look like this ideally (where the most recent entry receives the 'show' class): <span...