34 lines
No EOL
890 B
C++
34 lines
No EOL
890 B
C++
#ifndef FLOAT_TAG_H
|
|
#define FLOAT_TAG_H
|
|
|
|
#include "Tag.h"
|
|
#include "../utils/ByteLayer.h"
|
|
#include "../utils/StringBuilder.h"
|
|
#include "../utils/StringReader.h"
|
|
#include "../types/dynamic.h"
|
|
|
|
namespace nbt
|
|
{
|
|
class FloatTag : public Tag
|
|
{
|
|
public:
|
|
FloatTag();
|
|
FloatTag(float val);
|
|
~FloatTag();
|
|
|
|
// Function overrides
|
|
void readValue(ByteLayer &data) override;
|
|
void writeValue(ByteLayer &data) const override;
|
|
TagType getTagType() const override;
|
|
dynamic getValue() const override;
|
|
void setValue(const dynamic &val) override;
|
|
void prettyPrint(int indent, bool recurse) const override;
|
|
void writeStringifiedValue(StringBuilder &builder, int indent, bool isList) const override;
|
|
void readStringifiedValue(StringReader &reader) override;
|
|
|
|
private:
|
|
float value;
|
|
};
|
|
}
|
|
|
|
#endif |