def write(self, oprot):
if oprot._fast_encode is not None and self.thrift_spec is not None:
oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
return
oprot.writeStructBegin('ServiceDetails')
if self.serviceId is not None:
oprot.writeFieldBegin('serviceId', TType.I32, 1)
oprot.writeI32(self.serviceId)
oprot.writeFieldEnd()
if self.serviceDescription is not None:
oprot.writeFieldBegin('serviceDescription', TType.STRING, 2)
oprot.writeString(self.serviceDescription.encode('utf-8') if sys.version_info[0] == 2 else self.serviceDescription)
oprot.writeFieldEnd()
if self.serviceName is not None:
oprot.writeFieldBegin('serviceName', TType.STRING, 3)
oprot.writeString(self.serviceName.encode('utf-8') if sys.version_info[0] == 2 else self.serviceName)
oprot.writeFieldEnd()
oprot.writeFieldStop()
oprot.writeStructEnd()
评论列表
文章目录