-
Notifications
You must be signed in to change notification settings - Fork 16
/
ParamBuffer.h
53 lines (45 loc) · 1.19 KB
/
ParamBuffer.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#pragma once
#include <string>
#include <typeinfo>
#include "mysql.h"
#include "Binary.h"
#include "Julian.h"
namespace MySQLWrap {
class ParamBuffer {
public:
ParamBuffer(const enum_field_types type, my_bool isUnsigned);
ParamBuffer(const std::type_info &info);
ParamBuffer(const std::string &str, size_t maxSize);
ParamBuffer(const std::string &str);
ParamBuffer(const short int i);
ParamBuffer(const unsigned short int i);
ParamBuffer(const int i);
ParamBuffer(const unsigned int i);
ParamBuffer(const Julian &t);
ParamBuffer(const Binary &data);
ParamBuffer(const char ch);
ParamBuffer(const unsigned char ch);
ParamBuffer(const float f);
ParamBuffer(const double d);
ParamBuffer(const ParamBuffer ©);
~ParamBuffer();
void ResizeBlob(size_t newSize);
void *Buffer() const;
enum_field_types BufferType() const;
size_t BufferSize() const;
unsigned long *BufferLength();
my_bool *IsNull();
my_bool IsUnsigned();
my_bool *IsTruncated();
my_bool *Error();
private:
void *_buffer;
size_t _bufferSize;
unsigned long _bufferLength;
enum_field_types _type;
my_bool _isNull;
my_bool _isUnsigned;
my_bool _isTruncated;
my_bool _error;
};
}