Roguewaveライブラリを使用してC++からSybaseデータベースに接続しています。データベースオブジェクトが次のように構築されていることを理解しています。
RWDBManager::database("accessLib", "", "", "", "", "XA=lrm_name");
http://www2.roguewave.com/support/docs/sourcepro/edition8/html/dbxaug/5-3.htmlによると
All arguments are of type RWCString. Note that establishing an XA connection to the Sybase CT database requires only two of the six database() arguments, as described here:
accessLib
The argument for the first parameter is the same as that which you provide for the non-XA connection.
For static libraries, supply the string "SYBASE_CT".
For shared libraries, supply the name of your shared access library, for example "libctl420d.so".
理解できない:
コードでは、ライブラリで提供されているものを使用する必要がある場合、そのライブラリのヘッダーを含め、このライブラリのクラス/関数を使用し、プロジェクトのコンパイル中にLDLIBRARIESリストでこのライブラリを使用することに慣れています。ここの関数データベースにライブラリの名前が必要なのはなぜですか?#includeアプローチに対するこのアプローチの利点は何ですか。
それはいくつかの標準的な手法ですか?通常、これはどこで使用されますか?私は共有ライブラリを使用するプロジェクトに取り組んだことがあるので、リンクは静的に行われていませんでしたが、そのようなことはありませんでした。
ありがとう、