每天读懂一段代码,Go的struct

// A response with a representation similar to an HTTP response that can
// be used within another message.
type Response struct {
    // A status code that should follow the HTTP status codes.
    Status int32 `protobuf:"varint,1,opt,name=status" json:"status,omitempty"`
    // A message associated with the response code.
    Message string `protobuf:"bytes,2,opt,name=message" json:"message,omitempty"`
    // A payload that can be used to include metadata with this response.
    Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
}

你可能感兴趣的:(golang)