Final
Exam Review
Identifying Classes
- Know how to apply the Abbott
& Booch Nouns approach for object identifiication.
- Understand how to eliminate
false objects.
Identifying Responsibilities &
Attributes
- Know how to apply the Lee
& Tepenhart approach to identify & eliminate (false)
attributes.
- Understand how to use the
Abbott & Booch Verbs approach for service identifiication. .
Class Design
Notations: (NO QUESTIONS per se, but you may have to draw or read
and interpret a
diagram)
C++ Classes
- Understand how to use and
implement class constructors and destructors.
- Be able to trace and understand
code employing C++ classes.
- Know when objects are created
and destroyed.
- Understand how limited scope
and access are achieved using const and parameter passing mechanisms in member
functions.
- Be able to over-load
constructors to achieve flexible object creation and initialization: default
arguments, explicit constructor invocation for initialization.
Object Communication &
Behavior
- Identify static and dynamic
behaviors.
- Be able to trace and understand
code that communicates with objects and using objects.
- Know when to apply the
different object communication mechanisms.
- Understand passing object
parameter mechanisms: by copy versus by identity.
Objects and Memory
- Know the different scopes and
lifetimes and how they apply to objects.
- Be able to identify automatic
and dynamic object instantiation.
- Understand how to dynamically
allocate and deallocate objects.
- Know the problems associated
with dynamic objects: aliases, memory leaks and dangling pointers.
Object Copies
- Identify shallow and deep
object copies.
- Understand how to solve the
shallow copy problem.
- Know when copy constructors and
assignment overload operator functions are automatically invoked.
Association (knows_a
relationships)
- Know how to create an
association - handles: pointers (and references).
- Be able to diagram (and
interpret) class association diagrams.
- Be able to label and implement
static / dynamic and uni- / bi- directional associations.
Aggregation (has_a
relationships)
- Know how to create an
aggregation: encapsulation, pointers.
- Be able to diagram (and
interpret) class aggregation diagrams.
- Understand lifetime
relationships between aggregated objects.
- Know how the execution of
aggregated constructors is performed: (class declaration).
- Be able to label and implement
static and dynamic aggregation.
Composition
- Know how to distinguish between
association and aggregation.
- Identify when association and
aggregation should be used.
- Be able to trace the
instrumentation of constructors/destructors in a composed class
relationship.
- Constructor execution:
inside-out.
- Destructor execution:
outside-in.
Exceptions
- Be able to trace the throwing
and catching of exceptions.
- Understand the affects of a
thrown exception on the execution stack.
- Know how execution continues
after a caught exception.
- Understand the purpose and
consequences of the catch all clause: catch (...) { }.
Inheritance and Polymorphism (is_a_kind_of
relationships)
- Know the terminology of
inheritance/polymorphism.
- Be able to diagram (and
interpret) class hierarchy inheritance/polymorphism diagrams.
- Understand the access
mechanisms between a base class and derived class through public inheritance.
- Know when
constructors/destructors in a inheritance class hierarchy class are
automatically executed.
- Be able to implement function
over-riding and function extension in a derived class.
- Know the difference and
implication of:
- Up-casting / widening (base
class <-- derived-class)
- Down-casting / narrowing
(derived class <-- base class)
- Understand how to use virtual
methods to setup dynamic binding.
- Be able to determine when
method invocation is due to static or dynamic binding.
- Both implicit (this
->) and explicit dynamic binding.
- Both static/dynamic virtual
function invocation.
- Know when and why destructors
should be virtual.
- Recognize abstract classes:
(pure virtual methods).
Operator Overloading
- Know how to work with binary/unary member / non-member operator overload
functions
- Understand when overloaded operators should return references (L-values)
or copies (R-values).
- Be able to define both prefix / postfix increment / decrement operators
- Know how the compiler determines which overloaded function to invoke
Conversions
- Understand how to define conversion constructors and conversion operators.
- Understand how the use of default parameter values in constructors may
create automatic conversions, whether intended or not.
Friend Functions and Operators
- Understand how to define friend function relationships
- Be able to declare stream functions as friends
- Understand when and why using the friend relationship is acceptable or
necessary.
Templates
- Know how to define and use Template classes
- Understand how template type parameters are substituted to
generate/instantiate classes
- Be able to create, use and trace execution of C++ code involving templates
- Identify implicit (operator overloads) assumptions in C++ template
code
S T L: NO QUESTIONS
Know the 5 components of organization of the STL: containers,
iterators, algorithms, adaptors, allocators
Be able to create, use and trace execution of C++ code involving
sequential access STL template classes: vector, deque, list
Associative containers, (set, multiset, map, multimap)
Adaptor, (stack, queue,
priority_queue) and allocator template classes
Templates & Inheritance:
- Nothing deep, but know that it is legal to derive a template from
another using inheritance.
Design Patterns: NO QUESTIONS