class OneofDescriptor
Defined at line 1192 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
Describes a oneof defined in a message type.
Public Methods
void OneofDescriptor (const OneofDescriptor & )
Defined at line 1197 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
OneofDescriptor & operator= (const OneofDescriptor & )
Defined at line 1198 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
internal::DescriptorStringView name ()
Name of this oneof.
Defined at line 2588 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
internal::DescriptorStringView full_name ()
Fully-qualified name of the oneof.
Defined at line 2588 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
int index ()
Index of this oneof within the message's oneof array.
Defined at line 2793 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
const FileDescriptor * file ()
The .proto file in which this oneof was defined. Never nullptr.
Defined at line 2789 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
const Descriptor * containing_type ()
The Descriptor for the message containing this oneof.
Defined at line 2589 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
int field_count ()
The number of (non-extension) fields which are members of this oneof.
Defined at line 2590 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
const FieldDescriptor * field (int index)
Get a member of this oneof, in the order in which they were declared in the
.proto file. Does not include extensions.
Defined at line 2591 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
const OneofOptions & options ()
Defined at line 2592 of file ../../third_party/protobuf/src/google/protobuf/descriptor.h
void CopyTo (OneofDescriptorProto * proto)
See Descriptor::CopyTo().
std::string DebugString ()
See Descriptor::DebugString().
std::string DebugStringWithOptions (const DebugStringOptions & options)
See Descriptor::DebugStringWithOptions().
bool GetSourceLocation (SourceLocation * out_location)
Updates |*out_location| to the source location of the complete
extent of this oneof declaration. Returns false and leaves
|*out_location| unchanged iff location information was not available.
Friends
class Reflection
class FieldDescriptor
class Descriptor
class DescriptorBuilder
class InternalFeatureHelper
class OneofDescriptorLegacy
class Formatter
class Printer
class Symbol
template <typename Sink>
void OneofDescriptor (Sink & sinkconst OneofDescriptor & d)