packagedht// A helper struct to make working with protbuf types easiertypepDHTMessagestruct{TypeDHTMessage_MessageTypeKeystringValue[]byteResponseboolIduint64}func(m*pDHTMessage)ToProtobuf()*DHTMessage{pmes:=new(DHTMessage)ifm.Value!=nil{pmes.Value=m.Value}pmes.Type=&m.Typepmes.Key=&m.Keypmes.Response=&m.Responsepmes.Id=&m.Idreturnpmes}