40 lines
1 KiB
C++
40 lines
1 KiB
C++
#ifndef INTARRAYTAG_H
|
|
#define INTARRAYTAG_H
|
|
|
|
#include "Tag.h"
|
|
#include "../utils/ByteLayer.h"
|
|
#include "../utils/StringBuilder.h"
|
|
#include "../utils/StringReader.h"
|
|
#include "../types/dynamic.h"
|
|
#include <vector>
|
|
#include <string>
|
|
#include <sstream>
|
|
|
|
using namespace libac;
|
|
using namespace std;
|
|
|
|
namespace nbt
|
|
{
|
|
|
|
class IntArrayTag : public Tag
|
|
{
|
|
public:
|
|
IntArrayTag();
|
|
IntArrayTag(const std::vector<int> &value);
|
|
|
|
// Override functions from the Tag class
|
|
void readValue(ByteLayer &data) override;
|
|
void writeValue(ByteLayer &data) const override;
|
|
TagType getTagType() const override;
|
|
dynamic getValue() const;
|
|
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:
|
|
vector<int> value;
|
|
};
|
|
}
|
|
|
|
#endif // INTARRAYTAG_H
|