2023-02-20 22:11:18 +00:00
|
|
|
#include "formidrefid.hpp"
|
|
|
|
|
2023-03-24 11:31:37 +00:00
|
|
|
#include "serializerefid.hpp"
|
|
|
|
|
2023-02-20 22:11:18 +00:00
|
|
|
#include <ostream>
|
|
|
|
|
|
|
|
namespace ESM
|
|
|
|
{
|
|
|
|
std::string FormIdRefId::toString() const
|
|
|
|
{
|
2023-03-24 11:31:37 +00:00
|
|
|
std::string result;
|
2023-04-07 19:40:44 +00:00
|
|
|
result.resize(getHexIntegralSize(mValue) + 2, '\0');
|
|
|
|
serializeHexIntegral(mValue, 0, result);
|
2023-03-24 11:31:37 +00:00
|
|
|
return result;
|
2023-02-20 22:11:18 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
std::string FormIdRefId::toDebugString() const
|
|
|
|
{
|
2023-03-24 11:31:37 +00:00
|
|
|
std::string result;
|
|
|
|
serializeRefIdValue(mValue, formIdRefIdPrefix, result);
|
|
|
|
return result;
|
2023-02-20 22:11:18 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
std::ostream& operator<<(std::ostream& stream, FormIdRefId value)
|
|
|
|
{
|
2023-03-24 11:31:37 +00:00
|
|
|
return stream << value.toDebugString();
|
2023-02-20 22:11:18 +00:00
|
|
|
}
|
|
|
|
}
|