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

Method asString

external/jsoncpp/jsoncpp.cpp:3166–3189  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3164}
3165
3166JSONCPP_STRING Value::asString() const {
3167 switch (type_) {
3168 case nullValue:
3169 return "";
3170 case stringValue:
3171 {
3172 if (value_.string_ == 0) return "";
3173 unsigned this_len;
3174 char const* this_str;
3175 decodePrefixedString(this->allocated_, this->value_.string_, &this_len, &this_str);
3176 return JSONCPP_STRING(this_str, this_len);
3177 }
3178 case booleanValue:
3179 return value_.bool_ ? "true" : "false";
3180 case intValue:
3181 return valueToString(value_.int_);
3182 case uintValue:
3183 return valueToString(value_.uint_);
3184 case realValue:
3185 return valueToString(value_.real_);
3186 default:
3187 JSON_FAIL_MESSAGE("Type is not convertible to string");
3188 }
3189}
3190
3191#ifdef JSON_USE_CPPTL
3192CppTL::ConstString Value::asConstString() const {

Callers 15

graphFromJsonFunction · 0.80
pathsFromJsonFunction · 0.80
addAlignmentMethod · 0.80
setFromJsonMethod · 0.80
alignAndDisambiguateFunction · 0.80
getVariantsFunction · 0.80
loadMethod · 0.80
loadMethod · 0.80
writeAlignmentsFunction · 0.80
countAndGenotypeFunction · 0.80
TESTFunction · 0.80

Calls 2

decodePrefixedStringFunction · 0.85
valueToStringFunction · 0.85

Tested by 1

TESTFunction · 0.64