View Javadoc
1   package com.acumenvelocity.ath.model;
2   
3   import java.util.Objects;
4   import java.util.UUID;
5   
6   import com.acumenvelocity.ath.model.x.LayeredTextX;
7   import com.fasterxml.jackson.annotation.JsonProperty;
8   
9   import io.swagger.annotations.ApiModelProperty;
10  
11  @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaInflectorServerCodegen", comments = "Generator version: 7.15.0")
12  public class UpdateTranslationMemorySegmentRequest {
13    @JsonProperty("tm_seg_id")
14    private UUID tmSegId;
15  
16    @JsonProperty("doc_id")
17    private UUID docId;
18  
19    @JsonProperty("doc_file_name")
20    private String docFileName;
21  
22    @JsonProperty("target")
23    private LayeredTextX target;
24  
25    @JsonProperty("user_id")
26    private UUID userId;
27  
28    /**
29     * UUID of the TM segment
30     **/
31    public UpdateTranslationMemorySegmentRequest tmSegId(UUID tmSegId) {
32      this.tmSegId = tmSegId;
33      return this;
34    }
35  
36    @ApiModelProperty(required = true, value = "UUID of the TM segment")
37    @JsonProperty("tm_seg_id")
38    public UUID getTmSegId() {
39      return tmSegId;
40    }
41  
42    public void setTmSegId(UUID tmSegId) {
43      this.tmSegId = tmSegId;
44    }
45  
46    /**
47     * Optional UUID of the document if the TM segment was imported from a document.
48     **/
49    public UpdateTranslationMemorySegmentRequest docId(UUID docId) {
50      this.docId = docId;
51      return this;
52    }
53  
54    @ApiModelProperty(value = "Optional UUID of the document if the TM segment was imported from a document.")
55    @JsonProperty("doc_id")
56    public UUID getDocId() {
57      return docId;
58    }
59  
60    public void setDocId(UUID docId) {
61      this.docId = docId;
62    }
63  
64    /**
65     * Optional name of the document if the TM segment was imported from a document.
66     **/
67    public UpdateTranslationMemorySegmentRequest docFileName(String docFileName) {
68      this.docFileName = docFileName;
69      return this;
70    }
71  
72    @ApiModelProperty(value = "Optional name of the document if the TM segment was imported from a document.")
73    @JsonProperty("doc_file_name")
74    public String getDocFileName() {
75      return docFileName;
76    }
77  
78    public void setDocFileName(String docFileName) {
79      this.docFileName = docFileName;
80    }
81  
82    /**
83     **/
84    public UpdateTranslationMemorySegmentRequest target(LayeredTextX target) {
85      this.target = target;
86      return this;
87    }
88  
89    @ApiModelProperty(required = true, value = "")
90    @JsonProperty("target")
91    public LayeredTextX getTarget() {
92      return target;
93    }
94  
95    public void setTarget(LayeredTextX target) {
96      this.target = target;
97    }
98  
99    /**
100    * UUID of the user updating the TM segment.
101    **/
102   public UpdateTranslationMemorySegmentRequest userId(UUID userId) {
103     this.userId = userId;
104     return this;
105   }
106 
107   @ApiModelProperty(required = true, value = "UUID of the user updating the TM segment.")
108   @JsonProperty("user_id")
109   public UUID getUserId() {
110     return userId;
111   }
112 
113   public void setUserId(UUID userId) {
114     this.userId = userId;
115   }
116 
117   @Override
118   public boolean equals(Object o) {
119     if (this == o) {
120       return true;
121     }
122     if (o == null || getClass() != o.getClass()) {
123       return false;
124     }
125     UpdateTranslationMemorySegmentRequest updateTranslationMemorySegmentRequest = (UpdateTranslationMemorySegmentRequest) o;
126     return Objects.equals(tmSegId, updateTranslationMemorySegmentRequest.tmSegId) &&
127         Objects.equals(docId, updateTranslationMemorySegmentRequest.docId) &&
128         Objects.equals(docFileName, updateTranslationMemorySegmentRequest.docFileName) &&
129         Objects.equals(target, updateTranslationMemorySegmentRequest.target) &&
130         Objects.equals(userId, updateTranslationMemorySegmentRequest.userId);
131   }
132 
133   @Override
134   public int hashCode() {
135     return Objects.hash(tmSegId, docId, docFileName, target, userId);
136   }
137 
138   @Override
139   public String toString() {
140     StringBuilder sb = new StringBuilder();
141     sb.append("class UpdateTranslationMemorySegmentRequest {\n");
142 
143     sb.append("    tmSegId: ").append(toIndentedString(tmSegId)).append("\n");
144     sb.append("    docId: ").append(toIndentedString(docId)).append("\n");
145     sb.append("    docFileName: ").append(toIndentedString(docFileName)).append("\n");
146     sb.append("    target: ").append(toIndentedString(target)).append("\n");
147     sb.append("    userId: ").append(toIndentedString(userId)).append("\n");
148     sb.append("}");
149     return sb.toString();
150   }
151 
152   /**
153    * Convert the given object to string with each line indented by 4 spaces
154    * (except the first line).
155    */
156   private String toIndentedString(Object o) {
157     if (o == null) {
158       return "null";
159     }
160     return o.toString().replace("\n", "\n    ");
161   }
162 }