MCPcopy Create free account
hub / github.com/Illumina/paragraph / asUInt64

Method asUInt64

external/jsoncpp/jsoncpp.cpp:3268–3287  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3266}
3267
3268Value::UInt64 Value::asUInt64() const {
3269 switch (type_) {
3270 case intValue:
3271 JSON_ASSERT_MESSAGE(isUInt64(), "LargestInt out of UInt64 range");
3272 return UInt64(value_.int_);
3273 case uintValue:
3274 return UInt64(value_.uint_);
3275 case realValue:
3276 JSON_ASSERT_MESSAGE(InRange(value_.real_, 0, maxUInt64),
3277 "double out of UInt64 range");
3278 return UInt64(value_.real_);
3279 case nullValue:
3280 return 0;
3281 case booleanValue:
3282 return value_.bool_ ? 1 : 0;
3283 default:
3284 break;
3285 }
3286 JSON_FAIL_MESSAGE("Value is not convertible to UInt64.");
3287}
3288#endif // if defined(JSON_HAS_INT64)
3289
3290LargestInt Value::asLargestInt() const {

Callers 6

loadMethod · 0.80
addFragmentCountFunction · 0.80
loadMethod · 0.80
test_paragraph.cppFile · 0.80
TESTFunction · 0.80

Calls 1

InRangeFunction · 0.85

Tested by 1

TESTFunction · 0.64