VTK  9.0.1
vtkErrorCode.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkErrorCode.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
23 #ifndef vtkErrorCode_h
24 #define vtkErrorCode_h
25 #include "vtkCommonMiscModule.h" // For export macro
26 #include "vtkSystemIncludes.h"
27 
28 // The superclass that all commands should be subclasses of
29 class VTKCOMMONMISC_EXPORT vtkErrorCode
30 {
31 public:
32  static const char* GetStringFromErrorCode(unsigned long event);
33  static unsigned long GetErrorCodeFromString(const char* event);
34  static unsigned long GetLastSystemError();
35 
36  // all the currently defined error codes
37  // developers can use -- vtkErrorCode::UserError + int to
38  // specify their own errors.
39  // if this list is adjusted, be sure to adjust vtkErrorCodeErrorStrings
40  // in vtkErrorCode.cxx to match.
41  enum ErrorIds
42  {
43  NoError = 0,
44  FirstVTKErrorCode = 20000,
53  UserError = 40000
54  };
55 };
56 
57 #endif /* vtkErrorCode_h */
58 
59 // VTK-HeaderTest-Exclude: vtkErrorCode.h
vtkErrorCode::UnrecognizedFileTypeError
@ UnrecognizedFileTypeError
Definition: vtkErrorCode.h:47
vtkErrorCode::FileNotFoundError
@ FileNotFoundError
Definition: vtkErrorCode.h:45
vtkErrorCode
superclass for error codes
Definition: vtkErrorCode.h:29
vtkErrorCode::FileFormatError
@ FileFormatError
Definition: vtkErrorCode.h:49
vtkErrorCode::UnknownError
@ UnknownError
Definition: vtkErrorCode.h:52
vtkErrorCode::OutOfDiskSpaceError
@ OutOfDiskSpaceError
Definition: vtkErrorCode.h:51
vtkErrorCode::PrematureEndOfFileError
@ PrematureEndOfFileError
Definition: vtkErrorCode.h:48
vtkErrorCode::ErrorIds
ErrorIds
Definition: vtkErrorCode.h:41
vtkErrorCode::NoFileNameError
@ NoFileNameError
Definition: vtkErrorCode.h:50
vtkSystemIncludes.h
vtkErrorCode::CannotOpenFileError
@ CannotOpenFileError
Definition: vtkErrorCode.h:46