Blender
V5.0
source
blender
freestyle
intern
system
Exception.h
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2023 Blender Authors
2
*
3
* SPDX-License-Identifier: GPL-2.0-or-later */
4
5
#pragma once
6
11
12
#include "
MEM_guardedalloc.h
"
13
14
namespace
Freestyle
{
15
16
class
Exception
{
17
public
:
18
typedef
enum
{
19
NO_EXCEPTION
,
20
UNDEFINED
,
21
}
exception_type
;
22
23
static
int
getException
()
24
{
25
exception_type
e
= _exception;
26
_exception =
NO_EXCEPTION
;
27
return
e
;
28
}
29
30
static
int
raiseException
(
exception_type
exception =
UNDEFINED
)
31
{
32
_exception = exception;
33
return
_exception;
34
}
35
36
static
void
reset
()
37
{
38
_exception =
NO_EXCEPTION
;
39
}
40
41
private
:
42
static
exception_type
_exception;
43
44
MEM_CXX_CLASS_ALLOC_FUNCS(
"Freestyle:Exception"
)
45
};
46
47
}
/* namespace Freestyle */
MEM_guardedalloc.h
Read Guarded memory(de)allocation.
e
ATTR_WARN_UNUSED_RESULT const BMVert const BMEdge * e
Definition
bmesh_query_inline.hh:42
Freestyle::Exception
Definition
Exception.h:16
Freestyle::Exception::exception_type
exception_type
Definition
Exception.h:18
Freestyle::Exception::NO_EXCEPTION
@ NO_EXCEPTION
Definition
Exception.h:19
Freestyle::Exception::UNDEFINED
@ UNDEFINED
Definition
Exception.h:20
Freestyle::Exception::reset
static void reset()
Definition
Exception.h:36
Freestyle::Exception::getException
static int getException()
Definition
Exception.h:23
Freestyle::Exception::raiseException
static int raiseException(exception_type exception=UNDEFINED)
Definition
Exception.h:30
Freestyle
inherits from class Rep
Definition
AppCanvas.cpp:20
Generated on
for Blender by
doxygen
1.16.1