All Frameworks Class Hierarchy This Framework Previous Next Indexes
ObjectModelerBase Interface CATIReporter
System.IUnknown
|
+---System.IDispatch
|
+---System.CATBaseUnknown
|
+---CATIReporter
Usage: an implementation of this interface is supplied and you must use it as is. You should not reimplement it.
interface CATIReporter
Interface offering mechanims to store errors informations.
Each information is a couple:
- a Name: this name is usually the name of the object which has raised the error.
- an Error: This error is created from a CATError given in parameters or information to construct this CATError.
This information is manipulated by the interface CATIReporterInfo.
Before stacking information in the reporter (with CreateInfo methods), user must call ResetReporterData to empty the reporter list.
At any time, it is possible to get the list of information stacked by calling GetListReporterInfo.
Method Index
- o
CreateInfo(CATIReporterInfo*&,CATUnicodeString&,CATError*)
- Adds an information from an existing error.
- o
CreateInfo(CATIReporterInfo*&,CATUnicodeString&,CATErrorId,char*,char*)
- Adds an information from an error identifier.
- o
GetListReporterInfo()
- Gets the list of stored error information.
- o
ResetReporterData()
- Resets all error informations.
Methods
o CreateInfo
-
Adds an information from an existing error.
Role: This method creates an information and stores it in an internal list. The error associated to the
information is given in parameter.
- Parameters:
-
- opiReporterInfo
- [out] An interface pointer on the error information. It must be released.
- iObjStr
- [in] The string associated with the created error information.
- iError
- [in] The error to report.
- Returns:
-
S_OK
, if everything ran well, otherwise E_FAIL
.
o CreateInfo
-
Adds an information from an error identifier.
Role: This method creates an information and stores it in an internal list. The error associated to the
information, is created by using the 3 last parameters.
- Parameters:
-
- opiReporterInfo
- [out] An interface pointer on the error information. It must be released.
If an error occurs, this returned value is NULL.
- iObjStr
- [in] The string associated with the created error information.
- iId
- [in] The Identifier of the error.
- iMsgId
- [in] The index name used to retrieve th error message in the NLS file.
- iMsgCatalog
- [in] The name of the NLS file containing error messages. This file contains errors identified by messages identifier.
If this parameter is not given, the error message is the parameter iMsgId.
- Returns:
-
S_OK
, if everything ran well, otherwise E_FAIL
.
o GetListReporterInfo
-
Gets the list of stored error information.
Role: The returned list contained all informations stacked from the last call of ResetReporterData.
Warning, if you use this method, do not forget to call ResetReporterData before creating your informations.
- Returns:
- The list of errors information stacked in this reporter.
o ResetReporterData
public virtual HRESULT ResetReporterData( | )= 0 |
-
Resets all error informations.
Role: This method empties all information stacked from the last call of this method.
- Returns:
-
S_OK
if everything ran ok, otherwise E_FAIL
.
This object is included in the file: CATIReporter.h
If needed, your Imakefile.mk should include the module: CATObjectModelerBase