XPlor/libs/xassets/xpathnodetreenodes.cpp

47 lines
807 B
C++
Raw Normal View History

2025-08-17 13:14:17 -04:00
#include "xpathnodetreenodes.h"
XPathNodeTreeNodes::XPathNodeTreeNodes()
2025-09-05 18:35:17 -04:00
: XAsset()
, mNodeCount(0)
, mNodes()
{
2025-09-10 21:58:26 -04:00
SetName("Path Node Tree Nodes");
2025-09-05 18:35:17 -04:00
}
XPathNodeTreeNodes::~XPathNodeTreeNodes()
{
2025-08-17 13:14:17 -04:00
}
2025-09-10 21:58:26 -04:00
void XPathNodeTreeNodes::ParseData(XDataStream *aStream) {
2025-08-17 13:14:17 -04:00
if (GetPtr() == -1) {
2025-09-05 18:35:17 -04:00
*aStream >> mNodeCount;
2025-08-17 13:14:17 -04:00
2025-09-05 18:35:17 -04:00
for (int i = 0; i < mNodeCount; i++)
{
*aStream >> mNodes[i];
2025-08-17 13:14:17 -04:00
}
}
}
2025-09-05 18:35:17 -04:00
void XPathNodeTreeNodes::Clear()
{
}
2025-08-17 13:14:17 -04:00
int XPathNodeTreeNodes::GetNodeCount() const {
return mNodeCount;
}
void XPathNodeTreeNodes::SetNodeCount(int count) {
mNodeCount = count;
}
2025-09-05 18:35:17 -04:00
QVector<unsigned short> XPathNodeTreeNodes::GetNodes() const {
2025-08-17 13:14:17 -04:00
return mNodes;
}
2025-09-05 18:35:17 -04:00
void XPathNodeTreeNodes::SetNodes(QVector<unsigned short> aNodes) {
mNodes = aNodes;
2025-08-17 13:14:17 -04:00
}