University of Sheffield   

    The Simons
    Component Library

Introduction   Class Hierarchy   Class Listing   Index of Classes   Index of Methods   Header Files  

MethodError Class Reference

#include <MethodError.h>

Inheritance diagram for MethodError:

Exception Object NoElements OutOfRange Undefined List of all members.

Detailed Description

MethodError: the abstract superclass of Method failures.

MethodError is not raised directly, but classifies those exceptions that signal the failure of a method, usually because they have been invoked with their preconditions violated. Subclasses of MethodError include Undefined, OutOfRange and NoElements. MethodError captures common information about the failed Object and the name of the failed method.


Public Member Functions

 MethodError ()
 Construct a default MethodError.

virtual ~MethodError ()
 Release an MethodError.

 MethodError (ObjectID, StringID, StringID)
 Construct an MethodError reporting failure of a method in an Object.

StringID method () const
 Access the name of the failed method.


Protected Member Functions

 MethodError (const MethodError &)
 Copy another MethodError.


Protected Attributes

StringID failedMethod
 The name of the failed Method.


Constructor & Destructor Documentation

MethodError::MethodError const MethodError &  exception  )  [protected]
 

Copy another MethodError.

Required by C++ to ensure that copying an MethodError faithfully copies an Exception.

Parameters:
exception - the MethodError to copy.
Returns:
an MethodError, a shallow copy.

MethodError::MethodError  ) 
 

Construct a default MethodError.

Returns:
an MethodError

MethodError::~MethodError  )  [virtual]
 

Release an MethodError.

MethodError::MethodError ObjectID  object,
StringID  method,
StringID  message
 

Construct an MethodError reporting failure of a method in an Object.

Used by subclasses to record common information about the failure.

Parameters:
object - the Object in which failure occurred.
method - the name of the method which failed.
message - an error message String.


Member Function Documentation

StringID MethodError::method  )  const [inline]
 

Access the name of the failed method.

Returns:
the name of a method.


Member Data Documentation

StringID MethodError::failedMethod [protected]
 

The name of the failed Method.


The documentation for this class was generated from the following files:
Generated on Fri May 5 17:17:18 2006 for The Simons Component Library by doxygen1.3