31 #ifndef GOOGLE_PROTOBUF_UTIL_CONVERTER_PROTOSTREAM_OBJECTWRITER_H__ 32 #define GOOGLE_PROTOBUF_UTIL_CONVERTER_PROTOSTREAM_OBJECTWRITER_H__ 53 class CodedOutputStream;
68 class ObjectLocationTracker;
100 ProtoStreamObjectWriter::Options::Defaults());
122 explicit AnyWriter(ProtoStreamObjectWriter* parent);
151 ProtoStreamObjectWriter* parent_;
165 strings::StringByteSink output_;
176 bool is_well_known_type_;
177 TypeRenderer* well_known_type_render_;
192 Item(ProtoStreamObjectWriter* enclosing,
ItemType item_type,
193 bool is_placeholder,
bool is_list);
202 bool IsMap() {
return item_type_ == MAP; }
203 bool IsAny() {
return item_type_ == ANY; }
208 return static_cast<Item*
>(BaseElement::parent());
216 bool InsertMapKeyIfNotPresent(
StringPiece map_key);
224 ProtoStreamObjectWriter* ow_;
238 bool is_placeholder_;
247 ProtoStreamObjectWriter(
const TypeInfo* typeinfo,
268 static util::Status RenderStructValue(ProtoStreamObjectWriter* ow,
272 static util::Status RenderTimestamp(ProtoStreamObjectWriter* ow,
276 static util::Status RenderFieldMask(ProtoStreamObjectWriter* ow,
280 static util::Status RenderDuration(ProtoStreamObjectWriter* ow,
285 static util::Status RenderWrapperType(ProtoStreamObjectWriter* ow,
288 static void InitRendererMap();
289 static void DeleteRendererMap();
290 static TypeRenderer* FindTypeRenderer(
const string&
type_url);
315 void PopOneElement();
340 #endif // GOOGLE_PROTOBUF_UTIL_CONVERTER_PROTOSTREAM_OBJECTWRITER_H__ Definition: protostream_objectwriter.h:186
int Pop(int s)
Definition: towers.c:169
virtual Item * parent() const
Definition: protostream_objectwriter.h:207
const FieldDescriptor * field
Definition: parser_unittest.cc:2279
Definition: protostream_objectwriter.h:75
Definition: protostream_objectwriter.h:188
virtual ~Item()
Definition: protostream_objectwriter.h:198
Definition: structured_objectwriter.h:69
ItemType
Definition: protostream_objectwriter.h:185
AnyWriter * any() const
Definition: protostream_objectwriter.h:205
static const Options & Defaults()
Definition: protostream_objectwriter.h:89
bool is_placeholder() const
Definition: protostream_objectwriter.h:218
Definition: type_info.h:47
Definition: type_resolver.h:54
Definition: error_listener.h:54
Definition: stringpiece.h:178
#define GOOGLE_DISALLOW_IMPLICIT_CONSTRUCTORS(TypeName)
Definition: macros.h:45
EGLAttrib * value
Definition: eglext.h:120
EGLImageKHR EGLint * name
Definition: eglext.h:851
Definition: __init__.py:1
Definition: type.pb.h:276
bool IsMap()
Definition: protostream_objectwriter.h:202
Options()
Definition: protostream_objectwriter.h:86
bool IsMap(const google::protobuf::Field &field, const google::protobuf::Type &type)
Definition: utility.cc:312
Definition: datapiece.h:60
Definition: type.pb.h:133
EGLenum type
Definition: eglext.h:63
Definition: scoped_ptr.h:48
Definition: protostream_objectwriter.h:182
Definition: protostream_objectwriter.h:187
#define false
Definition: float-mm.c:5
bool IsAny()
Definition: protostream_objectwriter.h:203
Definition: proto_writer.h:75
Definition: protostream_objectwriter.h:120
#define LIBPROTOBUF_EXPORT
Definition: port.h:97
Definition: gflags_completions.h:115
bool is_list() const
Definition: protostream_objectwriter.h:219
Definition: protostream_objectwriter.h:78
Type
Type of JSON value.
Definition: rapidjson.h:616
bool struct_integers_as_strings
Definition: protostream_objectwriter.h:84
Inspector::Protocol::Array< String > Item
Definition: InspectorProtocolObjects.h:251
void Push(int i, int s)
Definition: towers.c:146