Core/MemoryStream: Add hash overload for MemoryStream
Former-commit-id: ab618e0db87bd85994a3b11a29c7f38e28d8aae3
This commit is contained in:
parent
11f85ab9bb
commit
35b27bbe67
|
|
@ -47,6 +47,14 @@ namespace Nz
|
|||
ByteArray m_buffer;
|
||||
UInt64 m_pos;
|
||||
};
|
||||
|
||||
class AbstractHash;
|
||||
|
||||
inline bool HashAppend(AbstractHash* hash, const String& string);
|
||||
NAZARA_CORE_API bool Serialize(SerializationContext& context, const String& string);
|
||||
NAZARA_CORE_API bool Unserialize(UnserializationContext& context, String* string);
|
||||
}
|
||||
|
||||
#include <Nazara/Core/MemoryStream.hpp>
|
||||
|
||||
#endif // NAZARA_MEMORYSTREAM_HPP
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
// Copyright (C) 2015 Jérôme Leclercq
|
||||
// This file is part of the "Nazara Engine - Core module"
|
||||
// For conditions of distribution and use, see copyright notice in Config.hpp
|
||||
|
||||
#include <Nazara/Core/Debug.hpp>
|
||||
|
||||
namespace Nz
|
||||
{
|
||||
inline bool HashAppend(AbstractHash* hash, const MemoryStream& stream)
|
||||
{
|
||||
return HashAppend(hash, stream.GetBuffer());
|
||||
}
|
||||
}
|
||||
|
||||
#include <Nazara/Core/DebugOff.hpp>
|
||||
Loading…
Reference in New Issue