You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

68 lines
1.4 KiB

  1. // @Title Golang SDK Client
  2. // @Description This code is auto generated
  3. // @Author Ecloud SDK
  4. package model
  5. import (
  6. "gitlab.ecloud.com/ecloud/ecloudsdkcore/position"
  7. "gitlab.ecloud.com/ecloud/ecloudsdkcore/utils"
  8. )
  9. type UpdateSegmentBody struct {
  10. position.Body
  11. // QA问答对的回答
  12. Answer *string `json:"answer,omitempty"`
  13. // 分段文档内容,或者QA问答对的提问
  14. Content *string `json:"content,omitempty"`
  15. }
  16. func (s UpdateSegmentBody) String() string {
  17. return utils.Beautify(s)
  18. }
  19. func (s UpdateSegmentBody) GoString() string {
  20. return s.String()
  21. }
  22. func (s UpdateSegmentBody) ToJsonString() string {
  23. return utils.ToJsonString(s)
  24. }
  25. func (s *UpdateSegmentBody) SetAnswer(v string) *UpdateSegmentBody {
  26. s.Answer = &v
  27. return s
  28. }
  29. func (s *UpdateSegmentBody) SetContent(v string) *UpdateSegmentBody {
  30. s.Content = &v
  31. return s
  32. }
  33. type UpdateSegmentBodyBuilder struct {
  34. s *UpdateSegmentBody
  35. }
  36. func NewUpdateSegmentBodyBuilder() *UpdateSegmentBodyBuilder {
  37. s := &UpdateSegmentBody{}
  38. b := &UpdateSegmentBodyBuilder{s: s}
  39. return b
  40. }
  41. func (b *UpdateSegmentBodyBuilder) Answer(v string) *UpdateSegmentBodyBuilder {
  42. b.s.Answer = &v
  43. return b
  44. }
  45. func (b *UpdateSegmentBodyBuilder) Content(v string) *UpdateSegmentBodyBuilder {
  46. b.s.Content = &v
  47. return b
  48. }
  49. func (b *UpdateSegmentBodyBuilder) Build() *UpdateSegmentBody {
  50. return b.s
  51. }