2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-06-08 05:10:53 +00:00
qpdf/libqpdf/qpdf/SparseOHArray.hh
2023-04-01 13:57:47 +01:00

27 lines
463 B
C++

#ifndef QPDF_SPARSEOHARRAY_HH
#define QPDF_SPARSEOHARRAY_HH
#include <qpdf/QPDFObjectHandle.hh>
#include <qpdf/QPDFObject_private.hh>
#include <map>
class QPDF_Array;
class SparseOHArray
{
public:
SparseOHArray() = default;
int
size() const noexcept
{
return n_elements;
}
private:
friend class QPDF_Array;
std::map<int, std::shared_ptr<QPDFObject>> elements;
int n_elements{0};
};
#endif // QPDF_SPARSEOHARRAY_HH