Posts

Showing posts from March, 2013

Data Flow Diagram (DFD)

The Data Flow Diagram ( DFD ) is a simple graphical notation that can be used to represent a system in terms of the input data to the system.  It is also known as " Bubble Chart ". The following are the basic element of DFD . External Entity An external entity can represent a human, system or subsystem. It is where certain data comes from or goes to. It is external to the system we study, in terms of the business process. For this reason, people use to draw external entities on the edge of a diagram . Process A process is a business activity or function where the manipulation and transformation of data takes place. A process can be decomposed to finer level of details, for representing how data is being processed within the process . Data Store A data store represents the storage of persistent data required and/or produced by the process. Here are some examples of data stores: membership forms, database table, etc. Data Flow A data flow represen...

Data Structure in C : Dangling References

If a heap variable is destroyed, any remaining pointer variable or object reference that still refers to it is said to contain a dangling reference. Unlike lower level languages such as C, dereferencing a dangling reference will not crash or corrupt your IDL session. It will, however, fail with an error message. For example: ;Create a new heap variable. A = PTR_NEW(23) ;Print A and the value of the heap variable A points to. PRINT, A, *A IDL prints:       23 For example: ;Destroy the heap variable. PTR_FREE, A ;Try to print again. PRINT, A, *A IDL prints: % Invalid pointer: A. % Execution halted at:  $MAIN$  There are several possible approaches to avoiding such errors. The best option is to structure your code  such that dangling references do not occur. You can, however, verify the validity of pointers or object references before using them (via the PTR_VALID or OBJ_VALID functions) or use the CATCH ...