IMP
2.0.1
The Integrative Modeling Platform
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
doxygen_macros.h
Go to the documentation of this file.
1
/**
2
* \file IMP/base/doxygen_macros.h
3
* \brief Various general useful macros for IMP.
4
*
5
* Copyright 2007-2013 IMP Inventors. All rights reserved.
6
*
7
*/
8
9
#ifndef IMPBASE_DOXYGEN_MACROS_H
10
#define IMPBASE_DOXYGEN_MACROS_H
11
#include <IMP/base/base_config.h>
12
// for IMP_OVERRIDE
13
#include "
swig_macros.h
"
14
15
16
#ifdef IMP_DOXYGEN
17
//! Hide something from doxygen
18
/** */
19
#define IMP_NO_DOXYGEN(x)
20
//! Only show something to doxygen
21
/** */
22
#define IMP_ONLY_DOXYGEN(x) x IMP_REQUIRE_SEMICOLON_CLASS(only_doxy)
23
#define IMP_SWITCH_DOXYGEN(x,y) x
24
#else
25
#define IMP_NO_DOXYGEN(x) x
26
#define IMP_ONLY_DOXYGEN(x) IMP_REQUIRE_SEMICOLON_CLASS(only_doxy)
27
#define IMP_SWITCH_DOXYGEN(x,y) y
28
#endif
29
30
31
#ifdef IMP_DOXYGEN
32
/** Declare a method that implements a method that is pure virtual in the
33
base class.
34
*/
35
#define IMP_IMPLEMENT(signature)
36
/** Define a method inline that impements a pure virtual method.
37
*/
38
#define IMP_IMPLEMENT_INLINE(signature, body)
39
40
/** Define a method inline that impements a pure virtual method that
41
is hidden from swig.
42
*/
43
#define IMP_IMPLEMENT_INLINE_NO_SWIG(signature, body)
44
45
/** Define an implementation detail template method.
46
*/
47
#define IMP_IMPLEMENTATION_TEMPLATE_1(arg0, signature, body)
48
#define IMP_IMPLEMENTATION_TEMPLATE_2(arg0, arg1, signature, body)
49
#else
50
#define IMP_IMPLEMENT(signature) signature
51
52
#define IMP_IMPLEMENT_INLINE(signature, body) \
53
signature IMP_OVERRIDE { \
54
body; \
55
}
56
57
#ifndef SWIG
58
#define IMP_IMPLEMENT_INLINE_NO_SWIG(signature, body) \
59
signature IMP_OVERRIDE { \
60
body; \
61
}
62
#else
63
#define IMP_IMPLEMENT_INLINE_NO_SWIG(signature, body)
64
65
#endif
66
67
#define IMP_IMPLEMENTATION_TEMPLATE_1(arg0, signature, body)\
68
template <arg0> signature IMP_OVERRIDE {body}
69
70
#define IMP_IMPLEMENTATION_TEMPLATE_2(arg0, arg1, signature, body)\
71
template <arg0, arg1> signature IMP_OVERRIDE {body}
72
73
74
#endif
75
76
77
78
79
#endif
/* IMPBASE_DOXYGEN_MACROS_H */