Friday, December 31, 2010

"Safe Mode" Programming

When you write software systems , at times  requirements can be fuzzy . Then , we will resort to some sort of plausibility analysis and can come up with software requirements which i would like to call as "Worst Possible Scenario approach" (WPS ).

The stakeholders of project can get worried and after some meeting , most often , some kind of cap on the requirement will be brought about. But, most systems will fall back to the Worst Possible Scenario mode.

How do programmers handle this ?

I call the WPS approach as SafeMode Programming . The code can be written as



if (GetSafeMode() ) {
     //Code Defensively...

}
else {
     // Code to satisfy customer requirements at this point of time….

}

0 comments: