2022-05-08 17:42:16 +00:00
|
|
|
#include <qpdf/QPDF.hh>
|
|
|
|
|
|
|
|
#include <qpdf/FileInputSource.hh>
|
|
|
|
|
2022-05-14 12:49:42 +00:00
|
|
|
void
|
|
|
|
QPDF::JSONReactor::dictionaryStart()
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
QPDF::JSONReactor::arrayStart()
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
QPDF::JSONReactor::containerEnd(JSON const& value)
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
QPDF::JSONReactor::topLevelScalar()
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
|
|
|
QPDF::JSONReactor::dictionaryItem(std::string const& key, JSON const& value)
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool
|
|
|
|
QPDF::JSONReactor::arrayItem(JSON const& value)
|
|
|
|
{
|
|
|
|
// QXXXXQ
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2022-05-08 17:42:16 +00:00
|
|
|
void
|
|
|
|
QPDF::createFromJSON(std::string const& json_file)
|
|
|
|
{
|
|
|
|
createFromJSON(std::make_shared<FileInputSource>(json_file.c_str()));
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2022-05-14 12:49:42 +00:00
|
|
|
QPDF::createFromJSON(std::shared_ptr<InputSource> is)
|
2022-05-08 17:42:16 +00:00
|
|
|
{
|
2022-05-14 12:49:42 +00:00
|
|
|
importJSON(is, true);
|
2022-05-08 17:42:16 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
QPDF::updateFromJSON(std::string const& json_file)
|
|
|
|
{
|
|
|
|
updateFromJSON(std::make_shared<FileInputSource>(json_file.c_str()));
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2022-05-14 12:49:42 +00:00
|
|
|
QPDF::updateFromJSON(std::shared_ptr<InputSource> is)
|
|
|
|
{
|
|
|
|
importJSON(is, false);
|
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
QPDF::importJSON(std::shared_ptr<InputSource>, bool must_be_complete)
|
2022-05-08 17:42:16 +00:00
|
|
|
{
|
|
|
|
// QXXXQ
|
|
|
|
}
|