aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDF_json.cc
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2022-05-08 19:42:16 +0200
committerJay Berkenbilt <ejb@ql.org>2022-05-16 19:41:40 +0200
commit4fe2e06b4787ffb639f965ac840b51018308ec07 (patch)
tree667474624e264384d544cbed4324b909478f3450 /libqpdf/QPDF_json.cc
parented6130036c65124cb236e709201330404a4b1d72 (diff)
downloadqpdf-4fe2e06b4787ffb639f965ac840b51018308ec07.tar.zst
Add --create-from-json and --update-from-json arguments
Also add stubs for top-level QPDF methods (createFromJSON, updateFromJSON)
Diffstat (limited to 'libqpdf/QPDF_json.cc')
-rw-r--r--libqpdf/QPDF_json.cc27
1 files changed, 27 insertions, 0 deletions
diff --git a/libqpdf/QPDF_json.cc b/libqpdf/QPDF_json.cc
new file mode 100644
index 00000000..908615b6
--- /dev/null
+++ b/libqpdf/QPDF_json.cc
@@ -0,0 +1,27 @@
+#include <qpdf/QPDF.hh>
+
+#include <qpdf/FileInputSource.hh>
+
+void
+QPDF::createFromJSON(std::string const& json_file)
+{
+ createFromJSON(std::make_shared<FileInputSource>(json_file.c_str()));
+}
+
+void
+QPDF::createFromJSON(std::shared_ptr<InputSource>)
+{
+ // QXXXQ
+}
+
+void
+QPDF::updateFromJSON(std::string const& json_file)
+{
+ updateFromJSON(std::make_shared<FileInputSource>(json_file.c_str()));
+}
+
+void
+QPDF::updateFromJSON(std::shared_ptr<InputSource>)
+{
+ // QXXXQ
+}