aboutsummaryrefslogtreecommitdiff
path: root/src/univalue/univalue.h
diff options
context:
space:
mode:
authorJonas Schnelli <jonas.schnelli@include7.ch>2015-05-10 15:53:54 +0200
committerJonas Schnelli <jonas.schnelli@include7.ch>2015-06-04 09:16:06 +0200
commit0c5b2cf69ae20f83cbd894bb19d0e111623bae0f (patch)
tree5adf63f805d4908ce5224c83bea99a763dfdf21d /src/univalue/univalue.h
parent21c10de8c2de17a6357dbbcea7613b41f6ab8449 (diff)
downloadbitcoin-0c5b2cf69ae20f83cbd894bb19d0e111623bae0f.tar.xz
univalue: add support for real, fix percision and make it json_spirit compatible
- avoid breaking the API because of different number/percision handling
Diffstat (limited to 'src/univalue/univalue.h')
-rw-r--r--src/univalue/univalue.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/univalue/univalue.h b/src/univalue/univalue.h
index 28d6e3d3cd..efcf202bdd 100644
--- a/src/univalue/univalue.h
+++ b/src/univalue/univalue.h
@@ -17,7 +17,7 @@
class UniValue {
public:
- enum VType { VNULL, VOBJ, VARR, VSTR, VNUM, VBOOL, };
+ enum VType { VNULL, VOBJ, VARR, VSTR, VNUM, VREAL, VBOOL, };
UniValue() { typ = VNULL; }
UniValue(UniValue::VType initialType, const std::string& initialStr = "") {
@@ -76,6 +76,7 @@ public:
bool isBool() const { return (typ == VBOOL); }
bool isStr() const { return (typ == VSTR); }
bool isNum() const { return (typ == VNUM); }
+ bool isReal() const { return (typ == VREAL); }
bool isArray() const { return (typ == VARR); }
bool isObject() const { return (typ == VOBJ); }