Commit cbc2c46b authored by Milo Yip's avatar Milo Yip

Update tutorial.md

Fixes table
parent bc2daea2
...@@ -178,7 +178,7 @@ As C++ provides several integer and floating point number types, the DOM trys to ...@@ -178,7 +178,7 @@ As C++ provides several integer and floating point number types, the DOM trys to
When the DOM parses a Number, it stores it as either one of the following type: When the DOM parses a Number, it stores it as either one of the following type:
Type | Description Type | Description
--------------------------------------------------- -----------|---------------------------------------
`unsigned` | 32-bit unsigned integer `unsigned` | 32-bit unsigned integer
`int` | 32-bit signed integer `int` | 32-bit signed integer
`uint64_t` | 64-bit unsigned integer `uint64_t` | 64-bit unsigned integer
...@@ -187,14 +187,14 @@ Type | Description ...@@ -187,14 +187,14 @@ Type | Description
When querying a number, you can check whether the number can be obtained as target type: When querying a number, you can check whether the number can be obtained as target type:
Function | Description Checking | Obtaining
----------------------------------------------- -------------|--------------
`IsNumber()` | whether the value is a number `IsNumber()` | N/A
`IsInt()` | whether the number is a int `IsInt()` | `GetInt()`
`IsUint()` | whether the number is a uint `IsUint()` | `GetUint()`
`IsInt64()` | whether the number is a int64_t `IsInt64()` | `GetInt64()`
`IsUint64()` | whether the number is a uint64_t `IsUint64()` | `GetUint()`
`IsDouble()` | whether the number is a double `IsDouble()` | `GetDouble()`
Note that, an integer value may be obtained in various ways without conversion. For example, A value `x` containing `123` will make `x.IsInt() == x.IsUint() == x.Int64() == x.Uint64() == ture`. But a value `y` containing `-3000000000` will only makes `x.int64() == true`. Note that, an integer value may be obtained in various ways without conversion. For example, A value `x` containing `123` will make `x.IsInt() == x.IsUint() == x.Int64() == x.Uint64() == ture`. But a value `y` containing `-3000000000` will only makes `x.int64() == true`.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment