00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef __TBB_runtime_loader_H
00022 #define __TBB_runtime_loader_H
00023
00024 #if ! TBB_PREVIEW_RUNTIME_LOADER
00025 #error Set TBB_PREVIEW_RUNTIME_LOADER to include runtime_loader.h
00026 #endif
00027
00028 #include "tbb/tbb_stddef.h"
00029 #include <climits>
00030
00031 #if _MSC_VER
00032 #if ! __TBB_NO_IMPLICIT_LINKAGE
00033 #ifdef _DEBUG
00034 #pragma comment( linker, "/nodefaultlib:tbb_debug.lib" )
00035 #pragma comment( linker, "/defaultlib:tbbproxy_debug.lib" )
00036 #else
00037 #pragma comment( linker, "/nodefaultlib:tbb.lib" )
00038 #pragma comment( linker, "/defaultlib:tbbproxy.lib" )
00039 #endif
00040 #endif
00041 #endif
00042
00043 namespace tbb {
00044
00045 namespace interface6 {
00046
00048
00085 class runtime_loader : tbb::internal::no_copy {
00086
00087 public:
00088
00090 enum error_mode {
00091 em_status,
00092 em_throw,
00093 em_abort
00094 };
00095
00097 enum error_code {
00098 ec_ok,
00099 ec_bad_call,
00100 ec_bad_arg,
00101 ec_bad_lib,
00102 ec_bad_ver,
00103 ec_no_lib
00104 };
00105
00107 runtime_loader( error_mode mode = em_abort );
00108
00110
00115 runtime_loader(
00116 char const * path[],
00117 int min_ver = TBB_INTERFACE_VERSION,
00118 int max_ver = INT_MAX,
00119 error_mode mode = em_abort
00120 );
00121
00123 ~runtime_loader();
00124
00126
00153 error_code
00154 load(
00155 char const * path[],
00156 int min_ver = TBB_INTERFACE_VERSION,
00157 int max_ver = INT_MAX
00158
00159 );
00160
00161
00163
00166 error_code status();
00167
00168 private:
00169
00170 error_mode const my_mode;
00171 error_code my_status;
00172 bool my_loaded;
00173
00174 };
00175
00176 }
00177
00178 using interface6::runtime_loader;
00179
00180 }
00181
00182 #endif
00183