summaryrefslogtreecommitdiff
path: root/dbaccess/source
diff options
context:
space:
mode:
authorMarcos Paulo de Souza <marcos.souza.org@gmail.com>2013-01-26 13:25:40 -0200
committerOlivier Hallot <olivier.hallot@alta.org.br>2013-01-27 17:31:43 +0000
commita1808e0d38dd36d590a5bae26a02c49252d6162a (patch)
tree4b8a7a879a01e798785a06e350135157363d1664 /dbaccess/source
parent3d033a8457180d9e4ccc2b1c1568d79087805209 (diff)
Remove more STRINGPARAM macros form dbaccess
Change-Id: I283ccd03dc811dda2f10963f400cd517f42ea7b3 Reviewed-on: https://gerrit.libreoffice.org/1878 Reviewed-by: Olivier Hallot <olivier.hallot@alta.org.br> Tested-by: Olivier Hallot <olivier.hallot@alta.org.br>
Diffstat (limited to 'dbaccess/source')
-rw-r--r--dbaccess/source/core/dataaccess/databasecontext.cxx5
-rw-r--r--dbaccess/source/core/dataaccess/databaseregistrations.cxx12
-rw-r--r--dbaccess/source/core/dataaccess/definitioncontainer.cxx12
-rw-r--r--dbaccess/source/core/dataaccess/documentcontainer.cxx2
-rw-r--r--dbaccess/source/core/dataaccess/intercept.cxx33
-rw-r--r--dbaccess/source/core/dataaccess/myucp_datasupplier.cxx5
-rw-r--r--dbaccess/source/core/misc/DatabaseDataProvider.cxx60
-rw-r--r--dbaccess/source/core/misc/dsntypes.cxx12
-rw-r--r--dbaccess/source/core/misc/sdbcoretools.cxx3
-rw-r--r--dbaccess/source/core/recovery/dbdocrecovery.cxx19
-rw-r--r--dbaccess/source/core/recovery/settingsimport.cxx10
-rw-r--r--dbaccess/source/core/recovery/storagetextstream.cxx4
-rw-r--r--dbaccess/source/core/recovery/subcomponentloader.cxx2
-rw-r--r--dbaccess/source/core/recovery/subcomponentrecovery.cxx42
14 files changed, 95 insertions, 126 deletions
diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx b/dbaccess/source/core/dataaccess/databasecontext.cxx
index b5372d42f0d0..8144f82c0ebb 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -204,10 +204,9 @@ ODatabaseContext::~ODatabaseContext()
}
// Helper
-rtl::OUString ODatabaseContext::getImplementationName_static() throw( RuntimeException )
-
+OUString ODatabaseContext::getImplementationName_static() throw( RuntimeException )
{
- return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.ODatabaseContext"));
+ return OUString("com.sun.star.comp.dba.ODatabaseContext");
}
Reference< XInterface > ODatabaseContext::Create(const Reference< XComponentContext >& _rxContext)
diff --git a/dbaccess/source/core/dataaccess/databaseregistrations.cxx b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
index 344c15cf4471..5886fbd2d492 100644
--- a/dbaccess/source/core/dataaccess/databaseregistrations.cxx
+++ b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
@@ -53,21 +53,21 @@ namespace dbaccess
using ::com::sun::star::uno::XAggregation;
/** === end UNO using === **/
- static const ::rtl::OUString& getConfigurationRootPath()
+ static const OUString& getConfigurationRootPath()
{
- static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.DataAccess/RegisteredNames"));
+ static OUString s_sNodeName("org.openoffice.Office.DataAccess/RegisteredNames");
return s_sNodeName;
}
- const ::rtl::OUString& getLocationNodeName()
+ const OUString& getLocationNodeName()
{
- static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Location"));
+ static OUString s_sNodeName("Location");
return s_sNodeName;
}
- const ::rtl::OUString& getNameNodeName()
+ const OUString& getNameNodeName()
{
- static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Name"));
+ static OUString s_sNodeName("Name");
return s_sNodeName;
}
diff --git a/dbaccess/source/core/dataaccess/definitioncontainer.cxx b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
index 928f2cf1a36f..8c8cd982c56b 100644
--- a/dbaccess/source/core/dataaccess/definitioncontainer.cxx
+++ b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
@@ -159,16 +159,16 @@ ODefinitionContainer::~ODefinitionContainer()
IMPLEMENT_FORWARD_XINTERFACE2( ODefinitionContainer,OContentHelper,ODefinitionContainer_Base)
IMPLEMENT_TYPEPROVIDER2(ODefinitionContainer,OContentHelper,ODefinitionContainer_Base);
// XServiceInfo
-::rtl::OUString SAL_CALL ODefinitionContainer::getImplementationName( ) throw(RuntimeException)
+OUString SAL_CALL ODefinitionContainer::getImplementationName( ) throw(RuntimeException)
{
- return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ODefinitionContainer"));
+ return OUString("com.sun.star.sdb.ODefinitionContainer");
}
-Sequence< ::rtl::OUString > SAL_CALL ODefinitionContainer::getSupportedServiceNames( ) throw(RuntimeException)
+Sequence< OUString > SAL_CALL ODefinitionContainer::getSupportedServiceNames( ) throw(RuntimeException)
{
- Sequence< ::rtl::OUString > aReturn(2);
- aReturn.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.DefinitionContainer"));
- aReturn.getArray()[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.Content"));
+ Sequence< OUString > aReturn(2);
+ aReturn.getArray()[0] = "com.sun.star.sdb.DefinitionContainer";
+ aReturn.getArray()[1] = "com.sun.star.ucb.Content";
return aReturn;
}
diff --git a/dbaccess/source/core/dataaccess/documentcontainer.cxx b/dbaccess/source/core/dataaccess/documentcontainer.cxx
index 9e91fd447a0a..90a8af52dd72 100644
--- a/dbaccess/source/core/dataaccess/documentcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/documentcontainer.cxx
@@ -733,7 +733,7 @@ void SAL_CALL ODocumentContainer::removeByName( const OUString& _rName ) throw(N
{
Command aCommand;
- aCommand.Name = OUString(RTL_CONSTASCII_USTRINGPARAM("delete"));
+ aCommand.Name = "delete";
xContent->execute(aCommand,xContent->createCommandIdentifier(),Reference< XCommandEnvironment >());
}
diff --git a/dbaccess/source/core/dataaccess/intercept.cxx b/dbaccess/source/core/dataaccess/intercept.cxx
index 9a29502b23db..cff678137762 100644
--- a/dbaccess/source/core/dataaccess/intercept.cxx
+++ b/dbaccess/source/core/dataaccess/intercept.cxx
@@ -86,12 +86,12 @@ OInterceptor::OInterceptor( ODocumentDefinition* _pContentHolder )
OSL_ENSURE(DISPATCH_RELOAD < m_aInterceptedURL.getLength(),"Illegal size.");
- m_aInterceptedURL[DISPATCH_SAVEAS] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:SaveAs"));
- m_aInterceptedURL[DISPATCH_SAVE] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Save"));
- m_aInterceptedURL[DISPATCH_CLOSEDOC] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseDoc"));
- m_aInterceptedURL[DISPATCH_CLOSEWIN] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseWin"));
- m_aInterceptedURL[DISPATCH_CLOSEFRAME] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:CloseFrame"));
- m_aInterceptedURL[DISPATCH_RELOAD] = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:Reload"));
+ m_aInterceptedURL[DISPATCH_SAVEAS] = ".uno:SaveAs";
+ m_aInterceptedURL[DISPATCH_SAVE] = ".uno:Save";
+ m_aInterceptedURL[DISPATCH_CLOSEDOC] = ".uno:CloseDoc";
+ m_aInterceptedURL[DISPATCH_CLOSEWIN] = ".uno:CloseWin";
+ m_aInterceptedURL[DISPATCH_CLOSEFRAME] = ".uno:CloseFrame";
+ m_aInterceptedURL[DISPATCH_RELOAD] = ".uno:Reload";
}
@@ -159,12 +159,11 @@ void SAL_CALL OInterceptor::dispatch( const URL& _URL,const Sequence<PropertyVal
if ( nInd == aNewArgs.getLength() )
{
aNewArgs.realloc( nInd + 1 );
- aNewArgs[nInd].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SaveTo"));
+ aNewArgs[nInd].Name = "SaveTo";
aNewArgs[nInd].Value <<= sal_True;
}
- Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(
- _URL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0 );
+ Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(_URL, "_self", 0 );
if ( xDispatch.is() )
xDispatch->dispatch( _URL, aNewArgs );
}
@@ -191,8 +190,7 @@ IMPL_LINK( OInterceptor, OnDispatch, void*, _pDispatcher )
{
if ( m_pContentHolder && m_pContentHolder->prepareClose() && m_xSlaveDispatchProvider.is() )
{
- Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(
- pHelper->aURL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0 );
+ Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(pHelper->aURL, "_self", 0 );
if ( xDispatch.is() )
{
Reference< ::com::sun::star::document::XEventBroadcaster> xEvtB(m_pContentHolder->getComponent(),UNO_QUERY);
@@ -230,10 +228,10 @@ void SAL_CALL OInterceptor::addStatusListener(
{
FeatureStateEvent aStateEvent;
aStateEvent.FeatureURL.Complete = m_aInterceptedURL[DISPATCH_SAVEAS];
- aStateEvent.FeatureDescriptor = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SaveCopyTo"));
+ aStateEvent.FeatureDescriptor = "SaveCopyTo";
aStateEvent.IsEnabled = sal_True;
aStateEvent.Requery = sal_False;
- aStateEvent.State <<= (rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("($3)")));
+ aStateEvent.State <<= OUString("($3)");
Control->statusChanged(aStateEvent);
}
@@ -249,7 +247,7 @@ void SAL_CALL OInterceptor::addStatusListener(
{ // Save
FeatureStateEvent aStateEvent;
aStateEvent.FeatureURL.Complete = m_aInterceptedURL[DISPATCH_SAVE];
- aStateEvent.FeatureDescriptor = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Update"));
+ aStateEvent.FeatureDescriptor = "Update";
aStateEvent.IsEnabled = m_pContentHolder != NULL && m_pContentHolder->isModified();
aStateEvent.Requery = sal_False;
@@ -275,8 +273,7 @@ void SAL_CALL OInterceptor::addStatusListener(
{ // Close and return
FeatureStateEvent aStateEvent;
aStateEvent.FeatureURL.Complete = m_aInterceptedURL[i];
- aStateEvent.FeatureDescriptor = rtl::OUString(
- RTL_CONSTASCII_USTRINGPARAM("Close and Return"));
+ aStateEvent.FeatureDescriptor = "Close and Return";
aStateEvent.IsEnabled = sal_True;
aStateEvent.Requery = sal_False;
Control->statusChanged(aStateEvent);
@@ -409,14 +406,14 @@ void SAL_CALL OInterceptor::setMasterDispatchProvider(
void SAL_CALL OInterceptor::notifyEvent( const ::com::sun::star::document::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException)
{
osl::ResettableMutexGuard _rGuard(m_aMutex);
- if ( m_pStatCL && Event.EventName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OnModifyChanged")) )
+ if ( m_pStatCL && Event.EventName == "OnModifyChanged" )
{
OInterfaceContainerHelper* pListener = m_pStatCL->getContainer(m_aInterceptedURL[DISPATCH_SAVE]);
if ( pListener )
{
FeatureStateEvent aEvt;
aEvt.FeatureURL.Complete = m_aInterceptedURL[DISPATCH_SAVE];
- aEvt.FeatureDescriptor = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Update"));
+ aEvt.FeatureDescriptor = "Update";
Reference<XModifiable> xModel(Event.Source,UNO_QUERY);
aEvt.IsEnabled = xModel.is() && xModel->isModified();
aEvt.Requery = sal_False;
diff --git a/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx b/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
index 108751038351..b34e981e95df 100644
--- a/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
+++ b/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
@@ -141,11 +141,10 @@ rtl::OUString DataSupplier::queryContentIdentifierString( sal_uInt32 nIndex )
if ( getResult( nIndex ) )
{
- rtl::OUString aId
- = m_pImpl->m_xContent->getIdentifier()->getContentIdentifier();
+ OUString aId = m_pImpl->m_xContent->getIdentifier()->getContentIdentifier();
if ( !aId.isEmpty() )
- aId += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/"));
+ aId += "/";
aId += m_pImpl->m_aResults[ nIndex ]->rData.aTitle;
diff --git a/dbaccess/source/core/misc/DatabaseDataProvider.cxx b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
index 78373c523b4a..e84a79df6469 100644
--- a/dbaccess/source/core/misc/DatabaseDataProvider.cxx
+++ b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
@@ -66,7 +66,7 @@ DatabaseDataProvider::DatabaseDataProvider(uno::Reference< uno::XComponentContex
m_EscapeProcessing(sal_True),
m_ApplyFilter(sal_True)
{
- m_xInternal.set( m_xContext->getServiceManager()->createInstanceWithContext(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.chart.InternalDataProvider")),m_xContext ), uno::UNO_QUERY );
+ m_xInternal.set( m_xContext->getServiceManager()->createInstanceWithContext("com.sun.star.comp.chart.InternalDataProvider",m_xContext ), uno::UNO_QUERY );
m_xRangeConversion.set(m_xInternal,uno::UNO_QUERY);
m_xComplexDescriptionAccess.set(m_xInternal,uno::UNO_QUERY);
@@ -105,15 +105,12 @@ uno::Any DatabaseDataProvider::queryInterface(uno::Type const & type) throw (uno
{
return TDatabaseDataProvider::queryInterface(type);
}
-// -----------------------------------------------------------------------------
-//------------------------------------------------------------------------------
-rtl::OUString DatabaseDataProvider::getImplementationName_Static( ) throw(uno::RuntimeException)
+OUString DatabaseDataProvider::getImplementationName_Static( ) throw(uno::RuntimeException)
{
- return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dbaccess.DatabaseDataProvider"));
+ return OUString("com.sun.star.comp.dbaccess.DatabaseDataProvider");
}
-// -----------------------------------------------------------------------------
-// -------------------------------------------------------------------------
+
// XServiceInfo
::rtl::OUString SAL_CALL DatabaseDataProvider::getImplementationName( ) throw(uno::RuntimeException)
{
@@ -127,10 +124,10 @@ sal_Bool SAL_CALL DatabaseDataProvider::supportsService( const ::rtl::OUString&
}
// -----------------------------------------------------------------------------
//------------------------------------------------------------------------------
-uno::Sequence< ::rtl::OUString > DatabaseDataProvider::getSupportedServiceNames_Static( ) throw (uno::RuntimeException)
+uno::Sequence< OUString > DatabaseDataProvider::getSupportedServiceNames_Static( ) throw (uno::RuntimeException)
{
- uno::Sequence< rtl::OUString > aSNS( 1 );
- aSNS[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.chart2.data.DatabaseDataProvider"));
+ uno::Sequence< OUString > aSNS( 1 );
+ aSNS[0] = "com.sun.star.chart2.data.DatabaseDataProvider";
return aSNS;
}
// -----------------------------------------------------------------------------
@@ -177,9 +174,9 @@ void SAL_CALL DatabaseDataProvider::initialize(const uno::Sequence< uno::Any > &
}
else if ( pArgIter->Name == "CellRangeRepresentation" )
{
- ::rtl::OUString sRange;
+ OUString sRange;
pArgIter->Value >>= sRange;
- if ( !sRange.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("all")) )
+ if ( sRange != "all" )
return sal_False;
}
else if ( pArgIter->Name == "FirstCellAsLabel" )
@@ -237,7 +234,7 @@ uno::Reference< chart2::data::XDataSource > SAL_CALL DatabaseDataProvider::creat
if ( xIni.is() )
{
uno::Sequence< uno::Any > aInitArgs(1);
- beans::NamedValue aParam(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CreateDefaultData")),uno::makeAny(sal_True));
+ beans::NamedValue aParam("CreateDefaultData",uno::makeAny(sal_True));
aInitArgs[0] <<= aParam;
xIni->initialize(aInitArgs);
}
@@ -251,7 +248,7 @@ uno::Reference< chart2::data::XDataSource > SAL_CALL DatabaseDataProvider::creat
uno::Sequence< beans::PropertyValue > SAL_CALL DatabaseDataProvider::detectArguments(const uno::Reference< chart2::data::XDataSource > & _xDataSource) throw (uno::RuntimeException)
{
::comphelper::NamedValueCollection aArguments;
- aArguments.put( "CellRangeRepresentation", uno::Any( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "all" ) ) ) );
+ aArguments.put( "CellRangeRepresentation", uno::Any( OUString( "all" ) ) );
aArguments.put( "DataRowSource", uno::makeAny( chart::ChartDataRowSource_COLUMNS ) );
// internal data always contains labels and categories
aArguments.put( "FirstCellAsLabel", uno::makeAny( sal_True ) );
@@ -266,9 +263,9 @@ uno::Sequence< beans::PropertyValue > SAL_CALL DatabaseDataProvider::detectArgum
if( aSequences[nIdx].is() )
{
uno::Reference< beans::XPropertySet > xSeqProp( aSequences[nIdx]->getValues(), uno::UNO_QUERY );
- ::rtl::OUString aRole;
+ OUString aRole;
if ( xSeqProp.is()
- && ( xSeqProp->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Role" ) ) ) >>= aRole )
+ && ( xSeqProp->getPropertyValue( "Role" ) >>= aRole )
&& aRole == "categories"
)
{
@@ -301,7 +298,7 @@ uno::Reference< chart2::data::XDataSequence > SAL_CALL DatabaseDataProvider::cre
osl::MutexGuard g(m_aMutex);
uno::Reference< chart2::data::XDataSequence > xData = m_xInternal->createDataSequenceByRangeRepresentation(_sRangeRepresentation);
uno::Reference<beans::XPropertySet> xProp(xData,uno::UNO_QUERY);
- const static ::rtl::OUString s_sNumberFormatKey(RTL_CONSTASCII_USTRINGPARAM("NumberFormatKey"));
+ const static OUString s_sNumberFormatKey("NumberFormatKey");
if ( xProp.is() && xProp->getPropertySetInfo()->hasPropertyByName(s_sNumberFormatKey) )
{
xProp->setPropertyValue(s_sNumberFormatKey,impl_getNumberFormatKey_nothrow(_sRangeRepresentation));
@@ -439,13 +436,11 @@ void SAL_CALL DatabaseDataProvider::addVetoableChangeListener(const ::rtl::OUStr
{
::cppu::PropertySetMixin< chart2::data::XDatabaseDataProvider >::addVetoableChangeListener(aPropertyName, xListener);
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::removeVetoableChangeListener(const ::rtl::OUString & aPropertyName, const uno::Reference< beans::XVetoableChangeListener > & xListener) throw (uno::RuntimeException, beans::UnknownPropertyException, lang::WrappedTargetException)
{
::cppu::PropertySetMixin< chart2::data::XDatabaseDataProvider >::removeVetoableChangeListener(aPropertyName, xListener);
}
-// -----------------------------------------------------------------------------
// chart2::data::XDatabaseDataProvider:
uno::Sequence< ::rtl::OUString > SAL_CALL DatabaseDataProvider::getMasterFields() throw (uno::RuntimeException)
@@ -453,27 +448,24 @@ uno::Sequence< ::rtl::OUString > SAL_CALL DatabaseDataProvider::getMasterFields(
osl::MutexGuard g(m_aMutex);
return m_MasterFields;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setMasterFields(const uno::Sequence< ::rtl::OUString > & the_value) throw (uno::RuntimeException)
{
impl_invalidateParameter_nothrow();
- set(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MasterFields")),the_value,m_MasterFields);
+ set(OUString("MasterFields"),the_value,m_MasterFields);
}
-// -----------------------------------------------------------------------------
uno::Sequence< ::rtl::OUString > SAL_CALL DatabaseDataProvider::getDetailFields() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
return m_DetailFields;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setDetailFields(const uno::Sequence< ::rtl::OUString > & the_value) throw (uno::RuntimeException)
{
- set(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DetailFields")),the_value,m_DetailFields);
+ set("DetailFields",the_value,m_DetailFields);
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL DatabaseDataProvider::getCommand() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
@@ -584,37 +576,34 @@ void SAL_CALL DatabaseDataProvider::setOrder( const ::rtl::OUString& the_value )
}
set(PROPERTY_ORDER,the_value,m_Order);
}
-// -----------------------------------------------------------------------------
+
::sal_Bool SAL_CALL DatabaseDataProvider::getEscapeProcessing() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
return m_EscapeProcessing;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setEscapeProcessing(::sal_Bool the_value) throw (uno::RuntimeException)
{
set(PROPERTY_ESCAPE_PROCESSING,the_value,m_EscapeProcessing);
}
-// -----------------------------------------------------------------------------
+
::sal_Int32 SAL_CALL DatabaseDataProvider::getRowLimit() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
return m_RowLimit;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setRowLimit(::sal_Int32 the_value) throw (uno::RuntimeException)
{
- set(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("RowLimit")),the_value,m_RowLimit);
+ set("RowLimit",the_value,m_RowLimit);
}
-// -----------------------------------------------------------------------------
+
uno::Reference< sdbc::XConnection > SAL_CALL DatabaseDataProvider::getActiveConnection() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
return m_xActiveConnection;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setActiveConnection(const uno::Reference< sdbc::XConnection > & the_value) throw (uno::RuntimeException, lang::IllegalArgumentException)
{
@@ -622,26 +611,24 @@ void SAL_CALL DatabaseDataProvider::setActiveConnection(const uno::Reference< sd
throw lang::IllegalArgumentException();
set(PROPERTY_ACTIVE_CONNECTION,the_value,m_xActiveConnection);
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL DatabaseDataProvider::getDataSourceName() throw (uno::RuntimeException)
{
osl::MutexGuard g(m_aMutex);
return m_DataSourceName;
}
-// -----------------------------------------------------------------------------
void SAL_CALL DatabaseDataProvider::setDataSourceName(const ::rtl::OUString& the_value) throw (uno::RuntimeException)
{
set(PROPERTY_DATASOURCENAME,the_value,m_DataSourceName);
}
-// -----------------------------------------------------------------------------
+
void DatabaseDataProvider::impl_executeRowSet_throw(::osl::ResettableMutexGuard& _rClearForNotifies)
{
if ( impl_fillParameters_nothrow(_rClearForNotifies) )
m_xRowSet->execute();
}
-// -----------------------------------------------------------------------------
namespace
{
struct ColumnDescription
@@ -681,7 +668,6 @@ namespace
};
}
-// -----------------------------------------------------------------------------
void DatabaseDataProvider::impl_fillInternalDataProvider_throw(sal_Bool _bHasCategories,const uno::Sequence< ::rtl::OUString >& i_aColumnNames)
{
// clear the data before fill the new one
diff --git a/dbaccess/source/core/misc/dsntypes.cxx b/dbaccess/source/core/misc/dsntypes.cxx
index 15587a0bf43a..31b21b271b12 100644
--- a/dbaccess/source/core/misc/dsntypes.cxx
+++ b/dbaccess/source/core/misc/dsntypes.cxx
@@ -301,24 +301,24 @@ bool ODsnTypeCollection::isEmbeddedDatabase( const ::rtl::OUString& _sURL ) cons
return aWildCard.Matches(_sURL);
}
// -----------------------------------------------------------------------------
-::rtl::OUString ODsnTypeCollection::getEmbeddedDatabase() const
+OUString ODsnTypeCollection::getEmbeddedDatabase() const
{
- ::rtl::OUString sEmbeddedDatabaseURL;
- static const ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.DataAccess")); ///Installed
+ OUString sEmbeddedDatabaseURL;
+ static const OUString s_sNodeName("org.openoffice.Office.DataAccess"); ///Installed
const ::utl::OConfigurationTreeRoot aInstalled = ::utl::OConfigurationTreeRoot::createWithComponentContext(m_xContext, s_sNodeName, -1, ::utl::OConfigurationTreeRoot::CM_READONLY);
if ( aInstalled.isValid() )
{
if ( aInstalled.hasByName("EmbeddedDatabases/DefaultEmbeddedDatabase/Value") )
{
- static const ::rtl::OUString s_sValue(RTL_CONSTASCII_USTRINGPARAM("EmbeddedDatabases/DefaultEmbeddedDatabase/Value"));
+ static const OUString s_sValue("EmbeddedDatabases/DefaultEmbeddedDatabase/Value");
aInstalled.getNodeValue(s_sValue) >>= sEmbeddedDatabaseURL;
if ( !sEmbeddedDatabaseURL.isEmpty() )
- aInstalled.getNodeValue(s_sValue + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sEmbeddedDatabaseURL + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/URL"))) >>= sEmbeddedDatabaseURL;
+ aInstalled.getNodeValue(s_sValue + "/" + sEmbeddedDatabaseURL + "/URL") >>= sEmbeddedDatabaseURL;
}
}
if ( sEmbeddedDatabaseURL.isEmpty() )
- sEmbeddedDatabaseURL = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:embedded:hsqldb"));
+ sEmbeddedDatabaseURL = "sdbc:embedded:hsqldb";
return sEmbeddedDatabaseURL;
}
//-------------------------------------------------------------------------
diff --git a/dbaccess/source/core/misc/sdbcoretools.cxx b/dbaccess/source/core/misc/sdbcoretools.cxx
index 0f11c1517a36..6fd8507b3b46 100644
--- a/dbaccess/source/core/misc/sdbcoretools.cxx
+++ b/dbaccess/source/core/misc/sdbcoretools.cxx
@@ -131,8 +131,7 @@ namespace dbaccess
try
{
Reference< XPropertySet > xStorageProps( _rxStorage, UNO_QUERY_THROW );
- xStorageProps->getPropertyValue(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "OpenMode" ) ) ) >>= nMode;
+ xStorageProps->getPropertyValue( "OpenMode" ) >>= nMode;
}
catch( const Exception& )
{
diff --git a/dbaccess/source/core/recovery/dbdocrecovery.cxx b/dbaccess/source/core/recovery/dbdocrecovery.cxx
index bc75824a7171..c7677ca8e471 100644
--- a/dbaccess/source/core/recovery/dbdocrecovery.cxx
+++ b/dbaccess/source/core/recovery/dbdocrecovery.cxx
@@ -115,27 +115,24 @@ namespace dbaccess
return true;
}
- // .........................................................................
- static const ::rtl::OUString& lcl_getRecoveryDataSubStorageName()
+ static const OUString& lcl_getRecoveryDataSubStorageName()
{
- static const ::rtl::OUString s_sRecDataStorName( RTL_CONSTASCII_USTRINGPARAM( "recovery" ) );
+ static const OUString s_sRecDataStorName( "recovery" );
return s_sRecDataStorName;
}
- // .........................................................................
- static const ::rtl::OUString& lcl_getObjectMapStreamName()
+
+ static const OUString& lcl_getObjectMapStreamName()
{
- static const ::rtl::OUString s_sObjectMapStreamName( RTL_CONSTASCII_USTRINGPARAM( "storage-component-map.ini" ) );
+ static const OUString s_sObjectMapStreamName( "storage-component-map.ini" );
return s_sObjectMapStreamName;
}
- // .........................................................................
- static const ::rtl::OUString& lcl_getMapStreamEncodingName()
+ static const OUString& lcl_getMapStreamEncodingName()
{
- static const ::rtl::OUString s_sMapStreamEncodingName( RTL_CONSTASCII_USTRINGPARAM( "UTF-8" ) );
+ static const OUString s_sMapStreamEncodingName( "UTF-8" );
return s_sMapStreamEncodingName;
}
- // .........................................................................
static void lcl_writeObjectMap_throw( const ::comphelper::ComponentContext& i_rContext, const Reference< XStorage >& i_rStorage,
const MapStringToCompDesc& i_mapStorageToCompDesc )
{
@@ -145,7 +142,7 @@ namespace dbaccess
StorageTextOutputStream aTextOutput( i_rContext, i_rStorage, lcl_getObjectMapStreamName() );
- aTextOutput.writeLine( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "[storages]" ) ) );
+ aTextOutput.writeLine( "[storages]" );
for ( MapStringToCompDesc::const_iterator stor = i_mapStorageToCompDesc.begin();
stor != i_mapStorageToCompDesc.end();
diff --git a/dbaccess/source/core/recovery/settingsimport.cxx b/dbaccess/source/core/recovery/settingsimport.cxx
index 614c268d4b86..e54aa04d7629 100644
--- a/dbaccess/source/core/recovery/settingsimport.cxx
+++ b/dbaccess/source/core/recovery/settingsimport.cxx
@@ -57,13 +57,11 @@ namespace dbaccess
{
}
- //--------------------------------------------------------------------
oslInterlockedCount SAL_CALL SettingsImport::acquire()
{
return osl_atomic_increment( &m_refCount );
}
- //--------------------------------------------------------------------
oslInterlockedCount SAL_CALL SettingsImport::release()
{
oslInterlockedCount newCount = osl_atomic_decrement( &m_refCount );
@@ -72,29 +70,25 @@ namespace dbaccess
return newCount;
}
- //--------------------------------------------------------------------
void SettingsImport::startElement( const Reference< XAttributeList >& i_rAttributes )
{
// find the name of the setting
if ( i_rAttributes.is() )
{
- m_sItemName = i_rAttributes->getValueByName( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "config:name" ) ) );
- m_sItemType = i_rAttributes->getValueByName( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "config:type" ) ) );
+ m_sItemName = i_rAttributes->getValueByName( "config:name" );
+ m_sItemType = i_rAttributes->getValueByName( "config:type" );
}
}
- //--------------------------------------------------------------------
void SettingsImport::endElement()
{
}
- //--------------------------------------------------------------------
void SettingsImport::characters( const ::rtl::OUString& i_rCharacters )
{
m_aCharacters.append( i_rCharacters );
}
- //--------------------------------------------------------------------
void SettingsImport::split( const ::rtl::OUString& i_rElementName, ::rtl::OUString& o_rNamespace, ::rtl::OUString& o_rLocalName )
{
o_rNamespace = ::rtl::OUString();
diff --git a/dbaccess/source/core/recovery/storagetextstream.cxx b/dbaccess/source/core/recovery/storagetextstream.cxx
index 4ab012706a39..26d5cfab2216 100644
--- a/dbaccess/source/core/recovery/storagetextstream.cxx
+++ b/dbaccess/source/core/recovery/storagetextstream.cxx
@@ -62,9 +62,9 @@ namespace dbaccess
namespace
{
//--------------------------------------------------------------------------------------------------------------
- static const ::rtl::OUString& lcl_getTextStreamEncodingName()
+ static const OUString& lcl_getTextStreamEncodingName()
{
- static const ::rtl::OUString s_sMapStreamEncodingName( RTL_CONSTASCII_USTRINGPARAM( "UTF-8" ) );
+ static const OUString s_sMapStreamEncodingName( "UTF-8" );
return s_sMapStreamEncodingName;
}
diff --git a/dbaccess/source/core/recovery/subcomponentloader.cxx b/dbaccess/source/core/recovery/subcomponentloader.cxx
index 7238b39930e8..8b6dd3bd244f 100644
--- a/dbaccess/source/core/recovery/subcomponentloader.cxx
+++ b/dbaccess/source/core/recovery/subcomponentloader.cxx
@@ -88,7 +88,7 @@ namespace dbaccess
if ( i_rData.xDocDefCommands.is() )
{
Command aCommandOpen;
- aCommandOpen.Name = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "show" ) );
+ aCommandOpen.Name = "show";
const sal_Int32 nCommandIdentifier = i_rData.xDocDefCommands->createCommandIdentifier();
i_rData.xDocDefCommands->execute( aCommandOpen, nCommandIdentifier, NULL );
diff --git a/dbaccess/source/core/recovery/subcomponentrecovery.cxx b/dbaccess/source/core/recovery/subcomponentrecovery.cxx
index d9129d18644b..3f738336682a 100644
--- a/dbaccess/source/core/recovery/subcomponentrecovery.cxx
+++ b/dbaccess/source/core/recovery/subcomponentrecovery.cxx
@@ -90,10 +90,10 @@ namespace dbaccess
// .........................................................................
static const ::rtl::OUString& lcl_getComponentStorageBaseName( const SubComponentType i_eType )
{
- static const ::rtl::OUString s_sFormBaseName( RTL_CONSTASCII_USTRINGPARAM( "form" ) );
- static const ::rtl::OUString s_sReportBaseName( RTL_CONSTASCII_USTRINGPARAM( "report" ) );
- static const ::rtl::OUString s_sTableBaseName( RTL_CONSTASCII_USTRINGPARAM( "table" ) );
- static const ::rtl::OUString s_sQueryBaseName( RTL_CONSTASCII_USTRINGPARAM( "query" ) );
+ static const OUString s_sFormBaseName( "form" );
+ static const OUString s_sReportBaseName( "report" );
+ static const OUString s_sTableBaseName( "table" );
+ static const OUString s_sQueryBaseName( "query" );
switch ( i_eType )
{
@@ -176,17 +176,15 @@ namespace dbaccess
return xCommandProcessor;
}
- // .........................................................................
- static const ::rtl::OUString& lcl_getSettingsStreamName()
+ static const OUString& lcl_getSettingsStreamName()
{
- static const ::rtl::OUString s_sStatementStreamName( RTL_CONSTASCII_USTRINGPARAM( "settings.xml" ) );
+ static const OUString s_sStatementStreamName( "settings.xml" );
return s_sStatementStreamName;
}
- // .........................................................................
- static const ::rtl::OUString& lcl_getCurrentQueryDesignName()
+ static const OUString& lcl_getCurrentQueryDesignName()
{
- static const ::rtl::OUString s_sQuerySettingsName( RTL_CONSTASCII_USTRINGPARAM( "ooo:current-query-design" ) );
+ static const OUString s_sQuerySettingsName( "ooo:current-query-design" );
return s_sQuerySettingsName;
}
}
@@ -249,7 +247,7 @@ namespace dbaccess
void SettingsExportContext::StartElement( enum ::xmloff::token::XMLTokenEnum i_eName, const sal_Bool i_bIgnoreWhitespace )
{
if ( i_bIgnoreWhitespace )
- m_rDelegator.ignorableWhitespace( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " " ) ) );
+ m_rDelegator.ignorableWhitespace( " " );
m_rDelegator.startElement( impl_prefix( i_eName ) );
}
@@ -258,7 +256,7 @@ namespace dbaccess
void SettingsExportContext::EndElement( const sal_Bool i_bIgnoreWhitespace )
{
if ( i_bIgnoreWhitespace )
- m_rDelegator.ignorableWhitespace( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " " ) ) );
+ m_rDelegator.ignorableWhitespace( " " );
m_rDelegator.endElement();
}
@@ -398,11 +396,11 @@ namespace dbaccess
//--------------------------------------------------------------------
const ::rtl::OUString SubComponentRecovery::getComponentsStorageName( const SubComponentType i_eType )
{
- static const ::rtl::OUString s_sFormsStorageName( RTL_CONSTASCII_USTRINGPARAM( "forms" ) );
- static const ::rtl::OUString s_sReportsStorageName( RTL_CONSTASCII_USTRINGPARAM( "reports" ) );
- static const ::rtl::OUString s_sTablesStorageName( RTL_CONSTASCII_USTRINGPARAM( "tables" ) );
- static const ::rtl::OUString s_sQueriesStorageName( RTL_CONSTASCII_USTRINGPARAM( "queries" ) );
- static const ::rtl::OUString s_sRelationsStorageName( RTL_CONSTASCII_USTRINGPARAM( "relations" ) );
+ static const OUString s_sFormsStorageName( "forms" );
+ static const OUString s_sReportsStorageName( "reports" );
+ static const OUString s_sTablesStorageName( "tables" );
+ static const OUString s_sQueriesStorageName( "queries" );
+ static const OUString s_sRelationsStorageName( "relations" );
switch ( i_eType )
{
@@ -487,11 +485,11 @@ namespace dbaccess
switch ( m_eType )
{
case TABLE:
- m_aCompDesc.bForEditing = sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.TableDesign" ) );
+ m_aCompDesc.bForEditing = sModuleIdentifier == "com.sun.star.sdb.TableDesign";
break;
case QUERY:
- m_aCompDesc.bForEditing = sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.QueryDesign" ) );
+ m_aCompDesc.bForEditing = sModuleIdentifier == "com.sun.star.sdb.QueryDesign";
break;
case REPORT:
@@ -534,15 +532,15 @@ namespace dbaccess
// the latter is updated only upon successful save of the design)
Reference< XPropertySet > xDesignerProps( m_xComponent, UNO_QUERY_THROW );
Sequence< PropertyValue > aCurrentQueryDesign;
- OSL_VERIFY( xDesignerProps->getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "CurrentQueryDesign" ) ) ) >>= aCurrentQueryDesign );
+ OSL_VERIFY( xDesignerProps->getPropertyValue( "CurrentQueryDesign" ) >>= aCurrentQueryDesign );
// write the query design
StorageXMLOutputStream aDesignOutput( m_rContext, i_rObjectStorage, lcl_getSettingsStreamName() );
SettingsExportContext aSettingsExportContext( m_rContext, aDesignOutput );
- const ::rtl::OUString sWhitespace( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( " " ) ) );
+ const OUString sWhitespace( " " );
- aDesignOutput.startElement( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "office:settings" ) ) );
+ aDesignOutput.startElement( "office:settings" );
aDesignOutput.ignorableWhitespace( sWhitespace );
XMLSettingsExportHelper aSettingsExporter( aSettingsExportContext );