mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-30 09:45:36 +00:00
Add const modifier to encoder type
This commit is contained in:
parent
c7ba4100e1
commit
13c970b37a
3 changed files with 5 additions and 5 deletions
|
@ -38,7 +38,7 @@ namespace ESM
|
|||
}
|
||||
|
||||
bool Reader::getStringImpl(std::string& str, std::size_t size,
|
||||
std::istream& stream, ToUTF8::StatelessUtf8Encoder* encoder, bool hasNull)
|
||||
std::istream& stream, const ToUTF8::StatelessUtf8Encoder* encoder, bool hasNull)
|
||||
{
|
||||
std::size_t newSize = size;
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ namespace ESM
|
|||
|
||||
virtual inline bool hasMoreRecs() const = 0;
|
||||
|
||||
virtual inline void setEncoder(ToUTF8::StatelessUtf8Encoder* encoder) = 0;
|
||||
virtual inline void setEncoder(const ToUTF8::StatelessUtf8Encoder* encoder) = 0;
|
||||
|
||||
// used to check for dependencies e.g. CS::Editor::run()
|
||||
virtual inline const std::vector<ESM::MasterData>& getGameFiles() const = 0;
|
||||
|
@ -53,7 +53,7 @@ namespace ESM
|
|||
|
||||
protected:
|
||||
bool getStringImpl(std::string& str, std::size_t size,
|
||||
std::istream& stream, ToUTF8::StatelessUtf8Encoder* encoder, bool hasNull = false);
|
||||
std::istream& stream, const ToUTF8::StatelessUtf8Encoder* encoder, bool hasNull = false);
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ namespace ESM4 {
|
|||
|
||||
ReaderContext mCtx;
|
||||
|
||||
ToUTF8::StatelessUtf8Encoder* mEncoder;
|
||||
const ToUTF8::StatelessUtf8Encoder* mEncoder;
|
||||
|
||||
std::size_t mFileSize;
|
||||
|
||||
|
@ -143,7 +143,7 @@ namespace ESM4 {
|
|||
|
||||
inline bool isEsm4() const final { return true; }
|
||||
|
||||
inline void setEncoder(ToUTF8::StatelessUtf8Encoder* encoder) final { mEncoder = encoder; };
|
||||
inline void setEncoder(const ToUTF8::StatelessUtf8Encoder* encoder) final { mEncoder = encoder; };
|
||||
|
||||
const std::vector<ESM::MasterData>& getGameFiles() const final { return mHeader.mMaster; }
|
||||
|
||||
|
|
Loading…
Reference in a new issue