|
UDK 3.2.7 C/C++ API Reference
|
00001 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 00002 /* 00003 * This file is part of the LibreOffice project. 00004 * 00005 * This Source Code Form is subject to the terms of the Mozilla Public 00006 * License, v. 2.0. If a copy of the MPL was not distributed with this 00007 * file, You can obtain one at http://mozilla.org/MPL/2.0/. 00008 * 00009 * This file incorporates work covered by the following license notice: 00010 * 00011 * Licensed to the Apache Software Foundation (ASF) under one or more 00012 * contributor license agreements. See the NOTICE file distributed 00013 * with this work for additional information regarding copyright 00014 * ownership. The ASF licenses this file to you under the Apache 00015 * License, Version 2.0 (the "License"); you may not use this file 00016 * except in compliance with the License. You may obtain a copy of 00017 * the License at http://www.apache.org/licenses/LICENSE-2.0 . 00018 */ 00019 00020 #ifndef _OSL_MODULE_H_ 00021 #define _OSL_MODULE_H_ 00022 00023 #include "sal/config.h" 00024 00025 #include "rtl/tencinfo.h" 00026 #include "rtl/ustring.h" 00027 #include "sal/saldllapi.h" 00028 00029 #ifdef __cplusplus 00030 extern "C" { 00031 #endif 00032 00033 #ifdef SAL_DLLPREFIX 00034 #define SAL_MODULENAME(name) SAL_DLLPREFIX name SAL_DLLEXTENSION 00035 #else 00036 #define SAL_MODULENAME(name) name SAL_DLLEXTENSION 00037 #endif 00038 00039 #if defined(SAL_W32) 00040 #define SAL_MODULENAME_WITH_VERSION(name, version) name version SAL_DLLEXTENSION 00041 00042 #elif defined(SAL_UNX) 00043 #if defined(MACOSX) 00044 #define SAL_MODULENAME_WITH_VERSION(name, version) SAL_DLLPREFIX name ".dylib." version 00045 #else 00046 #define SAL_MODULENAME_WITH_VERSION(name, version) SAL_DLLPREFIX name SAL_DLLEXTENSION "." version 00047 #endif 00048 00049 #endif 00050 00051 #define SAL_LOADMODULE_DEFAULT 0x00000 00052 #define SAL_LOADMODULE_LAZY 0x00001 00053 #define SAL_LOADMODULE_NOW 0x00002 00054 #define SAL_LOADMODULE_GLOBAL 0x00100 00055 00056 typedef void* oslModule; 00057 00062 typedef void ( SAL_CALL *oslGenericFunction )( void ); 00063 00064 #ifndef DISABLE_DYNLOADING 00065 00071 SAL_DLLPUBLIC oslModule SAL_CALL osl_loadModule(rtl_uString *strModuleName, sal_Int32 nRtldMode); 00072 00079 SAL_DLLPUBLIC oslModule SAL_CALL osl_loadModuleAscii(const sal_Char *pModuleName, sal_Int32 nRtldMode); 00080 00098 SAL_DLLPUBLIC oslModule SAL_CALL osl_loadModuleRelative( 00099 oslGenericFunction baseModule, rtl_uString * relativePath, sal_Int32 mode); 00100 00119 SAL_DLLPUBLIC oslModule SAL_CALL osl_loadModuleRelativeAscii( 00120 oslGenericFunction baseModule, char const * relativePath, sal_Int32 mode); 00121 /* This function is guaranteed not to call into 00122 FullTextEncodingDataSingleton in sal/textenc/textenc.cxx, so can be used 00123 in its implementation without running into circles. */ 00124 00125 #endif 00126 00147 SAL_DLLPUBLIC sal_Bool SAL_CALL osl_getModuleHandle(rtl_uString *pModuleName, oslModule *pResult); 00148 00149 #ifndef DISABLE_DYNLOADING 00150 00153 SAL_DLLPUBLIC void SAL_CALL osl_unloadModule(oslModule Module); 00154 00155 #endif 00156 00160 SAL_DLLPUBLIC void* SAL_CALL osl_getSymbol( oslModule Module, rtl_uString *strSymbolName); 00161 00184 SAL_DLLPUBLIC oslGenericFunction SAL_CALL osl_getFunctionSymbol( 00185 oslModule Module, rtl_uString *ustrFunctionSymbolName ); 00186 00209 SAL_DLLPUBLIC oslGenericFunction SAL_CALL osl_getAsciiFunctionSymbol( 00210 oslModule Module, const sal_Char *pSymbol ); 00211 00212 00218 SAL_DLLPUBLIC sal_Bool SAL_CALL osl_getModuleURLFromAddress( 00219 void *pv, rtl_uString **pustrURL ); 00220 00242 SAL_DLLPUBLIC sal_Bool SAL_CALL osl_getModuleURLFromFunctionAddress( 00243 oslGenericFunction pf, rtl_uString **pustrFunctionURL ); 00244 00245 #ifdef __cplusplus 00246 } 00247 #endif 00248 00249 #endif /* _OSL_MODULE_H_ */ 00250 00251 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
1.7.3