25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
* This is the only exception that is not an OFException as it's special.
* It does not know for which class allocation failed and it should not be
* handled like other exceptions, as the exception handling code is not
* allowed to allocate ANY memory.
*/
@interface OFAllocFailedException: OFObject
/**
* \return An error message for the exception as a string
*/
- (OFString*)string;
@end
/**
* \brief The base class for all exceptions in ObjFW
*
* The OFException class is the base class for all exceptions in ObjFW, except
* the OFAllocFailedException.
*
* IMPORTANT: Exceptions do NOT use OFAutoreleasePools and can't be autoreleased
* either! You have to make sure to dealloc the exception in your \@catch block!
*/
@interface OFException: OFObject
{
Class inClass;
OFString *string;
}
#ifdef OF_HAVE_PROPERTIES
@property (readonly, nonatomic) Class inClass;
#endif
/**
|
|
|
|
|
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
* This is the only exception that is not an OFException as it's special.
* It does not know for which class allocation failed and it should not be
* handled like other exceptions, as the exception handling code is not
* allowed to allocate ANY memory.
*/
@interface OFAllocFailedException: OFObject
/**
* \return A description of the exception
*/
- (OFString*)description;
@end
/**
* \brief The base class for all exceptions in ObjFW
*
* The OFException class is the base class for all exceptions in ObjFW, except
* the OFAllocFailedException.
*
* IMPORTANT: Exceptions do NOT use OFAutoreleasePools and can't be autoreleased
* either! You have to make sure to dealloc the exception in your \@catch block!
*/
@interface OFException: OFObject
{
Class inClass;
OFString *description;
}
#ifdef OF_HAVE_PROPERTIES
@property (readonly, nonatomic) Class inClass;
#endif
/**
|
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
/**
* \return The class of the object in which the exception happened
*/
- (Class)inClass;
/**
* \return An error message for the exception as a string
*/
- (OFString*)string;
@end
/**
* \brief An exception indicating there is not enough memory available.
*/
@interface OFOutOfMemoryException: OFException
{
|
|
|
|
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
/**
* \return The class of the object in which the exception happened
*/
- (Class)inClass;
/**
* \return A description of the exception
*/
- (OFString*)description;
@end
/**
* \brief An exception indicating there is not enough memory available.
*/
@interface OFOutOfMemoryException: OFException
{
|