loplugin:constmethod in idl,helpcompiler
Change-Id: I9b328fc0a3ebdd15a646ee6dab800ffbadb1aaef Reviewed-on: https://gerrit.libreoffice.org/44050 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
parent
4eec79bb37
commit
9ee60319c6
@ -878,7 +878,7 @@ void Components::parseModificationLayer(int layer, OUString const & url) {
|
||||
}
|
||||
}
|
||||
|
||||
int Components::getExtensionLayer(bool shared) {
|
||||
int Components::getExtensionLayer(bool shared) const {
|
||||
int layer = shared ? sharedExtensionLayer_ : userExtensionLayer_;
|
||||
if (layer == -1) {
|
||||
throw css::uno::RuntimeException(
|
||||
|
@ -139,7 +139,7 @@ private:
|
||||
|
||||
void parseModificationLayer(int layer, OUString const & url);
|
||||
|
||||
int getExtensionLayer(bool shared);
|
||||
int getExtensionLayer(bool shared) const;
|
||||
|
||||
typedef std::set< RootAccess * > WeakRootSet;
|
||||
|
||||
|
@ -56,7 +56,7 @@ class L10N_DLLPUBLIC LibXmlTreeWalker
|
||||
LibXmlTreeWalker( xmlDocPtr doc );
|
||||
void nextNode();
|
||||
xmlNodePtr currentNode() { return m_pCurrentNode;}
|
||||
bool end();
|
||||
bool end() const;
|
||||
void ignoreCurrNodesChildren();
|
||||
};
|
||||
|
||||
|
@ -43,7 +43,7 @@ void LibXmlTreeWalker::ignoreCurrNodesChildren()
|
||||
m_Queue.pop_back();
|
||||
}
|
||||
|
||||
bool LibXmlTreeWalker::end()
|
||||
bool LibXmlTreeWalker::end() const
|
||||
{
|
||||
return m_pCurrentNode->next == nullptr && m_Queue.empty();
|
||||
}
|
||||
|
@ -110,7 +110,7 @@ bool HelpIndexer::scanForFiles(OUString const & path) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void HelpIndexer::helpDocument(OUString const & fileName, Document *doc) {
|
||||
void HelpIndexer::helpDocument(OUString const & fileName, Document *doc) const {
|
||||
// Add the help path as an indexed, untokenized field.
|
||||
|
||||
OUString path = "#HLP#" + d_module + "/" + fileName;
|
||||
|
@ -112,7 +112,7 @@ public:
|
||||
void SetPath(const OUString &s) { aPath = s; }
|
||||
SvRefMemberList<SvMetaObject *>& GetStack() { return aContextStack; }
|
||||
|
||||
void Write(const OString& rText);
|
||||
void Write(const OString& rText) const;
|
||||
void WriteError( SvTokenStream & rInStm );
|
||||
void SetError( const OString& rError, SvToken const & rTok );
|
||||
void SetAndWriteError( SvTokenStream & rInStm, const OString& rError );
|
||||
|
@ -120,7 +120,7 @@ public:
|
||||
virtual void Insert( SvSlotElementList& ) override;
|
||||
void WriteSlotStubs( const OString& rShellName,
|
||||
ByteStringList & rList,
|
||||
SvStream & rOutStm );
|
||||
SvStream & rOutStm ) const;
|
||||
sal_uInt16 WriteSlotMap( const OString& rShellName,
|
||||
sal_uInt16 nCount,
|
||||
SvSlotElementList&,
|
||||
@ -128,7 +128,7 @@ public:
|
||||
SvIdlDataBase & rBase,
|
||||
SvStream & rOutStm );
|
||||
sal_uInt16 WriteSlotParamArray( SvIdlDataBase & rBase,
|
||||
SvStream & rOutStm );
|
||||
SvStream & rOutStm ) const;
|
||||
};
|
||||
|
||||
#endif // INCLUDED_IDL_INC_SLOT_HXX
|
||||
|
@ -43,7 +43,7 @@ public:
|
||||
|
||||
virtual bool Test( SvTokenStream & rInStm ) override;
|
||||
virtual bool ReadSvIdl( SvIdlDataBase &, SvTokenStream & rInStm ) override;
|
||||
sal_uLong MakeSfx( OStringBuffer& rAtrrArray );
|
||||
sal_uLong MakeSfx( OStringBuffer& rAtrrArray ) const;
|
||||
virtual void Insert( SvSlotElementList& );
|
||||
};
|
||||
|
||||
|
@ -355,7 +355,7 @@ static OString MakeSlotName( SvStringHashEntry const * pEntry )
|
||||
|
||||
void SvMetaSlot::WriteSlotStubs( const OString& rShellName,
|
||||
ByteStringList & rList,
|
||||
SvStream & rOutStm )
|
||||
SvStream & rOutStm ) const
|
||||
{
|
||||
if ( !GetExport() && !GetHidden() )
|
||||
return;
|
||||
@ -595,7 +595,7 @@ void SvMetaSlot::WriteSlot( const OString& rShellName, sal_uInt16 nCount,
|
||||
rOutStm.WriteCharPtr( " )," ) << endl;
|
||||
}
|
||||
|
||||
sal_uInt16 SvMetaSlot::WriteSlotParamArray( SvIdlDataBase & rBase, SvStream & rOutStm )
|
||||
sal_uInt16 SvMetaSlot::WriteSlotParamArray( SvIdlDataBase & rBase, SvStream & rOutStm ) const
|
||||
{
|
||||
if ( !GetExport() && !GetHidden() )
|
||||
return 0;
|
||||
|
@ -96,7 +96,7 @@ bool SvMetaAttribute::ReadSvIdl( SvIdlDataBase & rBase,
|
||||
return bOk;
|
||||
}
|
||||
|
||||
sal_uLong SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray )
|
||||
sal_uLong SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray ) const
|
||||
{
|
||||
SvMetaType * pType = GetType();
|
||||
DBG_ASSERT( pType, "no type for attribute" );
|
||||
|
@ -366,7 +366,8 @@ SvMetaClass * SvIdlDataBase::FindKnownClass( const OString& aName )
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
void SvIdlDataBase::Write(const OString& rText)
|
||||
|
||||
void SvIdlDataBase::Write(const OString& rText) const
|
||||
{
|
||||
if( nVerbosity != 0 )
|
||||
fprintf( stdout, "%s", rText.getStr() );
|
||||
|
@ -59,7 +59,7 @@ class L10N_DLLPUBLIC HelpIndexer {
|
||||
/**
|
||||
* Get the error string (empty if no error occurred).
|
||||
*/
|
||||
OUString const & getErrorMessage() { return d_error;}
|
||||
OUString const & getErrorMessage() const { return d_error;}
|
||||
|
||||
private:
|
||||
|
||||
@ -76,7 +76,7 @@ class L10N_DLLPUBLIC HelpIndexer {
|
||||
/**
|
||||
* Fill the Document with information on the given help file.
|
||||
*/
|
||||
void helpDocument(OUString const & fileName, lucene::document::Document *doc);
|
||||
void helpDocument(OUString const & fileName, lucene::document::Document *doc) const;
|
||||
|
||||
/**
|
||||
* Create a reader for the given file, and create an "empty" reader in case the file doesn't exist.
|
||||
|
@ -119,7 +119,7 @@ namespace connectivity
|
||||
OConnection(MysqlCDriver& _rDriver, sql::Driver * cppDriver);
|
||||
virtual ~OConnection();
|
||||
|
||||
rtl_TextEncoding getConnectionEncoding() { return m_settings.encoding; }
|
||||
rtl_TextEncoding getConnectionEncoding() const { return m_settings.encoding; }
|
||||
|
||||
|
||||
// OComponentHelper
|
||||
|
@ -395,7 +395,7 @@ public:
|
||||
mpCurrent = mpCurrent->next;
|
||||
}
|
||||
|
||||
bool isValid()
|
||||
bool isValid() const
|
||||
{
|
||||
return mpCurrent != nullptr;
|
||||
}
|
||||
|
@ -131,7 +131,7 @@ public:
|
||||
sal_Int32 XMLNS_DIALOGS_UID, XMLNS_SCRIPT_UID;
|
||||
|
||||
bool isEventElement(
|
||||
sal_Int32 nUid, OUString const & rLocalName )
|
||||
sal_Int32 nUid, OUString const & rLocalName ) const
|
||||
{
|
||||
return ((XMLNS_SCRIPT_UID == nUid && (rLocalName == "event" || rLocalName == "listener-event" )) ||
|
||||
(XMLNS_DIALOGS_UID == nUid && rLocalName == "event" ));
|
||||
@ -144,7 +144,7 @@ public:
|
||||
OUString const & rStyleId ) const;
|
||||
|
||||
css::uno::Reference< css::uno::XComponentContext >
|
||||
const & getComponentContext() { return _xContext; }
|
||||
const & getComponentContext() const { return _xContext; }
|
||||
css::uno::Reference< css::util::XNumberFormatsSupplier >
|
||||
const & getNumberFormatsSupplier();
|
||||
|
||||
@ -179,7 +179,7 @@ public:
|
||||
|
||||
virtual ~DialogImport() override;
|
||||
|
||||
const css::uno::Reference< css::frame::XModel >& getDocOwner() { return _xDoc; }
|
||||
const css::uno::Reference< css::frame::XModel >& getDocOwner() const { return _xDoc; }
|
||||
|
||||
// XRoot
|
||||
virtual void SAL_CALL startDocument(
|
||||
@ -269,7 +269,7 @@ class StyleElement
|
||||
short _inited, _hasValue;
|
||||
|
||||
void setFontProperties(
|
||||
css::uno::Reference< css::beans::XPropertySet > const & xProps );
|
||||
css::uno::Reference< css::beans::XPropertySet > const & xProps ) const;
|
||||
|
||||
public:
|
||||
virtual css::uno::Reference< css::xml::input::XElement >
|
||||
|
@ -274,7 +274,7 @@ void StyleElement::importVisualEffectStyle(
|
||||
}
|
||||
|
||||
void StyleElement::setFontProperties(
|
||||
Reference< beans::XPropertySet > const & xProps )
|
||||
Reference< beans::XPropertySet > const & xProps ) const
|
||||
{
|
||||
xProps->setPropertyValue("FontDescriptor", makeAny( _descr ) );
|
||||
xProps->setPropertyValue("FontEmphasisMark", makeAny( _fontEmphasisMark ) );
|
||||
|
Loading…
x
Reference in New Issue
Block a user