|Oracle C++ Call Interface Programmer's Guide
Release 2 (9.2)
Part Number A96583-01
OCCI Classes and Methods, 12 of 22
Map class is used to store the mapping of the SQL structured type to C++ classes.
For each user defined type, the Object Type Translator (OTT) generates a C++ class declaration and implements the static methods
readSQL() method is called when the object from the server appears in the application as a C++ class instance. The
writeSQL() method is called to marshal the object in the application cache to server data when it is being written / flushed to the server. The
writeSQL() methods generated by OTT are based upon the OCCI standard C++ mappings.
If you want to override the standard OTT generated mappings with customized mappings, you must implement a custom C++ class along with the
writeSQL() methods for each SQL structured type you need to customize. In addition, you must add an entry for each such class into the
Map member of the
To..., use the syntax:
Adds a map entry for the type to be customized.
This method adds a map entry for the type to be customized.
This method adds a map entry for the type, type_name, that you want to customize. You must implement the type_name C++ class along with its static methods,
You must then add this information into a map object, which should be registered with the connection if the user wants the standard mappings to overridden.This registration can be done by calling the this method after the environment is created passing the environment.