Main Page
Namespaces
Classes
Files
File List
File Members
libism
ISM
soci
src
core
prepare-temp-type.cpp
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
#define SOCI_SOURCE
9
#include "
prepare-temp-type.h
"
10
#include "
ref-counted-prepare-info.h
"
11
#include "
session.h
"
12
13
using namespace
soci
;
14
using namespace
soci::details
;
15
16
prepare_temp_type::prepare_temp_type
(
session
& s)
17
: rcpi_(new
ref_counted_prepare_info
(s))
18
{
19
// this is the beginning of new query
20
s.
get_query_stream
().str(
""
);
21
}
22
23
prepare_temp_type::prepare_temp_type
(
prepare_temp_type
const
& o)
24
:
rcpi_
(o.
rcpi_
)
25
{
26
rcpi_
->
inc_ref
();
27
}
28
29
prepare_temp_type
&
prepare_temp_type::operator=
(
prepare_temp_type
const
& o)
30
{
31
o.
rcpi_
->
inc_ref
();
32
rcpi_
->
dec_ref
();
33
rcpi_
= o.
rcpi_
;
34
35
return
*
this
;
36
}
37
38
prepare_temp_type::~prepare_temp_type
()
39
{
40
rcpi_
->
dec_ref
();
41
}
42
43
prepare_temp_type
&
prepare_temp_type::operator,
(
into_type_ptr
const
& i)
44
{
45
rcpi_
->
exchange
(i);
46
return
*
this
;
47
}
soci::details::prepare_temp_type::rcpi_
ref_counted_prepare_info * rcpi_
Definition:
prepare-temp-type.h:58
soci::details
Definition:
db2/common.h:15
session.h
soci::details::prepare_temp_type::prepare_temp_type
prepare_temp_type(session &)
Definition:
prepare-temp-type.cpp:16
soci::session::get_query_stream
std::ostringstream & get_query_stream()
Definition:
core/session.cpp:204
soci::details::prepare_temp_type
Definition:
prepare-temp-type.h:23
soci::details::ref_counted_statement_base::inc_ref
void inc_ref()
Definition:
ref-counted-statement.h:33
soci::details::prepare_temp_type::~prepare_temp_type
~prepare_temp_type()
Definition:
prepare-temp-type.cpp:38
ref-counted-prepare-info.h
soci::session
Definition:
session.h:40
prepare-temp-type.h
soci::details::ref_counted_statement_base::dec_ref
void dec_ref()
Definition:
ref-counted-statement.h:34
soci::details::ref_counted_prepare_info::exchange
void exchange(use_type_ptr const &u)
Definition:
ref-counted-prepare-info.h:40
soci::details::ref_counted_prepare_info
Definition:
ref-counted-prepare-info.h:32
soci::details::prepare_temp_type::operator=
prepare_temp_type & operator=(prepare_temp_type const &)
Definition:
prepare-temp-type.cpp:29
soci::details::type_ptr
Definition:
type-ptr.h:14
soci
Definition:
db2/common.h:15
soci::details::prepare_temp_type::operator,
prepare_temp_type & operator,(into_type_ptr const &i)
Definition:
prepare-temp-type.cpp:43
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:40