def from_protobuf_class(protobuf_class):
'''
Return a generator for an already-loaded Protobuf class.
Args:
protobuf_class(Message) -- A class object created from Protobuf-
generated code.
Returns:
A ProtobufGenerator instance that can be used to create inter-field
dependencies or to generate messages.
'''
return ProtobufGenerator(protobuf_class.DESCRIPTOR)
评论列表
文章目录