Main Page
Namespaces
Classes
Files
File List
File Members
libism
ISM
soci
src
core
type-ptr.h
Go to the documentation of this file.
1
//
2
// Copyright (C) 2004-2008 Maciej Sobczak, Stephen Hutton
3
// Distributed under the Boost Software License, Version 1.0.
4
// (See accompanying file LICENSE_1_0.txt or copy at
5
// http://www.boost.org/LICENSE_1_0.txt)
6
//
7
8
#ifndef SOCI_TYPE_PTR_H_INCLUDED
9
#define SOCI_TYPE_PTR_H_INCLUDED
10
11
namespace
soci
{
namespace
details {
12
13
template
<
typename
T>
14
class
type_ptr
15
{
16
public
:
17
type_ptr
(T * p) :
p_
(p) {}
18
~type_ptr
() {
delete
p_
; }
19
20
T *
get
()
const
{
return
p_
; }
21
void
release
()
const
{
p_
= 0; }
22
23
private
:
24
mutable
T *
p_
;
25
};
26
27
}
// namespace details
28
}
// namespace soci
29
30
#endif // SOCI_TYPE_PTR_H_INCLUDED
soci::details::type_ptr::release
void release() const
Definition:
type-ptr.h:21
soci::details::type_ptr::~type_ptr
~type_ptr()
Definition:
type-ptr.h:18
soci::details::type_ptr::p_
T * p_
Definition:
type-ptr.h:24
soci::details::type_ptr::type_ptr
type_ptr(T *p)
Definition:
type-ptr.h:17
soci::details::type_ptr
Definition:
type-ptr.h:14
soci
Definition:
db2/common.h:15
asr_lib_ism
Author(s): Hanselmann Fabian, Heller Florian, Heizmann Heinrich, Kübler Marcel, Mehlhaus Jonas, Meißner Pascal, Qattan Mohamad, Reckling Reno, Stroh Daniel
autogenerated on Wed Jan 8 2020 04:02:41