#pragma once typedef unsigned char Byte; class CArrayBuffer { public: CArrayBuffer(int byteLength = 8) { this->_byteLenght = byteLength; this->pData = new Byte[this->_byteLenght]; } ~CArrayBuffer() { if (this->pData != nullptr) { delete[] this->pData; this->pData = nullptr; } } int byteLength() { return this->_byteLenght; } public: Byte *pData; private: int _byteLenght; };