aboutsummaryrefslogtreecommitdiff
path: root/odb/oracle/oracle-types.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-11-30 08:57:37 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-11-30 08:57:37 +0200
commit3ed6a781cf4aad7986f805dc8a8e5c487d10a805 (patch)
tree1aa8eb896bcad843b3a3428059af200784f0f452 /odb/oracle/oracle-types.hxx
parente7ff893718d5ba3759d1c10d8ba82b611ee78b11 (diff)
Merge LOB callback function and context into struct
This allows us to have one less member in the bind struct.
Diffstat (limited to 'odb/oracle/oracle-types.hxx')
-rw-r--r--odb/oracle/oracle-types.hxx26
1 files changed, 12 insertions, 14 deletions
diff --git a/odb/oracle/oracle-types.hxx b/odb/oracle/oracle-types.hxx
index 4b58c08..bd62fe1 100644
--- a/odb/oracle/oracle-types.hxx
+++ b/odb/oracle/oracle-types.hxx
@@ -60,16 +60,19 @@ namespace odb
ub4 size, // [in] The result data size in bytes.
chunk_position); // [in] The position of this chunk.
- union lob_callback
+ struct lob_callback
{
- param_callback_type param;
- result_callback_type result;
- };
+ union
+ {
+ param_callback_type param;
+ result_callback_type result;
+ } callback;
- union lob_context
- {
- const void* param;
- void* result;
+ union
+ {
+ const void* param;
+ void* result;
+ } context;
};
struct bind
@@ -112,15 +115,10 @@ namespace odb
// bindings, this is interpreted as the OCIDefine
// handle associated with the LOB result parameter.
ub4 capacity; // The maximum number of bytes that can be stored in
- // buffer.
+ // the buffer.
sb2* indicator; // Pointer to an OCI indicator variable.
lob_callback* callback;
-
- // This pointer is provided to the user through the context argument
- // in both parameter and result callback functions.
- //
- lob_context* context;
};
// An instance of this structure specifies the function to invoke and