core/blob.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 "blob.h"
10 #include "session.h"
11 
12 #include <cstddef>
13 
14 using namespace soci;
15 
17 {
19 }
20 
22 {
23  delete backEnd_;
24 }
25 
26 std::size_t blob::get_len()
27 {
28  return backEnd_->get_len();
29 }
30 
31 std::size_t blob::read(std::size_t offset, char *buf, std::size_t toRead)
32 {
33  return backEnd_->read(offset, buf, toRead);
34 }
35 
36 std::size_t blob::write(
37  std::size_t offset, char const * buf, std::size_t toWrite)
38 {
39  return backEnd_->write(offset, buf, toWrite);
40 }
41 
42 std::size_t blob::append(char const * buf, std::size_t toWrite)
43 {
44  return backEnd_->append(buf, toWrite);
45 }
46 
47 void blob::trim(std::size_t newLen)
48 {
49  backEnd_->trim(newLen);
50 }
virtual std::size_t read(std::size_t offset, char *buf, std::size_t toRead)=0
void trim(std::size_t newLen)
Definition: core/blob.cpp:47
std::size_t read(std::size_t offset, char *buf, std::size_t toRead)
Definition: core/blob.cpp:31
virtual void trim(std::size_t newLen)=0
blob(session &s)
Definition: core/blob.cpp:16
virtual std::size_t get_len()=0
details::blob_backend * backEnd_
Definition: blob.h:42
virtual std::size_t write(std::size_t offset, char const *buf, std::size_t toWrite)=0
virtual std::size_t append(char const *buf, std::size_t toWrite)=0
std::size_t append(char const *buf, std::size_t toWrite)
Definition: core/blob.cpp:42
details::blob_backend * make_blob_backend()
std::size_t get_len()
Definition: core/blob.cpp:26
std::size_t write(std::size_t offset, char const *buf, std::size_t toWrite)
Definition: core/blob.cpp:36


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