Monthly Archives: October 2016
When writing code for real systems we often need to build a state machine. That is, we write code that is based on a set of states and transitions. For instance, think about a stop light or even a virtual … Continue reading
The three main components of the Observer design pattern are: Subject, Observer and ConcreteObserver. The observer pattern is one of the commonly used patterns. You’ll find it not only used in your own code, but you’ll find it used in … Continue reading
The standard way of creating an object is to instantiate a concrete class directly with the new operator: SomeClass sc = new SomeClass(); One of the drawbacks of using the new operator to create an object is the need to … Continue reading
Don’t only practice your art, But force your way into its secrets, For it and knowledge can Raise men to the divine. — Ludwig Van Beethoven.
Afoot and light-hearted I take to the open road, Healthy, free, the world before me, The long brown path before me leading wherever I chose. Henceforth I ask not good-fortune, I myself am good-fortune, Henceforth I whimper no more, postpone … Continue reading
The goal of the simple factory idiom is to separate the process of creating concrete objects to reduce the dependency of the client from the concrete implementations. To implement the simple factory we need three things: A factory, the pizza … Continue reading
Context: Engineers look for routine solutions before resorting to original problem solving. Design is probably the most challenging activity in the software development life cycle. There is no algorithm for deriving abstract solution models from requirements. The best the discipline … Continue reading