Protocol Buffers - Google's data interchange format (grpc依赖)
https://developers.google.com/protocol-buffers/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
420 lines
12 KiB
420 lines
12 KiB
/* This file was generated by upbc (the upb compiler). Do not edit. */ |
|
|
|
#ifndef DESCRIPTOR_DESCRIPTOR_H |
|
#define DESCRIPTOR_DESCRIPTOR_H |
|
|
|
#include <upb_data.h> |
|
|
|
#ifdef __cplusplus |
|
extern "C" { |
|
#endif |
|
|
|
struct google_protobuf_FileDescriptorSet; |
|
extern struct google_protobuf_FileDescriptorSet *upb_file_descriptor_set; |
|
|
|
/* Forward declarations of all message types. |
|
* So they can refer to each other in possibly-recursive ways. */ |
|
|
|
struct google_protobuf_UninterpretedOption_NamePart; |
|
typedef struct google_protobuf_UninterpretedOption_NamePart |
|
google_protobuf_UninterpretedOption_NamePart; |
|
|
|
struct google_protobuf_DescriptorProto; |
|
typedef struct google_protobuf_DescriptorProto |
|
google_protobuf_DescriptorProto; |
|
|
|
struct google_protobuf_EnumDescriptorProto; |
|
typedef struct google_protobuf_EnumDescriptorProto |
|
google_protobuf_EnumDescriptorProto; |
|
|
|
struct google_protobuf_UninterpretedOption; |
|
typedef struct google_protobuf_UninterpretedOption |
|
google_protobuf_UninterpretedOption; |
|
|
|
struct google_protobuf_FileDescriptorProto; |
|
typedef struct google_protobuf_FileDescriptorProto |
|
google_protobuf_FileDescriptorProto; |
|
|
|
struct google_protobuf_MethodDescriptorProto; |
|
typedef struct google_protobuf_MethodDescriptorProto |
|
google_protobuf_MethodDescriptorProto; |
|
|
|
struct google_protobuf_EnumValueOptions; |
|
typedef struct google_protobuf_EnumValueOptions |
|
google_protobuf_EnumValueOptions; |
|
|
|
struct google_protobuf_EnumValueDescriptorProto; |
|
typedef struct google_protobuf_EnumValueDescriptorProto |
|
google_protobuf_EnumValueDescriptorProto; |
|
|
|
struct google_protobuf_ServiceDescriptorProto; |
|
typedef struct google_protobuf_ServiceDescriptorProto |
|
google_protobuf_ServiceDescriptorProto; |
|
|
|
struct google_protobuf_FileDescriptorSet; |
|
typedef struct google_protobuf_FileDescriptorSet |
|
google_protobuf_FileDescriptorSet; |
|
|
|
struct google_protobuf_DescriptorProto_ExtensionRange; |
|
typedef struct google_protobuf_DescriptorProto_ExtensionRange |
|
google_protobuf_DescriptorProto_ExtensionRange; |
|
|
|
struct google_protobuf_FieldOptions; |
|
typedef struct google_protobuf_FieldOptions |
|
google_protobuf_FieldOptions; |
|
|
|
struct google_protobuf_FileOptions; |
|
typedef struct google_protobuf_FileOptions |
|
google_protobuf_FileOptions; |
|
|
|
struct google_protobuf_MessageOptions; |
|
typedef struct google_protobuf_MessageOptions |
|
google_protobuf_MessageOptions; |
|
|
|
struct google_protobuf_EnumOptions; |
|
typedef struct google_protobuf_EnumOptions |
|
google_protobuf_EnumOptions; |
|
|
|
struct google_protobuf_FieldDescriptorProto; |
|
typedef struct google_protobuf_FieldDescriptorProto |
|
google_protobuf_FieldDescriptorProto; |
|
|
|
struct google_protobuf_ServiceOptions; |
|
typedef struct google_protobuf_ServiceOptions |
|
google_protobuf_ServiceOptions; |
|
|
|
struct google_protobuf_MethodOptions; |
|
typedef struct google_protobuf_MethodOptions |
|
google_protobuf_MethodOptions; |
|
|
|
/* The message definitions themselves. */ |
|
|
|
struct google_protobuf_UninterpretedOption_NamePart { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name_part:1; /* = 1, required. */ |
|
bool is_extension:1; /* = 2, required. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name_part; |
|
bool is_extension; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_UninterpretedOption_NamePart) |
|
|
|
struct google_protobuf_DescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool field:1; /* = 2, repeated. */ |
|
bool nested_type:1; /* = 3, repeated. */ |
|
bool enum_type:1; /* = 4, repeated. */ |
|
bool extension_range:1; /* = 5, repeated. */ |
|
bool extension:1; /* = 6, repeated. */ |
|
bool options:1; /* = 7, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
UPB_MSG_ARRAY(google_protobuf_FieldDescriptorProto)* field; |
|
UPB_MSG_ARRAY(google_protobuf_DescriptorProto)* nested_type; |
|
UPB_MSG_ARRAY(google_protobuf_EnumDescriptorProto)* enum_type; |
|
UPB_MSG_ARRAY(google_protobuf_DescriptorProto_ExtensionRange)* extension_range; |
|
UPB_MSG_ARRAY(google_protobuf_FieldDescriptorProto)* extension; |
|
google_protobuf_MessageOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_DescriptorProto) |
|
|
|
struct google_protobuf_EnumDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool value:1; /* = 2, repeated. */ |
|
bool options:1; /* = 3, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
UPB_MSG_ARRAY(google_protobuf_EnumValueDescriptorProto)* value; |
|
google_protobuf_EnumOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_EnumDescriptorProto) |
|
|
|
struct google_protobuf_UninterpretedOption { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 2, repeated. */ |
|
bool identifier_value:1; /* = 3, optional. */ |
|
bool positive_int_value:1; /* = 4, optional. */ |
|
bool negative_int_value:1; /* = 5, optional. */ |
|
bool double_value:1; /* = 6, optional. */ |
|
bool string_value:1; /* = 7, optional. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption_NamePart)* name; |
|
upb_string* identifier_value; |
|
uint64_t positive_int_value; |
|
int64_t negative_int_value; |
|
double double_value; |
|
upb_string* string_value; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_UninterpretedOption) |
|
|
|
struct google_protobuf_FileDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool package:1; /* = 2, optional. */ |
|
bool dependency:1; /* = 3, repeated. */ |
|
bool message_type:1; /* = 4, repeated. */ |
|
bool enum_type:1; /* = 5, repeated. */ |
|
bool service:1; /* = 6, repeated. */ |
|
bool extension:1; /* = 7, repeated. */ |
|
bool options:1; /* = 8, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
upb_string* package; |
|
struct upb_string_array* dependency; |
|
UPB_MSG_ARRAY(google_protobuf_DescriptorProto)* message_type; |
|
UPB_MSG_ARRAY(google_protobuf_EnumDescriptorProto)* enum_type; |
|
UPB_MSG_ARRAY(google_protobuf_ServiceDescriptorProto)* service; |
|
UPB_MSG_ARRAY(google_protobuf_FieldDescriptorProto)* extension; |
|
google_protobuf_FileOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_FileDescriptorProto) |
|
|
|
struct google_protobuf_MethodDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool input_type:1; /* = 2, optional. */ |
|
bool output_type:1; /* = 3, optional. */ |
|
bool options:1; /* = 4, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
upb_string* input_type; |
|
upb_string* output_type; |
|
google_protobuf_MethodOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_MethodDescriptorProto) |
|
|
|
struct google_protobuf_EnumValueOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_EnumValueOptions) |
|
|
|
struct google_protobuf_EnumValueDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool number:1; /* = 2, optional. */ |
|
bool options:1; /* = 3, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
int32_t number; |
|
google_protobuf_EnumValueOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_EnumValueDescriptorProto) |
|
|
|
struct google_protobuf_ServiceDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool method:1; /* = 2, repeated. */ |
|
bool options:1; /* = 3, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
UPB_MSG_ARRAY(google_protobuf_MethodDescriptorProto)* method; |
|
google_protobuf_ServiceOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_ServiceDescriptorProto) |
|
|
|
struct google_protobuf_FileDescriptorSet { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool file:1; /* = 1, repeated. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_FileDescriptorProto)* file; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_FileDescriptorSet) |
|
|
|
struct google_protobuf_DescriptorProto_ExtensionRange { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool start:1; /* = 1, optional. */ |
|
bool end:1; /* = 2, optional. */ |
|
} has; |
|
} set_flags; |
|
int32_t start; |
|
int32_t end; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_DescriptorProto_ExtensionRange) |
|
|
|
struct google_protobuf_FieldOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool ctype:1; /* = 1, optional. */ |
|
bool packed:1; /* = 2, optional. */ |
|
bool deprecated:1; /* = 3, optional. */ |
|
bool experimental_map_key:1; /* = 9, optional. */ |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
int32_t ctype; |
|
bool packed; |
|
bool deprecated; |
|
upb_string* experimental_map_key; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_FieldOptions) |
|
|
|
struct google_protobuf_FileOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool java_package:1; /* = 1, optional. */ |
|
bool java_outer_classname:1; /* = 8, optional. */ |
|
bool optimize_for:1; /* = 9, optional. */ |
|
bool java_multiple_files:1; /* = 10, optional. */ |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
upb_string* java_package; |
|
upb_string* java_outer_classname; |
|
int32_t optimize_for; |
|
bool java_multiple_files; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_FileOptions) |
|
|
|
struct google_protobuf_MessageOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool message_set_wire_format:1; /* = 1, optional. */ |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
bool message_set_wire_format; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_MessageOptions) |
|
|
|
struct google_protobuf_EnumOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_EnumOptions) |
|
|
|
struct google_protobuf_FieldDescriptorProto { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool name:1; /* = 1, optional. */ |
|
bool extendee:1; /* = 2, optional. */ |
|
bool number:1; /* = 3, optional. */ |
|
bool label:1; /* = 4, optional. */ |
|
bool type:1; /* = 5, optional. */ |
|
bool type_name:1; /* = 6, optional. */ |
|
bool default_value:1; /* = 7, optional. */ |
|
bool options:1; /* = 8, optional. */ |
|
} has; |
|
} set_flags; |
|
upb_string* name; |
|
upb_string* extendee; |
|
int32_t number; |
|
int32_t label; |
|
int32_t type; |
|
upb_string* type_name; |
|
upb_string* default_value; |
|
google_protobuf_FieldOptions* options; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_FieldDescriptorProto) |
|
|
|
struct google_protobuf_ServiceOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_ServiceOptions) |
|
|
|
struct google_protobuf_MethodOptions { |
|
struct upb_mmhead mmhead; |
|
struct upb_msgdef *def; |
|
union { |
|
uint8_t bytes[1]; |
|
struct { |
|
bool uninterpreted_option:1; /* = 999, repeated. */ |
|
} has; |
|
} set_flags; |
|
UPB_MSG_ARRAY(google_protobuf_UninterpretedOption)* uninterpreted_option; |
|
}; |
|
UPB_DEFINE_MSG_ARRAY(google_protobuf_MethodOptions) |
|
|
|
#ifdef __cplusplus |
|
} /* extern "C" */ |
|
#endif |
|
|
|
#endif /* DESCRIPTOR_DESCRIPTOR_H */
|
|
|