mirror of
https://github.com/qpdf/qpdf.git
synced 2024-05-29 08:20:53 +00:00
dba61da1bf
When a QPDF is destroyed, changing indirect objects to direct nulls makes them effectively disappear silently when they sneak into other places. Instead, we should treat this as an error. Adding a destroyed object type makes this possible.
20 lines
432 B
C++
20 lines
432 B
C++
#ifndef QPDF_DESTROYED_HH
|
|
#define QPDF_DESTROYED_HH
|
|
|
|
#include <qpdf/QPDFValue.hh>
|
|
|
|
class QPDF_Destroyed: public QPDFValue
|
|
{
|
|
public:
|
|
virtual ~QPDF_Destroyed() = default;
|
|
virtual std::shared_ptr<QPDFValueProxy> shallowCopy();
|
|
virtual std::string unparse();
|
|
virtual JSON getJSON(int json_version);
|
|
static std::shared_ptr<QPDFValue> getInstance();
|
|
|
|
private:
|
|
QPDF_Destroyed();
|
|
};
|
|
|
|
#endif // QPDF_DESTROYED_HH
|