diff options
-rw-r--r-- | sax/source/expatwrap/sax_expat.cxx | 2 | ||||
-rw-r--r-- | sax/source/expatwrap/saxwriter.cxx | 2 | ||||
-rw-r--r-- | sax/source/expatwrap/xml2utf.cxx | 4 | ||||
-rw-r--r-- | sax/source/fastparser/fastparser.cxx | 6 | ||||
-rw-r--r-- | sax/source/tools/converter.cxx | 2 | ||||
-rw-r--r-- | sax/source/tools/fastserializer.cxx | 6 | ||||
-rw-r--r-- | scaddins/source/analysis/analysis.cxx | 2 | ||||
-rw-r--r-- | scaddins/source/analysis/analysishelper.cxx | 6 | ||||
-rw-r--r-- | scaddins/source/datefunc/datefunc.cxx | 2 | ||||
-rw-r--r-- | sccomp/source/solver/solver.cxx | 2 | ||||
-rw-r--r-- | scripting/source/basprov/basmethnode.cxx | 2 | ||||
-rw-r--r-- | scripting/source/basprov/basprov.cxx | 6 | ||||
-rw-r--r-- | scripting/source/dlgprov/dlgprov.cxx | 4 | ||||
-rw-r--r-- | scripting/source/protocolhandler/scripthandler.cxx | 2 | ||||
-rw-r--r-- | scripting/source/provider/MasterScriptProvider.cxx | 8 | ||||
-rw-r--r-- | scripting/source/stringresource/stringresource.cxx | 10 | ||||
-rw-r--r-- | scripting/source/vbaevents/eventhelper.cxx | 4 |
17 files changed, 35 insertions, 35 deletions
diff --git a/sax/source/expatwrap/sax_expat.cxx b/sax/source/expatwrap/sax_expat.cxx index bd65a52855f8..7e57583ccccf 100644 --- a/sax/source/expatwrap/sax_expat.cxx +++ b/sax/source/expatwrap/sax_expat.cxx @@ -472,7 +472,7 @@ void SaxExpatParser::parseStream( const InputSource& structSource) } entity.converter.setInputStream( entity.structSource.aInputStream ); - if( entity.structSource.sEncoding.getLength() ) + if( !entity.structSource.sEncoding.isEmpty() ) { entity.converter.setEncoding( OUStringToOString( entity.structSource.sEncoding , RTL_TEXTENCODING_ASCII_US ) ); diff --git a/sax/source/expatwrap/saxwriter.cxx b/sax/source/expatwrap/saxwriter.cxx index f0869b072bc4..3969eb33d779 100644 --- a/sax/source/expatwrap/saxwriter.cxx +++ b/sax/source/expatwrap/saxwriter.cxx @@ -1252,7 +1252,7 @@ void SAXWriter::characters(const OUString& aChars) throw(SAXException, RuntimeE } sal_Bool bThrowException(sal_False); - if( aChars.getLength() ) + if( !aChars.isEmpty() ) { if( m_bIsCDATA ) bThrowException = !mp_SaxWriterHelper->writeString( aChars, sal_False, sal_False ); diff --git a/sax/source/expatwrap/xml2utf.cxx b/sax/source/expatwrap/xml2utf.cxx index b7aa1cad0424..edebc8a8e290 100644 --- a/sax/source/expatwrap/xml2utf.cxx +++ b/sax/source/expatwrap/xml2utf.cxx @@ -93,7 +93,7 @@ sal_Int32 XMLFile2UTFConverter::readAndConvert( Sequence<sal_Int8> &seq , sal_In // read more ! continue; } - if( scanForEncoding( seq ) || m_sEncoding.getLength() ) { + if( scanForEncoding( seq ) || !m_sEncoding.isEmpty() ) { // initialize decoding initializeDecoding(); } @@ -340,7 +340,7 @@ sal_Bool XMLFile2UTFConverter::scanForEncoding( Sequence< sal_Int8 > &seq ) void XMLFile2UTFConverter::initializeDecoding() { - if( m_sEncoding.getLength() ) + if( !m_sEncoding.isEmpty() ) { rtl_TextEncoding encoding = rtl_getTextEncodingFromMimeCharset( m_sEncoding.getStr() ); if( encoding != RTL_TEXTENCODING_UTF8 ) diff --git a/sax/source/fastparser/fastparser.cxx b/sax/source/fastparser/fastparser.cxx index df7dcfcb36f1..3480628813f0 100644 --- a/sax/source/fastparser/fastparser.cxx +++ b/sax/source/fastparser/fastparser.cxx @@ -446,7 +446,7 @@ void FastSaxParser::parseStream( const InputSource& maStructSource) throw (SAXEx throw SAXException( OUString( RTL_CONSTASCII_USTRINGPARAM( "No input source" ) ), Reference< XInterface >(), Any() ); entity.maConverter.setInputStream( entity.maStructSource.aInputStream ); - if( entity.maStructSource.sEncoding.getLength() ) + if( !entity.maStructSource.sEncoding.isEmpty() ) entity.maConverter.setEncoding( OUStringToOString( entity.maStructSource.sEncoding, RTL_TEXTENCODING_ASCII_US ) ); // create parser with proper encoding @@ -776,7 +776,7 @@ void FastSaxParser::callbackStartElement( const XML_Char* pwName, const XML_Char // #158414# second: fill attribute list with other attributes for( ::std::vector< AttributeData >::const_iterator aIt = aAttribs.begin(), aEnd = aAttribs.end(); aIt != aEnd; ++aIt ) { - if( aIt->maPrefix.getLength() > 0 ) + if( !aIt->maPrefix.isEmpty() ) { sal_Int32 nAttributeToken = GetTokenWithPrefix( aIt->maPrefix, aIt->maName ); if( nAttributeToken != FastToken::DONTKNOW ) @@ -798,7 +798,7 @@ void FastSaxParser::callbackStartElement( const XML_Char* pwName, const XML_Char splitName( pwName, pPrefix, nPrefixLen, pName, nNameLen ); if( nPrefixLen > 0 ) nElementToken = GetTokenWithPrefix( pPrefix, nPrefixLen, pName, nNameLen ); - else if( rEntity.maContextStack.top()->maNamespace.getLength() > 0 ) + else if( !rEntity.maContextStack.top()->maNamespace.isEmpty() ) nElementToken = GetTokenWithNamespaceURL( rEntity.maContextStack.top()->maNamespace, pName, nNameLen ); else nElementToken = GetToken( pName ); diff --git a/sax/source/tools/converter.cxx b/sax/source/tools/converter.cxx index f2dea8a9a1a3..698dea826ba2 100644 --- a/sax/source/tools/converter.cxx +++ b/sax/source/tools/converter.cxx @@ -1038,7 +1038,7 @@ bool Converter::convertDuration(util::Duration& rDuration, sal_Int32 nPos(0); bool bIsNegativeDuration(false); - if (string.getLength() && (sal_Unicode('-') == string[0])) + if (!string.isEmpty() && (sal_Unicode('-') == string[0])) { bIsNegativeDuration = true; ++nPos; diff --git a/sax/source/tools/fastserializer.cxx b/sax/source/tools/fastserializer.cxx index ebd0467caade..67db04b1268e 100644 --- a/sax/source/tools/fastserializer.cxx +++ b/sax/source/tools/fastserializer.cxx @@ -157,7 +157,7 @@ namespace sax_fastparser { writeBytes(toUnoSequence(aOpeningBracket)); - if (Namespace.getLength()) + if (!Namespace.isEmpty()) { write(Namespace); writeBytes(toUnoSequence(aColon)); @@ -191,7 +191,7 @@ namespace sax_fastparser { writeBytes(toUnoSequence(aOpeningBracketAndSlash)); - if (Namespace.getLength()) + if (!Namespace.isEmpty()) { write(Namespace); writeBytes(toUnoSequence(aColon)); @@ -227,7 +227,7 @@ namespace sax_fastparser { writeBytes(toUnoSequence(aOpeningBracket)); - if (Namespace.getLength()) + if (!Namespace.isEmpty()) { write(Namespace); writeBytes(toUnoSequence(aColon)); diff --git a/scaddins/source/analysis/analysis.cxx b/scaddins/source/analysis/analysis.cxx index 4994c3692f91..357706e470c7 100644 --- a/scaddins/source/analysis/analysis.cxx +++ b/scaddins/source/analysis/analysis.cxx @@ -1227,7 +1227,7 @@ STRING SAL_CALL AnalysisAddIn::getComplex( double fR, double fI, const ANY& rSuf case uno::TypeClass_STRING: { const STRING* pSuff = ( const STRING* ) rSuff.getValue(); - bi = pSuff->compareToAscii( "i" ) == 0 || pSuff->getLength() == 0; + bi = pSuff->compareToAscii( "i" ) == 0 || pSuff->isEmpty(); if( !bi && pSuff->compareToAscii( "j" ) != 0 ) THROW_IAE; } diff --git a/scaddins/source/analysis/analysishelper.cxx b/scaddins/source/analysis/analysishelper.cxx index b9d505cf4c32..c2e17a8c05a8 100644 --- a/scaddins/source/analysis/analysishelper.cxx +++ b/scaddins/source/analysis/analysishelper.cxx @@ -1987,7 +1987,7 @@ void ComplexList::Append( const SEQSEQ( STRING )& r, ComplListAppendHandl eAH ) { const STRING& rStr = rList[ n2 ]; - if( rStr.getLength() ) + if( !rStr.isEmpty() ) Append( new Complex( rStr ) ); else if( bEmpty0 ) Append( new Complex( 0.0 ) ); @@ -2014,7 +2014,7 @@ void ComplexList::Append( const SEQ( ANY )& aMultPars, ComplListAppendHandl eAH { const STRING* pStr = ( const STRING* ) r.getValue(); - if( pStr->getLength() ) + if( !pStr->isEmpty() ) Append( new Complex( *( STRING* ) r.getValue() ) ); else if( bEmpty0 ) Append( new Complex( 0.0 ) ); @@ -2781,7 +2781,7 @@ sal_Bool ScaAnyConverter::getDouble( case uno::TypeClass_STRING: { const OUString* pString = static_cast< const OUString* >( rAny.getValue() ); - if( pString->getLength() ) + if( !pString->isEmpty() ) rfResult = convertToDouble( *pString ); else bContainsVal = sal_False; diff --git a/scaddins/source/datefunc/datefunc.cxx b/scaddins/source/datefunc/datefunc.cxx index e3d11bdbbb0c..4ae9543a3fc4 100644 --- a/scaddins/source/datefunc/datefunc.cxx +++ b/scaddins/source/datefunc/datefunc.cxx @@ -517,7 +517,7 @@ OUString SAL_CALL ScaDateAddIn::getProgrammaticCategoryName( } } - if( !aRet.getLength() ) + if( aRet.isEmpty() ) aRet = STR_FROM_ANSI( "Add-In" ); return aRet; } diff --git a/sccomp/source/solver/solver.cxx b/sccomp/source/solver/solver.cxx index a02b2975e20b..a529f3a60f5e 100644 --- a/sccomp/source/solver/solver.cxx +++ b/sccomp/source/solver/solver.cxx @@ -395,7 +395,7 @@ void SAL_CALL SolverComponent::solve() throw(uno::RuntimeException) xModel->unlockControllers(); - if ( maStatus.getLength() ) + if ( !maStatus.isEmpty() ) return; // diff --git a/scripting/source/basprov/basmethnode.cxx b/scripting/source/basprov/basmethnode.cxx index 750210d39a32..b07720c50606 100644 --- a/scripting/source/basprov/basmethnode.cxx +++ b/scripting/source/basprov/basmethnode.cxx @@ -226,7 +226,7 @@ namespace basprov if ( xModel.is() ) { sDocURL = xModel->getURL(); - if ( sDocURL.getLength() == 0 ) + if ( sDocURL.isEmpty() ) { Sequence < PropertyValue > aProps = xModel->getArgs(); sal_Int32 nProps = aProps.getLength(); diff --git a/scripting/source/basprov/basprov.cxx b/scripting/source/basprov/basprov.cxx index 4d1ff81e87e5..c2c0653b85d6 100644 --- a/scripting/source/basprov/basprov.cxx +++ b/scripting/source/basprov/basprov.cxx @@ -183,7 +183,7 @@ namespace basprov } } - if ( aFileURL.getLength() ) + if ( !aFileURL.isEmpty() ) { osl::DirectoryItem aFileItem; osl::FileStatus aFileStatus( osl_FileStatus_Mask_FileURL ); @@ -385,7 +385,7 @@ namespace basprov sProjectName = pBasicMgr->GetName(); ::rtl::OUString aLibrary; - if ( sProjectName.getLength() && aDescription.match( sProjectName ) ) + if ( !sProjectName.isEmpty() && aDescription.match( sProjectName ) ) { OSL_TRACE("LibraryName %s is part of the url %s", rtl::OUStringToOString( sProjectName, RTL_TEXTENCODING_UTF8 ).getStr(), @@ -402,7 +402,7 @@ namespace basprov if ( nIndex != -1 ) aMethod = aDescription.getToken( 0, (sal_Unicode)'.', nIndex ); - if ( aLibrary.getLength() != 0 && aModule.getLength() != 0 && aMethod.getLength() != 0 && aLocation.getLength() != 0 ) + if ( !aLibrary.isEmpty() && !aModule.isEmpty() && !aMethod.isEmpty() && !aLocation.isEmpty() ) { if ( pBasicMgr ) diff --git a/scripting/source/dlgprov/dlgprov.cxx b/scripting/source/dlgprov/dlgprov.cxx index b498fa84d42b..d828e04c69a8 100644 --- a/scripting/source/dlgprov/dlgprov.cxx +++ b/scripting/source/dlgprov/dlgprov.cxx @@ -406,7 +406,7 @@ static ::rtl::OUString aResourceResolverPropName(RTL_CONSTASCII_USTRINGPARAM("Re continue; ::rtl::OUString sDocURL = xModel->getURL(); - if ( sDocURL.getLength() == 0 ) + if ( sDocURL.isEmpty() ) { ::comphelper::NamedValueCollection aModelArgs( xModel->getArgs() ); sDocURL = aModelArgs.getOrDefault( "Title", sDocURL ); @@ -738,7 +738,7 @@ static ::rtl::OUString aResourceResolverPropName(RTL_CONSTASCII_USTRINGPARAM("Re xCtrlMod = createDialogModelForBasic(); else { - OSL_ENSURE( URL.getLength(), "DialogProviderImpl::getDialog: no URL!" ); + OSL_ENSURE( !URL.isEmpty(), "DialogProviderImpl::getDialog: no URL!" ); xCtrlMod = createDialogModel( URL ); } } diff --git a/scripting/source/protocolhandler/scripthandler.cxx b/scripting/source/protocolhandler/scripthandler.cxx index c1d2b2c0310a..73f4e56b8771 100644 --- a/scripting/source/protocolhandler/scripthandler.cxx +++ b/scripting/source/protocolhandler/scripthandler.cxx @@ -198,7 +198,7 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification( // this is not an argument to be passed to script, so // ignore. if ( lArgs[ index ].Name.compareToAscii("Referer") != 0 || - lArgs[ index ].Name.getLength() == 0 ) + lArgs[ index ].Name.isEmpty() ) { inArgs.realloc( ++argCount ); inArgs[ argCount - 1 ] = lArgs[ index ].Value; diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx index c5fe4c879285..81d647895811 100644 --- a/scripting/source/provider/MasterScriptProvider.cxx +++ b/scripting/source/provider/MasterScriptProvider.cxx @@ -302,7 +302,7 @@ throw ( provider::ScriptFrameworkErrorException, if ( sfUri->hasParameter( langKey ) == sal_False || sfUri->hasParameter( locKey ) == sal_False || - ( sfUri->getName().getLength() == 0 ) ) + ( sfUri->getName().isEmpty() ) ) { ::rtl::OUString errorMsg = OUSTR( "Incorrect format for Script URI: " ); errorMsg = errorMsg.concat( scriptURI ); @@ -551,7 +551,7 @@ MasterScriptProvider::insertByName( const ::rtl::OUString& aName, const Any& aEl throw lang::IllegalArgumentException( OUSTR("Couldn't convert to XPackage"), Reference < XInterface > (), 2 ); } - if ( !aName.getLength() ) + if ( aName.isEmpty() ) { throw lang::IllegalArgumentException( OUSTR("Name not set!!"), Reference < XInterface > (), 1 ); @@ -625,7 +625,7 @@ MasterScriptProvider::removeByName( const ::rtl::OUString& Name ) throw ( contai } else { - if ( !Name.getLength() ) + if ( Name.isEmpty() ) { throw lang::IllegalArgumentException( OUSTR("Name not set!!"), Reference < XInterface > (), 1 ); @@ -730,7 +730,7 @@ MasterScriptProvider::hasByName( const ::rtl::OUString& aName ) throw (RuntimeEx } else { - if ( !aName.getLength() ) + if ( aName.isEmpty() ) { throw lang::IllegalArgumentException( OUSTR("Name not set!!"), Reference < XInterface > (), 1 ); diff --git a/scripting/source/stringresource/stringresource.cxx b/scripting/source/stringresource/stringresource.cxx index f7a0673a4711..c15a6bb6dbac 100644 --- a/scripting/source/stringresource/stringresource.cxx +++ b/scripting/source/stringresource/stringresource.cxx @@ -855,7 +855,7 @@ void StringResourcePersistenceImpl::implInitializeCommonParameters ::rtl::OUString errorMsg(RTL_CONSTASCII_USTRINGPARAM("XInitialization::initialize: Expected NameBase string")); throw IllegalArgumentException( errorMsg, Reference< XInterface >(), 3 ); } - if( m_aNameBase.getLength() == 0 ) + if( m_aNameBase.isEmpty() ) m_aNameBase = aNameBaseDefaultStr; bool bCommentOk = (aArguments[4] >>= m_aComment); @@ -1854,14 +1854,14 @@ bool StringResourcePersistenceImpl::implLoadLocale( LocaleItem* ) aRetStr += aLocale.Language; ::rtl::OUString aCountry = aLocale.Country; - if( aCountry.getLength() ) + if( !aCountry.isEmpty() ) { aRetStr += aUnder; aRetStr += aCountry; } ::rtl::OUString aVariant = aLocale.Variant; - if( aVariant.getLength() ) + if( !aVariant.isEmpty() ) { aRetStr += aUnder; aRetStr += aVariant; @@ -1873,7 +1873,7 @@ bool StringResourcePersistenceImpl::implLoadLocale( LocaleItem* ) ( LocaleItem* pLocaleItem, const ::rtl::OUString& aNameBase ) { ::rtl::OUString aFileName = aNameBase; - if( aFileName.getLength() == 0 ) + if( aFileName.isEmpty() ) aFileName = aNameBaseDefaultStr; aFileName += implGetNameScemeForLocaleItem( pLocaleItem ); @@ -2089,7 +2089,7 @@ bool StringResourcePersistenceImpl::implReadPropertiesFile } // Ignore lines with empty keys - if( 0 == aResourceID.getLength() ) + if( aResourceID.isEmpty() ) continue; // Scan value diff --git a/scripting/source/vbaevents/eventhelper.cxx b/scripting/source/vbaevents/eventhelper.cxx index d13bbe7b5023..3b9cf401e39a 100644 --- a/scripting/source/vbaevents/eventhelper.cxx +++ b/scripting/source/vbaevents/eventhelper.cxx @@ -396,8 +396,8 @@ eventMethodToDescriptor( const ::rtl::OUString& rEventMethod, ScriptEventDescrip // Only create an ScriptEventDescriptor for an event we can translate // or emulate - if ( sMethodName.getLength() - && sTypeName.getLength() + if ( !sMethodName.isEmpty() + && !sTypeName.isEmpty() && ( infos.find( sMethodName ) != infos.end() ) ) { // just fill in CodeName, when the event fires the other |