design

Entity Updating strategy

There is some discussion on my team about updating entity data and how best to approach it. This is a security framework and so here are some of the constraints and ideas. every table in DB has a PK that is a guid, this is required for our multi-node clustering solution. The idea is that we don't want to expose this on an entity to a ...

Avoid circular reference in domain model

Hi, this must be such a common scenario that there's been a lot written about it already, hopefully even a really good pattern. I have a domain model in which a custom container contains entities. For example (properties and interfaces excluded for brevity): class Entity { public int Id; public EntityContainer ParentContainer;...

When does it make sense to abandon MVVM?

As I've been learning WPF, I've been concentrating on applying only the MVVM pattern to applications. However, I notice that for some functionality such as validation, it is difficult or impossible to remain true to the MVVM model. Many times simply sticking an x:Name on an element and changing it in code-behind event-handler solves the...

How to write stories / scenarios in BDD ( Behavior Driven Design )

I am about to use BDD (Behavior Driven Design) for the first time and am trying to get used to this different way of approaching a problem. Can you give some stories / scenarios that you would write for say a simple login application using BDD? For example, from what I have read, it seems that: “When a user enters an invalid user...

Design strategies for class libraries that span Javascript and C#

I'm implementing some objects which will have about an equal amount of richness on both the client-side and server side. In this particular case, I'll be building a (hopefully) little class library to deal with search tokens. So as a pseudo-code example, I'll want to be able to do the equivalent of the following in both Javascript and ...

How does Robotreplay work? Can it be coded in php/javascript?

Hi, I'm looking to find out how robotreplay works. (Basically, it shows a movie of a visitor's mouse, and where he clicks when he enters a site) I don't know much about ajax, and I'm learning, and I'm trying to figure out if I can replicate what they are doing in a basic way. Would stuff like onmousemove or onscroll be useful? BTW, thi...

Rating architectural efficiency

How would you rate by numbers the efficiency of a certain design? What will be your variables? I can think of: Coupling Design Patterns use Language idioms use. Scalability. High-viability. Code Reuse. Flexibility. Robustness to errors. Testability. Design implications on resource use and memory. Portability. Usage of the correct pro...

Resources for learning C program design

Coming from a OO background (C#/java) I'm looking for resources to learn how to design pure C programs well. Whilst i'm familiar with the syntax of C, and i can write small programs, i'm unsure of the approach to take for larger applications, and what techniques to employ. Anything you guys can recommend. EDIT: I'm happy to completly...

Is UML still seen as a viable way of documenting a software design?

Is UML still seen as a viable way of a documenting a software design? Extra points for references that back up any claims :) ...

Rotting design and viscosity

Robert C. Martin in one of his book mention about viscosity as a symptom of rotting design. I don't fully understand idea of viscosity in software development. Could you give me some examples? ...

Refactoring away from the Shared Database pattern

At work, we have several applications with databases in a centralized SQL server. Whenever one application needs to work with data from another application, it just queries it or updates it through the database. I believe this is the “Shared Database” pattern as described in the Enterprise Integration Patterns book (Hohpe & Woolf). Th...

Unit Testing the Web GUI

Recently i heard a dicussion in which TDD was the hot buzz word. Now acc to one speaker that to test your behaviors you need to use MVC but on the other side its been said that TDD is an approach which can be adopted in any environment (as the discussion sorround between ASP.NET MVC or Webforms). The other guy claimed if you put your beh...

Do any .NET ORMs use constructors "properly"?

This is related conceptually to my question here. However, I've been playing around with NHibernate, and realized what the real core of my question is. In classic OO design, to properly encapsulate data, it's a common pattern to have values passed in to an object's constructor that are stored in data members (fields). Those values whic...

Lookup Structure for Error Messages

I need to translate result strings from a library into exceptions. Each string has a numeric result code, followed by a pipe char, and then additional, code specific data. I'm thinking of using a custom exception with a ResultCode property, and storing a lookup table of message strings keyed by result code, which I will format with an ...

Whats better using HTML/CSS edited by hand or using design programs? and why?

For design websites is it better to do it your self by learning HTML/CSS or using web design programs? and why? ...

Tips and Tricks for making beautiful designed views on the iPhone / Objective-C

What programming tips / tricks have you learned for styling views on the iPhone? As an example, you can set the background color of a view to an image: [myView setBackgroundColor:[UIColor colorWithPatternImage: [UIImage imageNamed:@"view-background.png"]]]; ...

How can I draw my database design?

I have mysql database and I want a software which can draw the database design for me? is there any way to do this? Thanks ...

Design questions about a plugginable Java framework

Hello, During the last 4 years, I was working on a project in my spare time having two goals : to improve myself as a software engineer and to build something which(I hoped) it will help me to build faster and better Java applications. I've always liked modular applications, so I though a plugginable framework wouldn't be bad to have. ...

How to partition a problem into smaller understandable portions?

I'm not sure if it's possible to give general advice on this topic, but please try. It's hard to explain my case because it's too complex to explain. And that's exactly the problem. I seem to constantly stumble on a situation where I try to design some part of my project, but it has so many things to take into consideration that I'm una...

Scale Out Application (Split User Data) - How to establish single point of login?

Hello Ladies & Gentlemen. I have to make an architectural decision for an application and would like to know the best way to achieve the following, hopefully without having to keep information duplicated or in multiple places. Scenario: Application instances with separated, autonomous parts of the entire user data are split across mu...