genericpropertyset.cxx (dde7d3fa) | genericpropertyset.cxx (49b34792) |
---|---|
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 --- 100 unchanged lines hidden (view full) --- 109GenericPropertySet::~GenericPropertySet() throw() 110{ 111} 112void SAL_CALL GenericPropertySet::addPropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< XPropertyChangeListener >& xListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 113{ 114 Reference < XPropertySetInfo > xInfo = getPropertySetInfo( ); 115 if ( xInfo.is() ) 116 { | 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 --- 100 unchanged lines hidden (view full) --- 109GenericPropertySet::~GenericPropertySet() throw() 110{ 111} 112void SAL_CALL GenericPropertySet::addPropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< XPropertyChangeListener >& xListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 113{ 114 Reference < XPropertySetInfo > xInfo = getPropertySetInfo( ); 115 if ( xInfo.is() ) 116 { |
117 if ( !aPropertyName.getLength() ) | 117 if ( aPropertyName.isEmpty() ) |
118 { 119 Sequence< Property> aSeq = xInfo->getProperties(); 120 const Property* pIter = aSeq.getConstArray(); 121 const Property* pEnd = pIter + aSeq.getLength(); 122 for( ; pIter != pEnd ; ++pIter) 123 { 124 m_aListener.addInterface(pIter->Name,xListener); 125 } --- 7 unchanged lines hidden (view full) --- 133 134void SAL_CALL GenericPropertySet::removePropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< XPropertyChangeListener >& xListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 135{ 136 ResettableMutexGuard aGuard( maMutex ); 137 Reference < XPropertySetInfo > xInfo = getPropertySetInfo( ); 138 aGuard.clear(); 139 if ( xInfo.is() ) 140 { | 118 { 119 Sequence< Property> aSeq = xInfo->getProperties(); 120 const Property* pIter = aSeq.getConstArray(); 121 const Property* pEnd = pIter + aSeq.getLength(); 122 for( ; pIter != pEnd ; ++pIter) 123 { 124 m_aListener.addInterface(pIter->Name,xListener); 125 } --- 7 unchanged lines hidden (view full) --- 133 134void SAL_CALL GenericPropertySet::removePropertyChangeListener( const ::rtl::OUString& aPropertyName, const Reference< XPropertyChangeListener >& xListener ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) 135{ 136 ResettableMutexGuard aGuard( maMutex ); 137 Reference < XPropertySetInfo > xInfo = getPropertySetInfo( ); 138 aGuard.clear(); 139 if ( xInfo.is() ) 140 { |
141 if ( !aPropertyName.getLength() ) | 141 if ( aPropertyName.isEmpty() ) |
142 { 143 Sequence< Property> aSeq = xInfo->getProperties(); 144 const Property* pIter = aSeq.getConstArray(); 145 const Property* pEnd = pIter + aSeq.getLength(); 146 for( ; pIter != pEnd ; ++pIter) 147 { 148 m_aListener.removeInterface(pIter->Name,xListener); 149 } --- 148 unchanged lines hidden --- | 142 { 143 Sequence< Property> aSeq = xInfo->getProperties(); 144 const Property* pIter = aSeq.getConstArray(); 145 const Property* pEnd = pIter + aSeq.getLength(); 146 for( ; pIter != pEnd ; ++pIter) 147 { 148 m_aListener.removeInterface(pIter->Name,xListener); 149 } --- 148 unchanged lines hidden --- |