| 3700 | } |
| 3701 | |
| 3702 | void writeResourceAttributes(ThriftBinaryBufferWriter& w, const ResourceAttributes& s) { |
| 3703 | w.writeStructBegin("ResourceAttributes"); |
| 3704 | if(s.sourceURL.isSet()) { |
| 3705 | w.writeFieldBegin("sourceURL", ThriftFieldType::T_STRING, 1); |
| 3706 | w.writeString(s.sourceURL.ref()); |
| 3707 | w.writeFieldEnd(); |
| 3708 | } |
| 3709 | if(s.timestamp.isSet()) { |
| 3710 | w.writeFieldBegin("timestamp", ThriftFieldType::T_I64, 2); |
| 3711 | w.writeI64(s.timestamp.ref()); |
| 3712 | w.writeFieldEnd(); |
| 3713 | } |
| 3714 | if(s.latitude.isSet()) { |
| 3715 | w.writeFieldBegin("latitude", ThriftFieldType::T_DOUBLE, 3); |
| 3716 | w.writeDouble(s.latitude.ref()); |
| 3717 | w.writeFieldEnd(); |
| 3718 | } |
| 3719 | if(s.longitude.isSet()) { |
| 3720 | w.writeFieldBegin("longitude", ThriftFieldType::T_DOUBLE, 4); |
| 3721 | w.writeDouble(s.longitude.ref()); |
| 3722 | w.writeFieldEnd(); |
| 3723 | } |
| 3724 | if(s.altitude.isSet()) { |
| 3725 | w.writeFieldBegin("altitude", ThriftFieldType::T_DOUBLE, 5); |
| 3726 | w.writeDouble(s.altitude.ref()); |
| 3727 | w.writeFieldEnd(); |
| 3728 | } |
| 3729 | if(s.cameraMake.isSet()) { |
| 3730 | w.writeFieldBegin("cameraMake", ThriftFieldType::T_STRING, 6); |
| 3731 | w.writeString(s.cameraMake.ref()); |
| 3732 | w.writeFieldEnd(); |
| 3733 | } |
| 3734 | if(s.cameraModel.isSet()) { |
| 3735 | w.writeFieldBegin("cameraModel", ThriftFieldType::T_STRING, 7); |
| 3736 | w.writeString(s.cameraModel.ref()); |
| 3737 | w.writeFieldEnd(); |
| 3738 | } |
| 3739 | if(s.clientWillIndex.isSet()) { |
| 3740 | w.writeFieldBegin("clientWillIndex", ThriftFieldType::T_BOOL, 8); |
| 3741 | w.writeBool(s.clientWillIndex.ref()); |
| 3742 | w.writeFieldEnd(); |
| 3743 | } |
| 3744 | if(s.recoType.isSet()) { |
| 3745 | w.writeFieldBegin("recoType", ThriftFieldType::T_STRING, 9); |
| 3746 | w.writeString(s.recoType.ref()); |
| 3747 | w.writeFieldEnd(); |
| 3748 | } |
| 3749 | if(s.fileName.isSet()) { |
| 3750 | w.writeFieldBegin("fileName", ThriftFieldType::T_STRING, 10); |
| 3751 | w.writeString(s.fileName.ref()); |
| 3752 | w.writeFieldEnd(); |
| 3753 | } |
| 3754 | if(s.attachment.isSet()) { |
| 3755 | w.writeFieldBegin("attachment", ThriftFieldType::T_BOOL, 11); |
| 3756 | w.writeBool(s.attachment.ref()); |
| 3757 | w.writeFieldEnd(); |
| 3758 | } |
| 3759 | if(s.applicationData.isSet()) { |
no test coverage detected