@@ -18,13 +18,15 @@ import java.util.Objects
1818class CreateCompanyBenefitsResponse
1919private constructor (
2020 private val benefitId: JsonField <String >,
21+ private val jobId: JsonField <String >,
2122 private val additionalProperties: MutableMap <String , JsonValue >,
2223) {
2324
2425 @JsonCreator
2526 private constructor (
26- @JsonProperty(" benefit_id" ) @ExcludeMissing benefitId: JsonField <String > = JsonMissing .of()
27- ) : this (benefitId, mutableMapOf ())
27+ @JsonProperty(" benefit_id" ) @ExcludeMissing benefitId: JsonField <String > = JsonMissing .of(),
28+ @JsonProperty(" job_id" ) @ExcludeMissing jobId: JsonField <String > = JsonMissing .of(),
29+ ) : this (benefitId, jobId, mutableMapOf ())
2830
2931 /* *
3032 * The id of the benefit.
@@ -34,13 +36,26 @@ private constructor(
3436 */
3537 fun benefitId (): String = benefitId.getRequired(" benefit_id" )
3638
39+ /* *
40+ * @throws FinchInvalidDataException if the JSON field has an unexpected type or is unexpectedly
41+ * missing or null (e.g. if the server responded with an unexpected value).
42+ */
43+ fun jobId (): String = jobId.getRequired(" job_id" )
44+
3745 /* *
3846 * Returns the raw JSON value of [benefitId].
3947 *
4048 * Unlike [benefitId], this method doesn't throw if the JSON field has an unexpected type.
4149 */
4250 @JsonProperty(" benefit_id" ) @ExcludeMissing fun _benefitId (): JsonField <String > = benefitId
4351
52+ /* *
53+ * Returns the raw JSON value of [jobId].
54+ *
55+ * Unlike [jobId], this method doesn't throw if the JSON field has an unexpected type.
56+ */
57+ @JsonProperty(" job_id" ) @ExcludeMissing fun _jobId (): JsonField <String > = jobId
58+
4459 @JsonAnySetter
4560 private fun putAdditionalProperty (key : String , value : JsonValue ) {
4661 additionalProperties.put(key, value)
@@ -62,6 +77,7 @@ private constructor(
6277 * The following fields are required:
6378 * ```java
6479 * .benefitId()
80+ * .jobId()
6581 * ```
6682 */
6783 @JvmStatic fun builder () = Builder ()
@@ -71,11 +87,13 @@ private constructor(
7187 class Builder internal constructor() {
7288
7389 private var benefitId: JsonField <String >? = null
90+ private var jobId: JsonField <String >? = null
7491 private var additionalProperties: MutableMap <String , JsonValue > = mutableMapOf ()
7592
7693 @JvmSynthetic
7794 internal fun from (createCompanyBenefitsResponse : CreateCompanyBenefitsResponse ) = apply {
7895 benefitId = createCompanyBenefitsResponse.benefitId
96+ jobId = createCompanyBenefitsResponse.jobId
7997 additionalProperties = createCompanyBenefitsResponse.additionalProperties.toMutableMap()
8098 }
8199
@@ -91,6 +109,16 @@ private constructor(
91109 */
92110 fun benefitId (benefitId : JsonField <String >) = apply { this .benefitId = benefitId }
93111
112+ fun jobId (jobId : String ) = jobId(JsonField .of(jobId))
113+
114+ /* *
115+ * Sets [Builder.jobId] to an arbitrary JSON value.
116+ *
117+ * You should usually call [Builder.jobId] with a well-typed [String] value instead. This
118+ * method is primarily for setting the field to an undocumented or not yet supported value.
119+ */
120+ fun jobId (jobId : JsonField <String >) = apply { this .jobId = jobId }
121+
94122 fun additionalProperties (additionalProperties : Map <String , JsonValue >) = apply {
95123 this .additionalProperties.clear()
96124 putAllAdditionalProperties(additionalProperties)
@@ -118,13 +146,15 @@ private constructor(
118146 * The following fields are required:
119147 * ```java
120148 * .benefitId()
149+ * .jobId()
121150 * ```
122151 *
123152 * @throws IllegalStateException if any required field is unset.
124153 */
125154 fun build (): CreateCompanyBenefitsResponse =
126155 CreateCompanyBenefitsResponse (
127156 checkRequired(" benefitId" , benefitId),
157+ checkRequired(" jobId" , jobId),
128158 additionalProperties.toMutableMap(),
129159 )
130160 }
@@ -137,6 +167,7 @@ private constructor(
137167 }
138168
139169 benefitId()
170+ jobId()
140171 validated = true
141172 }
142173
@@ -153,22 +184,24 @@ private constructor(
153184 *
154185 * Used for best match union deserialization.
155186 */
156- @JvmSynthetic internal fun validity (): Int = (if (benefitId.asKnown().isPresent) 1 else 0 )
187+ @JvmSynthetic
188+ internal fun validity (): Int =
189+ (if (benefitId.asKnown().isPresent) 1 else 0 ) + (if (jobId.asKnown().isPresent) 1 else 0 )
157190
158191 override fun equals (other : Any? ): Boolean {
159192 if (this == = other) {
160193 return true
161194 }
162195
163- return /* spotless:off */ other is CreateCompanyBenefitsResponse && benefitId == other.benefitId && additionalProperties == other.additionalProperties /* spotless:on */
196+ return /* spotless:off */ other is CreateCompanyBenefitsResponse && benefitId == other.benefitId && jobId == other.jobId && additionalProperties == other.additionalProperties /* spotless:on */
164197 }
165198
166199 /* spotless:off */
167- private val hashCode: Int by lazy { Objects .hash(benefitId, additionalProperties) }
200+ private val hashCode: Int by lazy { Objects .hash(benefitId, jobId, additionalProperties) }
168201 /* spotless:on */
169202
170203 override fun hashCode (): Int = hashCode
171204
172205 override fun toString () =
173- " CreateCompanyBenefitsResponse{benefitId=$benefitId , additionalProperties=$additionalProperties }"
206+ " CreateCompanyBenefitsResponse{benefitId=$benefitId , jobId= $jobId , additionalProperties=$additionalProperties }"
174207}
0 commit comments