Kaydet (Commit) b2d99944 authored tarafından Thomas Arnhold's avatar Thomas Arnhold

stoc: remove using namespace from headers

Change-Id: I1bee29ddcef66cb38ef2619507ad66c886f6f20d
üst 71e36bbc
...@@ -22,6 +22,9 @@ ...@@ -22,6 +22,9 @@
#include "base.hxx" #include "base.hxx"
using namespace css::lang;
using namespace css::reflection;
using namespace css::uno;
namespace stoc_corefl namespace stoc_corefl
{ {
...@@ -50,13 +53,13 @@ void ArrayIdlClassImpl::release() throw() ...@@ -50,13 +53,13 @@ void ArrayIdlClassImpl::release() throw()
Sequence< Type > ArrayIdlClassImpl::getTypes() Sequence< Type > ArrayIdlClassImpl::getTypes()
throw (::com::sun::star::uno::RuntimeException, std::exception) throw (::com::sun::star::uno::RuntimeException, std::exception)
{ {
static OTypeCollection * s_pTypes = 0; static ::cppu::OTypeCollection * s_pTypes = 0;
if (! s_pTypes) if (! s_pTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! s_pTypes) if (! s_pTypes)
{ {
static OTypeCollection s_aTypes( static ::cppu::OTypeCollection s_aTypes(
::getCppuType( (const Reference< XIdlArray > *)0 ), ::getCppuType( (const Reference< XIdlArray > *)0 ),
IdlClassImpl::getTypes() ); IdlClassImpl::getTypes() );
s_pTypes = &s_aTypes; s_pTypes = &s_aTypes;
......
...@@ -22,6 +22,9 @@ ...@@ -22,6 +22,9 @@
#include "base.hxx" #include "base.hxx"
using namespace css::reflection;
using namespace css::uno;
namespace stoc_corefl namespace stoc_corefl
{ {
...@@ -30,15 +33,15 @@ ClassNameList g_aClassNames; ...@@ -30,15 +33,15 @@ ClassNameList g_aClassNames;
#endif #endif
Mutex & getMutexAccess() ::osl::Mutex & getMutexAccess()
{ {
static Mutex * s_pMutex = 0; static ::osl::Mutex * s_pMutex = 0;
if (! s_pMutex) if (! s_pMutex)
{ {
MutexGuard aGuard( Mutex::getGlobalMutex() ); ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
if (! s_pMutex) if (! s_pMutex)
{ {
static Mutex s_aMutex; static ::osl::Mutex s_aMutex;
s_pMutex = &s_aMutex; s_pMutex = &s_aMutex;
} }
} }
...@@ -263,7 +266,7 @@ Reference< XIdlClass > IdlMemberImpl::getDeclaringClass() ...@@ -263,7 +266,7 @@ Reference< XIdlClass > IdlMemberImpl::getDeclaringClass()
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
Reference< XIdlClass > xDeclClass( getReflection()->forType( getDeclTypeDescr() ) ); Reference< XIdlClass > xDeclClass( getReflection()->forType( getDeclTypeDescr() ) );
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _xDeclClass.is()) if (! _xDeclClass.is())
_xDeclClass = xDeclClass; _xDeclClass = xDeclClass;
} }
......
...@@ -25,6 +25,9 @@ ...@@ -25,6 +25,9 @@
#include "base.hxx" #include "base.hxx"
using namespace css::lang;
using namespace css::reflection;
using namespace css::uno;
namespace stoc_corefl namespace stoc_corefl
{ {
...@@ -92,13 +95,13 @@ void IdlCompFieldImpl::release() throw() ...@@ -92,13 +95,13 @@ void IdlCompFieldImpl::release() throw()
Sequence< Type > IdlCompFieldImpl::getTypes() Sequence< Type > IdlCompFieldImpl::getTypes()
throw (::com::sun::star::uno::RuntimeException, std::exception) throw (::com::sun::star::uno::RuntimeException, std::exception)
{ {
static OTypeCollection * s_pTypes = 0; static ::cppu::OTypeCollection * s_pTypes = 0;
if (! s_pTypes) if (! s_pTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! s_pTypes) if (! s_pTypes)
{ {
static OTypeCollection s_aTypes( static ::cppu::OTypeCollection s_aTypes(
::getCppuType( (const Reference< XIdlField2 > *)0 ), ::getCppuType( (const Reference< XIdlField2 > *)0 ),
::getCppuType( (const Reference< XIdlField > *)0 ), ::getCppuType( (const Reference< XIdlField > *)0 ),
IdlMemberImpl::getTypes() ); IdlMemberImpl::getTypes() );
...@@ -121,7 +124,7 @@ Reference< XIdlClass > IdlCompFieldImpl::getDeclaringClass() ...@@ -121,7 +124,7 @@ Reference< XIdlClass > IdlCompFieldImpl::getDeclaringClass()
{ {
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
typelib_CompoundTypeDescription * pTD = typelib_CompoundTypeDescription * pTD =
...@@ -311,7 +314,7 @@ Sequence< Reference< XIdlClass > > CompoundIdlClassImpl::getSuperclasses() ...@@ -311,7 +314,7 @@ Sequence< Reference< XIdlClass > > CompoundIdlClassImpl::getSuperclasses()
{ {
if (! _xSuperClass.is()) if (! _xSuperClass.is())
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _xSuperClass.is()) if (! _xSuperClass.is())
{ {
typelib_CompoundTypeDescription * pCompTypeDescr = getTypeDescr()->pBaseTypeDescription; typelib_CompoundTypeDescription * pCompTypeDescr = getTypeDescr()->pBaseTypeDescription;
...@@ -341,7 +344,7 @@ Reference< XIdlField > CompoundIdlClassImpl::getField( const OUString & rName ) ...@@ -341,7 +344,7 @@ Reference< XIdlField > CompoundIdlClassImpl::getField( const OUString & rName )
Sequence< Reference< XIdlField > > CompoundIdlClassImpl::getFields() Sequence< Reference< XIdlField > > CompoundIdlClassImpl::getFields()
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pFields) if (! _pFields)
{ {
sal_Int32 nAll = 0; sal_Int32 nAll = 0;
......
...@@ -27,9 +27,11 @@ ...@@ -27,9 +27,11 @@
#include "com/sun/star/uno/RuntimeException.hpp" #include "com/sun/star/uno/RuntimeException.hpp"
#include <uno/lbnames.h> #include <uno/lbnames.h>
using namespace com::sun::star; using namespace css;
using namespace com::sun::star::lang; using namespace css::uno;
using namespace com::sun::star::registry; using namespace css::lang;
using namespace css::reflection;
using namespace css::registry;
using namespace cppu; using namespace cppu;
using namespace osl; using namespace osl;
...@@ -298,7 +300,7 @@ Any IdlReflectionServiceImpl::getByHierarchicalName( const OUString & rName ) ...@@ -298,7 +300,7 @@ Any IdlReflectionServiceImpl::getByHierarchicalName( const OUString & rName )
_aElements.setValue( rName, aRet ); _aElements.setValue( rName, aRet );
else else
{ {
throw NoSuchElementException( rName, Reference< XInterface >() ); throw container::NoSuchElementException( rName, Reference< XInterface >() );
} }
} }
return aRet; return aRet;
...@@ -311,7 +313,7 @@ sal_Bool IdlReflectionServiceImpl::hasByHierarchicalName( const OUString & rName ...@@ -311,7 +313,7 @@ sal_Bool IdlReflectionServiceImpl::hasByHierarchicalName( const OUString & rName
{ {
return getByHierarchicalName( rName ).hasValue(); return getByHierarchicalName( rName ).hasValue();
} }
catch (NoSuchElementException &) catch (container::NoSuchElementException &)
{ {
} }
return sal_False; return sal_False;
......
...@@ -17,9 +17,12 @@ ...@@ -17,9 +17,12 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 . * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/ */
#include "base.hxx" #include "base.hxx"
using namespace css::lang;
using namespace css::reflection;
using namespace css::uno;
namespace stoc_corefl namespace stoc_corefl
{ {
...@@ -90,13 +93,13 @@ void IdlEnumFieldImpl::release() throw() ...@@ -90,13 +93,13 @@ void IdlEnumFieldImpl::release() throw()
Sequence< Type > IdlEnumFieldImpl::getTypes() Sequence< Type > IdlEnumFieldImpl::getTypes()
throw (::com::sun::star::uno::RuntimeException, std::exception) throw (::com::sun::star::uno::RuntimeException, std::exception)
{ {
static OTypeCollection * s_pTypes = 0; static ::cppu::OTypeCollection * s_pTypes = 0;
if (! s_pTypes) if (! s_pTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! s_pTypes) if (! s_pTypes)
{ {
static OTypeCollection s_aTypes( static ::cppu::OTypeCollection s_aTypes(
::getCppuType( (const Reference< XIdlField2 > *)0 ), ::getCppuType( (const Reference< XIdlField2 > *)0 ),
::getCppuType( (const Reference< XIdlField > *)0 ), ::getCppuType( (const Reference< XIdlField > *)0 ),
IdlMemberImpl::getTypes() ); IdlMemberImpl::getTypes() );
...@@ -193,7 +196,7 @@ Sequence< Reference< XIdlField > > EnumIdlClassImpl::getFields() ...@@ -193,7 +196,7 @@ Sequence< Reference< XIdlField > > EnumIdlClassImpl::getFields()
{ {
if (! _pFields) if (! _pFields)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pFields) if (! _pFields)
{ {
sal_Int32 nFields = getTypeDescr()->nEnumValues; sal_Int32 nFields = getTypeDescr()->nEnumValues;
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 . * the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/ */
#include <sal/config.h> #include <sal/config.h>
#ifdef SAL_UNX #ifdef SAL_UNX
#include <sal/alloca.h> #include <sal/alloca.h>
...@@ -35,6 +34,10 @@ ...@@ -35,6 +34,10 @@
#include "com/sun/star/uno/RuntimeException.hpp" #include "com/sun/star/uno/RuntimeException.hpp"
#include "cppuhelper/exc_hlp.hxx" #include "cppuhelper/exc_hlp.hxx"
using namespace css::lang;
using namespace css::reflection;
using namespace css::uno;
namespace stoc_corefl namespace stoc_corefl
{ {
...@@ -104,13 +107,13 @@ void IdlAttributeFieldImpl::release() throw() ...@@ -104,13 +107,13 @@ void IdlAttributeFieldImpl::release() throw()
Sequence< Type > IdlAttributeFieldImpl::getTypes() Sequence< Type > IdlAttributeFieldImpl::getTypes()
throw (::com::sun::star::uno::RuntimeException, std::exception) throw (::com::sun::star::uno::RuntimeException, std::exception)
{ {
static OTypeCollection * s_pTypes = 0; static ::cppu::OTypeCollection * s_pTypes = 0;
if (! s_pTypes) if (! s_pTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! s_pTypes) if (! s_pTypes)
{ {
static OTypeCollection s_aTypes( static ::cppu::OTypeCollection s_aTypes(
::getCppuType( (const Reference< XIdlField2 > *)0 ), ::getCppuType( (const Reference< XIdlField2 > *)0 ),
::getCppuType( (const Reference< XIdlField > *)0 ), ::getCppuType( (const Reference< XIdlField > *)0 ),
IdlMemberImpl::getTypes() ); IdlMemberImpl::getTypes() );
...@@ -133,7 +136,7 @@ Reference< XIdlClass > IdlAttributeFieldImpl::getDeclaringClass() ...@@ -133,7 +136,7 @@ Reference< XIdlClass > IdlAttributeFieldImpl::getDeclaringClass()
{ {
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
OUString aName(getAttributeTypeDescr()->aBase.aBase.pTypeName); OUString aName(getAttributeTypeDescr()->aBase.aBase.pTypeName);
...@@ -399,13 +402,13 @@ void IdlInterfaceMethodImpl::release() throw() ...@@ -399,13 +402,13 @@ void IdlInterfaceMethodImpl::release() throw()
Sequence< Type > IdlInterfaceMethodImpl::getTypes() Sequence< Type > IdlInterfaceMethodImpl::getTypes()
throw (::com::sun::star::uno::RuntimeException, std::exception) throw (::com::sun::star::uno::RuntimeException, std::exception)
{ {
static OTypeCollection * s_pTypes = 0; static ::cppu::OTypeCollection * s_pTypes = 0;
if (! s_pTypes) if (! s_pTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! s_pTypes) if (! s_pTypes)
{ {
static OTypeCollection s_aTypes( static ::cppu::OTypeCollection s_aTypes(
::getCppuType( (const Reference< XIdlMethod > *)0 ), ::getCppuType( (const Reference< XIdlMethod > *)0 ),
IdlMemberImpl::getTypes() ); IdlMemberImpl::getTypes() );
s_pTypes = &s_aTypes; s_pTypes = &s_aTypes;
...@@ -427,7 +430,7 @@ Reference< XIdlClass > IdlInterfaceMethodImpl::getDeclaringClass() ...@@ -427,7 +430,7 @@ Reference< XIdlClass > IdlInterfaceMethodImpl::getDeclaringClass()
{ {
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _xDeclClass.is()) if (! _xDeclClass.is())
{ {
OUString aName(getMethodTypeDescr()->aBase.aBase.pTypeName); OUString aName(getMethodTypeDescr()->aBase.aBase.pTypeName);
...@@ -458,7 +461,7 @@ Sequence< Reference< XIdlClass > > IdlInterfaceMethodImpl::getExceptionTypes() ...@@ -458,7 +461,7 @@ Sequence< Reference< XIdlClass > > IdlInterfaceMethodImpl::getExceptionTypes()
{ {
if (! _pExceptionTypes) if (! _pExceptionTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pExceptionTypes) if (! _pExceptionTypes)
{ {
sal_Int32 nExc = getMethodTypeDescr()->nExceptions; sal_Int32 nExc = getMethodTypeDescr()->nExceptions;
...@@ -484,7 +487,7 @@ Sequence< Reference< XIdlClass > > IdlInterfaceMethodImpl::getParameterTypes() ...@@ -484,7 +487,7 @@ Sequence< Reference< XIdlClass > > IdlInterfaceMethodImpl::getParameterTypes()
{ {
if (! _pParamTypes) if (! _pParamTypes)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pParamTypes) if (! _pParamTypes)
{ {
sal_Int32 nParams = getMethodTypeDescr()->nParams; sal_Int32 nParams = getMethodTypeDescr()->nParams;
...@@ -510,7 +513,7 @@ Sequence< ParamInfo > IdlInterfaceMethodImpl::getParameterInfos() ...@@ -510,7 +513,7 @@ Sequence< ParamInfo > IdlInterfaceMethodImpl::getParameterInfos()
{ {
if (! _pParamInfos) if (! _pParamInfos)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pParamInfos) if (! _pParamInfos)
{ {
sal_Int32 nParams = getMethodTypeDescr()->nParams; sal_Int32 nParams = getMethodTypeDescr()->nParams;
...@@ -778,7 +781,7 @@ InterfaceIdlClassImpl::~InterfaceIdlClassImpl() ...@@ -778,7 +781,7 @@ InterfaceIdlClassImpl::~InterfaceIdlClassImpl()
Sequence< Reference< XIdlClass > > InterfaceIdlClassImpl::getSuperclasses() Sequence< Reference< XIdlClass > > InterfaceIdlClassImpl::getSuperclasses()
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard(getMutexAccess()); ::osl::MutexGuard aGuard(getMutexAccess());
if (_xSuperClasses.getLength() == 0) { if (_xSuperClasses.getLength() == 0) {
typelib_InterfaceTypeDescription * pType = getTypeDescr(); typelib_InterfaceTypeDescription * pType = getTypeDescr();
_xSuperClasses.realloc(pType->nBaseTypes); _xSuperClasses.realloc(pType->nBaseTypes);
...@@ -853,7 +856,7 @@ Uik InterfaceIdlClassImpl::getUik() ...@@ -853,7 +856,7 @@ Uik InterfaceIdlClassImpl::getUik()
Sequence< Reference< XIdlMethod > > InterfaceIdlClassImpl::getMethods() Sequence< Reference< XIdlMethod > > InterfaceIdlClassImpl::getMethods()
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pSortedMemberInit) if (! _pSortedMemberInit)
initMembers(); initMembers();
...@@ -873,7 +876,7 @@ Sequence< Reference< XIdlMethod > > InterfaceIdlClassImpl::getMethods() ...@@ -873,7 +876,7 @@ Sequence< Reference< XIdlMethod > > InterfaceIdlClassImpl::getMethods()
Sequence< Reference< XIdlField > > InterfaceIdlClassImpl::getFields() Sequence< Reference< XIdlField > > InterfaceIdlClassImpl::getFields()
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pSortedMemberInit) if (! _pSortedMemberInit)
initMembers(); initMembers();
...@@ -893,7 +896,7 @@ Sequence< Reference< XIdlField > > InterfaceIdlClassImpl::getFields() ...@@ -893,7 +896,7 @@ Sequence< Reference< XIdlField > > InterfaceIdlClassImpl::getFields()
Reference< XIdlMethod > InterfaceIdlClassImpl::getMethod( const OUString & rName ) Reference< XIdlMethod > InterfaceIdlClassImpl::getMethod( const OUString & rName )
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pSortedMemberInit) if (! _pSortedMemberInit)
initMembers(); initMembers();
...@@ -923,7 +926,7 @@ Reference< XIdlMethod > InterfaceIdlClassImpl::getMethod( const OUString & rName ...@@ -923,7 +926,7 @@ Reference< XIdlMethod > InterfaceIdlClassImpl::getMethod( const OUString & rName
Reference< XIdlField > InterfaceIdlClassImpl::getField( const OUString & rName ) Reference< XIdlField > InterfaceIdlClassImpl::getField( const OUString & rName )
throw(::com::sun::star::uno::RuntimeException, std::exception) throw(::com::sun::star::uno::RuntimeException, std::exception)
{ {
MutexGuard aGuard( getMutexAccess() ); ::osl::MutexGuard aGuard( getMutexAccess() );
if (! _pSortedMemberInit) if (! _pSortedMemberInit)
initMembers(); initMembers();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment