compact namespace decl

used
   git grep -lw namespace
    | xargs perl -i -p0e 's/(\w+)\s*.\{.\s*namespace\s*(\w+)/\1::\2/smg;'
 to do the initial replace, then compiled and fixed.

Change-Id: If69904d75940c851aeffab0e78c4ba02cc968d44
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98526
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin 2020-07-10 15:19:30 +02:00
parent abea0d6647
commit da7489eb6a
36 changed files with 75 additions and 253 deletions

View File

@ -25,13 +25,10 @@
#include <vector>
// forward declaractions
namespace com::sun::star
namespace com::sun::star::xml::dom
{
namespace xml::dom
{
class XNodeList;
namespace events { class XEventListener; }
}
class XNodeList;
namespace events { class XEventListener; }
}

View File

@ -25,10 +25,7 @@
#include <com/sun/star/xforms/XFormsEvent.hpp>
#include <com/sun/star/xml/dom/events/XEventTarget.hpp>
namespace com {
namespace sun {
namespace star {
namespace xforms {
namespace com::sun::star::xforms {
class XFormsEventConcrete : public cppu::WeakImplHelper< XFormsEvent > {
@ -67,7 +64,7 @@ class XFormsEventConcrete : public cppu::WeakImplHelper< XFormsEvent > {
bool m_cancelable;
};
} } } }
}
#endif

View File

@ -27,9 +27,7 @@
// namespaces
namespace framework{
namespace pattern{
namespace frame{
namespace framework::pattern::frame{
/** @short close (or dispose) the given resource.
@ -77,9 +75,7 @@ inline bool closeIt(const css::uno::Reference< css::uno::XInterface >& xResource
return true;
}
} // namespace frame
} // namespace pattern
} // namespace framework
} // namespace framework::pattern::frame
#endif // INCLUDED_FRAMEWORK_SOURCE_INC_PATTERN_FRAME_HXX

View File

@ -26,8 +26,7 @@
namespace com::sun::star::frame { class XModel; }
namespace com::sun::star::uno { template <typename > class Reference; }
namespace basic {
namespace vba {
namespace basic::vba {
/* This header contains public helper functions for VBA used from this module
and from other VBA implementation modules such as vbahelper.
@ -88,8 +87,7 @@ BASIC_DLLPUBLIC void registerCurrentDirectory(
const OUString& rPath );
} // namespace vba
} // namespace basic
} // namespace basic::vba
#endif

View File

@ -26,9 +26,7 @@
namespace rtl { class OString; }
namespace codemaker {
namespace UnoType {
namespace codemaker::UnoType {
/**
An enumeration of all the sorts of relevant UNOIDL entities.
*/
@ -82,7 +80,6 @@ namespace UnoType {
rtl::OString decompose(
rtl::OString const & type, sal_Int32 * rank = nullptr,
std::vector< rtl::OString > * arguments = nullptr);
}
}

View File

@ -33,25 +33,12 @@
#include <memory>
#include <vector>
namespace com
namespace com::sun::star::ui::dialogs
{
namespace sun
{
namespace star
{
namespace ui
{
namespace dialogs
{
class XFilePicker3;
struct FilePickerEvent;
struct DialogClosedEvent;
}
}
}
}
class XFilePicker3;
struct FilePickerEvent;
struct DialogClosedEvent;
}
namespace com::sun::star::awt { class XWindow; }
namespace com::sun::star::uno { template <typename > class Reference; }
namespace weld { class Window; }

View File

@ -33,19 +33,10 @@
#include <vector>
namespace com
namespace com::sun::star::frame
{
namespace sun
{
namespace star
{
namespace frame
{
class XFrame;
class XController;
}
}
}
class XFrame;
class XController;
}
class SvBorder;

View File

@ -18,19 +18,11 @@
#include <svl/svldllapi.h>
namespace com {
namespace sun {
namespace star {
namespace security {
class XCertificate; }
}}}
namespace com::sun::star::security { class XCertificate; }
class SvStream;
struct SignatureInformation;
namespace svl {
namespace crypto {
namespace svl::crypto {
/// Converts a hex-encoded string into a byte array.
SVL_DLLPUBLIC std::vector<unsigned char> DecodeHexString(const OString& rHex);
@ -84,7 +76,6 @@ private:
OUString m_aSignPassword;
};
}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View File

@ -71,9 +71,7 @@ struct SignatureReferenceInformation
typedef ::std::vector< SignatureReferenceInformation > SignatureReferenceInformations;
namespace svl
{
namespace crypto
namespace svl::crypto
{
/// Specifies the algorithm used for signature generation and validation.
enum class SignatureMethodAlgorithm
@ -82,7 +80,7 @@ enum class SignatureMethodAlgorithm
ECDSA
};
}
}
struct SignatureInformation
{

View File

@ -30,9 +30,7 @@ namespace com :: sun :: star :: uno { class XComponentContext; }
class SvStream;
namespace svt
{
namespace GraphicAccess
namespace svt::GraphicAccess
{
/** Helpers for obtaining streams (which also can be used with the ImageProducer)
@ -62,8 +60,7 @@ UNLESS_MERGELIBS(SVT_DLLPUBLIC) css::uno::Reference<css::io::XInputStream> getIm
css::uno::Reference<css::uno::XComponentContext> const & rxContext,
OUString const & rImageResourceURL);
} // namespace GraphicAccess
} // namespace svt
} // namespace svt::GraphicAccess
#endif // INCLUDED_SVTOOLS_IMAGERESOURCEACCESS_HXX

View File

@ -25,13 +25,10 @@
#include <sal/types.h>
#include <rtl/ustring.hxx>
namespace com {
namespace sun {
namespace star {
namespace uno {
namespace com::sun::star::uno {
class Type;
class Any;
} } } }
}
#define BASEPROPERTY_NOTFOUND 0

View File

@ -31,16 +31,7 @@ class CharClass;
namespace com::sun::star::lang { struct Locale; }
namespace com::sun::star::util { class XTextSearch2; }
namespace com {
namespace sun {
namespace star {
namespace util {
struct SearchResult;
}
}
}
}
namespace com::sun::star::util { struct SearchResult; }
namespace i18nutil {
struct SearchOptions;
struct SearchOptions2;

View File

@ -26,20 +26,11 @@
#include <tools/stream.hxx>
#include <memory>
namespace com
{
namespace sun
{
namespace star
{
namespace io
namespace com::sun::star::io
{
class XStream;
class XInputStream;
}
}
}
}
namespace com::sun::star::awt { class XWindow; }

View File

@ -22,8 +22,7 @@
#include <comphelper/servicedecl.hxx>
namespace comphelper {
namespace service_decl {
namespace comphelper::service_decl {
template <typename ImplT_, typename WithArgsT = with_args<false> >
struct vba_service_class_ : public serviceimpl_base< detail::OwnServiceImpl<ImplT_>, WithArgsT >
{
@ -43,8 +42,7 @@ struct vba_service_class_ : public serviceimpl_base< detail::OwnServiceImpl<Impl
explicit vba_service_class_( PostProcessFuncT const& postProcessFunc ) : baseT( postProcessFunc ) {}
};
} // namespace service_decl
} // namespace comphelper
} // namespace comphelper::service_decl
#endif

View File

@ -36,10 +36,8 @@
#include <sfx2/docfilt.hxx>
#include <sfx2/docfile.hxx>
namespace ooo
namespace ooo::vba
{
namespace vba
{
inline css::uno::Reference< css::lang::XMultiServiceFactory > getVBAServiceFactory( SfxObjectShell const * pShell )
{
@ -74,7 +72,6 @@ namespace ooo
// word seems to return an erroneous mime type :-/ "application/msword" not consistent with the excel one
inline bool isAlienWordDoc( SfxObjectShell const & rDocShell ) { return isAlienDoc( rDocShell, "application/msword" ); }
}
}
#endif

View File

@ -51,9 +51,7 @@ class SfxObjectShell;
class SfxViewFrame;
class SfxViewShell;
namespace ooo
{
namespace vba
namespace ooo::vba
{
/// @throws css::lang::IllegalArgumentException
template < class T >
@ -273,8 +271,7 @@ public:
static void runtimeexception( ErrCode err );
};
} // vba
} // ooo
} // ooo::vba
namespace ov = ooo::vba;

View File

@ -27,9 +27,7 @@
#include <sal/types.h>
#include <vbahelper/vbahelper.hxx>
namespace ooo
{
namespace vba
namespace ooo::vba
{
template< typename T1, typename T2 >
class DefaultReturnHelper : public ::cppu::WeakImplHelper< T2, css::script::XDefaultProperty >
@ -49,8 +47,7 @@ namespace ooo
ReturnInteger( sal_Int32 nValue ) : ReturnInteger_BASE( nValue ){}
};
} // vba
} // ooo
} // ooo::vba
#endif

View File

@ -22,15 +22,12 @@
#include <rtl/ustring.hxx>
namespace registry
{
namespace tools
namespace registry::tools
{
OUString convertToFileUrl(char const * filename, sal_Int32 length);
} // namespace tools
} // namespace registry
} // namespace registry::tools
#endif /* INCLUDED_REGISTRY_TOOLS_FILEURL_HXX */

View File

@ -23,9 +23,7 @@
#include <string>
#include <vector>
namespace registry
{
namespace tools
namespace registry::tools
{
class Options
{
@ -52,8 +50,7 @@ protected:
virtual void printUsage_Impl() const = 0;
};
} // namespace tools
} // namespace registry
} // namespace registry::tools
#endif /* INCLUDED_REGISTRY_TOOLS_OPTIONS_HXX */

View File

@ -22,8 +22,7 @@
#include <sal/types.h>
namespace sca {
namespace analysis {
namespace sca::analysis {
// BESSEL functions
@ -57,8 +56,7 @@ double BesselY( double x, sal_Int32 n );
*/
double BesselK( double x, sal_Int32 n );
} // namespace analysis
} // namespace sca
} // namespace sca::analysis
#endif

View File

@ -42,8 +42,7 @@ namespace com::sun::star::lang { class XMultiServiceFactory; }
#define RETURN_FINITE(d) if( !std::isfinite( d ) ) throw css::lang::IllegalArgumentException(); return d;
namespace sca {
namespace pricing {
namespace sca::pricing {
enum class ScaCategory
{
@ -112,8 +111,7 @@ struct FindScaFuncData
bool operator() ( ScaFuncData const & rCandidate ) const { return rCandidate.Is(m_rId); }
};
} // namespace pricing
} // namespace sca
} // namespace sca::pricing
css::uno::Reference< css::uno::XInterface > SAL_CALL PricingFunctionAddIn_CreateInstance(

View File

@ -42,7 +42,6 @@ namespace drawinglayer {
namespace processor2d {
class BaseProcessor2D;
}
namespace primitive2d {
class PolygonHairlinePrimitive2D;
}

View File

@ -54,10 +54,8 @@ class SfxInterface;
class BasicManager;
class SfxBasicManagerHolder;
class SfxBasicManagerCreationListener;
namespace sfx2::sidebar { class Theme; }
namespace sfx2 {
namespace sidebar { class Theme; }
}
typedef std::vector<SfxDdeDocTopic_Impl*> SfxDdeDocTopics_Impl;

View File

@ -23,19 +23,7 @@
#include <sfx2/dockwin.hxx>
namespace com
{
namespace sun
{
namespace star
{
namespace frame
{
class XFrame;
}
}
}
}
namespace com::sun::star::frame { class XFrame; }
// forward ---------------------------------------------------------------

View File

@ -24,19 +24,10 @@
#include <com/sun/star/beans/Optional.hpp>
namespace com
{
namespace sun
{
namespace star
{
namespace uno
namespace com::sun::star::uno
{
class Any;
}
}
}
}
namespace kf5access
{

View File

@ -27,19 +27,7 @@
#include <com/sun/star/lang/XServiceInfo.hpp>
namespace com
{
namespace sun
{
namespace star
{
namespace beans
{
struct PropertyValue;
}
}
}
}
namespace com::sun::star::beans { struct PropertyValue; }
class SmFilterDetect : public ::cppu::WeakImplHelper< css::document::XExtendedFilterDetection, css::lang::XServiceInfo >
{

View File

@ -25,12 +25,8 @@
#include <com/sun/star/uno/Sequence.hxx>
#include <vcl/weld.hxx>
namespace com {
namespace sun {
namespace star {
namespace security {
class XCertificate; }
}}}
namespace com::sun::star::security { class XCertificate; }
class MacroWarning : public weld::MessageDialogController
{

View File

@ -18,8 +18,7 @@
#include <sal/log.hxx>
#include <xmloff/dllapi.h>
namespace xmloff {
namespace token {
namespace xmloff::token {
class TokenMap
{
@ -89,8 +88,7 @@ private:
TokenMap& mrTokenMap;
};
} // namespace token
} // namespace xmloff
} // namespace xmloff::token
#endif

View File

@ -25,9 +25,7 @@
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/XPropertyState.hpp>
namespace xmloff
{
namespace chart
namespace xmloff::chart
{
class ColorPropertySet : public ::cppu::WeakImplHelper<
@ -76,8 +74,7 @@ private:
Color m_nDefaultColor;
};
} // namespace chart
} // namespace xmloff
} // namespace xmloff::chart
// XMLOFF_COLORPROPERTYSET_HXX
#endif

View File

@ -26,14 +26,10 @@
#include <vector>
namespace com {
namespace sun {
namespace star {
namespace io {
class XStream; }
namespace embed {
class XStorage; }
}}}
namespace com::sun::star {
namespace io { class XStream; }
namespace embed { class XStorage; }
}
namespace com::sun::star::xml::sax { class XDocumentHandler; }

View File

@ -30,11 +30,7 @@
#include <com/sun/star/xml/crypto/XSEInitializer.hpp>
namespace com
{
namespace sun
{
namespace star
namespace com::sun::star
{
namespace beans
{
@ -57,8 +53,6 @@ namespace uno
class XComponentContext;
}
}
}
}
class PDFSignatureHelper;
/// Manages signatures (addition, removal), used by DigitalSignaturesDialog.

View File

@ -13,19 +13,14 @@
#include <xmlsecuritydllapi.h>
namespace vcl
{
namespace filter
namespace vcl::filter
{
class PDFObjectElement;
}
}
struct SignatureInformation;
class SvStream;
namespace xmlsecurity
{
namespace pdfio
namespace xmlsecurity::pdfio
{
/**
* @param rInformation The actual result.
@ -36,8 +31,7 @@ XMLSECURITY_DLLPUBLIC bool ValidateSignature(SvStream& rStream,
vcl::filter::PDFObjectElement* pSignature,
SignatureInformation& rInformation, bool bLast);
} // namespace pdfio
} // namespace xmlsecurity
} // namespace xmlsecurity::pdfio
#endif // INCLUDED_XMLSECURITY_INC_PDFIO_PDFDOCUMENT_HXX

View File

@ -15,11 +15,7 @@
#include <svl/sigstruct.hxx>
namespace com
{
namespace sun
{
namespace star
namespace com::sun::star
{
namespace frame
{
@ -37,16 +33,11 @@ namespace security
{
struct DocumentSignatureInformation;
}
namespace xml
{
namespace crypto
namespace xml::crypto
{
class XSecurityEnvironment;
}
}
}
}
}
/// Handles signatures of a PDF file.
class XMLSECURITY_DLLPUBLIC PDFSignatureHelper

View File

@ -31,15 +31,13 @@
class DateTime;
class UriBindingHelper;
namespace com {
namespace sun {
namespace star {
namespace io {
class XOutputStream;
class XInputStream; }
namespace embed {
class XStorage; }
}}}
namespace com::sun::star {
namespace io {
class XOutputStream;
class XInputStream;
}
namespace embed { class XStorage; }
}
namespace com::sun::star::graphic { class XGraphic; }
namespace com::sun::star::uno { class XComponentContext; }

View File

@ -26,14 +26,10 @@
#include <com/sun/star/xml/crypto/XUriBinding.hpp>
namespace com {
namespace sun {
namespace star {
namespace io {
class XInputStream; }
namespace embed {
class XStorage; }
}}}
namespace com::sun::star {
namespace io { class XInputStream; }
namespace embed { class XStorage; }
}
// XUriBinding

View File

@ -14,11 +14,7 @@
#include <svl/sigstruct.hxx>
namespace com
{
namespace sun
{
namespace star
namespace com::sun::star
{
namespace embed
{
@ -28,16 +24,11 @@ namespace uno
{
class XComponentContext;
}
namespace xml
{
namespace sax
namespace xml::sax
{
class XDocumentHandler;
}
}
}
}
}
/// Writes a single OOXML digital signature.
class OOXMLSecExporter