Main Page
Related Pages
+
Namespaces
Namespace List
+
Namespace Members
+
All
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
z
+
Variables
a
b
c
d
e
f
g
i
l
n
o
p
r
s
t
u
v
x
y
+
Typedefs
a
b
c
d
e
f
g
h
i
j
m
o
r
s
t
v
w
Enumerations
+
Enumerator
_
a
b
c
f
g
i
l
m
n
o
p
r
s
t
u
+
Classes
Class List
Class Hierarchy
+
Class Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
~
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
a
b
c
e
i
j
l
m
n
o
p
r
s
t
u
v
Enumerations
+
Enumerator
a
c
d
e
f
h
i
l
m
n
p
r
s
t
v
+
Related Functions
a
b
c
d
e
f
i
j
l
m
o
p
s
t
u
v
w
+
Files
File List
+
File Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
b
c
d
e
f
g
h
i
j
k
l
m
o
p
r
s
t
u
v
w
y
z
Enumerations
+
Enumerator
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
x
y
z
+
Macros
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
z
hrplib
hrpUtil
Referenced.h
Go to the documentation of this file.
1
5
#ifndef OPENHRP_UTIL_REFERENCED_H_INCLUDED
6
#define OPENHRP_UTIL_REFERENCED_H_INCLUDED
7
8
#include <boost/intrusive_ptr.hpp>
9
10
namespace
hrp
{
11
class
Referenced;
12
void
intrusive_ptr_add_ref
(Referenced*
obj
);
13
void
intrusive_ptr_release
(Referenced*
obj
);
14
15
class
Referenced
16
{
17
public
:
18
Referenced
() {
refCounter_
= 0; }
19
virtual
~Referenced
() { }
20
21
protected
:
22
int
refCounter
() {
return
refCounter_
; }
23
24
private
:
25
friend
void
intrusive_ptr_add_ref
(
Referenced
*
obj
);
26
friend
void
intrusive_ptr_release
(
Referenced
* obj);
27
28
int
refCounter_
;
29
};
30
31
inline
void
intrusive_ptr_add_ref
(
hrp::Referenced
*
obj
){
32
obj->
refCounter_
++;
33
}
34
35
inline
void
intrusive_ptr_release
(
hrp::Referenced
*
obj
){
36
obj->
refCounter_
--;
37
if
(obj->
refCounter_
== 0){
38
delete
obj
;
39
}
40
}
41
};
42
43
#endif
hrp::intrusive_ptr_add_ref
void intrusive_ptr_add_ref(Referenced *obj)
Definition:
Referenced.h:31
hrp::intrusive_ptr_release
void intrusive_ptr_release(Referenced *obj)
Definition:
Referenced.h:35
hrp::Referenced::refCounter_
int refCounter_
Definition:
Referenced.h:28
hrp
Definition:
ColdetModel.h:28
hrp::Referenced::refCounter
int refCounter()
Definition:
Referenced.h:22
hrp::Referenced
Definition:
Referenced.h:15
hrp::Referenced::intrusive_ptr_release
friend void intrusive_ptr_release(Referenced *obj)
Definition:
Referenced.h:35
hrp::Referenced::intrusive_ptr_add_ref
friend void intrusive_ptr_add_ref(Referenced *obj)
Definition:
Referenced.h:31
viewSimTest.obj
obj
Definition:
viewSimTest.py:6
hrp::Referenced::Referenced
Referenced()
Definition:
Referenced.h:18
hrp::Referenced::~Referenced
virtual ~Referenced()
Definition:
Referenced.h:19
openhrp3
Author(s): AIST, General Robotix Inc., Nakamura Lab of Dept. of Mechano Informatics at University of Tokyo
autogenerated on Thu Sep 8 2022 02:24:05