Resource aggregator that compresses payloads using Zlib.
More...
#include <ZlibResourceAggregator.h>
Resource aggregator that compresses payloads using Zlib.
Pair this class with ZlibResourceDictionary to unpack resources in generated code.
◆ addResource()
Adds a resource to the dictionary, avoiding duplicates.
It is an error to add resources after finalize has been called.
- Parameters
-
pResourceIdOut | Variable receiving the stored resource ID |
pBuffer | Pointer to the resource |
bufferBytes | Size of the buffer in bytes |
◆ finalize()
Finalizes the resource collection, allowing for compression and serialization to take place.
◆ resourceBufferByIndex()
const void * ZlibResourceAggregator::resourceBufferByIndex |
( |
std::size_t |
resourceIndex | ) |
const |
|
noexcept |
Returns a pointer to the Nth finalized resource buffer in the object.
- Parameters
-
◆ resourceBufferSizeByIndex()
size_t ZlibResourceAggregator::resourceBufferSizeByIndex |
( |
std::size_t |
resourceIndex | ) |
const |
|
noexcept |
Returns the byte count associated with the Nth finalized resource buffer in the object.
- Parameters
-
◆ resourceIdByIndex()
ZlibResourceAggregator::ResourceId ZlibResourceAggregator::resourceIdByIndex |
( |
std::size_t |
resourceIndex | ) |
const |
|
noexcept |
Returns the Nth resource ID in the object.
- Parameters
-
◆ resourceIdCount()
size_t ZlibResourceAggregator::resourceIdCount |
( |
| ) |
const |
|
noexcept |
Returns the number of finalized resources in the object.
The documentation for this class was generated from the following files: