mirror of
https://github.com/thunderbrewhq/squall.git
synced 2025-12-12 10:32:29 +00:00
feat(big): add SBigFromUnsigned, SBigNew, and SBigToBinaryBuffer
This commit is contained in:
parent
630e6dbb1f
commit
7d5a157162
10 changed files with 211 additions and 0 deletions
22
storm/big/BigBuffer.hpp
Normal file
22
storm/big/BigBuffer.hpp
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
#ifndef STORM_BIG_BIG_BUFFER_HPP
|
||||
#define STORM_BIG_BIG_BUFFER_HPP
|
||||
|
||||
#include "storm/Array.hpp"
|
||||
#include <cstdint>
|
||||
|
||||
class BigBuffer {
|
||||
public:
|
||||
// Member variables
|
||||
TSGrowableArray<uint32_t> m_data;
|
||||
uint32_t m_offset = 0;
|
||||
|
||||
// Member functions
|
||||
uint32_t& operator[](uint32_t index);
|
||||
uint32_t operator[](uint32_t index) const;
|
||||
uint32_t Count() const;
|
||||
void GrowToFit(uint32_t index);
|
||||
int32_t IsUsed(uint32_t index) const;
|
||||
void SetCount(uint32_t count);
|
||||
};
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue