mirror of
https://github.com/qpdf/qpdf.git
synced 2024-11-19 02:45:10 +00:00
913eb5ac35
Add virtual methods to QPDFObject, wrappers to QPDFObjectHandle, and implementations to all the QPDF_Object types.
42 lines
547 B
C++
42 lines
547 B
C++
#include <qpdf/QPDF_Real.hh>
|
|
|
|
#include <qpdf/QUtil.hh>
|
|
|
|
QPDF_Real::QPDF_Real(std::string const& val) :
|
|
val(val)
|
|
{
|
|
}
|
|
|
|
QPDF_Real::QPDF_Real(double value, int decimal_places) :
|
|
val(QUtil::double_to_string(value, decimal_places))
|
|
{
|
|
}
|
|
|
|
QPDF_Real::~QPDF_Real()
|
|
{
|
|
}
|
|
|
|
std::string
|
|
QPDF_Real::unparse()
|
|
{
|
|
return this->val;
|
|
}
|
|
|
|
QPDFObject::object_type_e
|
|
QPDF_Real::getTypeCode() const
|
|
{
|
|
return QPDFObject::ot_real;
|
|
}
|
|
|
|
char const*
|
|
QPDF_Real::getTypeName() const
|
|
{
|
|
return "real";
|
|
}
|
|
|
|
std::string
|
|
QPDF_Real::getVal()
|
|
{
|
|
return this->val;
|
|
}
|