From e186da17213826ae22b73584641d2e8cd10b24d5 Mon Sep 17 00:00:00 2001 From: m-holger Date: Wed, 29 Mar 2023 16:39:34 +0100 Subject: Remove SparseOHArray::at, setAt and append --- libqpdf/SparseOHArray.cc | 34 ---------------------------------- 1 file changed, 34 deletions(-) (limited to 'libqpdf/SparseOHArray.cc') diff --git a/libqpdf/SparseOHArray.cc b/libqpdf/SparseOHArray.cc index e0c2d41d..6a1c976a 100644 --- a/libqpdf/SparseOHArray.cc +++ b/libqpdf/SparseOHArray.cc @@ -1,27 +1,5 @@ #include -#include - -static const QPDFObjectHandle null_oh = QPDFObjectHandle::newNull(); - -QPDFObjectHandle -SparseOHArray::at(int idx) const -{ - auto const& iter = elements.find(idx); - return iter == elements.end() ? null_oh : (*iter).second; -} - -void -SparseOHArray::remove_last() -{ - if (this->n_elements == 0) { - throw std::logic_error("INTERNAL ERROR: attempt to remove" - " last item from empty SparseOHArray"); - } - --this->n_elements; - this->elements.erase(this->n_elements); -} - void SparseOHArray::disconnect() { @@ -42,15 +20,3 @@ SparseOHArray::copy() } return result; } - -SparseOHArray::const_iterator -SparseOHArray::begin() const -{ - return this->elements.begin(); -} - -SparseOHArray::const_iterator -SparseOHArray::end() const -{ - return this->elements.end(); -} -- cgit v1.2.3-54-g00ecf