LCOV - code coverage report
Current view: top level - libreoffice/sw/source/core/unocore - TextCursorHelper.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 8 8 100.0 %
Date: 2012-12-27 Functions: 2 2 100.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 "TextCursorHelper.hxx"
      22             : #include "unobaseclass.hxx"
      23             : #include <comphelper/servicehelper.hxx>
      24             : 
      25             : using namespace ::com::sun::star;
      26             : 
      27             : namespace
      28             : {
      29             :     class theOTextCursorHelperUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theOTextCursorHelperUnoTunnelId > {};
      30             : }
      31             : 
      32        8140 : const uno::Sequence< sal_Int8 > & OTextCursorHelper::getUnoTunnelId()
      33             : {
      34        8140 :     return theOTextCursorHelperUnoTunnelId::get().getSeq();
      35             : }
      36             : 
      37             : //XUnoTunnel
      38        4807 : sal_Int64 SAL_CALL OTextCursorHelper::getSomething(
      39             :     const uno::Sequence< sal_Int8 >& rId )
      40             :         throw(uno::RuntimeException)
      41             : {
      42        9614 :     if( rId.getLength() == 16
      43        4807 :         && 0 == memcmp( getUnoTunnelId().getConstArray(),
      44        9614 :                                         rId.getConstArray(), 16 ) )
      45             :         {
      46        1645 :             return sal::static_int_cast< sal_Int64 >( reinterpret_cast< sal_IntPtr >(this) );
      47             :         }
      48        3162 :     return 0;
      49             : }
      50             : 
      51             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10