1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 24 #ifndef _XMLOFF_XMLCNITM_HXX 25 #define _XMLOFF_XMLCNITM_HXX 26 27 #include <svl/poolitem.hxx> 28 29 class SvXMLNamespaceMap; 30 namespace rtl { class OUString; } 31 32 //============================================================================ 33 34 class SvXMLAttrContainerItem_Impl; 35 36 class SvXMLAttrContainerItem: public SfxPoolItem 37 { 38 SvXMLAttrContainerItem_Impl *pImpl; 39 40 public: 41 TYPEINFO(); 42 43 SvXMLAttrContainerItem( sal_uInt16 nWhich = 0 ); 44 SvXMLAttrContainerItem( const SvXMLAttrContainerItem& ); 45 virtual ~SvXMLAttrContainerItem(); 46 47 virtual int operator==( const SfxPoolItem& ) const; 48 using SfxPoolItem::Compare; 49 virtual int Compare( const SfxPoolItem &rWith ) const; 50 51 virtual SfxItemPresentation GetPresentation( 52 SfxItemPresentation ePresentation, 53 SfxMapUnit eCoreMetric, 54 SfxMapUnit ePresentationMetric, 55 XubString &rText, 56 const IntlWrapper *pIntlWrapper = 0 ) const; 57 58 virtual sal_uInt16 GetVersion( sal_uInt16 nFileFormatVersion ) const; 59 60 virtual sal_Bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ) const; 61 virtual sal_Bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId = 0 ); 62 Clone(SfxItemPool * =0) const63 virtual SfxPoolItem *Clone( SfxItemPool * = 0) const 64 { return new SvXMLAttrContainerItem( *this ); } 65 66 sal_Bool AddAttr( const ::rtl::OUString& rLName, 67 const ::rtl::OUString& rValue ); 68 sal_Bool AddAttr( const ::rtl::OUString& rPrefix, 69 const ::rtl::OUString& rNamespace, 70 const ::rtl::OUString& rLName, 71 const ::rtl::OUString& rValue ); 72 73 sal_uInt16 GetAttrCount() const; 74 ::rtl::OUString GetAttrNamespace( sal_uInt16 i ) const; 75 ::rtl::OUString GetAttrPrefix( sal_uInt16 i ) const; 76 const ::rtl::OUString& GetAttrLName( sal_uInt16 i ) const; 77 const ::rtl::OUString& GetAttrValue( sal_uInt16 i ) const; 78 79 sal_uInt16 GetFirstNamespaceIndex() const; 80 sal_uInt16 GetNextNamespaceIndex( sal_uInt16 nIdx ) const; 81 const ::rtl::OUString& GetNamespace( sal_uInt16 i ) const; 82 const ::rtl::OUString& GetPrefix( sal_uInt16 i ) const; 83 }; 84 85 #endif // _XMLOFF_XMLCNITM_HXX 86 87