Comment Programming - Practical Uses

Practical Uses

This programming process can be used for prototyping a new design pattern. This is done by creating a new structure of classes without any implementation, and then you can add the implementation later.

Pseudocode Example:

function onClick { // This is where we handle mouse click. // The result of this function is that a button will be highlighted. }

As you can see in the example, there is a structure around a click event handler. However, comment programming is used instead of a real implementation. The idea is that many functions can be written like this, and then the design can be reworked and revisited without having to refactor a lot of source code.

Read more about this topic:  Comment Programming

Famous quotes containing the word practical:

    Despair, feeding, as it always does, on phantasmagoria, is imperturbably leading literature to the rejection, en masse, of all divine and social laws, towards practical and theoretical evil.
    Isidore Ducasse, Comte de LautrĂ©amont (1846–1870)

    The question of armaments, whether on land or sea, is the most immediately and intensely practical question connected with the future fortunes of nations and of mankind.
    Woodrow Wilson (1856–1924)