MCPcopy Create free account
hub / github.com/baumgarr/nixnote2 / readBootstrapProfile

Function readBootstrapProfile

qevercloud/generated/types.cpp:6523–6561  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6521}
6522
6523void readBootstrapProfile(ThriftBinaryBufferReader& r, BootstrapProfile& s) {
6524 QString fname;
6525 ThriftFieldType::type fieldType;
6526 qint16 fieldId;
6527 bool name_isset = false;
6528 bool settings_isset = false;
6529 r.readStructBegin(fname);
6530 while(true) {
6531 r.readFieldBegin(fname, fieldType, fieldId);
6532 if(fieldType == ThriftFieldType::T_STOP) break;
6533 if(fieldId == 1) {
6534 if(fieldType == ThriftFieldType::T_STRING) {
6535 name_isset = true;
6536 QString v;
6537 r.readString(v);
6538 s.name = v;
6539 } else {
6540 r.skip(fieldType);
6541 }
6542 } else
6543 if(fieldId == 2) {
6544 if(fieldType == ThriftFieldType::T_STRUCT) {
6545 settings_isset = true;
6546 BootstrapSettings v;
6547 readBootstrapSettings(r, v);
6548 s.settings = v;
6549 } else {
6550 r.skip(fieldType);
6551 }
6552 } else
6553 {
6554 r.skip(fieldType);
6555 }
6556 r.readFieldEnd();
6557 }
6558 r.readStructEnd();
6559 if(!name_isset) throw ThriftException(ThriftException::Type::INVALID_DATA, "BootstrapProfile.name has no value");
6560 if(!settings_isset) throw ThriftException(ThriftException::Type::INVALID_DATA, "BootstrapProfile.settings has no value");
6561}
6562
6563void writeBootstrapInfo(ThriftBinaryBufferWriter& w, const BootstrapInfo& s) {
6564 w.writeStructBegin("BootstrapInfo");

Callers 1

readBootstrapInfoFunction · 0.85

Calls 8

readBootstrapSettingsFunction · 0.85
ThriftExceptionClass · 0.85
readStructBeginMethod · 0.80
readFieldBeginMethod · 0.80
readStringMethod · 0.80
skipMethod · 0.80
readFieldEndMethod · 0.80
readStructEndMethod · 0.80

Tested by

no test coverage detected