diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-10-19 11:09:13 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-10-20 08:50:48 +0200 |
commit | 14d45665433eec974acd96f813f2bf314bdb3eba (patch) | |
tree | 814e8fc8448754fa32ad447095a4353ab4dfb7d1 /codemaker | |
parent | use std::unique_ptr in EscherSolverContainer (diff) | |
download | core-14d45665433eec974acd96f813f2bf314bdb3eba.tar.gz core-14d45665433eec974acd96f813f2bf314bdb3eba.zip |
loplugin:constmethod in codemaker,registry,store
Change-Id: Ie75875974f054ff79bd64b1c261e79e2b78eb7fc
Reviewed-on: https://gerrit.libreoffice.org/43540
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'codemaker')
-rw-r--r-- | codemaker/source/codemaker/global.cxx | 2 | ||||
-rw-r--r-- | codemaker/source/cppumaker/cppuoptions.cxx | 2 | ||||
-rw-r--r-- | codemaker/source/cppumaker/cppuoptions.hxx | 2 | ||||
-rw-r--r-- | codemaker/source/cppumaker/cpputype.cxx | 36 | ||||
-rw-r--r-- | codemaker/source/javamaker/javaoptions.cxx | 2 | ||||
-rw-r--r-- | codemaker/source/javamaker/javaoptions.hxx | 2 |
6 files changed, 23 insertions, 23 deletions
diff --git a/codemaker/source/codemaker/global.cxx b/codemaker/source/codemaker/global.cxx index 46d5a07e35a6..30484f7e6111 100644 --- a/codemaker/source/codemaker/global.cxx +++ b/codemaker/source/codemaker/global.cxx @@ -273,7 +273,7 @@ FileStream::~FileStream() osl_closeFile(m_file); } -bool FileStream::isValid() +bool FileStream::isValid() const { if ( m_file ) return true; diff --git a/codemaker/source/cppumaker/cppuoptions.cxx b/codemaker/source/cppumaker/cppuoptions.cxx index af644af1538f..d4575968b784 100644 --- a/codemaker/source/cppumaker/cppuoptions.cxx +++ b/codemaker/source/cppumaker/cppuoptions.cxx @@ -320,7 +320,7 @@ OString CppuOptions::prepareHelp() return help; } -OString CppuOptions::prepareVersion() +OString CppuOptions::prepareVersion() const { OString version = m_program + " Version 2.0\n\n"; return version; diff --git a/codemaker/source/cppumaker/cppuoptions.hxx b/codemaker/source/cppumaker/cppuoptions.hxx index 497fbd96402b..882dfa66dbef 100644 --- a/codemaker/source/cppumaker/cppuoptions.hxx +++ b/codemaker/source/cppumaker/cppuoptions.hxx @@ -32,7 +32,7 @@ public: OString prepareHelp() override; - OString prepareVersion(); + OString prepareVersion() const; protected: }; diff --git a/codemaker/source/cppumaker/cpputype.cxx b/codemaker/source/cppumaker/cpputype.cxx index dafbe682fd8b..bff92a920d57 100644 --- a/codemaker/source/cppumaker/cpputype.cxx +++ b/codemaker/source/cppumaker/cpputype.cxx @@ -167,7 +167,7 @@ public: CppuOptions const & options); void dumpDependedTypes( - codemaker::GeneratedTypeSet & generated, CppuOptions const & options); + codemaker::GeneratedTypeSet & generated, CppuOptions const & options) const; virtual void dumpHdlFile( FileStream & out, codemaker::cppumaker::Includes & includes) { @@ -176,7 +176,7 @@ public: virtual void dumpHppFile(FileStream& o, codemaker::cppumaker::Includes & includes) = 0; - OUString dumpHeaderDefine(FileStream& o, OUString const & extension); + OUString dumpHeaderDefine(FileStream& o, OUString const & extension) const; void dumpGetCppuType(FileStream & out); @@ -198,7 +198,7 @@ public: OUString getTypeClass(OUString const & name, bool cStyle = false); void dumpCppuGetType( - FileStream & out, OUString const & name, OUString const * ownName = nullptr); + FileStream & out, OUString const & name, OUString const * ownName = nullptr) const; sal_uInt32 getInheritedMemberCount(); @@ -454,7 +454,7 @@ bool CppuType::dumpFile( } void CppuType::dumpDependedTypes( - codemaker::GeneratedTypeSet & generated, CppuOptions const & options) + codemaker::GeneratedTypeSet & generated, CppuOptions const & options) const { if (!options.isValid("-nD")) { codemaker::cppumaker::Dependencies::Map const & map @@ -466,7 +466,7 @@ void CppuType::dumpDependedTypes( } OUString CppuType::dumpHeaderDefine( - FileStream & out, OUString const & extension) + FileStream & out, OUString const & extension) const { OUString def( "INCLUDED_" + name_.replace('.', '_').toAsciiUpperCase() + "_" @@ -849,7 +849,7 @@ void CppuType::dumpType( } void CppuType::dumpCppuGetType( - FileStream & out, OUString const & name, OUString const * ownName) + FileStream & out, OUString const & name, OUString const * ownName) const { //TODO: What are these calls good for? OUString nucleus; @@ -1110,16 +1110,16 @@ public: virtual void dumpDeclaration(FileStream& o) override; void dumpHppFile(FileStream& o, codemaker::cppumaker::Includes & includes) override; - void dumpAttributes(FileStream& o); - void dumpMethods(FileStream& o); + void dumpAttributes(FileStream& o) const; + void dumpMethods(FileStream& o) const; void dumpNormalGetCppuType(FileStream& o) override; void dumpComprehensiveGetCppuType(FileStream& o) override; void dumpCppuAttributeRefs(FileStream& o, sal_uInt32& index); void dumpCppuMethodRefs(FileStream& o, sal_uInt32& index); void dumpCppuAttributes(FileStream& o, sal_uInt32& index); void dumpCppuMethods(FileStream& o, sal_uInt32& index); - void dumpAttributesCppuDecl(FileStream & out, std::set< OUString > * seen); - void dumpMethodsCppuDecl(FileStream & out, std::set< OUString > * seen); + void dumpAttributesCppuDecl(FileStream & out, std::set< OUString > * seen) const; + void dumpMethodsCppuDecl(FileStream & out, std::set< OUString > * seen) const; private: virtual void addComprehensiveGetCppuTypeIncludes( @@ -1131,11 +1131,11 @@ private: void dumpExceptionTypeName( FileStream & out, OUString const & prefix, sal_uInt32 index, - OUString const & name); + OUString const & name) const; sal_Int32 dumpExceptionTypeNames( FileStream & out, OUString const & prefix, - std::vector< OUString > const & exceptions, bool runtimeException); + std::vector< OUString > const & exceptions, bool runtimeException) const; rtl::Reference< unoidl::InterfaceTypeEntity > entity_; bool m_isDeprecated; @@ -1196,7 +1196,7 @@ void InterfaceType::dumpHppFile( out << "}\n\n#endif // "<< headerDefine << "\n"; } -void InterfaceType::dumpAttributes(FileStream & out) +void InterfaceType::dumpAttributes(FileStream & out) const { if (!entity_->getDirectAttributes().empty()) { out << "\n" << indent() << "// Attributes\n"; @@ -1219,7 +1219,7 @@ void InterfaceType::dumpAttributes(FileStream & out) } } -void InterfaceType::dumpMethods(FileStream & out) +void InterfaceType::dumpMethods(FileStream & out) const { if (!entity_->getDirectMethods().empty()) { out << "\n" << indent() << "// Methods\n"; @@ -1551,7 +1551,7 @@ void InterfaceType::dumpCppuMethods(FileStream & out, sal_uInt32 & index) } void InterfaceType::dumpAttributesCppuDecl( - FileStream & out, std::set< OUString > * seen) + FileStream & out, std::set< OUString > * seen) const { assert(seen != nullptr); for (const unoidl::InterfaceTypeEntity::Attribute& attr : entity_->getDirectAttributes()) { @@ -1572,7 +1572,7 @@ void InterfaceType::dumpAttributesCppuDecl( } void InterfaceType::dumpMethodsCppuDecl( - FileStream & out, std::set< OUString > * seen) + FileStream & out, std::set< OUString > * seen) const { assert(seen != nullptr); for (const unoidl::InterfaceTypeEntity::Method& method : entity_->getDirectMethods()) { @@ -1586,7 +1586,7 @@ void InterfaceType::dumpMethodsCppuDecl( void InterfaceType::dumpExceptionTypeName( FileStream & out, OUString const & prefix, sal_uInt32 index, - OUString const & name) + OUString const & name) const { out << indent() << "::rtl::OUString the_" << prefix << "ExceptionName" << index << "( \"" << name << "\" );\n"; @@ -1594,7 +1594,7 @@ void InterfaceType::dumpExceptionTypeName( sal_Int32 InterfaceType::dumpExceptionTypeNames( FileStream & out, OUString const & prefix, - std::vector< OUString > const & exceptions, bool runtimeException) + std::vector< OUString > const & exceptions, bool runtimeException) const { sal_Int32 count = 0; for (const OUString& ex : exceptions) { diff --git a/codemaker/source/javamaker/javaoptions.cxx b/codemaker/source/javamaker/javaoptions.cxx index 19818f8143be..798b32b55683 100644 --- a/codemaker/source/javamaker/javaoptions.cxx +++ b/codemaker/source/javamaker/javaoptions.cxx @@ -242,7 +242,7 @@ OString JavaOptions::prepareHelp() return help; } -OString JavaOptions::prepareVersion() +OString JavaOptions::prepareVersion() const { OString version(m_program); version += " Version 2.0\n\n"; diff --git a/codemaker/source/javamaker/javaoptions.hxx b/codemaker/source/javamaker/javaoptions.hxx index e4eed6883849..6f6d321a2a94 100644 --- a/codemaker/source/javamaker/javaoptions.hxx +++ b/codemaker/source/javamaker/javaoptions.hxx @@ -32,7 +32,7 @@ public: OString prepareHelp() override; - OString prepareVersion(); + OString prepareVersion() const; protected: }; |