FbClient constructor
FbClient([
- String? fbLibPath
Opens the Firebird client dynamic library and retrieve the reference to fb_get_master_interface function.
Optionally, a path to the libfbclient dynamic library
can be provided in fbLibPath
. If omitted, a mechanism
default for the current OS will be used to resolve the
location of libfbclient.
Implementation
FbClient([String? fbLibPath]) {
fbLibPath ??= locateFbClient();
lib = DynamicLibrary.open(fbLibPath);
if (lib == null) {
throw FbClientException("Cannot open $fbLibPath");
}
_fbGetMasterInterface = lib!
.lookup<NativeFunction<FbInterface Function()>>(
"fb_get_master_interface")
.asFunction();
_iscVaxInteger = lib!
.lookup<NativeFunction<Long Function(Pointer<Uint8>, Short)>>(
"isc_vax_integer")
.asFunction();
}