From fc9cc0c5c8c5eb7be175ab4048ac09db20a32087 Mon Sep 17 00:00:00 2001 From: Vladimir Glazounov Date: Tue, 22 May 2007 17:15:18 +0000 Subject: INTEGRATION: CWS chart2mst3 (1.1.4); FILE ADDED 2005/10/11 09:20:32 bm 1.1.4.5: license header change 2005/06/20 14:36:08 bm 1.1.4.4: DataSource may be created via factory 2005/05/09 09:51:03 bm 1.1.4.3: moved parts of API to data namespace 2004/03/19 14:32:52 bm 1.1.4.2: XDataSource now contains XLabeledDataSources 2004/02/13 16:51:22 bm 1.1.4.1: join from changes on branch bm_post_chart01 --- chart2/source/inc/DataSource.hxx | 117 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 117 insertions(+) create mode 100644 chart2/source/inc/DataSource.hxx (limited to 'chart2/source/inc/DataSource.hxx') diff --git a/chart2/source/inc/DataSource.hxx b/chart2/source/inc/DataSource.hxx new file mode 100644 index 000000000000..4cd97a689f0e --- /dev/null +++ b/chart2/source/inc/DataSource.hxx @@ -0,0 +1,117 @@ +/************************************************************************* + * + * OpenOffice.org - a multi-platform office productivity suite + * + * $RCSfile: DataSource.hxx,v $ + * + * $Revision: 1.2 $ + * + * last change: $Author: vg $ $Date: 2007-05-22 18:15:18 $ + * + * The Contents of this file are made available subject to + * the terms of GNU Lesser General Public License Version 2.1. + * + * + * GNU Lesser General Public License Version 2.1 + * ============================================= + * Copyright 2005 by Sun Microsystems, Inc. + * 901 San Antonio Road, Palo Alto, CA 94303, USA + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License version 2.1, as published by the Free Software Foundation. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + * + ************************************************************************/ +#ifndef CHART2_DATASOURCE_HXX +#define CHART2_DATASOURCE_HXX + +#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_ +#include +#endif +#ifndef _COM_SUN_STAR_CHART2_DATA_XDATASOURCE_HPP_ +#include +#endif +#ifndef _COM_SUN_STAR_CHART2_DATA_XDATASINK_HPP_ +#include +#endif +#ifndef _COM_SUN_STAR_UNO_XCOMPONENTCONTEXT_HPP_ +#include +#endif + +#ifndef _CPPUHELPER_IMPLBASE3_HXX_ +#include +#endif +#ifndef _COMPHELPER_UNO3_HXX_ +#include +#endif +#ifndef _APPHELPER_SERVICEMACROS_HXX +#include "ServiceMacros.hxx" +#endif + +namespace chart +{ + +class DataSource : public + ::cppu::WeakImplHelper3< + ::com::sun::star::lang::XServiceInfo, + ::com::sun::star::chart2::data::XDataSource, + ::com::sun::star::chart2::data::XDataSink > +{ +public: + explicit DataSource( + const ::com::sun::star::uno::Reference< + ::com::sun::star::uno::XComponentContext > & xContext ); + explicit DataSource( + const ::com::sun::star::uno::Sequence< + ::com::sun::star::uno::Reference< + ::com::sun::star::chart2::data::XLabeledDataSequence > > & rSequences ); + explicit DataSource( + const ::com::sun::star::uno::Sequence< + ::com::sun::star::uno::Reference< + ::com::sun::star::chart2::data::XDataSequence > > & rSequences ); + explicit DataSource( + const ::com::sun::star::uno::Sequence< + ::com::sun::star::uno::Reference< + ::com::sun::star::chart2::data::XDataSequence > > & rSequences, + const ::com::sun::star::uno::Sequence< + ::com::sun::star::uno::Reference< + ::com::sun::star::chart2::data::XDataSequence > > & rLabel ); + + virtual ~DataSource(); + + /// establish methods for factory instatiation + APPHELPER_SERVICE_FACTORY_HELPER( DataSource ) + /// declare XServiceInfo methods + APPHELPER_XSERVICEINFO_DECL() + +protected: + // ____ XDataSource ____ + virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::chart2::data::XLabeledDataSequence > > SAL_CALL + getDataSequences() + throw (::com::sun::star::uno::RuntimeException); + + // ____ XDataSink ____ + virtual void SAL_CALL setData( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::chart2::data::XLabeledDataSequence > >& aData ) + throw (::com::sun::star::uno::RuntimeException); + +private: + ::com::sun::star::uno::Sequence< + ::com::sun::star::uno::Reference< + ::com::sun::star::chart2::data::XLabeledDataSequence > > + m_aDataSeq; +}; + +} // namespace chart + +// CHART2_DATASOURCE_HXX +#endif -- cgit