 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
Determine
if any of the class operations should be
|
|
|
implemented
as overloaded operators: does an operator
|
|
|
exists
that performs behavior similar in nature to our
|
|
|
operations?
If so, consider overloading those operators. If
|
|
|
not,
use member functions.
|
|
| • |
Consider
what data types are allowed as operands, what
|
|
|
conversions
can be applied to the operands, whether or not
|
|
the
operands are modified by the operation that takes
|
|
|
place,
what data type is returned as the residual value, and
|
|
|
whether
the residual value is an rvalue (an object returned
|
|
|
by
value), a non-modifiable lvalue (a const reference to an
|
|
|
object),
or a modifiable lvalue (a reference to an object).
|
|