Tag Archives: design pattern

How to divide your GUI from your processing code?

Many students don’t know how to organize their code. Abstractions and Interfaces makes a difference when developing Java applications. What if your code was divided? For instance, if you have created a network application with a GUI (Graphical User Interface). The first approach is to put the code all together because it’s easier from the beginning. That’s wrong because it’s harder to find an error and you have to read a lot of garbage code like textBox.setValue

Posted in Software Development | Also tagged , , , | Leave a comment

Singleton Design Pattern problems?

The Singleton Pattern ensures a class has only one instance that provides a global point to access it. This design pattern is perfect for maintaining a set of configurations or other variables always available at run-time in your software. public static Singleton getInstance() { if (uniqueInstance == null) { uniqueInstance = new Singleton(); } return [...]

Posted in Software Development | Also tagged , , , | Leave a comment