aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDF_Real.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libqpdf/QPDF_Real.cc')
-rw-r--r--libqpdf/QPDF_Real.cc19
1 files changed, 0 insertions, 19 deletions
diff --git a/libqpdf/QPDF_Real.cc b/libqpdf/QPDF_Real.cc
index af96c9df..f4304397 100644
--- a/libqpdf/QPDF_Real.cc
+++ b/libqpdf/QPDF_Real.cc
@@ -39,25 +39,6 @@ QPDF_Real::unparse()
return this->val;
}
-JSON
-QPDF_Real::getJSON(int json_version)
-{
- // While PDF allows .x or -.x, JSON does not. Rather than converting from string to double and
- // back, just handle this as a special case for JSON.
- std::string result;
- if (this->val.length() == 0) {
- // Can't really happen...
- result = "0";
- } else if (this->val.at(0) == '.') {
- result = "0" + this->val;
- } else if ((this->val.length() >= 2) && (this->val.at(0) == '-') && (this->val.at(1) == '.')) {
- result = "-0." + this->val.substr(2);
- } else {
- result = this->val;
- }
- return JSON::makeNumber(result);
-}
-
void
QPDF_Real::writeJSON(int json_version, JSON::Writer& p)
{