This commit is contained in:
watrabi
2025-10-28 14:05:46 -04:00
parent 977f1ff4b8
commit c93494f795
452 changed files with 47860 additions and 152 deletions
+49
View File
@@ -0,0 +1,49 @@
#pragma once
#include <string>
namespace RBX {
// use this for properties that contain binary data so that they're serialized to XML without roundtrip issues
class BinaryString
{
public:
BinaryString()
{
}
explicit BinaryString(const std::string& value)
: internalValue(value)
{
}
const std::string& value() const
{
return internalValue;
}
void set(const char* buffer, unsigned int size)
{
internalValue.assign(buffer, size);
}
bool operator==(const BinaryString& other) const
{
return internalValue == other.internalValue;
}
bool operator!=(const BinaryString& other) const
{
return internalValue != other.internalValue;
}
bool operator<(const BinaryString& other) const
{
return internalValue < other.internalValue;
}
private:
std::string internalValue;
};
}