LCOV - code coverage report
Current view: top level - chart2/source/tools - DataSource.cxx (source / functions) Hit Total Coverage
Test: commit 0e63ca4fde4e446f346e35849c756a30ca294aab Lines: 20 20 100.0 %
Date: 2014-04-11 Functions: 10 13 76.9 %
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 "DataSource.hxx"
      21             : #include "LabeledDataSequence.hxx"
      22             : 
      23             : using ::osl::MutexGuard;
      24             : using ::com::sun::star::uno::Sequence;
      25             : using ::com::sun::star::uno::Reference;
      26             : using ::com::sun::star::uno::RuntimeException;
      27             : using ::com::sun::star::uno::Any;
      28             : 
      29             : using namespace ::com::sun::star;
      30             : 
      31             : namespace
      32             : {
      33          16 : static const OUString lcl_aServiceName( "com.sun.star.comp.chart.DataSource" );
      34             : }  // anonymous namespace
      35             : 
      36             : namespace chart
      37             : {
      38             : 
      39         539 : DataSource::DataSource(
      40         539 :     const Reference< uno::XComponentContext > & /*xContext*/ )
      41         539 : {}
      42             : 
      43        6763 : DataSource::DataSource(
      44             :     const Sequence< Reference< chart2::data::XLabeledDataSequence > > & rSequences ) :
      45        6763 :         m_aDataSeq( rSequences )
      46        6763 : {}
      47             : 
      48       14604 : DataSource::~DataSource()
      49       14604 : {}
      50             : 
      51             : // ____ XDataSource ____
      52        7227 : Sequence< Reference< chart2::data::XLabeledDataSequence > > SAL_CALL DataSource::getDataSequences()
      53             :     throw (uno::RuntimeException, std::exception)
      54             : {
      55        7227 :     return m_aDataSeq;
      56             : }
      57             : 
      58             : // ____ XDataSink ____
      59         539 : void SAL_CALL DataSource::setData( const Sequence< Reference< chart2::data::XLabeledDataSequence > >& aData )
      60             :     throw (uno::RuntimeException, std::exception)
      61             : {
      62         539 :     m_aDataSeq = aData;
      63         539 : }
      64             : 
      65           7 : Sequence< OUString > DataSource::getSupportedServiceNames_Static()
      66             : {
      67           7 :     Sequence< OUString > aServices( 1 );
      68           7 :     aServices[ 0 ] = "com.sun.star.chart2.data.DataSource";
      69           7 :     return aServices;
      70             : }
      71             : 
      72          43 : APPHELPER_XSERVICEINFO_IMPL( DataSource, lcl_aServiceName );
      73             : 
      74          48 : } // namespace chart
      75             : 
      76             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10