LCOV - code coverage report
Current view: top level - usr/local/src/libreoffice/i18npool/source/textconversion - textconversion.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 22 0.0 %
Date: 2013-07-09 Functions: 0 9 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : 
      20             : 
      21             : #include <assert.h>
      22             : #include <textconversion.hxx>
      23             : 
      24             : using namespace com::sun::star::uno;
      25             : 
      26             : 
      27             : namespace com { namespace sun { namespace star { namespace i18n {
      28             : 
      29             : #ifndef DISABLE_DYNLOADING
      30             : 
      31           0 : extern "C" { static void SAL_CALL thisModule() {} }
      32             : 
      33             : #endif
      34             : 
      35           0 : TextConversion::TextConversion()
      36             : {
      37             : #ifndef DISABLE_DYNLOADING
      38             : #ifdef SAL_DLLPREFIX
      39           0 :     OUString lib(SAL_DLLPREFIX"textconv_dict" SAL_DLLEXTENSION);
      40             : #else
      41             :     OUString lib("textconv_dict" SAL_DLLEXTENSION);
      42             : #endif
      43             :     hModule = osl_loadModuleRelative(
      44           0 :         &thisModule, lib.pData, SAL_LOADMODULE_DEFAULT );
      45             : #endif
      46           0 : }
      47             : 
      48           0 : TextConversion::~TextConversion()
      49             : {
      50             : #ifndef DISABLE_DYNLOADING
      51           0 :     if (hModule) osl_unloadModule(hModule);
      52             : #endif
      53           0 : }
      54             : 
      55             : #ifndef DISABLE_DYNLOADING
      56             : 
      57           0 : static void* nullFunc()
      58             : {
      59           0 :     return NULL;
      60             : }
      61             : 
      62             : oslGenericFunction SAL_CALL
      63           0 : TextConversion::getFunctionBySymbol(const sal_Char* func)
      64             : {
      65           0 :     if (hModule)
      66           0 :         return osl_getFunctionSymbol(hModule, OUString::createFromAscii(func).pData);
      67             :     else
      68           0 :         return reinterpret_cast< oslGenericFunction >(nullFunc);
      69             : }
      70             : 
      71             : #endif
      72             : 
      73             : OUString SAL_CALL
      74           0 : TextConversion::getImplementationName() throw( RuntimeException )
      75             : {
      76           0 :     return OUString::createFromAscii(implementationName);
      77             : }
      78             : 
      79             : sal_Bool SAL_CALL
      80           0 : TextConversion::supportsService(const OUString& rServiceName) throw( RuntimeException )
      81             : {
      82           0 :     return rServiceName.equalsAscii(implementationName);
      83             : }
      84             : 
      85             : Sequence< OUString > SAL_CALL
      86           0 : TextConversion::getSupportedServiceNames() throw( RuntimeException )
      87             : {
      88           0 :     Sequence< OUString > aRet(1);
      89           0 :     aRet[0] = OUString::createFromAscii(implementationName);
      90           0 :     return aRet;
      91             : }
      92             : 
      93             : } } } }
      94             : 
      95             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10