diff options
author | Constantin Michael <constantin@codesynthesis.com> | 2011-09-26 08:36:55 +0200 |
---|---|---|
committer | Constantin Michael <constantin@codesynthesis.com> | 2011-09-26 11:04:09 +0200 |
commit | 927b42789bd3c3f108867bf067a89013a932cab3 (patch) | |
tree | bcd30812c3716aeb0fb91a8afe1208bd3f37dd15 /odb/oracle/details/number.hxx | |
parent | 385a45a47fdb47a890178b7b4604a37fc214a10e (diff) |
Reimplement Oracle NUMBER to/from C++ integer type conversions
The implementation has been moved to the details namespace. Signed and
unsigned 32 bit versions, as well as an unsigned 64 bit version have also
been added.
Diffstat (limited to 'odb/oracle/details/number.hxx')
-rw-r--r-- | odb/oracle/details/number.hxx | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/odb/oracle/details/number.hxx b/odb/oracle/details/number.hxx new file mode 100644 index 0000000..4f49643 --- /dev/null +++ b/odb/oracle/details/number.hxx @@ -0,0 +1,35 @@ +// file : odb/oracle/details/number.hxx +// author : Constantin Michael <constantin@codesynthesis.com> +// copyright : Copyright (c) 2005-2011 Code Synthesis Tools CC +// license : GNU GPL v2; see accompanying LICENSE file + +#ifndef ODB_ORACLE_NUMBER_HXX +#define ODB_ORACLE_NUMBER_HXX + +#include <odb/pre.hxx> +#include <odb/oracle/details/export.hxx> + +namespace odb +{ + namespace oracle + { + namespace details + { + LIBODB_ORACLE_EXPORT long long + number_to_int64 (const unsigned char* buffer); + + LIBODB_ORACLE_EXPORT void + int64_to_number (unsigned char* buffer, long long value); + + LIBODB_ORACLE_EXPORT unsigned long long + number_to_uint64 (const unsigned char* buffer); + + LIBODB_ORACLE_EXPORT void + uint64_to_number (unsigned char* buffer, unsigned long long value); + } + } +} + +#include <odb/post.hxx> + +#endif // ODB_ORACLE_NUMBER_HXX |