It's generally best practice to use named constants in place of magic numbers, but it sure is tedious and error prone keeping a database reference table and a file of named constants in sync. Is there some easy way to keep these two sources for this info in sync, or am I overlooking an obvious design enhancement?
In case my question isn...
Hi all,
I have a (design of) an application to basically work like this:
class Main, class BusinessLogic, class UserInterface
BusinessLogic and UserInterface are designed to be library-like - not on-goingly developed but used by a developer in say, class Main.
The constructor of BusinessLogic also instantiates UserInterface, which w...
What I'm looking for in this question are interface bits, eye candy, easter eggs, novel error messages or anything cool and interesting that you thought was particularly creative and that enhanced the user experience of an application. Feel free to brag on your own stuff!
I'm thinking if things like:
Creative 404 pages
The Digg 'Kevi...
Hi all,
I am currently writing a wrapper library in C# that wraps a COM object that has a very small and painful to use API and am having a bit of problem with clutter.
This is the first project that I have used TDD and mocking on, so sorry if this isn't really a big problem. I gave a copy of my library to one of my work mates and t...
My main area of interest in the world of programming is enhancing the user experience. I’m currently enrolled in a Information Science and Technology degree program and intend to tackle the Human-Computer Interaction focus my university offers through this major.
So to expand and actually ask a question; as a UX designer what programmin...
i'm building a 3 tier wpf application.
i heard that nhibernate is best for web applications.
i know how to use nhibernate.
should i use it or not??
are there any recommended or mappers that will be more suitable?
...
I always had doubts when it comes to designing proper report of execution.
Say you have the following (stupid, to be simple) case. I will use python.
def doStuff():
doStep1()
doStep2()
doStep3()
Now, suppose you want to give a report of the various steps, if something goes wrong etc. Not really debug: just informative beh...
A requirment has been given that the desktop icon change colors "to fit well" with the users chosen desktop color. Not only is that a vague requirement but it is not the standard way that applications behave. The correct solution is to provide a number of icons which the users can select from. I just think its a bad idea. We are in t...
Hi all.
I recently started to to learn Irricht 3D Engine, I already went through all the tutorials and I'm feeling ready to build a simple game upon it. So here is some background:
I have irricht , a 3D engine that is based upon the scene graph model . It knows how to load meshes & textures and show them , It provides me structured cl...
UML2 offers different kinds of diagrams.
Up to now I only used class diagrams.
What kind of UML diagrams do you use?
What kinds of diagrams do you recommend for design & documentation of a software project?
...
Is there any open source data modeler available? If yes, which is the best or closest to Rational Rose?
...
I know that the default answer is "it depends", but I want to know the feature list you are working from in developing a good application.
I'm particularly interested in features that need to be cared about at design time because adding them late will cost us a lot.
Please list one feature per answer so we can vote for the most importa...
In my experience, UI programming is very time consuming, expensive (designers, graphics, etc) and error prone - and by definition UI bugs or glitches are very visible embarasing.
What do you do to mitigate this problem?
Do you know of a solution that can automatically convert an API to a user interface (preferably a Web user interface?...
Hi, one of these days I came across one of those very long scrolling pages with several great jQuery samples: calendars, sliders, collpsible menus etc. I am googling like crazy to find it again but I haven't been successful, although there are lots of jQuery examples. This website I am talking about (ouch, I don't know its name) has the ...
In my domain, an Employee and a Department have a one-to-many bidirectional relationship; to let the child Employee synchronize this, I have an 'internal' access field for the Set (Iesi for NHibernate) of Employees that are in the Department, which would otherwise be readonly public. Like so:
Department class:
protected internal ISet<E...
Sometimes I find myself designing my classes for a certain project. I start with some entities, some interfaces, but after some time I think:
Hey what about creating a handler for the classes using a Factory Method, Strategy, Using Generics, etc, etc, etc.
At some point when I look to my classes I have a lot of generics, small objects,...
I would like to implement a heartbeat functionality in the server that would periodically alert window clients of its liveness. There are few ideas I am considering but would appreciate suggestions and examples/references
have a separate thread that would send a heartbeat to connected clients
have different types of heartbeat to ind...
The advantages of immutable objects in Java seem clear:
consistent state
automatic thread safety
simplicity
You can favour immutability by using private final fields and constructor injection.
But, what are the downsides to favouring immutable objects in Java?
i.e.
incompatibility with ORM or web presentation tools?
Inflexible de...
Hello,
Q1:
“The ListControl.OnSelectedIndexChanged method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.”
A) If I understand the above quote, then if we derive a class from ListControl, we should instead of subscribing to Sele...
I have a control in which we show some links to different sites based on some business rules. Currently all business logic to build link list is in control.
I plan to move out the busincess logic from the control.
what will be a good design for this?
can I use any design pattern?
...