
[ Home | Syllabus | Progress
Map | Search | Help | Lectures | Glossary]
Glossary of Terms
- abstraction:
- define essential properties and behaviors while hiding the inessential
details.
-
- alternate constructor:
- A constructor with parameters
that is called when a newly created object has arguments. There
may be several alternate constructors which are resolved by function overloading rules.
-
- argument:
- actual data object which is passed to a function during a function
call. The value or reference to this
argument will be bound to the function parameter as appropriate.
-
- attribute:
- a property of an object. data whose value defines a characteristic of
the object.
-
- base class:
- a class from which another class inherits
data and functions forming an IS-A relationship between the classes
-
- binary function:
- A function which has two arguments, many binary functions use special operator symbols and infix notation
-
- call by reference:
- a method of passing arguments into a function which references that
argument allowing it to be modified (unless there is a const modifier). Sometimes used
with const modifier for reasons of efficiency (reference is basically a pointer and so
usually takes only 32 bits).
-
- call by value:
- a method of passing arguments into a function in which a copy is made
of the argument's value (state) and placed in the parameter (which acts like a local variable of the function). Changes to value parameters have no
effect on the value of the argument.
-
- class:
- A set of objects defined by common
attributes or properties (data members) and common behavior or operations (function
members). see terminology
-
- component:
- group of objects that work together
-
-
- composition relationship:
- See HasA relationship
-
- constructor:
- A class member function that is called whenever a new call object is
created. Default constructors have no parameters. Alternate (or
non-default) constructors can have parameters. There can be several constructors for a
given class.
-
- constructor-initializer:
- special syntax for invoking alternate constructors for data members of
a class. Needed since all data members are constructed BEFORE the containing class is
constructed. Allows arguments to be passed from the containing classes alternate
constructor to the data member alternate constructors. SYNTAX: ContainingClassConstructor(parameterList)
: dataMember(constructorArguments)
-
- data member:
- data variables in a class. also known as property or attribute.
-
- deep copy:
- when an object contains pointers, a deep copy will follow the pointers
and make a copy of all objects pointed at. For example. A deep copy of a linked list, will
copy every node in the list so that two identical but distinct lists exist.
-
- default constructor:
- A constructor for a class which has no
parameters and is called whenever a new object is created without arguments.
-
- derived class:
- A class which inherits data members and
functions from a base class forming an IS-A relationship with that
class.
-
- encapsulation:
- ability to hide information about the details of an abstraction and to
protect those details from unwarranted use. This means that the details could be changed
without changing the abstraction. The class and function are the primary
encapsulation mechanisms in C++.
-
- function prototype:
- Information for the compiler and user about how to use a function.
Gives function name, return type, a parameter list (number and type of arguments in order)
-
- has-a relationship:
- A relationship between classes in which one class has data member
which are from the other class. also known as a composition relationship
-
- header file:
- files containing class definitions, function prototypes, global data
and other information of general interest to a program.
-
- hierarchy:
- a relationship between modules where one module is the parent or
controller of another module. Inheritance (IS-A) relationships
between classes and calling/called relationships between functions are examples of
hierarchies.
-
- infix functions:
- a binary functions where the
function name appears in between the arguments of the function
Usually infix functions use special functions names called operators (e.g. +, -, *, /, << , >>)
-
- inheritance:
- Allows the definition of new classes from old classes where the new
class can reuse existing data and function members, modify them or add new members. (see also IS-A relationship)
-
- instance:
- A particular object in a class, usually associated with a variable
name. An instance has state which can be changed by the
modifiers of the class.
-
- implementation file:
- file containing member function defintions (i.e.
function bodies) usually associated with a header file.
-
- is-a relationship:
- An inheritance relationship between classes
whereby one class (derived class) is a specialization of another
class (called the base class)
-
- local variable:
- a variable whose visibility and lifetime are limited to the function
in which it is defined. Thus a local variable cannot be accessed outside the function and
only is allocated when the function is invoked (Called). (unless it has the
"static" modifier).
-
- member access operator:
- the single dot ('.') which is used to access both the data and
function members of an object. general syntax: objectID.MemberName
-
- member function:
- functions defined for a class. also known as the bahaviors of the
class, the methods of the class or the operations of the class.
-
- modularity:
- division of a program into units (modules) which have a well defined
interface. modules are building blocks for a program.
-
- non-default constructor:
- see alternate constructor
-
- objects:
- any thing, real or abstract about which we store data and those
methods (operations) that manipulate that data (Martin/Odell) see terminology
-
- object-oriented analysis:
- process of examining the application requirements to discover the
classes and object, their state, behaviors and relationships in the vocabulary of the
problem domain.
-
- object-oriented design:
- is a design method that breaks the problem into class and object
abstractions to logically structure the solution
-
-
- operator:
- Special functions names which are represented by special symbols (e.g.
+, -, *, /, << , >>, ++)
-
- overloading functions:
- results whenever the same function name is used for more than one
function. The compiler resolves which function should be called by examining the
function's signature: that is, the number and type of the parameters. When types differ
but are convertible (e.g. int to float), then a best match is made (see pages 75-77 for
details)
-
- parameter:
- place holder in a function definition into which the value
or reference to the actual function argument
(during a function call) will be bound (copied). This is a variable name that is local to the function body.
-
- polymorphism:
- Using the same name to denote objects of different (but related by inheritance) types
-
- post-condition:
- what must be try after a function executes. Usually applies to the
output data or data members of a class. With the pre-condition
forms a contract between the writer of a function and the user of that function.
-
- pre-condition:
- says what must be try before a function is executed. Usually places
restrictions on the values on the input parameters.
-
- prototype:
- see function prototype
-
- pseudocode:(a1)
- is structured English version of the program which uses English nouns
and verbs and C++ control structure syntax to express the way the program should work (the
algorithm)
-
-
- reference:
- see call by reference
-
- scope resolution operator:
- the double colon ("::") which is used to associate a member
function with its class. Needed to disambiguate function definitions for the compiler.
-
- shallow copy:
- when an object contains pointers, a shallow copy only makes a copy of
the pointers and not the objects pointed at. For example. A shallow copy of a linked list,
will copy only the head pointer, both the original and copied head pointers will point to
the same list.
-
- signature of a function:
- function name and the order and type of its parameters.
(NOTE: this information is contained in the function prototype).
-
- state (of object):
- the values of an objects attributes,
the properties of an object, the values of the object's data members
-
- strongly typed language:
- Language which requires that only compatible types are used in
expressions. Helps catch incorrect usage of variables.
-
- value:
- see call by value
Copyright chris wild 1998.
For problems or questions regarding this web contact [Dr.
Wild].
Last updated: October 14, 1998.