good programming portal 01-13-2014d1942

2015-04-04

good programming portal 01-13-2014d1942

-good programming
-General concepts for good programming design
-good programming style
-clean code
-programming philosophy

General Concepts for Good Program Design

Coupling: the term coupling describes the interconnectedness of classes. We strive for loose coupling in a system - that is, a system where each class is largely independent and communicates with other classes via a small, well defined interface.

Cohesion: the expression cohesion describes how well a unit of code maps to a logical task or entity. In a highly cohesive system each unit of code (method, class, or module) is responsible for a well defined task or entity. Good class design exhibits a high degree of cohesion.

Code Duplication: code duplication (having the same segment of code in an application more than once is a sign of bad design. It should be avoided.

Encapsulation: proper encapsulation in classes reduces coupling, and thus leads to a better design.

Responsibility-Driven Design: Responsibility-driven design is the process of designing classes by assigning well-defined responsibilities to each class. This process can be used to determine which class should implement which part of an application function.

Localizing Change: one of the main goals of a good class design is that of localizing change: making changes to one class should have minimal effects on other classes.

Method Cohesion: a cohesive method is responsible for one and only one well-defined task.

Class Cohesion: a cohesive class represents one well-defined entity.

Refactoring: refactoring is the activity of restructuring an existing design to maintain a good class design when the application is modified or extended.

-text from Objects First with Java: A Practical Introduction using BlueJ
----http://www.slideshare.net/fielazurah/objects-first-with-java-a-practical-introduction-using-blue-j
--http://www.amazon.com/Objects-First-Java-Practical-Introduction/dp/0132492660/ref=sr_1_1?ie=UTF8&qid=1424042698&sr=8-1&keywords=Objects+First+with+Java%3A+A+Practical+Introduction+using+BlueJ
-same text here: "C:\Users\kurtw_000\Documents\kurt\storage\Documents\Programming\General Concepts for Good Program Design.wpd"

here's a video
http://www.youtube.com/watch?v=Qi6L9lfbyyQ



--------
See also
-How to apply common algorithms to any problem 07-12-2014d0745
-computer programming practice portal 04-04-2015d1740