1*38d50f7bSAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*38d50f7bSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*38d50f7bSAndrew Rist * or more contributor license agreements. See the NOTICE file 5*38d50f7bSAndrew Rist * distributed with this work for additional information 6*38d50f7bSAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*38d50f7bSAndrew Rist * to you under the Apache License, Version 2.0 (the 8*38d50f7bSAndrew Rist * "License"); you may not use this file except in compliance 9*38d50f7bSAndrew Rist * with the License. You may obtain a copy of the License at 10*38d50f7bSAndrew Rist * 11*38d50f7bSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*38d50f7bSAndrew Rist * 13*38d50f7bSAndrew Rist * Unless required by applicable law or agreed to in writing, 14*38d50f7bSAndrew Rist * software distributed under the License is distributed on an 15*38d50f7bSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*38d50f7bSAndrew Rist * KIND, either express or implied. See the License for the 17*38d50f7bSAndrew Rist * specific language governing permissions and limitations 18*38d50f7bSAndrew Rist * under the License. 19*38d50f7bSAndrew Rist * 20*38d50f7bSAndrew Rist *************************************************************/ 21*38d50f7bSAndrew Rist 22*38d50f7bSAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweir #ifndef SC_CELLSUNO_HXX 25cdf0e10cSrcweir #define SC_CELLSUNO_HXX 26cdf0e10cSrcweir 27cdf0e10cSrcweir #include "global.hxx" // ScRange, ScAddress 28cdf0e10cSrcweir #include "rangelst.hxx" // ScRangeList 29cdf0e10cSrcweir 30cdf0e10cSrcweir #include "formula/grammar.hxx" 31cdf0e10cSrcweir #include <svl/lstner.hxx> 32cdf0e10cSrcweir #include <svl/listener.hxx> 33cdf0e10cSrcweir #include <svl/itemprop.hxx> 34cdf0e10cSrcweir #include <com/sun/star/table/XTableChartsSupplier.hpp> 35cdf0e10cSrcweir #include <com/sun/star/chart/XChartDataArray.hpp> 36cdf0e10cSrcweir #include <com/sun/star/text/XTextFieldsSupplier.hpp> 37cdf0e10cSrcweir #include <com/sun/star/drawing/XDrawPageSupplier.hpp> 38cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetCellRange.hpp> 39cdf0e10cSrcweir #include <com/sun/star/sheet/XFormulaQuery.hpp> 40cdf0e10cSrcweir #include <com/sun/star/sheet/XCellRangeAddressable.hpp> 41cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetOperation.hpp> 42cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetCellRangeContainer.hpp> 43cdf0e10cSrcweir #include <com/sun/star/sheet/XCellFormatRangesSupplier.hpp> 44cdf0e10cSrcweir #include <com/sun/star/sheet/XUniqueCellFormatRangesSupplier.hpp> 45cdf0e10cSrcweir #include <com/sun/star/sheet/XCellRangesQuery.hpp> 46cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetFilterableEx.hpp> 47cdf0e10cSrcweir #include <com/sun/star/sheet/XSpreadsheet.hpp> 48cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetPageBreak.hpp> 49cdf0e10cSrcweir #include <com/sun/star/sheet/XCellRangeMovement.hpp> 50cdf0e10cSrcweir #include <com/sun/star/text/XText.hpp> 51cdf0e10cSrcweir #include <com/sun/star/sheet/XPrintAreas.hpp> 52cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetLinkable.hpp> 53cdf0e10cSrcweir #include <com/sun/star/sheet/XSubTotalCalculatable.hpp> 54cdf0e10cSrcweir #include <com/sun/star/sheet/XArrayFormulaRange.hpp> 55cdf0e10cSrcweir #include <com/sun/star/sheet/XCellRangeData.hpp> 56cdf0e10cSrcweir #include <com/sun/star/sheet/XCellRangeFormula.hpp> 57cdf0e10cSrcweir #include <com/sun/star/sheet/XCellSeries.hpp> 58cdf0e10cSrcweir #include <com/sun/star/sheet/XMultipleOperation.hpp> 59cdf0e10cSrcweir #include <com/sun/star/sheet/XFormulaTokens.hpp> 60cdf0e10cSrcweir #include <com/sun/star/sheet/XArrayFormulaTokens.hpp> 61cdf0e10cSrcweir #include <com/sun/star/sheet/XCellAddressable.hpp> 62cdf0e10cSrcweir #include <com/sun/star/util/XReplaceable.hpp> 63cdf0e10cSrcweir #include <com/sun/star/util/XIndent.hpp> 64cdf0e10cSrcweir #include <com/sun/star/lang/XServiceInfo.hpp> 65cdf0e10cSrcweir #include <com/sun/star/container/XNameContainer.hpp> 66cdf0e10cSrcweir #include <com/sun/star/util/XMergeable.hpp> 67cdf0e10cSrcweir #include <com/sun/star/table/XAutoFormattable.hpp> 68cdf0e10cSrcweir #include <com/sun/star/util/XSortable.hpp> 69cdf0e10cSrcweir #include <com/sun/star/util/XImportable.hpp> 70cdf0e10cSrcweir #include <com/sun/star/table/XColumnRowRange.hpp> 71cdf0e10cSrcweir #include <com/sun/star/table/BorderLine.hpp> 72cdf0e10cSrcweir #include <com/sun/star/table/TableBorder.hpp> 73cdf0e10cSrcweir #include <com/sun/star/sheet/XDataPilotTablesSupplier.hpp> 74cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetAnnotationAnchor.hpp> 75cdf0e10cSrcweir #include <com/sun/star/sheet/XScenariosSupplier.hpp> 76cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetAnnotationsSupplier.hpp> 77cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetAuditing.hpp> 78cdf0e10cSrcweir #include <com/sun/star/sheet/XSheetOutline.hpp> 79cdf0e10cSrcweir #include <com/sun/star/util/XProtectable.hpp> 80cdf0e10cSrcweir #include <com/sun/star/sheet/XScenario.hpp> 81cdf0e10cSrcweir #include <com/sun/star/sheet/XScenarioEnhanced.hpp> 82cdf0e10cSrcweir #include <com/sun/star/util/XModifyBroadcaster.hpp> 83cdf0e10cSrcweir #include <com/sun/star/beans/XPropertyState.hpp> 84cdf0e10cSrcweir #include <com/sun/star/beans/XMultiPropertySet.hpp> 85cdf0e10cSrcweir #include <com/sun/star/lang/XUnoTunnel.hpp> 86cdf0e10cSrcweir #include <com/sun/star/document/XActionLockable.hpp> 87cdf0e10cSrcweir #include <com/sun/star/beans/XTolerantMultiPropertySet.hpp> 88cdf0e10cSrcweir #include <com/sun/star/sheet/XExternalSheetName.hpp> 89cdf0e10cSrcweir #include <com/sun/star/document/XEventsSupplier.hpp> 90cdf0e10cSrcweir #include <cppuhelper/implbase2.hxx> 91cdf0e10cSrcweir #include <cppuhelper/implbase3.hxx> 92cdf0e10cSrcweir 93cdf0e10cSrcweir #ifndef __SGI_STL_VECTOR 94cdf0e10cSrcweir #include <vector> 95cdf0e10cSrcweir #endif 96cdf0e10cSrcweir 97cdf0e10cSrcweir class ScDocShell; 98cdf0e10cSrcweir class ScMarkData; 99cdf0e10cSrcweir class ScMemChart; 100cdf0e10cSrcweir class ScPrintRangeSaver; 101cdf0e10cSrcweir class ScAttrRectIterator; 102cdf0e10cSrcweir class ScCellRangeObj; 103cdf0e10cSrcweir class SvxUnoText; 104cdf0e10cSrcweir class ScLinkListener; 105cdf0e10cSrcweir class ScPatternAttr; 106cdf0e10cSrcweir class SvxBorderLine; 107cdf0e10cSrcweir class SvxBoxItem; 108cdf0e10cSrcweir class SvxBoxInfoItem; 109cdf0e10cSrcweir class SvxItemPropertySet; 110cdf0e10cSrcweir 111cdf0e10cSrcweir class ScLinkListener : public SvtListener 112cdf0e10cSrcweir { 113cdf0e10cSrcweir Link aLink; 114cdf0e10cSrcweir public: ScLinkListener(const Link & rL)115cdf0e10cSrcweir ScLinkListener(const Link& rL) : aLink(rL) {} 116cdf0e10cSrcweir virtual ~ScLinkListener(); 117cdf0e10cSrcweir virtual void Notify( SvtBroadcaster& rBC, const SfxHint& rHint ); 118cdf0e10cSrcweir }; 119cdf0e10cSrcweir 120cdf0e10cSrcweir typedef ::com::sun::star::uno::Reference< 121cdf0e10cSrcweir ::com::sun::star::util::XModifyListener >* XModifyListenerPtr; 122cdf0e10cSrcweir SV_DECL_PTRARR_DEL( XModifyListenerArr_Impl, XModifyListenerPtr, 4, 4 ) 123cdf0e10cSrcweir 124cdf0e10cSrcweir class ScNamedEntry; 125cdf0e10cSrcweir typedef ScNamedEntry* ScNamedEntryPtr; 126cdf0e10cSrcweir SV_DECL_PTRARR_DEL( ScNamedEntryArr_Impl, ScNamedEntryPtr, 4, 4 ) 127cdf0e10cSrcweir 128cdf0e10cSrcweir 129cdf0e10cSrcweir // ScCellRangesBase - Basisklasse fuer ScCellRangesObj (mit Index-Access) 130cdf0e10cSrcweir // und ScCellRangeObj (ohne Index-Access) 131cdf0e10cSrcweir 132cdf0e10cSrcweir // XServiceInfo ist in den Ableitungen implementiert 133cdf0e10cSrcweir 134cdf0e10cSrcweir class ScHelperFunctions 135cdf0e10cSrcweir { 136cdf0e10cSrcweir public: 137cdf0e10cSrcweir static const SvxBorderLine* GetBorderLine( SvxBorderLine& rLine, const com::sun::star::table::BorderLine& rStruct ); 138cdf0e10cSrcweir static void FillBoxItems( SvxBoxItem& rOuter, SvxBoxInfoItem& rInner, const com::sun::star::table::TableBorder& rBorder ); 139cdf0e10cSrcweir static void FillBorderLine( com::sun::star::table::BorderLine& rStruct, const SvxBorderLine* pLine ); 140cdf0e10cSrcweir static void FillTableBorder( com::sun::star::table::TableBorder& rBorder, 141cdf0e10cSrcweir const SvxBoxItem& rOuter, const SvxBoxInfoItem& rInner ); 142cdf0e10cSrcweir static void ApplyBorder( ScDocShell* pDocShell, const ScRangeList& rRanges, 143cdf0e10cSrcweir const SvxBoxItem& rOuter, const SvxBoxInfoItem& rInner ); 144cdf0e10cSrcweir }; 145cdf0e10cSrcweir 146cdf0e10cSrcweir namespace ooo 147cdf0e10cSrcweir { 148cdf0e10cSrcweir namespace vba { 149cdf0e10cSrcweir namespace excel { 150cdf0e10cSrcweir class ScVbaCellRangeAccess; // Vba Helper class 151cdf0e10cSrcweir } 152cdf0e10cSrcweir } 153cdf0e10cSrcweir } 154cdf0e10cSrcweir 155cdf0e10cSrcweir class SC_DLLPUBLIC ScCellRangesBase : public com::sun::star::beans::XPropertySet, 156cdf0e10cSrcweir public com::sun::star::beans::XMultiPropertySet, 157cdf0e10cSrcweir public com::sun::star::beans::XPropertyState, 158cdf0e10cSrcweir public com::sun::star::sheet::XSheetOperation, 159cdf0e10cSrcweir public com::sun::star::chart::XChartDataArray, 160cdf0e10cSrcweir public com::sun::star::util::XIndent, 161cdf0e10cSrcweir public com::sun::star::sheet::XCellRangesQuery, 162cdf0e10cSrcweir public com::sun::star::sheet::XFormulaQuery, 163cdf0e10cSrcweir public com::sun::star::util::XReplaceable, 164cdf0e10cSrcweir public com::sun::star::util::XModifyBroadcaster, 165cdf0e10cSrcweir public com::sun::star::lang::XServiceInfo, 166cdf0e10cSrcweir public com::sun::star::lang::XUnoTunnel, 167cdf0e10cSrcweir public com::sun::star::lang::XTypeProvider, 168cdf0e10cSrcweir public com::sun::star::beans::XTolerantMultiPropertySet, 169cdf0e10cSrcweir public cppu::OWeakObject, 170cdf0e10cSrcweir public SfxListener 171cdf0e10cSrcweir { 172cdf0e10cSrcweir friend class ScTabViewObj; // fuer select() 173cdf0e10cSrcweir friend class ScTableSheetObj; // fuer createCursorByRange() 174cdf0e10cSrcweir friend class ooo::vba::excel::ScVbaCellRangeAccess; 175cdf0e10cSrcweir 176cdf0e10cSrcweir private: 177cdf0e10cSrcweir const SfxItemPropertySet* pPropSet; 178cdf0e10cSrcweir ScDocShell* pDocShell; 179cdf0e10cSrcweir ScLinkListener* pValueListener; 180cdf0e10cSrcweir ScPatternAttr* pCurrentFlat; 181cdf0e10cSrcweir ScPatternAttr* pCurrentDeep; 182cdf0e10cSrcweir SfxItemSet* pCurrentDataSet; 183cdf0e10cSrcweir SfxItemSet* pNoDfltCurrentDataSet; 184cdf0e10cSrcweir ScMarkData* pMarkData; 185cdf0e10cSrcweir ScRangeList aRanges; 186cdf0e10cSrcweir sal_Int64 nObjectId; 187cdf0e10cSrcweir sal_Bool bChartColAsHdr; 188cdf0e10cSrcweir sal_Bool bChartRowAsHdr; 189cdf0e10cSrcweir sal_Bool bCursorOnly; 190cdf0e10cSrcweir sal_Bool bGotDataChangedHint; 191cdf0e10cSrcweir XModifyListenerArr_Impl aValueListeners; 192cdf0e10cSrcweir 193cdf0e10cSrcweir DECL_LINK( ValueListenerHdl, SfxHint* ); 194cdf0e10cSrcweir 195cdf0e10cSrcweir private: 196cdf0e10cSrcweir void PaintRanges_Impl( sal_uInt16 nPart ); 197cdf0e10cSrcweir ScRangeListRef GetLimitedChartRanges_Impl( long nDataColumns, long nDataRows ) const; 198cdf0e10cSrcweir void ForceChartListener_Impl(); 199cdf0e10cSrcweir ScMemChart* CreateMemChart_Impl() const; 200cdf0e10cSrcweir 201cdf0e10cSrcweir const ScPatternAttr* GetCurrentAttrsFlat(); 202cdf0e10cSrcweir const ScPatternAttr* GetCurrentAttrsDeep(); 203cdf0e10cSrcweir SfxItemSet* GetCurrentDataSet(bool bNoDflt = false); 204cdf0e10cSrcweir void ForgetMarkData(); 205cdf0e10cSrcweir void ForgetCurrentAttrs(); 206cdf0e10cSrcweir 207cdf0e10cSrcweir com::sun::star::uno::Reference<com::sun::star::sheet::XSheetCellRanges> 208cdf0e10cSrcweir QueryDifferences_Impl(const com::sun::star::table::CellAddress& aCompare, 209cdf0e10cSrcweir sal_Bool bColumnDiff); 210cdf0e10cSrcweir com::sun::star::uno::Reference<com::sun::star::uno::XInterface> 211cdf0e10cSrcweir Find_Impl(const com::sun::star::uno::Reference< 212cdf0e10cSrcweir com::sun::star::util::XSearchDescriptor>& xDesc, 213cdf0e10cSrcweir const ScAddress* pLastPos); 214cdf0e10cSrcweir 215cdf0e10cSrcweir protected: 216cdf0e10cSrcweir const ScMarkData* GetMarkData(); 217cdf0e10cSrcweir 218cdf0e10cSrcweir // GetItemPropertyMap for derived classes must contain all entries, including base class 219cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 220cdf0e10cSrcweir virtual ::com::sun::star::beans::PropertyState GetOnePropertyState( 221cdf0e10cSrcweir sal_uInt16 nItemWhich, const SfxItemPropertySimpleEntry* pEntry ); 222cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 223cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 224cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 225cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 226cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 227cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 228cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 229cdf0e10cSrcweir 230cdf0e10cSrcweir public: 231cdf0e10cSrcweir ScCellRangesBase(); // fuer SMART_REFLECTION Krempel 232cdf0e10cSrcweir ScCellRangesBase(ScDocShell* pDocSh, const ScRange& rR); 233cdf0e10cSrcweir ScCellRangesBase(ScDocShell* pDocSh, const ScRangeList& rR); 234cdf0e10cSrcweir virtual ~ScCellRangesBase(); 235cdf0e10cSrcweir 236cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 237cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 238cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 239cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 240cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 241cdf0e10cSrcweir 242cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 243cdf0e10cSrcweir virtual void RefChanged(); 244cdf0e10cSrcweir 245cdf0e10cSrcweir // aus Ableitungen, aber auch per getImplementation GetDocShell() const246cdf0e10cSrcweir ScDocShell* GetDocShell() const { return pDocShell; } 247cdf0e10cSrcweir ScDocument* GetDocument() const; GetRangeList() const248cdf0e10cSrcweir const ScRangeList& GetRangeList() const { return aRanges; } 249cdf0e10cSrcweir void AddRange(const ScRange& rRange, const sal_Bool bMergeRanges); 250cdf0e10cSrcweir 251cdf0e10cSrcweir // per Service erzeugtes Objekt zum Leben erwecken: 252cdf0e10cSrcweir void InitInsertRange(ScDocShell* pDocSh, const ScRange& rR); 253cdf0e10cSrcweir 254cdf0e10cSrcweir void SetNewRange(const ScRange& rNew); // fuer Cursor 255cdf0e10cSrcweir void SetNewRanges(const ScRangeList& rNew); 256cdf0e10cSrcweir 257cdf0e10cSrcweir void SetCursorOnly(sal_Bool bSet); IsCursorOnly() const258cdf0e10cSrcweir sal_Bool IsCursorOnly() const { return bCursorOnly; } 259cdf0e10cSrcweir 260cdf0e10cSrcweir // XSheetOperation 261cdf0e10cSrcweir virtual double SAL_CALL computeFunction( ::com::sun::star::sheet::GeneralFunction nFunction ) 262cdf0e10cSrcweir throw(::com::sun::star::uno::Exception, 263cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 264cdf0e10cSrcweir virtual void SAL_CALL clearContents( sal_Int32 nContentFlags ) 265cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 266cdf0e10cSrcweir 267cdf0e10cSrcweir // XPropertySet 268cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 269cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 270cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 271cdf0e10cSrcweir virtual void SAL_CALL setPropertyValue( const ::rtl::OUString& aPropertyName, 272cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 273cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 274cdf0e10cSrcweir ::com::sun::star::beans::PropertyVetoException, 275cdf0e10cSrcweir ::com::sun::star::lang::IllegalArgumentException, 276cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 277cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 278cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue( 279cdf0e10cSrcweir const ::rtl::OUString& PropertyName ) 280cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 281cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 282cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 283cdf0e10cSrcweir virtual void SAL_CALL addPropertyChangeListener( const ::rtl::OUString& aPropertyName, 284cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 285cdf0e10cSrcweir ::com::sun::star::beans::XPropertyChangeListener >& xListener ) 286cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 287cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 288cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 289cdf0e10cSrcweir virtual void SAL_CALL removePropertyChangeListener( const ::rtl::OUString& aPropertyName, 290cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 291cdf0e10cSrcweir ::com::sun::star::beans::XPropertyChangeListener >& aListener ) 292cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 293cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 294cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 295cdf0e10cSrcweir virtual void SAL_CALL addVetoableChangeListener( const ::rtl::OUString& PropertyName, 296cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 297cdf0e10cSrcweir ::com::sun::star::beans::XVetoableChangeListener >& aListener ) 298cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 299cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 300cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 301cdf0e10cSrcweir virtual void SAL_CALL removeVetoableChangeListener( const ::rtl::OUString& PropertyName, 302cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 303cdf0e10cSrcweir ::com::sun::star::beans::XVetoableChangeListener >& aListener ) 304cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 305cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 306cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 307cdf0e10cSrcweir 308cdf0e10cSrcweir // XMultiPropertySet 309cdf0e10cSrcweir virtual void SAL_CALL setPropertyValues( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, 310cdf0e10cSrcweir const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aValues ) 311cdf0e10cSrcweir throw (::com::sun::star::beans::PropertyVetoException, 312cdf0e10cSrcweir ::com::sun::star::lang::IllegalArgumentException, 313cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 314cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 315cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > SAL_CALL 316cdf0e10cSrcweir getPropertyValues( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) 317cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 318cdf0e10cSrcweir virtual void SAL_CALL addPropertiesChangeListener( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, 319cdf0e10cSrcweir const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) 320cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 321cdf0e10cSrcweir virtual void SAL_CALL removePropertiesChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) 322cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 323cdf0e10cSrcweir virtual void SAL_CALL firePropertiesChangeEvent( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, 324cdf0e10cSrcweir const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) 325cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 326cdf0e10cSrcweir 327cdf0e10cSrcweir // XTolerantMultiPropertySet 328cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::SetPropertyTolerantFailed > SAL_CALL 329cdf0e10cSrcweir setPropertyValuesTolerant( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, 330cdf0e10cSrcweir const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aValues ) 331cdf0e10cSrcweir throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException); 332cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::GetPropertyTolerantResult > SAL_CALL 333cdf0e10cSrcweir getPropertyValuesTolerant( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) 334cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 335cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::GetDirectPropertyTolerantResult > SAL_CALL 336cdf0e10cSrcweir getDirectPropertyValuesTolerant( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) 337cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 338cdf0e10cSrcweir 339cdf0e10cSrcweir // XPropertyState 340cdf0e10cSrcweir virtual ::com::sun::star::beans::PropertyState SAL_CALL getPropertyState( 341cdf0e10cSrcweir const ::rtl::OUString& PropertyName ) 342cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 343cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 344cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyState > SAL_CALL 345cdf0e10cSrcweir getPropertyStates( const ::com::sun::star::uno::Sequence< 346cdf0e10cSrcweir ::rtl::OUString >& aPropertyName ) 347cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 348cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 349cdf0e10cSrcweir virtual void SAL_CALL setPropertyToDefault( const ::rtl::OUString& PropertyName ) 350cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 351cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 352cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getPropertyDefault( 353cdf0e10cSrcweir const ::rtl::OUString& aPropertyName ) 354cdf0e10cSrcweir throw(::com::sun::star::beans::UnknownPropertyException, 355cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 356cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 357cdf0e10cSrcweir 358cdf0e10cSrcweir // XIndent 359cdf0e10cSrcweir virtual void SAL_CALL decrementIndent() throw(::com::sun::star::uno::RuntimeException); 360cdf0e10cSrcweir virtual void SAL_CALL incrementIndent() throw(::com::sun::star::uno::RuntimeException); 361cdf0e10cSrcweir 362cdf0e10cSrcweir // XChartData 363cdf0e10cSrcweir virtual void SAL_CALL addChartDataChangeEventListener( 364cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 365cdf0e10cSrcweir ::com::sun::star::chart::XChartDataChangeEventListener >& aListener ) 366cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 367cdf0e10cSrcweir virtual void SAL_CALL removeChartDataChangeEventListener( const ::com::sun::star::uno::Reference< 368cdf0e10cSrcweir ::com::sun::star::chart::XChartDataChangeEventListener >& aListener ) 369cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 370cdf0e10cSrcweir virtual double SAL_CALL getNotANumber() throw(::com::sun::star::uno::RuntimeException); 371cdf0e10cSrcweir virtual sal_Bool SAL_CALL isNotANumber( double nNumber ) 372cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 373cdf0e10cSrcweir 374cdf0e10cSrcweir // XChartDataArray 375cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< double > > SAL_CALL 376cdf0e10cSrcweir getData() throw(::com::sun::star::uno::RuntimeException); 377cdf0e10cSrcweir virtual void SAL_CALL setData( const ::com::sun::star::uno::Sequence< 378cdf0e10cSrcweir ::com::sun::star::uno::Sequence< double > >& aData ) 379cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 380cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getRowDescriptions() 381cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 382cdf0e10cSrcweir virtual void SAL_CALL setRowDescriptions( const ::com::sun::star::uno::Sequence< 383cdf0e10cSrcweir ::rtl::OUString >& aRowDescriptions ) 384cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 385cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getColumnDescriptions() 386cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 387cdf0e10cSrcweir virtual void SAL_CALL setColumnDescriptions( const ::com::sun::star::uno::Sequence< 388cdf0e10cSrcweir ::rtl::OUString >& aColumnDescriptions ) 389cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 390cdf0e10cSrcweir 391cdf0e10cSrcweir // XCellRangesQuery 392cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 393cdf0e10cSrcweir queryVisibleCells() throw(::com::sun::star::uno::RuntimeException); 394cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 395cdf0e10cSrcweir queryEmptyCells() throw(::com::sun::star::uno::RuntimeException); 396cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 397cdf0e10cSrcweir queryContentCells( sal_Int16 nContentFlags ) 398cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 399cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 400cdf0e10cSrcweir queryFormulaCells( sal_Int32 nResultFlags ) 401cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 402cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 403cdf0e10cSrcweir queryColumnDifferences( 404cdf0e10cSrcweir const ::com::sun::star::table::CellAddress& aCompare ) 405cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 406cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 407cdf0e10cSrcweir queryRowDifferences( 408cdf0e10cSrcweir const ::com::sun::star::table::CellAddress& aCompare ) 409cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 410cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 411cdf0e10cSrcweir queryIntersection( 412cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aRange ) 413cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 414cdf0e10cSrcweir 415cdf0e10cSrcweir // XFormulaQuery 416cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 417cdf0e10cSrcweir queryDependents( sal_Bool bRecursive ) 418cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 419cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellRanges > SAL_CALL 420cdf0e10cSrcweir queryPrecedents( sal_Bool bRecursive ) 421cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 422cdf0e10cSrcweir 423cdf0e10cSrcweir // XSearchable 424cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::util::XSearchDescriptor > SAL_CALL 425cdf0e10cSrcweir createSearchDescriptor() 426cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 427cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > SAL_CALL 428cdf0e10cSrcweir findAll( const ::com::sun::star::uno::Reference< 429cdf0e10cSrcweir ::com::sun::star::util::XSearchDescriptor >& xDesc ) 430cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 431cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > SAL_CALL 432cdf0e10cSrcweir findFirst( const ::com::sun::star::uno::Reference< 433cdf0e10cSrcweir ::com::sun::star::util::XSearchDescriptor >& xDesc ) 434cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 435cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > SAL_CALL 436cdf0e10cSrcweir findNext( const ::com::sun::star::uno::Reference< 437cdf0e10cSrcweir ::com::sun::star::uno::XInterface >& xStartAt, 438cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 439cdf0e10cSrcweir ::com::sun::star::util::XSearchDescriptor >& xDesc ) 440cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 441cdf0e10cSrcweir 442cdf0e10cSrcweir // XReplaceable 443cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::util::XReplaceDescriptor > SAL_CALL 444cdf0e10cSrcweir createReplaceDescriptor() throw(::com::sun::star::uno::RuntimeException); 445cdf0e10cSrcweir virtual sal_Int32 SAL_CALL replaceAll( const ::com::sun::star::uno::Reference< 446cdf0e10cSrcweir ::com::sun::star::util::XSearchDescriptor >& xDesc ) 447cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 448cdf0e10cSrcweir 449cdf0e10cSrcweir // XModifyBroadcaster 450cdf0e10cSrcweir virtual void SAL_CALL addModifyListener( const ::com::sun::star::uno::Reference< 451cdf0e10cSrcweir ::com::sun::star::util::XModifyListener >& aListener ) 452cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 453cdf0e10cSrcweir virtual void SAL_CALL removeModifyListener( const ::com::sun::star::uno::Reference< 454cdf0e10cSrcweir ::com::sun::star::util::XModifyListener >& aListener ) 455cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 456cdf0e10cSrcweir 457cdf0e10cSrcweir // XServiceInfo 458cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 459cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 460cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 461cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 462cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 463cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 464cdf0e10cSrcweir 465cdf0e10cSrcweir // XUnoTunnel 466cdf0e10cSrcweir virtual sal_Int64 SAL_CALL getSomething( const ::com::sun::star::uno::Sequence< 467cdf0e10cSrcweir sal_Int8 >& aIdentifier ) 468cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 469cdf0e10cSrcweir 470cdf0e10cSrcweir static const com::sun::star::uno::Sequence<sal_Int8>& getUnoTunnelId(); 471cdf0e10cSrcweir static ScCellRangesBase* getImplementation( const com::sun::star::uno::Reference< 472cdf0e10cSrcweir com::sun::star::uno::XInterface> xObj ); 473cdf0e10cSrcweir 474cdf0e10cSrcweir // XTypeProvider 475cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 476cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 477cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 478cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 479cdf0e10cSrcweir }; 480cdf0e10cSrcweir 481cdf0e10cSrcweir 482cdf0e10cSrcweir class SC_DLLPUBLIC ScCellRangesObj : public ScCellRangesBase, 483cdf0e10cSrcweir public com::sun::star::sheet::XSheetCellRangeContainer, 484cdf0e10cSrcweir public com::sun::star::container::XNameContainer, 485cdf0e10cSrcweir public com::sun::star::container::XEnumerationAccess 486cdf0e10cSrcweir { 487cdf0e10cSrcweir private: 488cdf0e10cSrcweir ScNamedEntryArr_Impl aNamedEntries; 489cdf0e10cSrcweir 490cdf0e10cSrcweir ScCellRangeObj* GetObjectByIndex_Impl(sal_Int32 nIndex) const; 491cdf0e10cSrcweir 492cdf0e10cSrcweir public: 493cdf0e10cSrcweir ScCellRangesObj(ScDocShell* pDocSh, const ScRangeList& rR); 494cdf0e10cSrcweir virtual ~ScCellRangesObj(); 495cdf0e10cSrcweir 496cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 497cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 498cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 499cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 500cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 501cdf0e10cSrcweir 502cdf0e10cSrcweir virtual void RefChanged(); 503cdf0e10cSrcweir 504cdf0e10cSrcweir // XSheetCellRanges 505cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess > SAL_CALL 506cdf0e10cSrcweir getCells() throw(::com::sun::star::uno::RuntimeException); 507cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getRangeAddressesAsString() 508cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 509cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::table::CellRangeAddress > SAL_CALL 510cdf0e10cSrcweir getRangeAddresses() throw(::com::sun::star::uno::RuntimeException); 511cdf0e10cSrcweir 512cdf0e10cSrcweir // XSheetCellRangeContainer 513cdf0e10cSrcweir virtual void SAL_CALL addRangeAddress( const ::com::sun::star::table::CellRangeAddress& rRange, 514cdf0e10cSrcweir sal_Bool bMergeRanges ) 515cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 516cdf0e10cSrcweir virtual void SAL_CALL removeRangeAddress( const ::com::sun::star::table::CellRangeAddress& rRange ) 517cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 518cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 519cdf0e10cSrcweir virtual void SAL_CALL addRangeAddresses( const ::com::sun::star::uno::Sequence< 520cdf0e10cSrcweir ::com::sun::star::table::CellRangeAddress >& rRanges, 521cdf0e10cSrcweir sal_Bool bMergeRanges ) 522cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 523cdf0e10cSrcweir virtual void SAL_CALL removeRangeAddresses( const ::com::sun::star::uno::Sequence< 524cdf0e10cSrcweir ::com::sun::star::table::CellRangeAddress >& rRanges ) 525cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 526cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 527cdf0e10cSrcweir 528cdf0e10cSrcweir // XNameContainer 529cdf0e10cSrcweir virtual void SAL_CALL insertByName( const ::rtl::OUString& aName, 530cdf0e10cSrcweir const ::com::sun::star::uno::Any& aElement ) 531cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 532cdf0e10cSrcweir ::com::sun::star::container::ElementExistException, 533cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 534cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 535cdf0e10cSrcweir virtual void SAL_CALL removeByName( const ::rtl::OUString& Name ) 536cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 537cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 538cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 539cdf0e10cSrcweir 540cdf0e10cSrcweir // XNameReplace 541cdf0e10cSrcweir virtual void SAL_CALL replaceByName( const ::rtl::OUString& aName, 542cdf0e10cSrcweir const ::com::sun::star::uno::Any& aElement ) 543cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 544cdf0e10cSrcweir ::com::sun::star::container::NoSuchElementException, 545cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 546cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 547cdf0e10cSrcweir 548cdf0e10cSrcweir // XNameAccess 549cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getByName( const ::rtl::OUString& aName ) 550cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 551cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 552cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 553cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames() 554cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 555cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName ) 556cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 557cdf0e10cSrcweir 558cdf0e10cSrcweir // XIndexAccess 559cdf0e10cSrcweir virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException); 560cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index ) 561cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 562cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 563cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 564cdf0e10cSrcweir 565cdf0e10cSrcweir // XElementAccess 566cdf0e10cSrcweir virtual ::com::sun::star::uno::Type SAL_CALL getElementType() 567cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 568cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException); 569cdf0e10cSrcweir 570cdf0e10cSrcweir // XEnumerationAccess 571cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL 572cdf0e10cSrcweir createEnumeration() throw(::com::sun::star::uno::RuntimeException); 573cdf0e10cSrcweir 574cdf0e10cSrcweir // XServiceInfo 575cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 576cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 577cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 578cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 579cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 580cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 581cdf0e10cSrcweir 582cdf0e10cSrcweir // XTypeProvider 583cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 584cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 585cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 586cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 587cdf0e10cSrcweir }; 588cdf0e10cSrcweir 589cdf0e10cSrcweir 590cdf0e10cSrcweir class SC_DLLPUBLIC ScCellRangeObj : public ScCellRangesBase, 591cdf0e10cSrcweir public com::sun::star::sheet::XCellRangeAddressable, 592cdf0e10cSrcweir public com::sun::star::sheet::XSheetCellRange, 593cdf0e10cSrcweir public com::sun::star::sheet::XArrayFormulaRange, 594cdf0e10cSrcweir public com::sun::star::sheet::XArrayFormulaTokens, 595cdf0e10cSrcweir public com::sun::star::sheet::XCellRangeData, 596cdf0e10cSrcweir public com::sun::star::sheet::XCellRangeFormula, 597cdf0e10cSrcweir public com::sun::star::sheet::XMultipleOperation, 598cdf0e10cSrcweir public com::sun::star::util::XMergeable, 599cdf0e10cSrcweir public com::sun::star::sheet::XCellSeries, 600cdf0e10cSrcweir public com::sun::star::table::XAutoFormattable, 601cdf0e10cSrcweir public com::sun::star::util::XSortable, 602cdf0e10cSrcweir public com::sun::star::sheet::XSheetFilterableEx, 603cdf0e10cSrcweir public com::sun::star::sheet::XSubTotalCalculatable, 604cdf0e10cSrcweir public com::sun::star::util::XImportable, 605cdf0e10cSrcweir public com::sun::star::sheet::XCellFormatRangesSupplier, 606cdf0e10cSrcweir public com::sun::star::sheet::XUniqueCellFormatRangesSupplier, 607cdf0e10cSrcweir public com::sun::star::table::XColumnRowRange 608cdf0e10cSrcweir { 609cdf0e10cSrcweir private: 610cdf0e10cSrcweir const SfxItemPropertySet* pRangePropSet; 611cdf0e10cSrcweir ScRange aRange; 612cdf0e10cSrcweir 613cdf0e10cSrcweir protected: GetRange() const614cdf0e10cSrcweir const ScRange& GetRange() const { return aRange; } 615cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 616cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 617cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 618cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 619cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 620cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 621cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 622cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 623cdf0e10cSrcweir 624cdf0e10cSrcweir ::com::sun::star::uno::Reference< ::com::sun::star::table::XCell > 625cdf0e10cSrcweir GetCellByPosition_Impl( sal_Int32 nColumn, sal_Int32 nRow ) 626cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 627cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 628cdf0e10cSrcweir 629cdf0e10cSrcweir void SetArrayFormula_Impl( const rtl::OUString& rFormula, 630cdf0e10cSrcweir const rtl::OUString& rFormulaNmsp, 631cdf0e10cSrcweir const formula::FormulaGrammar::Grammar eGrammar ) 632cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 633cdf0e10cSrcweir 634cdf0e10cSrcweir public: 635cdf0e10cSrcweir ScCellRangeObj(ScDocShell* pDocSh, const ScRange& rR); 636cdf0e10cSrcweir virtual ~ScCellRangeObj(); 637cdf0e10cSrcweir 638cdf0e10cSrcweir // uses ObjectShell from document, if set (returns NULL otherwise) 639cdf0e10cSrcweir static com::sun::star::uno::Reference<com::sun::star::table::XCellRange> 640cdf0e10cSrcweir CreateRangeFromDoc( ScDocument* pDoc, const ScRange& rR ); 641cdf0e10cSrcweir 642cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 643cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 644cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 645cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 646cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 647cdf0e10cSrcweir 648cdf0e10cSrcweir virtual void RefChanged(); 649cdf0e10cSrcweir 650cdf0e10cSrcweir // via getImplementation() 651cdf0e10cSrcweir virtual void SetArrayFormulaWithGrammar( const ::rtl::OUString& rFormula, 652cdf0e10cSrcweir const ::rtl::OUString& rFormulaNmsp, 653cdf0e10cSrcweir const formula::FormulaGrammar::Grammar ) 654cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 655cdf0e10cSrcweir 656cdf0e10cSrcweir // XCellRange ist Basisklasse von XSheetCellRange und XSheetOperation 657cdf0e10cSrcweir // operator XCellRangeRef() const { return (XSheetCellRange*)this; } 658cdf0e10cSrcweir 659cdf0e10cSrcweir // XCellRangeAddressable 660cdf0e10cSrcweir virtual ::com::sun::star::table::CellRangeAddress SAL_CALL getRangeAddress() 661cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 662cdf0e10cSrcweir 663cdf0e10cSrcweir // XSheetCellRange 664cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSpreadsheet > SAL_CALL 665cdf0e10cSrcweir getSpreadsheet() throw(::com::sun::star::uno::RuntimeException); 666cdf0e10cSrcweir 667cdf0e10cSrcweir // XArrayFormulaRange 668cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getArrayFormula() throw(::com::sun::star::uno::RuntimeException); 669cdf0e10cSrcweir virtual void SAL_CALL setArrayFormula( const ::rtl::OUString& aFormula ) 670cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 671cdf0e10cSrcweir 672cdf0e10cSrcweir // XArrayFormulaTokens 673cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::sheet::FormulaToken > SAL_CALL getArrayTokens() 674cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 675cdf0e10cSrcweir virtual void SAL_CALL setArrayTokens( const ::com::sun::star::uno::Sequence< 676cdf0e10cSrcweir ::com::sun::star::sheet::FormulaToken >& aTokens ) 677cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 678cdf0e10cSrcweir 679cdf0e10cSrcweir // XCellRangeData 680cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< 681cdf0e10cSrcweir ::com::sun::star::uno::Any > > SAL_CALL getDataArray() 682cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 683cdf0e10cSrcweir virtual void SAL_CALL setDataArray( const ::com::sun::star::uno::Sequence< 684cdf0e10cSrcweir ::com::sun::star::uno::Sequence< 685cdf0e10cSrcweir ::com::sun::star::uno::Any > >& aArray ) 686cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 687cdf0e10cSrcweir 688cdf0e10cSrcweir // XCellRangeFormula 689cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< 690cdf0e10cSrcweir ::rtl::OUString > > SAL_CALL getFormulaArray() 691cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 692cdf0e10cSrcweir virtual void SAL_CALL setFormulaArray( const ::com::sun::star::uno::Sequence< 693cdf0e10cSrcweir ::com::sun::star::uno::Sequence< ::rtl::OUString > >& aArray ) 694cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 695cdf0e10cSrcweir 696cdf0e10cSrcweir // XMultipleOperation 697cdf0e10cSrcweir virtual void SAL_CALL setTableOperation( 698cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aFormulaRange, 699cdf0e10cSrcweir ::com::sun::star::sheet::TableOperationMode nMode, 700cdf0e10cSrcweir const ::com::sun::star::table::CellAddress& aColumnCell, 701cdf0e10cSrcweir const ::com::sun::star::table::CellAddress& aRowCell ) 702cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 703cdf0e10cSrcweir 704cdf0e10cSrcweir // XMergeable 705cdf0e10cSrcweir virtual void SAL_CALL merge( sal_Bool bMerge ) throw(::com::sun::star::uno::RuntimeException); 706cdf0e10cSrcweir virtual sal_Bool SAL_CALL getIsMerged() throw(::com::sun::star::uno::RuntimeException); 707cdf0e10cSrcweir 708cdf0e10cSrcweir // XCellSeries 709cdf0e10cSrcweir virtual void SAL_CALL fillSeries( ::com::sun::star::sheet::FillDirection nFillDirection, 710cdf0e10cSrcweir ::com::sun::star::sheet::FillMode nFillMode, 711cdf0e10cSrcweir ::com::sun::star::sheet::FillDateMode nFillDateMode, 712cdf0e10cSrcweir double fStep, double fEndValue ) 713cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 714cdf0e10cSrcweir virtual void SAL_CALL fillAuto( ::com::sun::star::sheet::FillDirection nFillDirection, 715cdf0e10cSrcweir sal_Int32 nSourceCount ) 716cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 717cdf0e10cSrcweir 718cdf0e10cSrcweir // XAutoFormattable 719cdf0e10cSrcweir virtual void SAL_CALL autoFormat( const ::rtl::OUString& aName ) 720cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 721cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 722cdf0e10cSrcweir 723cdf0e10cSrcweir // XSortable 724cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > SAL_CALL 725cdf0e10cSrcweir createSortDescriptor() throw(::com::sun::star::uno::RuntimeException); 726cdf0e10cSrcweir virtual void SAL_CALL sort( const ::com::sun::star::uno::Sequence< 727cdf0e10cSrcweir ::com::sun::star::beans::PropertyValue >& xDescriptor ) 728cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 729cdf0e10cSrcweir 730cdf0e10cSrcweir // XSheetFilterableEx 731cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetFilterDescriptor > SAL_CALL 732cdf0e10cSrcweir createFilterDescriptorByObject( const ::com::sun::star::uno::Reference< 733cdf0e10cSrcweir ::com::sun::star::sheet::XSheetFilterable >& xObject ) 734cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 735cdf0e10cSrcweir 736cdf0e10cSrcweir // XSheetFilterable 737cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetFilterDescriptor > SAL_CALL 738cdf0e10cSrcweir createFilterDescriptor( sal_Bool bEmpty ) 739cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 740cdf0e10cSrcweir virtual void SAL_CALL filter( const ::com::sun::star::uno::Reference< 741cdf0e10cSrcweir ::com::sun::star::sheet::XSheetFilterDescriptor >& xDescriptor ) 742cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 743cdf0e10cSrcweir 744cdf0e10cSrcweir // XSubTotalCalculatable 745cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSubTotalDescriptor > SAL_CALL 746cdf0e10cSrcweir createSubTotalDescriptor( sal_Bool bEmpty ) 747cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 748cdf0e10cSrcweir virtual void SAL_CALL applySubTotals( const ::com::sun::star::uno::Reference< 749cdf0e10cSrcweir ::com::sun::star::sheet::XSubTotalDescriptor >& xDescriptor, 750cdf0e10cSrcweir sal_Bool bReplace ) throw(::com::sun::star::uno::RuntimeException); 751cdf0e10cSrcweir virtual void SAL_CALL removeSubTotals() throw(::com::sun::star::uno::RuntimeException); 752cdf0e10cSrcweir 753cdf0e10cSrcweir // XImportable 754cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > SAL_CALL 755cdf0e10cSrcweir createImportDescriptor( sal_Bool bEmpty ) 756cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 757cdf0e10cSrcweir virtual void SAL_CALL doImport( const ::com::sun::star::uno::Sequence< 758cdf0e10cSrcweir ::com::sun::star::beans::PropertyValue >& aDescriptor ) 759cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 760cdf0e10cSrcweir 761cdf0e10cSrcweir // XCellFormatRangesSupplier 762cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > SAL_CALL 763cdf0e10cSrcweir getCellFormatRanges() throw(::com::sun::star::uno::RuntimeException); 764cdf0e10cSrcweir 765cdf0e10cSrcweir // XUniqueCellFormatRangesSupplier 766cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > SAL_CALL 767cdf0e10cSrcweir getUniqueCellFormatRanges() throw(::com::sun::star::uno::RuntimeException); 768cdf0e10cSrcweir 769cdf0e10cSrcweir // XColumnRowRange 770cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XTableColumns > SAL_CALL 771cdf0e10cSrcweir getColumns() throw(::com::sun::star::uno::RuntimeException); 772cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XTableRows > SAL_CALL 773cdf0e10cSrcweir getRows() throw(::com::sun::star::uno::RuntimeException); 774cdf0e10cSrcweir 775cdf0e10cSrcweir // XCellRange 776cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCell > SAL_CALL 777cdf0e10cSrcweir getCellByPosition( sal_Int32 nColumn, sal_Int32 nRow ) 778cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 779cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 780cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCellRange > SAL_CALL 781cdf0e10cSrcweir getCellRangeByPosition( sal_Int32 nLeft, sal_Int32 nTop, 782cdf0e10cSrcweir sal_Int32 nRight, sal_Int32 nBottom ) 783cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 784cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 785cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCellRange > SAL_CALL 786cdf0e10cSrcweir getCellRangeByName( const ::rtl::OUString& aRange ) 787cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 788cdf0e10cSrcweir ::com::sun::star::uno::Reference< ::com::sun::star::table::XCellRange > 789cdf0e10cSrcweir getCellRangeByName( const ::rtl::OUString& aRange, const ScAddress::Details& rDetails ) 790cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 791cdf0e10cSrcweir 792cdf0e10cSrcweir // XPropertySet ueberladen wegen Range-Properties 793cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 794cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 795cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 796cdf0e10cSrcweir 797cdf0e10cSrcweir // XServiceInfo 798cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 799cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 800cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 801cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 802cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 803cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 804cdf0e10cSrcweir 805cdf0e10cSrcweir // XTypeProvider 806cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 807cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 808cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 809cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 810cdf0e10cSrcweir }; 811cdf0e10cSrcweir 812cdf0e10cSrcweir 813cdf0e10cSrcweir //! really derive cell from range? 814cdf0e10cSrcweir 815cdf0e10cSrcweir class SC_DLLPUBLIC ScCellObj : public ScCellRangeObj, 816cdf0e10cSrcweir public com::sun::star::text::XText, 817cdf0e10cSrcweir public com::sun::star::container::XEnumerationAccess, 818cdf0e10cSrcweir public com::sun::star::table::XCell, 819cdf0e10cSrcweir public com::sun::star::sheet::XFormulaTokens, 820cdf0e10cSrcweir public com::sun::star::sheet::XCellAddressable, 821cdf0e10cSrcweir public com::sun::star::sheet::XSheetAnnotationAnchor, 822cdf0e10cSrcweir public com::sun::star::text::XTextFieldsSupplier, 823cdf0e10cSrcweir public com::sun::star::document::XActionLockable 824cdf0e10cSrcweir { 825cdf0e10cSrcweir private: 826cdf0e10cSrcweir SvxUnoText* pUnoText; 827cdf0e10cSrcweir const SfxItemPropertySet* pCellPropSet; 828cdf0e10cSrcweir ScAddress aCellPos; 829cdf0e10cSrcweir sal_Int16 nActionLockCount; 830cdf0e10cSrcweir 831cdf0e10cSrcweir private: 832cdf0e10cSrcweir String GetInputString_Impl(sal_Bool bEnglish) const; 833cdf0e10cSrcweir String GetOutputString_Impl() const; 834cdf0e10cSrcweir void SetString_Impl(const String& rString, sal_Bool bInterpret, sal_Bool bEnglish); 835cdf0e10cSrcweir double GetValue_Impl() const; 836cdf0e10cSrcweir void SetValue_Impl(double fValue); 837cdf0e10cSrcweir com::sun::star::table::CellContentType GetResultType_Impl(); 838cdf0e10cSrcweir 839cdf0e10cSrcweir protected: 840cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 841cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 842cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 843cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 844cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 845cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 846cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 847cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 848cdf0e10cSrcweir 849cdf0e10cSrcweir public: 850cdf0e10cSrcweir static const SvxItemPropertySet* GetEditPropertySet(); 851cdf0e10cSrcweir static const SfxItemPropertyMap* GetCellPropertyMap(); 852cdf0e10cSrcweir 853cdf0e10cSrcweir ScCellObj(ScDocShell* pDocSh, const ScAddress& rP); 854cdf0e10cSrcweir virtual ~ScCellObj(); 855cdf0e10cSrcweir 856cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 857cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 858cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 859cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 860cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 861cdf0e10cSrcweir 862cdf0e10cSrcweir virtual void RefChanged(); 863cdf0e10cSrcweir 864cdf0e10cSrcweir SvxUnoText& GetUnoText(); 865cdf0e10cSrcweir 866cdf0e10cSrcweir // XML import needs to set results at formula cells, 867cdf0e10cSrcweir // not meant for any other purpose. 868cdf0e10cSrcweir void SetFormulaResultString( const ::rtl::OUString& rResult ); 869cdf0e10cSrcweir void SetFormulaResultDouble( double fResult ); 870cdf0e10cSrcweir void SetFormulaWithGrammar( const ::rtl::OUString& rFormula, 871cdf0e10cSrcweir const ::rtl::OUString& rFormulaNmsp, const formula::FormulaGrammar::Grammar ); GetPosition() const872cdf0e10cSrcweir const ScAddress& GetPosition() const { return aCellPos; } 873cdf0e10cSrcweir 874cdf0e10cSrcweir void InputEnglishString( const ::rtl::OUString& rText ); 875cdf0e10cSrcweir 876cdf0e10cSrcweir // XText 877cdf0e10cSrcweir virtual void SAL_CALL insertTextContent( const ::com::sun::star::uno::Reference< 878cdf0e10cSrcweir ::com::sun::star::text::XTextRange >& xRange, 879cdf0e10cSrcweir const ::com::sun::star::uno::Reference< 880cdf0e10cSrcweir ::com::sun::star::text::XTextContent >& xContent, 881cdf0e10cSrcweir sal_Bool bAbsorb ) 882cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 883cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 884cdf0e10cSrcweir virtual void SAL_CALL removeTextContent( const ::com::sun::star::uno::Reference< 885cdf0e10cSrcweir ::com::sun::star::text::XTextContent >& xContent ) 886cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 887cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 888cdf0e10cSrcweir 889cdf0e10cSrcweir // XSimpleText 890cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > SAL_CALL 891cdf0e10cSrcweir createTextCursor() throw(::com::sun::star::uno::RuntimeException); 892cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > SAL_CALL 893cdf0e10cSrcweir createTextCursorByRange( const ::com::sun::star::uno::Reference< 894cdf0e10cSrcweir ::com::sun::star::text::XTextRange >& aTextPosition ) 895cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 896cdf0e10cSrcweir virtual void SAL_CALL insertString( const ::com::sun::star::uno::Reference< 897cdf0e10cSrcweir ::com::sun::star::text::XTextRange >& xRange, 898cdf0e10cSrcweir const ::rtl::OUString& aString, sal_Bool bAbsorb ) 899cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 900cdf0e10cSrcweir virtual void SAL_CALL insertControlCharacter( const ::com::sun::star::uno::Reference< 901cdf0e10cSrcweir ::com::sun::star::text::XTextRange >& xRange, 902cdf0e10cSrcweir sal_Int16 nControlCharacter, sal_Bool bAbsorb ) 903cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 904cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 905cdf0e10cSrcweir 906cdf0e10cSrcweir // XTextRange 907cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XText > SAL_CALL 908cdf0e10cSrcweir getText() throw(::com::sun::star::uno::RuntimeException); 909cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > SAL_CALL 910cdf0e10cSrcweir getStart() throw(::com::sun::star::uno::RuntimeException); 911cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > SAL_CALL 912cdf0e10cSrcweir getEnd() throw(::com::sun::star::uno::RuntimeException); 913cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getString() throw(::com::sun::star::uno::RuntimeException); 914cdf0e10cSrcweir virtual void SAL_CALL setString( const ::rtl::OUString& aString ) 915cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 916cdf0e10cSrcweir 917cdf0e10cSrcweir // XEnumerationAccess 918cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL 919cdf0e10cSrcweir createEnumeration() throw(::com::sun::star::uno::RuntimeException); 920cdf0e10cSrcweir 921cdf0e10cSrcweir // XElementAccess 922cdf0e10cSrcweir virtual ::com::sun::star::uno::Type SAL_CALL getElementType() 923cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 924cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException); 925cdf0e10cSrcweir 926cdf0e10cSrcweir // XCell 927cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getFormula() throw(::com::sun::star::uno::RuntimeException); 928cdf0e10cSrcweir virtual void SAL_CALL setFormula( const ::rtl::OUString& aFormula ) 929cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 930cdf0e10cSrcweir virtual double SAL_CALL getValue() throw(::com::sun::star::uno::RuntimeException); 931cdf0e10cSrcweir virtual void SAL_CALL setValue( double nValue ) throw(::com::sun::star::uno::RuntimeException); 932cdf0e10cSrcweir virtual ::com::sun::star::table::CellContentType SAL_CALL getType() 933cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 934cdf0e10cSrcweir virtual sal_Int32 SAL_CALL getError() throw(::com::sun::star::uno::RuntimeException); 935cdf0e10cSrcweir 936cdf0e10cSrcweir // XFormulaTokens 937cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::sheet::FormulaToken > SAL_CALL getTokens() 938cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 939cdf0e10cSrcweir virtual void SAL_CALL setTokens( const ::com::sun::star::uno::Sequence< 940cdf0e10cSrcweir ::com::sun::star::sheet::FormulaToken >& aTokens ) 941cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 942cdf0e10cSrcweir 943cdf0e10cSrcweir // XCellAddressable 944cdf0e10cSrcweir virtual ::com::sun::star::table::CellAddress SAL_CALL getCellAddress() 945cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 946cdf0e10cSrcweir 947cdf0e10cSrcweir // XSheetAnnotationAnchor 948cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetAnnotation > SAL_CALL 949cdf0e10cSrcweir getAnnotation() throw(::com::sun::star::uno::RuntimeException); 950cdf0e10cSrcweir 951cdf0e10cSrcweir // XTextFieldsSupplier 952cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumerationAccess > SAL_CALL 953cdf0e10cSrcweir getTextFields() throw(::com::sun::star::uno::RuntimeException); 954cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > SAL_CALL 955cdf0e10cSrcweir getTextFieldMasters() throw(::com::sun::star::uno::RuntimeException); 956cdf0e10cSrcweir 957cdf0e10cSrcweir // XPropertySet ueberladen wegen Zell-Properties 958cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 959cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 960cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 961cdf0e10cSrcweir 962cdf0e10cSrcweir // XServiceInfo 963cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 964cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 965cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 966cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 967cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 968cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 969cdf0e10cSrcweir 970cdf0e10cSrcweir // XTypeProvider 971cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 972cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 973cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 974cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 975cdf0e10cSrcweir 976cdf0e10cSrcweir // XActionLockable 977cdf0e10cSrcweir virtual sal_Bool SAL_CALL isActionLocked() throw(::com::sun::star::uno::RuntimeException); 978cdf0e10cSrcweir virtual void SAL_CALL addActionLock() throw(::com::sun::star::uno::RuntimeException); 979cdf0e10cSrcweir virtual void SAL_CALL removeActionLock() throw(::com::sun::star::uno::RuntimeException); 980cdf0e10cSrcweir virtual void SAL_CALL setActionLocks( sal_Int16 nLock ) 981cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 982cdf0e10cSrcweir virtual sal_Int16 SAL_CALL resetActionLocks() throw(::com::sun::star::uno::RuntimeException); 983cdf0e10cSrcweir 984cdf0e10cSrcweir static String GetOutputString_Impl(ScDocument* pDoc, const ScAddress& aPos); 985cdf0e10cSrcweir }; 986cdf0e10cSrcweir 987cdf0e10cSrcweir 988cdf0e10cSrcweir class ScTableSheetObj : public ScCellRangeObj, 989cdf0e10cSrcweir public com::sun::star::sheet::XSpreadsheet, 990cdf0e10cSrcweir public com::sun::star::container::XNamed, 991cdf0e10cSrcweir public com::sun::star::sheet::XSheetPageBreak, 992cdf0e10cSrcweir public com::sun::star::sheet::XCellRangeMovement, 993cdf0e10cSrcweir public com::sun::star::table::XTableChartsSupplier, 994cdf0e10cSrcweir public com::sun::star::sheet::XDataPilotTablesSupplier, 995cdf0e10cSrcweir public com::sun::star::sheet::XScenariosSupplier, 996cdf0e10cSrcweir public com::sun::star::sheet::XSheetAnnotationsSupplier, 997cdf0e10cSrcweir public com::sun::star::drawing::XDrawPageSupplier, 998cdf0e10cSrcweir public com::sun::star::sheet::XPrintAreas, 999cdf0e10cSrcweir public com::sun::star::sheet::XSheetLinkable, 1000cdf0e10cSrcweir public com::sun::star::sheet::XSheetAuditing, 1001cdf0e10cSrcweir public com::sun::star::sheet::XSheetOutline, 1002cdf0e10cSrcweir public com::sun::star::util::XProtectable, 1003cdf0e10cSrcweir public com::sun::star::sheet::XScenario, 1004cdf0e10cSrcweir public com::sun::star::sheet::XScenarioEnhanced, 1005cdf0e10cSrcweir public com::sun::star::sheet::XExternalSheetName, 1006cdf0e10cSrcweir public com::sun::star::document::XEventsSupplier 1007cdf0e10cSrcweir { 1008cdf0e10cSrcweir friend class ScTableSheetsObj; // fuer insertByName() 1009cdf0e10cSrcweir 1010cdf0e10cSrcweir private: 1011cdf0e10cSrcweir const SfxItemPropertySet* pSheetPropSet; 1012cdf0e10cSrcweir 1013cdf0e10cSrcweir SCTAB GetTab_Impl() const; 1014cdf0e10cSrcweir void PrintAreaUndo_Impl( ScPrintRangeSaver* pOldRanges ); 1015cdf0e10cSrcweir 1016cdf0e10cSrcweir protected: 1017cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 1018cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1019cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 1020cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1021cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1022cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 1023cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 1024cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1025cdf0e10cSrcweir 1026cdf0e10cSrcweir public: 1027cdf0e10cSrcweir ScTableSheetObj(ScDocShell* pDocSh, SCTAB nTab); 1028cdf0e10cSrcweir virtual ~ScTableSheetObj(); 1029cdf0e10cSrcweir 1030cdf0e10cSrcweir void InitInsertSheet(ScDocShell* pDocSh, SCTAB nTab); 1031cdf0e10cSrcweir 1032cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 1033cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 1034cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1035cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 1036cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 1037cdf0e10cSrcweir 1038cdf0e10cSrcweir // XSpreadsheet 1039cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellCursor > 1040cdf0e10cSrcweir SAL_CALL createCursor() throw(::com::sun::star::uno::RuntimeException); 1041cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetCellCursor > SAL_CALL 1042cdf0e10cSrcweir createCursorByRange( const ::com::sun::star::uno::Reference< 1043cdf0e10cSrcweir ::com::sun::star::sheet::XSheetCellRange >& aRange ) 1044cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1045cdf0e10cSrcweir 1046cdf0e10cSrcweir // XSheetCellRange 1047cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSpreadsheet > SAL_CALL 1048cdf0e10cSrcweir getSpreadsheet() throw(::com::sun::star::uno::RuntimeException); 1049cdf0e10cSrcweir 1050cdf0e10cSrcweir // XCellRange 1051cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCell > SAL_CALL 1052cdf0e10cSrcweir getCellByPosition( sal_Int32 nColumn, sal_Int32 nRow ) 1053cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 1054cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1055cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCellRange > SAL_CALL 1056cdf0e10cSrcweir getCellRangeByPosition( sal_Int32 nLeft, sal_Int32 nTop, 1057cdf0e10cSrcweir sal_Int32 nRight, sal_Int32 nBottom ) 1058cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 1059cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1060cdf0e10cSrcweir using ScCellRangeObj::getCellRangeByName; 1061cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XCellRange > SAL_CALL 1062cdf0e10cSrcweir getCellRangeByName( const ::rtl::OUString& aRange ) 1063cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1064cdf0e10cSrcweir 1065cdf0e10cSrcweir // XNamed 1066cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getName() throw(::com::sun::star::uno::RuntimeException); 1067cdf0e10cSrcweir virtual void SAL_CALL setName( const ::rtl::OUString& aName ) 1068cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1069cdf0e10cSrcweir 1070cdf0e10cSrcweir // XSheetPageBreak 1071cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::sheet::TablePageBreakData > SAL_CALL 1072cdf0e10cSrcweir getColumnPageBreaks() throw(::com::sun::star::uno::RuntimeException); 1073cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::sheet::TablePageBreakData > SAL_CALL 1074cdf0e10cSrcweir getRowPageBreaks() throw(::com::sun::star::uno::RuntimeException); 1075cdf0e10cSrcweir virtual void SAL_CALL removeAllManualPageBreaks() throw(::com::sun::star::uno::RuntimeException); 1076cdf0e10cSrcweir 1077cdf0e10cSrcweir // XCellRangeMovement 1078cdf0e10cSrcweir virtual void SAL_CALL insertCells( const ::com::sun::star::table::CellRangeAddress& aRange, 1079cdf0e10cSrcweir ::com::sun::star::sheet::CellInsertMode nMode ) 1080cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1081cdf0e10cSrcweir virtual void SAL_CALL removeRange( const ::com::sun::star::table::CellRangeAddress& aRange, 1082cdf0e10cSrcweir ::com::sun::star::sheet::CellDeleteMode nMode ) 1083cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1084cdf0e10cSrcweir virtual void SAL_CALL moveRange( const ::com::sun::star::table::CellAddress& aDestination, 1085cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aSource ) 1086cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1087cdf0e10cSrcweir virtual void SAL_CALL copyRange( const ::com::sun::star::table::CellAddress& aDestination, 1088cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aSource ) 1089cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1090cdf0e10cSrcweir 1091cdf0e10cSrcweir // XTableChartsSupplier 1092cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::table::XTableCharts > SAL_CALL 1093cdf0e10cSrcweir getCharts() throw(::com::sun::star::uno::RuntimeException); 1094cdf0e10cSrcweir 1095cdf0e10cSrcweir // XDataPilotTablesSupplier 1096cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XDataPilotTables > SAL_CALL 1097cdf0e10cSrcweir getDataPilotTables() throw(::com::sun::star::uno::RuntimeException); 1098cdf0e10cSrcweir 1099cdf0e10cSrcweir // XScenariosSupplier 1100cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XScenarios > SAL_CALL 1101cdf0e10cSrcweir getScenarios() throw(::com::sun::star::uno::RuntimeException); 1102cdf0e10cSrcweir 1103cdf0e10cSrcweir // XSheetAnnotationsSupplier 1104cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XSheetAnnotations > SAL_CALL 1105cdf0e10cSrcweir getAnnotations() throw(::com::sun::star::uno::RuntimeException); 1106cdf0e10cSrcweir 1107cdf0e10cSrcweir // XDrawPageSupplier 1108cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawPage > SAL_CALL 1109cdf0e10cSrcweir getDrawPage() throw(::com::sun::star::uno::RuntimeException); 1110cdf0e10cSrcweir 1111cdf0e10cSrcweir // XPrintAreas 1112cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::table::CellRangeAddress > SAL_CALL 1113cdf0e10cSrcweir getPrintAreas() throw(::com::sun::star::uno::RuntimeException); 1114cdf0e10cSrcweir virtual void SAL_CALL setPrintAreas( const ::com::sun::star::uno::Sequence< 1115cdf0e10cSrcweir ::com::sun::star::table::CellRangeAddress >& aPrintAreas ) 1116cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1117cdf0e10cSrcweir virtual sal_Bool SAL_CALL getPrintTitleColumns() throw(::com::sun::star::uno::RuntimeException); 1118cdf0e10cSrcweir virtual void SAL_CALL setPrintTitleColumns( sal_Bool bPrintTitleColumns ) 1119cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1120cdf0e10cSrcweir virtual ::com::sun::star::table::CellRangeAddress SAL_CALL getTitleColumns() 1121cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1122cdf0e10cSrcweir virtual void SAL_CALL setTitleColumns( 1123cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aTitleColumns ) 1124cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1125cdf0e10cSrcweir virtual sal_Bool SAL_CALL getPrintTitleRows() throw(::com::sun::star::uno::RuntimeException); 1126cdf0e10cSrcweir virtual void SAL_CALL setPrintTitleRows( sal_Bool bPrintTitleRows ) 1127cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1128cdf0e10cSrcweir virtual ::com::sun::star::table::CellRangeAddress SAL_CALL getTitleRows() 1129cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1130cdf0e10cSrcweir virtual void SAL_CALL setTitleRows( 1131cdf0e10cSrcweir const ::com::sun::star::table::CellRangeAddress& aTitleRows ) 1132cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1133cdf0e10cSrcweir 1134cdf0e10cSrcweir // XSheetLinkable 1135cdf0e10cSrcweir virtual ::com::sun::star::sheet::SheetLinkMode SAL_CALL getLinkMode() 1136cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1137cdf0e10cSrcweir virtual void SAL_CALL setLinkMode( ::com::sun::star::sheet::SheetLinkMode nLinkMode ) 1138cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1139cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getLinkUrl() throw(::com::sun::star::uno::RuntimeException); 1140cdf0e10cSrcweir virtual void SAL_CALL setLinkUrl( const ::rtl::OUString& aLinkUrl ) 1141cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1142cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getLinkSheetName() throw(::com::sun::star::uno::RuntimeException); 1143cdf0e10cSrcweir virtual void SAL_CALL setLinkSheetName( const ::rtl::OUString& aLinkSheetName ) 1144cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1145cdf0e10cSrcweir virtual void SAL_CALL link( const ::rtl::OUString& aUrl, 1146cdf0e10cSrcweir const ::rtl::OUString& aSheetName, 1147cdf0e10cSrcweir const ::rtl::OUString& aFilterName, 1148cdf0e10cSrcweir const ::rtl::OUString& aFilterOptions, 1149cdf0e10cSrcweir ::com::sun::star::sheet::SheetLinkMode nMode ) 1150cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1151cdf0e10cSrcweir 1152cdf0e10cSrcweir // XSheetAuditing 1153cdf0e10cSrcweir virtual sal_Bool SAL_CALL hideDependents( const ::com::sun::star::table::CellAddress& aPosition ) 1154cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1155cdf0e10cSrcweir virtual sal_Bool SAL_CALL hidePrecedents( const ::com::sun::star::table::CellAddress& aPosition ) 1156cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1157cdf0e10cSrcweir virtual sal_Bool SAL_CALL showDependents( const ::com::sun::star::table::CellAddress& aPosition ) 1158cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1159cdf0e10cSrcweir virtual sal_Bool SAL_CALL showPrecedents( const ::com::sun::star::table::CellAddress& aPosition ) 1160cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1161cdf0e10cSrcweir virtual sal_Bool SAL_CALL showErrors( const ::com::sun::star::table::CellAddress& aPosition ) 1162cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1163cdf0e10cSrcweir virtual sal_Bool SAL_CALL showInvalid() throw(::com::sun::star::uno::RuntimeException); 1164cdf0e10cSrcweir virtual void SAL_CALL clearArrows() throw(::com::sun::star::uno::RuntimeException); 1165cdf0e10cSrcweir 1166cdf0e10cSrcweir // XSheetOutline 1167cdf0e10cSrcweir virtual void SAL_CALL group( const ::com::sun::star::table::CellRangeAddress& aRange, 1168cdf0e10cSrcweir ::com::sun::star::table::TableOrientation nOrientation ) 1169cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1170cdf0e10cSrcweir virtual void SAL_CALL ungroup( const ::com::sun::star::table::CellRangeAddress& aRange, 1171cdf0e10cSrcweir ::com::sun::star::table::TableOrientation nOrientation ) 1172cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1173cdf0e10cSrcweir virtual void SAL_CALL autoOutline( const ::com::sun::star::table::CellRangeAddress& aRange ) 1174cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1175cdf0e10cSrcweir virtual void SAL_CALL clearOutline() throw(::com::sun::star::uno::RuntimeException); 1176cdf0e10cSrcweir virtual void SAL_CALL hideDetail( const ::com::sun::star::table::CellRangeAddress& aRange ) 1177cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1178cdf0e10cSrcweir virtual void SAL_CALL showDetail( const ::com::sun::star::table::CellRangeAddress& aRange ) 1179cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1180cdf0e10cSrcweir virtual void SAL_CALL showLevel( sal_Int16 nLevel, 1181cdf0e10cSrcweir ::com::sun::star::table::TableOrientation nOrientation ) 1182cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1183cdf0e10cSrcweir 1184cdf0e10cSrcweir // XProtectable 1185cdf0e10cSrcweir virtual void SAL_CALL protect( const ::rtl::OUString& aPassword ) 1186cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1187cdf0e10cSrcweir virtual void SAL_CALL unprotect( const ::rtl::OUString& aPassword ) 1188cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 1189cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1190cdf0e10cSrcweir virtual sal_Bool SAL_CALL isProtected() throw(::com::sun::star::uno::RuntimeException); 1191cdf0e10cSrcweir 1192cdf0e10cSrcweir // XScenario 1193cdf0e10cSrcweir virtual sal_Bool SAL_CALL getIsScenario() throw(::com::sun::star::uno::RuntimeException); 1194cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getScenarioComment() throw(::com::sun::star::uno::RuntimeException); 1195cdf0e10cSrcweir virtual void SAL_CALL setScenarioComment( const ::rtl::OUString& aScenarioComment ) 1196cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1197cdf0e10cSrcweir virtual void SAL_CALL addRanges( const ::com::sun::star::uno::Sequence< 1198cdf0e10cSrcweir ::com::sun::star::table::CellRangeAddress >& aRanges ) 1199cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1200cdf0e10cSrcweir virtual void SAL_CALL apply() throw(::com::sun::star::uno::RuntimeException); 1201cdf0e10cSrcweir // XScenarioEnhanced 1202cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::table::CellRangeAddress > SAL_CALL 1203cdf0e10cSrcweir getRanges( ) 1204cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1205cdf0e10cSrcweir 1206cdf0e10cSrcweir // XExternalSheetName 1207cdf0e10cSrcweir virtual void SAL_CALL setExternalName( const ::rtl::OUString& aUrl, const ::rtl::OUString& aSheetName ) 1208cdf0e10cSrcweir throw (::com::sun::star::container::ElementExistException, 1209cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1210cdf0e10cSrcweir 1211cdf0e10cSrcweir // XEventsSupplier 1212cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > SAL_CALL getEvents() 1213cdf0e10cSrcweir throw (::com::sun::star::uno::RuntimeException); 1214cdf0e10cSrcweir 1215cdf0e10cSrcweir // XPropertySet ueberladen wegen Sheet-Properties 1216cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 1217cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 1218cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1219cdf0e10cSrcweir 1220cdf0e10cSrcweir // XServiceInfo 1221cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1222cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1223cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1224cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1225cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1226cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1227cdf0e10cSrcweir 1228cdf0e10cSrcweir // XUnoTunnel 1229cdf0e10cSrcweir virtual sal_Int64 SAL_CALL getSomething( const ::com::sun::star::uno::Sequence< 1230cdf0e10cSrcweir sal_Int8 >& aIdentifier ) 1231cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1232cdf0e10cSrcweir 1233cdf0e10cSrcweir static const com::sun::star::uno::Sequence<sal_Int8>& getUnoTunnelId(); 1234cdf0e10cSrcweir static ScTableSheetObj* getImplementation( const com::sun::star::uno::Reference< 1235cdf0e10cSrcweir com::sun::star::uno::XInterface> xObj ); 1236cdf0e10cSrcweir 1237cdf0e10cSrcweir // XTypeProvider 1238cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 1239cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1240cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 1241cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1242cdf0e10cSrcweir }; 1243cdf0e10cSrcweir 1244cdf0e10cSrcweir 1245cdf0e10cSrcweir class ScTableColumnObj : public ScCellRangeObj, 1246cdf0e10cSrcweir public com::sun::star::container::XNamed 1247cdf0e10cSrcweir { 1248cdf0e10cSrcweir private: 1249cdf0e10cSrcweir const SfxItemPropertySet* pColPropSet; 1250cdf0e10cSrcweir 1251cdf0e10cSrcweir protected: 1252cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 1253cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1254cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 1255cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1256cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1257cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 1258cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 1259cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1260cdf0e10cSrcweir 1261cdf0e10cSrcweir public: 1262cdf0e10cSrcweir ScTableColumnObj(ScDocShell* pDocSh, SCCOL nCol, SCTAB nTab); 1263cdf0e10cSrcweir virtual ~ScTableColumnObj(); 1264cdf0e10cSrcweir 1265cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( 1266cdf0e10cSrcweir const ::com::sun::star::uno::Type & rType ) 1267cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1268cdf0e10cSrcweir virtual void SAL_CALL acquire() throw(); 1269cdf0e10cSrcweir virtual void SAL_CALL release() throw(); 1270cdf0e10cSrcweir 1271cdf0e10cSrcweir // XNamed 1272cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getName() throw(::com::sun::star::uno::RuntimeException); 1273cdf0e10cSrcweir virtual void SAL_CALL setName( const ::rtl::OUString& aName ) 1274cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1275cdf0e10cSrcweir 1276cdf0e10cSrcweir // XPropertySet ueberladen wegen Spalten-Properties 1277cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 1278cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 1279cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1280cdf0e10cSrcweir 1281cdf0e10cSrcweir // XServiceInfo 1282cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1283cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1284cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1285cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1286cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1287cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1288cdf0e10cSrcweir 1289cdf0e10cSrcweir // XTypeProvider 1290cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() 1291cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1292cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() 1293cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1294cdf0e10cSrcweir }; 1295cdf0e10cSrcweir 1296cdf0e10cSrcweir 1297cdf0e10cSrcweir class ScTableRowObj : public ScCellRangeObj 1298cdf0e10cSrcweir { 1299cdf0e10cSrcweir private: 1300cdf0e10cSrcweir const SfxItemPropertySet* pRowPropSet; 1301cdf0e10cSrcweir 1302cdf0e10cSrcweir protected: 1303cdf0e10cSrcweir virtual const SfxItemPropertyMap* GetItemPropertyMap(); 1304cdf0e10cSrcweir virtual void GetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1305cdf0e10cSrcweir ::com::sun::star::uno::Any& ) 1306cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1307cdf0e10cSrcweir virtual void SetOnePropertyValue( const SfxItemPropertySimpleEntry* pEntry, 1308cdf0e10cSrcweir const ::com::sun::star::uno::Any& aValue ) 1309cdf0e10cSrcweir throw(::com::sun::star::lang::IllegalArgumentException, 1310cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1311cdf0e10cSrcweir 1312cdf0e10cSrcweir public: 1313cdf0e10cSrcweir ScTableRowObj(ScDocShell* pDocSh, SCROW nRow, SCTAB nTab); 1314cdf0e10cSrcweir virtual ~ScTableRowObj(); 1315cdf0e10cSrcweir 1316cdf0e10cSrcweir // XPropertySet ueberladen wegen Zeilen-Properties 1317cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > 1318cdf0e10cSrcweir SAL_CALL getPropertySetInfo() 1319cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1320cdf0e10cSrcweir 1321cdf0e10cSrcweir // XServiceInfo 1322cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1323cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1324cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1325cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1326cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1327cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1328cdf0e10cSrcweir }; 1329cdf0e10cSrcweir 1330cdf0e10cSrcweir 1331cdf0e10cSrcweir class ScCellsObj : public cppu::WeakImplHelper2< 1332cdf0e10cSrcweir com::sun::star::container::XEnumerationAccess, 1333cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1334cdf0e10cSrcweir public SfxListener 1335cdf0e10cSrcweir { 1336cdf0e10cSrcweir private: 1337cdf0e10cSrcweir ScDocShell* pDocShell; 1338cdf0e10cSrcweir ScRangeList aRanges; 1339cdf0e10cSrcweir 1340cdf0e10cSrcweir public: 1341cdf0e10cSrcweir ScCellsObj(ScDocShell* pDocSh, const ScRangeList& rR); 1342cdf0e10cSrcweir virtual ~ScCellsObj(); 1343cdf0e10cSrcweir 1344cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1345cdf0e10cSrcweir 1346cdf0e10cSrcweir // XEnumerationAccess 1347cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL 1348cdf0e10cSrcweir createEnumeration() throw(::com::sun::star::uno::RuntimeException); 1349cdf0e10cSrcweir 1350cdf0e10cSrcweir // XElementAccess 1351cdf0e10cSrcweir virtual ::com::sun::star::uno::Type SAL_CALL getElementType() 1352cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1353cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException); 1354cdf0e10cSrcweir 1355cdf0e10cSrcweir // XServiceInfo 1356cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1357cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1358cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1359cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1360cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1361cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1362cdf0e10cSrcweir }; 1363cdf0e10cSrcweir 1364cdf0e10cSrcweir 1365cdf0e10cSrcweir class ScCellsEnumeration : public cppu::WeakImplHelper2< 1366cdf0e10cSrcweir com::sun::star::container::XEnumeration, 1367cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1368cdf0e10cSrcweir public SfxListener 1369cdf0e10cSrcweir { 1370cdf0e10cSrcweir private: 1371cdf0e10cSrcweir ScDocShell* pDocShell; 1372cdf0e10cSrcweir ScRangeList aRanges; 1373cdf0e10cSrcweir ScAddress aPos; 1374cdf0e10cSrcweir ScMarkData* pMark; 1375cdf0e10cSrcweir sal_Bool bAtEnd; 1376cdf0e10cSrcweir 1377cdf0e10cSrcweir private: 1378cdf0e10cSrcweir void Advance_Impl(); 1379cdf0e10cSrcweir void CheckPos_Impl(); 1380cdf0e10cSrcweir 1381cdf0e10cSrcweir public: 1382cdf0e10cSrcweir ScCellsEnumeration(ScDocShell* pDocSh, const ScRangeList& rR); 1383cdf0e10cSrcweir virtual ~ScCellsEnumeration(); 1384cdf0e10cSrcweir 1385cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1386cdf0e10cSrcweir 1387cdf0e10cSrcweir // XEnumeration 1388cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasMoreElements() throw(::com::sun::star::uno::RuntimeException); 1389cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL nextElement() 1390cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 1391cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 1392cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1393cdf0e10cSrcweir 1394cdf0e10cSrcweir // XServiceInfo 1395cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1396cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1397cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1398cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1399cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1400cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1401cdf0e10cSrcweir }; 1402cdf0e10cSrcweir 1403cdf0e10cSrcweir class ScCellFormatsObj : public cppu::WeakImplHelper3< 1404cdf0e10cSrcweir com::sun::star::container::XIndexAccess, 1405cdf0e10cSrcweir com::sun::star::container::XEnumerationAccess, 1406cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1407cdf0e10cSrcweir public SfxListener 1408cdf0e10cSrcweir { 1409cdf0e10cSrcweir private: 1410cdf0e10cSrcweir ScDocShell* pDocShell; 1411cdf0e10cSrcweir ScRange aTotalRange; 1412cdf0e10cSrcweir 1413cdf0e10cSrcweir private: 1414cdf0e10cSrcweir ScCellRangeObj* GetObjectByIndex_Impl(long nIndex) const; 1415cdf0e10cSrcweir 1416cdf0e10cSrcweir public: 1417cdf0e10cSrcweir ScCellFormatsObj(ScDocShell* pDocSh, const ScRange& rR); 1418cdf0e10cSrcweir virtual ~ScCellFormatsObj(); 1419cdf0e10cSrcweir 1420cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1421cdf0e10cSrcweir 1422cdf0e10cSrcweir // XIndexAccess 1423cdf0e10cSrcweir virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException); 1424cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index ) 1425cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 1426cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 1427cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1428cdf0e10cSrcweir 1429cdf0e10cSrcweir // XEnumerationAccess 1430cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL 1431cdf0e10cSrcweir createEnumeration() throw(::com::sun::star::uno::RuntimeException); 1432cdf0e10cSrcweir 1433cdf0e10cSrcweir // XElementAccess 1434cdf0e10cSrcweir virtual ::com::sun::star::uno::Type SAL_CALL getElementType() 1435cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1436cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException); 1437cdf0e10cSrcweir 1438cdf0e10cSrcweir // XServiceInfo 1439cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1440cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1441cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1442cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1443cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1444cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1445cdf0e10cSrcweir }; 1446cdf0e10cSrcweir 1447cdf0e10cSrcweir 1448cdf0e10cSrcweir class ScCellFormatsEnumeration : public cppu::WeakImplHelper2< 1449cdf0e10cSrcweir com::sun::star::container::XEnumeration, 1450cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1451cdf0e10cSrcweir public SfxListener 1452cdf0e10cSrcweir { 1453cdf0e10cSrcweir private: 1454cdf0e10cSrcweir ScDocShell* pDocShell; 1455cdf0e10cSrcweir SCTAB nTab; 1456cdf0e10cSrcweir ScAttrRectIterator* pIter; 1457cdf0e10cSrcweir ScRange aNext; 1458cdf0e10cSrcweir sal_Bool bAtEnd; 1459cdf0e10cSrcweir sal_Bool bDirty; 1460cdf0e10cSrcweir 1461cdf0e10cSrcweir private: 1462cdf0e10cSrcweir void Advance_Impl(); 1463cdf0e10cSrcweir ScCellRangeObj* NextObject_Impl(); 1464cdf0e10cSrcweir 1465cdf0e10cSrcweir public: 1466cdf0e10cSrcweir ScCellFormatsEnumeration(ScDocShell* pDocSh, const ScRange& rR); 1467cdf0e10cSrcweir virtual ~ScCellFormatsEnumeration(); 1468cdf0e10cSrcweir 1469cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1470cdf0e10cSrcweir 1471cdf0e10cSrcweir // XEnumeration 1472cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasMoreElements() throw(::com::sun::star::uno::RuntimeException); 1473cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL nextElement() 1474cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 1475cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 1476cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1477cdf0e10cSrcweir 1478cdf0e10cSrcweir // XServiceInfo 1479cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1480cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1481cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1482cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1483cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1484cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1485cdf0e10cSrcweir }; 1486cdf0e10cSrcweir 1487cdf0e10cSrcweir typedef std::vector< ScRangeList > ScMyRangeLists; 1488cdf0e10cSrcweir 1489cdf0e10cSrcweir class ScUniqueCellFormatsObj : public cppu::WeakImplHelper3< 1490cdf0e10cSrcweir com::sun::star::container::XIndexAccess, 1491cdf0e10cSrcweir com::sun::star::container::XEnumerationAccess, 1492cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1493cdf0e10cSrcweir public SfxListener 1494cdf0e10cSrcweir { 1495cdf0e10cSrcweir private: 1496cdf0e10cSrcweir ScDocShell* pDocShell; 1497cdf0e10cSrcweir ScRange aTotalRange; 1498cdf0e10cSrcweir ScMyRangeLists aRangeLists; 1499cdf0e10cSrcweir 1500cdf0e10cSrcweir private: 1501cdf0e10cSrcweir void GetObjects_Impl(); 1502cdf0e10cSrcweir 1503cdf0e10cSrcweir public: 1504cdf0e10cSrcweir ScUniqueCellFormatsObj(ScDocShell* pDocSh, const ScRange& rR); 1505cdf0e10cSrcweir virtual ~ScUniqueCellFormatsObj(); 1506cdf0e10cSrcweir 1507cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1508cdf0e10cSrcweir 1509cdf0e10cSrcweir // XIndexAccess 1510cdf0e10cSrcweir virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException); 1511cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index ) 1512cdf0e10cSrcweir throw(::com::sun::star::lang::IndexOutOfBoundsException, 1513cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 1514cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1515cdf0e10cSrcweir 1516cdf0e10cSrcweir // XEnumerationAccess 1517cdf0e10cSrcweir virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL 1518cdf0e10cSrcweir createEnumeration() throw(::com::sun::star::uno::RuntimeException); 1519cdf0e10cSrcweir 1520cdf0e10cSrcweir // XElementAccess 1521cdf0e10cSrcweir virtual ::com::sun::star::uno::Type SAL_CALL getElementType() 1522cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1523cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException); 1524cdf0e10cSrcweir 1525cdf0e10cSrcweir // XServiceInfo 1526cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1527cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1528cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1529cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1530cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1531cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1532cdf0e10cSrcweir }; 1533cdf0e10cSrcweir 1534cdf0e10cSrcweir class ScUniqueCellFormatsEnumeration : public cppu::WeakImplHelper2< 1535cdf0e10cSrcweir com::sun::star::container::XEnumeration, 1536cdf0e10cSrcweir com::sun::star::lang::XServiceInfo >, 1537cdf0e10cSrcweir public SfxListener 1538cdf0e10cSrcweir { 1539cdf0e10cSrcweir private: 1540cdf0e10cSrcweir ScMyRangeLists aRangeLists; 1541cdf0e10cSrcweir ScDocShell* pDocShell; 1542cdf0e10cSrcweir sal_Int32 nCurrentPosition; 1543cdf0e10cSrcweir 1544cdf0e10cSrcweir public: 1545cdf0e10cSrcweir ScUniqueCellFormatsEnumeration(ScDocShell* pDocShell, const ScMyRangeLists& rRangeLists); 1546cdf0e10cSrcweir virtual ~ScUniqueCellFormatsEnumeration(); 1547cdf0e10cSrcweir 1548cdf0e10cSrcweir virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ); 1549cdf0e10cSrcweir 1550cdf0e10cSrcweir // XEnumeration 1551cdf0e10cSrcweir virtual sal_Bool SAL_CALL hasMoreElements() throw(::com::sun::star::uno::RuntimeException); 1552cdf0e10cSrcweir virtual ::com::sun::star::uno::Any SAL_CALL nextElement() 1553cdf0e10cSrcweir throw(::com::sun::star::container::NoSuchElementException, 1554cdf0e10cSrcweir ::com::sun::star::lang::WrappedTargetException, 1555cdf0e10cSrcweir ::com::sun::star::uno::RuntimeException); 1556cdf0e10cSrcweir 1557cdf0e10cSrcweir // XServiceInfo 1558cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName() 1559cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1560cdf0e10cSrcweir virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) 1561cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1562cdf0e10cSrcweir virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames() 1563cdf0e10cSrcweir throw(::com::sun::star::uno::RuntimeException); 1564cdf0e10cSrcweir }; 1565cdf0e10cSrcweir 1566cdf0e10cSrcweir 1567cdf0e10cSrcweir #endif 1568cdf0e10cSrcweir 1569