LCOV - code coverage report
Current view: top level - libreoffice/basegfx/source/tuple - b2ituple.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 8 33 24.2 %
Date: 2012-12-27 Functions: 2 8 25.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             : #include <basegfx/tuple/b2ituple.hxx>
      21             : #include <basegfx/tuple/b2dtuple.hxx>
      22             : #include <rtl/instance.hxx>
      23             : 
      24             : namespace { struct EmptyTuple : public rtl::Static<basegfx::B2ITuple, EmptyTuple> {}; }
      25             : 
      26             : namespace basegfx
      27             : {
      28             :     // external operators
      29             :     //////////////////////////////////////////////////////////////////////////
      30             : 
      31       61588 :     B2ITuple operator+(const B2ITuple& rTupA, const B2ITuple& rTupB)
      32             :     {
      33       61588 :         B2ITuple aSum(rTupA);
      34       61588 :         aSum += rTupB;
      35       61588 :         return aSum;
      36             :     }
      37             : 
      38       69382 :     B2ITuple operator-(const B2ITuple& rTupA, const B2ITuple& rTupB)
      39             :     {
      40       69382 :         B2ITuple aSub(rTupA);
      41       69382 :         aSub -= rTupB;
      42       69382 :         return aSub;
      43             :     }
      44             : 
      45           0 :     B2ITuple operator/(const B2ITuple& rTupA, const B2ITuple& rTupB)
      46             :     {
      47           0 :         B2ITuple aDiv(rTupA);
      48           0 :         aDiv /= rTupB;
      49           0 :         return aDiv;
      50             :     }
      51             : 
      52           0 :     B2ITuple operator*(const B2ITuple& rTupA, const B2ITuple& rTupB)
      53             :     {
      54           0 :         B2ITuple aMul(rTupA);
      55           0 :         aMul *= rTupB;
      56           0 :         return aMul;
      57             :     }
      58             : 
      59           0 :     B2ITuple operator*(const B2ITuple& rTup, sal_Int32 t)
      60             :     {
      61           0 :         B2ITuple aNew(rTup);
      62           0 :         aNew *= t;
      63           0 :         return aNew;
      64             :     }
      65             : 
      66           0 :     B2ITuple operator*(sal_Int32 t, const B2ITuple& rTup)
      67             :     {
      68           0 :         B2ITuple aNew(rTup);
      69           0 :         aNew *= t;
      70           0 :         return aNew;
      71             :     }
      72             : 
      73           0 :     B2ITuple operator/(const B2ITuple& rTup, sal_Int32 t)
      74             :     {
      75           0 :         B2ITuple aNew(rTup);
      76           0 :         aNew /= t;
      77           0 :         return aNew;
      78             :     }
      79             : 
      80           0 :     B2ITuple operator/(sal_Int32 t, const B2ITuple& rTup)
      81             :     {
      82           0 :         B2ITuple aNew(t, t);
      83           0 :         B2ITuple aTmp(rTup);
      84           0 :         aNew /= aTmp;
      85           0 :         return aNew;
      86             :     }
      87             : 
      88             : } // end of namespace basegfx
      89             : 
      90             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10