Login | Register   
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


advertisement
Search the Tips
Tip Bank > Application Design > Design Patterns

Design Patterns - Page 3

41-60 of 79     Previous     Next
Methodological Unimplementation
by Ajit Sagar
Designing a class for an application involves identifying and defining its behavior and state. The behavior is defined in the form of methods that the class provides. Often, in the design process, ...
Use an Interface to Provide Classes with Constant Value(s)
by Brett Spell
If you have two or more classes that need to share some constant value(s), but you want the classes to be independent of each other, define the constant values in an interface. You can then implement ...
How Do I Christen This Class?
by Ajit Sagar
Good design goes hand in hand with the nomenclature it uses for exchanging that design between developers. A key feature to writing good code consists of good naming conventions and consistency to ...
Application Design and Passwords
by DevX Pro
How do you protect an application with a password and store it in the application's exe-file?
Function Wrappers - The First Step toward Gaining OO Advantages
by Danny Kalev
In large-scale projects different teams use API functions developed by another team or a third-party vendor. For example: ...
Garbage Collector in C++?
by Danny Kalev
A garbage collector is handy, since it eliminates a big source for bugs, runtime crashes and memory leaks. However, garbage collection is not for free; it incurs additional runtime overhead for ...
Three Flavors of Polymorphism
by Danny Kalev
Polymorphism is the ability of different objects to react in an individual manner to the same message. This notion was imported from natural languages. For example, the verb "to close" means ...
Components Help Team Based Development
by Joe Karbowski
Aside from fitting well with the Microsoft environment, creating components and component based software also works well with the management and tracking of development teams. Components naturally ...
Before You Resort to Void *...
by Danny Kalev
Void * can serve as a generic data pointer, yet it suffers from the well-known ailments associated with pointers: it can be NULL or a dangling pointer. Furthermore, it usually has to be cast back to ...
The 'resource acquisition is initialization' Idiom
by Danny Kalev
Many objects of various kinds share a similar characterization: they have to be acquired by means of initialization prior to their usage, then they can be used, and finally - they have to be released ...
Prefer Private Data Members to Protected Ones
by Danny Kalev
Data members of a class are usually a part of its implementation rather than its interface. They may be replaced when the internal implementation of the class is to be changed, and hence, they should ...
Returning Objects by Value
by Danny Kalev
For efficiency reasons, large objects should usually be passed to or returned from a function by reference or by their address (using a pointer). There are, however, a few circumstances in which the ...
A general base class - is it such a good idea?
by Danny Kalev
In many frameworks and software projects, all classes are enforced to be descendants of one common generic class, usually named Object. This design policy prevails in other OO language such as ...
When can an empty class be useful?
by Danny Kalev
A class containing no data members and no member functions is an empty class. It's defined like ...
Exceptions as objects
by Danny Kalev
The traditional convention of sending an integer as an error flag is problematic and unsatisfactory in OOP. The C++ exception handling mechanism can offer much more flexibility, safety and robustness.
To have or to hold?
by Danny Kalev
Ownership in its OO sense relates to the responsibility for the creation and the destruction of an object. An object (in its broader sense) is an owner of some other resource if and only if it has ...
Error Creating Window
by DevX Pro
In my Delphi 1.0 application, when I open a form (e.g. ClientForm.Show) I get an error message: "Error creating window." This error occurs when several forms (nine or ten forms that manage Paradox tables) were previously "showed" then "closed." An EOutofMemory exception is raised, but doing a MemAvail shows that 16 MB still remains in heap. I don't know what the problem is.
Parameter Passing
by DevX Pro
I am writing a program that needs to keep a running total of ID numbers allocated for this reason. The ID numbers are in an auto-increment field. I need a mechanism to keep a count of numbers assigned so that it may be incremented so that the next ID number can be displayed prior to the record being posted. Any ideas?
Constructors and destructors should be minimal
by Danny Kalev
When designing a class, you should remember that one day it may serve as a base class for other classes. When deriving a class from a base, the base's destructor and constructor(s) are implicitly ...
Templates in java
by DevX Pro
Any suggestions on a good way to implement templates in java?
41-60 of 79     Previous     Next
Sitemap