void toJson( JsonWriter &json, const _T & v ) const { switch( v.d() ) { case ADL::picture::Picture::CIRCLE: json.startObject(); writeField( json, circle_s(), "circle", v.circle() ); json.endObject(); break; case ADL::picture::Picture::RECTANGLE: json.startObject(); writeField( json, rectangle_s(), "rectangle", v.rectangle() ); json.endObject(); break; case ADL::picture::Picture::COMPOSED: json.startObject(); writeField( json, composed_s(), "composed", v.composed() ); json.endObject(); break; case ADL::picture::Picture::TRANSLATED: json.startObject(); writeField( json, translated_s(), "translated", v.translated() ); json.endObject(); break; } }
void toJson( JsonWriter &json, const _T & v ) const { json.startObject(); writeField<double>( json, width_s, "width", v.width ); writeField<double>( json, height_s, "height", v.height ); json.endObject(); }
void toJson( JsonWriter &json, const _T & v ) const { json.startObject(); writeField<double>( json, radius_s, "radius", v.radius ); json.endObject(); }