OOP Examples

Exam 1

#define Macros vs. Inline
Directives
New And Delete
Function Templates
Char Pointers
Constructors
Namespacing
Dog in C++ C# and Java

Conversion Constructor
Conversion Constructor 2
Command Line Arguments
Returning A Reference
Static Variable in a function
Static Data Members
Assignment by Default Memberwise Copy
Order of construction (Global, Function Level and Static Objects)
Order of construction (Composite Classes)
string data-type example
const non-member variables, const member functions, const parameters
Friend Function
Friend Class
Using "this" to be more specific
Returning "this"
Copy Constructor Tip
const_cast

Exam 2

Operator Overloading #1
Operator Overloading #2
Operator Overloading #3 Rational Example
Operator Overloading #4 operator() the funtion operator
Operator Overloading With Enums
String Stream Extraction (When you do not know the string length)
String Stream Extraction (When you do not know the string length) method 2
Inhertiance
Multiple Inheritance
The Penguin can not fly problem
Order of construction (Inheritance / Composite Classes)
Function Pointer Example
Polymorphism
Dynamic And Static Binding
Virtual Inheritance
Template Functions
Template (Sorted List)
Templates With Friends
Templates With Inheritance

Exam 3 C++

Exception Handling
Streaming (Geting input of any data type)
RTTI (Run Time Type Information) Introduction
RTTI (Run Time Type Information) With Inheritance
STL_Example.CPP
Vector_Deque.cpp

Exam 3 Design Patterns

Singleton Design Pattern
Class Factory

Exam 3 Java

Java If Example
Java For Example
Java While Example
Java Switch Example
Java Array Example
Java Compiling a java file from a java program
Java IDE with (Frames, scroll bars, buttons, text areas)
Java CircleExample.java
Java MouseExample.java
Java PanelExample.java

Java PrintExample.java
Cursor.java
Java Singleton.java
Java SingletonTest.java
DumpClass.java
Packages
SuperHero.java (Object Serialization)

Exam 3 C#

Playing A Sound file in C#
Declaring a 1D Array in C# & (Looping with GetUpperBound and foreach)
Declaring a 2D Array in C# & (Random Numbers)
Property Get/Set in C#
Const and Readonly in C#
C# Inheritance with a function declared "new" in the derived class
C# Inheritance with a function declared "override" in the derived class and virtual in the base class
C# Inheritance with a function declared "override" in the derived class and abstract in the base class
C# Interface
Set.zip (Set in C#)

Miscellaneous

Playing a .wav file from a C++ console app.
C# Sending an e-mail message
C# Database Example