summaryrefslogtreecommitdiff
path: root/svl/source/fsstor/fsfactory.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svl/source/fsstor/fsfactory.cxx')
-rw-r--r--svl/source/fsstor/fsfactory.cxx24
1 files changed, 13 insertions, 11 deletions
diff --git a/svl/source/fsstor/fsfactory.cxx b/svl/source/fsstor/fsfactory.cxx
index 62fc88f6053a..a641a5d80c04 100644
--- a/svl/source/fsstor/fsfactory.cxx
+++ b/svl/source/fsstor/fsfactory.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,15 +53,15 @@ using namespace ::com::sun::star;
uno::Sequence< ::rtl::OUString > SAL_CALL FSStorageFactory::impl_staticGetSupportedServiceNames()
{
uno::Sequence< ::rtl::OUString > aRet(2);
- aRet[0] = ::rtl::OUString::createFromAscii("com.sun.star.embed.FileSystemStorageFactory");
- aRet[1] = ::rtl::OUString::createFromAscii("com.sun.star.comp.embed.FileSystemStorageFactory");
+ aRet[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.embed.FileSystemStorageFactory"));
+ aRet[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.embed.FileSystemStorageFactory"));
return aRet;
}
//-------------------------------------------------------------------------
::rtl::OUString SAL_CALL FSStorageFactory::impl_staticGetImplementationName()
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.embed.FileSystemStorageFactory");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.embed.FileSystemStorageFactory"));
}
//-------------------------------------------------------------------------
@@ -120,7 +121,7 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstanceWithA
{
if( !( aArguments[1] >>= nStorageMode ) )
{
- OSL_ENSURE( sal_False, "Wrong second argument!\n" );
+ OSL_FAIL( "Wrong second argument!\n" );
throw uno::Exception(); // TODO: Illegal argument
}
// it's allways possible to read written storage in this implementation
@@ -134,13 +135,13 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstanceWithA
{
if ( !aURL.getLength() )
{
- OSL_ENSURE( sal_False, "Empty URL is provided!\n" );
+ OSL_FAIL( "Empty URL is provided!\n" );
throw uno::Exception(); // TODO: illegal argument
}
}
else
{
- OSL_ENSURE( sal_False, "Wrong first argument!\n" );
+ OSL_FAIL( "Wrong first argument!\n" );
throw uno::Exception(); // TODO: Illegal argument
}
@@ -153,12 +154,12 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstanceWithA
if( aArguments[2] >>= aDescr )
{
aPropsToSet.realloc(1);
- aPropsToSet[0].Name = ::rtl::OUString::createFromAscii( "URL" );
+ aPropsToSet[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URL"));
aPropsToSet[0].Value <<= aURL;
for ( sal_Int32 nInd = 0, nNumArgs = 1; nInd < aDescr.getLength(); nInd++ )
{
- if ( aDescr[nInd].Name.equalsAscii( "InteractionHandler" ) )
+ if ( aDescr[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "InteractionHandler" ) ) )
{
aPropsToSet.realloc( ++nNumArgs );
aPropsToSet[nNumArgs-1].Name = aDescr[nInd].Name;
@@ -166,12 +167,12 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstanceWithA
break;
}
else
- OSL_ENSURE( sal_False, "Unacceptable property, will be ignored!\n" );
+ OSL_FAIL( "Unacceptable property, will be ignored!\n" );
}
}
else
{
- OSL_ENSURE( sal_False, "Wrong third argument!\n" );
+ OSL_FAIL( "Wrong third argument!\n" );
throw uno::Exception(); // TODO: Illegal argument
}
}
@@ -182,7 +183,7 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstanceWithA
|| aURL.equalsIgnoreAsciiCaseAsciiL( "vnd.sun.star.zip", 16 )
|| ::utl::UCBContentHelper::IsDocument( aURL ) )
{
- OSL_ENSURE( sal_False, "File system storages can be based only on file URLs!\n" ); // ???
+ OSL_FAIL( "File system storages can be based only on file URLs!\n" ); // ???
throw uno::Exception(); // TODO: illegal argument
}
@@ -266,3 +267,4 @@ SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory (
} // extern "C"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */