20#include <com/sun/star/container/XNameContainer.hpp>
21#include <com/sun/star/xml/AttributeData.hpp>
22#include <com/sun/star/uno/Any.hxx>
42 Reference< XNameContainer > xContainer1;
43 Reference< XNameContainer > xContainer2;
45 if( ( r1 >>= xContainer1 ) && ( r2 >>= xContainer2 ) )
47 const uno::Sequence< OUString > aAttribNames1( xContainer1->getElementNames() );
48 uno::Sequence< OUString > aAttribNames2( xContainer2->getElementNames() );
50 if( aAttribNames1.getLength() == aAttribNames2.getLength() )
52 xml::AttributeData aData1;
53 xml::AttributeData aData2;
55 for(
const OUString& rAttribName : aAttribNames1 )
57 if( !xContainer2->hasByName( rAttribName ) )
60 xContainer1->getByName( rAttribName ) >>= aData1;
61 xContainer2->getByName( rAttribName ) >>= aData2;
63 if( ( aData1.Namespace != aData2.Namespace ) ||
64 ( aData1.Type != aData2.Type ) ||
65 ( aData1.Value != aData2.Value ) )
the SvXMLTypeConverter converts values of various types from their internal representation to the tex...
virtual ~XMLAttributeContainerHandler() override
virtual bool equals(const css::uno::Any &r1, const css::uno::Any &r2) const override
Compares two Any's in case of the given XML-data-type.
virtual bool importXML(const OUString &rStrImpValue, css::uno::Any &rValue, const SvXMLUnitConverter &rUnitConverter) const override
Imports the given value according to the XML-data-type corresponding to the derived class.
virtual bool exportXML(OUString &rStrExpValue, const css::uno::Any &rValue, const SvXMLUnitConverter &rUnitConverter) const override
Exports the given value according to the XML-data-type corresponding to the derived class.