Skip to content

Commit 3d4d199

Browse files
committedMar 17, 2025
chore(internal): codegen related update (#85)
1 parent 687dd63 commit 3d4d199

File tree

53 files changed

+192
-160
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+192
-160
lines changed
 

‎openlayer-java-core/src/main/kotlin/com/openlayer/api/core/http/QueryParams.kt

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// File generated from our OpenAPI spec by Stainless.
2+
13
package com.openlayer.api.core.http
24

35
import com.openlayer.api.core.toImmutable

‎openlayer-java-core/src/main/kotlin/com/openlayer/api/models/projects/commits/CommitCreateParams.kt

+45-38
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ import kotlin.jvm.optionals.getOrNull
2727
/** Create a new commit (project version) in a project. */
2828
class CommitCreateParams
2929
private constructor(
30-
private val projectId: String,
30+
private val pathProjectId: String,
3131
private val body: Body,
3232
private val additionalHeaders: Headers,
3333
private val additionalQueryParams: QueryParams,
3434
) : Params {
3535

36-
fun projectId(): String = projectId
36+
fun pathProjectId(): String = pathProjectId
3737

3838
/**
3939
* The project version (commit) id.
@@ -97,7 +97,7 @@ private constructor(
9797
* @throws OpenlayerInvalidDataException if the JSON field has an unexpected type or is
9898
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
9999
*/
100-
fun projectId(): String = body.projectId()
100+
fun bodyProjectId(): String = body.bodyProjectId()
101101

102102
/**
103103
* The commit status. Initially, the commit is `queued`, then, it switches to `running`.
@@ -222,11 +222,11 @@ private constructor(
222222
fun _passingGoalCount(): JsonField<Long> = body._passingGoalCount()
223223

224224
/**
225-
* Returns the raw JSON value of [projectId].
225+
* Returns the raw JSON value of [bodyProjectId].
226226
*
227-
* Unlike [projectId], this method doesn't throw if the JSON field has an unexpected type.
227+
* Unlike [bodyProjectId], this method doesn't throw if the JSON field has an unexpected type.
228228
*/
229-
fun _projectId(): JsonField<String> = body._projectId()
229+
fun _bodyProjectId(): JsonField<String> = body._bodyProjectId()
230230

231231
/**
232232
* Returns the raw JSON value of [status].
@@ -308,7 +308,7 @@ private constructor(
308308

309309
fun getPathParam(index: Int): String {
310310
return when (index) {
311-
0 -> projectId
311+
0 -> pathProjectId
312312
else -> ""
313313
}
314314
}
@@ -338,7 +338,7 @@ private constructor(
338338
private val passingGoalCount: JsonField<Long> = JsonMissing.of(),
339339
@JsonProperty("projectId")
340340
@ExcludeMissing
341-
private val projectId: JsonField<String> = JsonMissing.of(),
341+
private val bodyProjectId: JsonField<String> = JsonMissing.of(),
342342
@JsonProperty("status")
343343
@ExcludeMissing
344344
private val status: JsonField<Status> = JsonMissing.of(),
@@ -433,7 +433,7 @@ private constructor(
433433
* @throws OpenlayerInvalidDataException if the JSON field has an unexpected type or is
434434
* unexpectedly missing or null (e.g. if the server responded with an unexpected value).
435435
*/
436-
fun projectId(): String = projectId.getRequired("projectId")
436+
fun bodyProjectId(): String = bodyProjectId.getRequired("projectId")
437437

438438
/**
439439
* The commit status. Initially, the commit is `queued`, then, it switches to `running`.
@@ -571,11 +571,14 @@ private constructor(
571571
fun _passingGoalCount(): JsonField<Long> = passingGoalCount
572572

573573
/**
574-
* Returns the raw JSON value of [projectId].
574+
* Returns the raw JSON value of [bodyProjectId].
575575
*
576-
* Unlike [projectId], this method doesn't throw if the JSON field has an unexpected type.
576+
* Unlike [bodyProjectId], this method doesn't throw if the JSON field has an unexpected
577+
* type.
577578
*/
578-
@JsonProperty("projectId") @ExcludeMissing fun _projectId(): JsonField<String> = projectId
579+
@JsonProperty("projectId")
580+
@ExcludeMissing
581+
fun _bodyProjectId(): JsonField<String> = bodyProjectId
579582

580583
/**
581584
* Returns the raw JSON value of [status].
@@ -675,7 +678,7 @@ private constructor(
675678
failingGoalCount()
676679
mlModelId()
677680
passingGoalCount()
678-
projectId()
681+
bodyProjectId()
679682
status()
680683
statusMessage()
681684
storageUri()
@@ -704,7 +707,7 @@ private constructor(
704707
* .failingGoalCount()
705708
* .mlModelId()
706709
* .passingGoalCount()
707-
* .projectId()
710+
* .bodyProjectId()
708711
* .status()
709712
* .statusMessage()
710713
* .storageUri()
@@ -726,7 +729,7 @@ private constructor(
726729
private var failingGoalCount: JsonField<Long>? = null
727730
private var mlModelId: JsonField<String>? = null
728731
private var passingGoalCount: JsonField<Long>? = null
729-
private var projectId: JsonField<String>? = null
732+
private var bodyProjectId: JsonField<String>? = null
730733
private var status: JsonField<Status>? = null
731734
private var statusMessage: JsonField<String>? = null
732735
private var storageUri: JsonField<String>? = null
@@ -747,7 +750,7 @@ private constructor(
747750
failingGoalCount = body.failingGoalCount
748751
mlModelId = body.mlModelId
749752
passingGoalCount = body.passingGoalCount
750-
projectId = body.projectId
753+
bodyProjectId = body.bodyProjectId
751754
status = body.status
752755
statusMessage = body.statusMessage
753756
storageUri = body.storageUri
@@ -863,16 +866,18 @@ private constructor(
863866
}
864867

865868
/** The project id. */
866-
fun projectId(projectId: String) = projectId(JsonField.of(projectId))
869+
fun bodyProjectId(bodyProjectId: String) = bodyProjectId(JsonField.of(bodyProjectId))
867870

868871
/**
869-
* Sets [Builder.projectId] to an arbitrary JSON value.
872+
* Sets [Builder.bodyProjectId] to an arbitrary JSON value.
870873
*
871-
* You should usually call [Builder.projectId] with a well-typed [String] value instead.
872-
* This method is primarily for setting the field to an undocumented or not yet
874+
* You should usually call [Builder.bodyProjectId] with a well-typed [String] value
875+
* instead. This method is primarily for setting the field to an undocumented or not yet
873876
* supported value.
874877
*/
875-
fun projectId(projectId: JsonField<String>) = apply { this.projectId = projectId }
878+
fun bodyProjectId(bodyProjectId: JsonField<String>) = apply {
879+
this.bodyProjectId = bodyProjectId
880+
}
876881

877882
/**
878883
* The commit status. Initially, the commit is `queued`, then, it switches to `running`.
@@ -1053,7 +1058,7 @@ private constructor(
10531058
checkRequired("failingGoalCount", failingGoalCount),
10541059
checkRequired("mlModelId", mlModelId),
10551060
checkRequired("passingGoalCount", passingGoalCount),
1056-
checkRequired("projectId", projectId),
1061+
checkRequired("bodyProjectId", bodyProjectId),
10571062
checkRequired("status", status),
10581063
checkRequired("statusMessage", statusMessage),
10591064
checkRequired("storageUri", storageUri),
@@ -1072,17 +1077,17 @@ private constructor(
10721077
return true
10731078
}
10741079

1075-
return /* spotless:off */ other is Body && id == other.id && commit == other.commit && dateArchived == other.dateArchived && dateCreated == other.dateCreated && failingGoalCount == other.failingGoalCount && mlModelId == other.mlModelId && passingGoalCount == other.passingGoalCount && projectId == other.projectId && status == other.status && statusMessage == other.statusMessage && storageUri == other.storageUri && totalGoalCount == other.totalGoalCount && trainingDatasetId == other.trainingDatasetId && validationDatasetId == other.validationDatasetId && archived == other.archived && deploymentStatus == other.deploymentStatus && links == other.links && additionalProperties == other.additionalProperties /* spotless:on */
1080+
return /* spotless:off */ other is Body && id == other.id && commit == other.commit && dateArchived == other.dateArchived && dateCreated == other.dateCreated && failingGoalCount == other.failingGoalCount && mlModelId == other.mlModelId && passingGoalCount == other.passingGoalCount && bodyProjectId == other.bodyProjectId && status == other.status && statusMessage == other.statusMessage && storageUri == other.storageUri && totalGoalCount == other.totalGoalCount && trainingDatasetId == other.trainingDatasetId && validationDatasetId == other.validationDatasetId && archived == other.archived && deploymentStatus == other.deploymentStatus && links == other.links && additionalProperties == other.additionalProperties /* spotless:on */
10761081
}
10771082

10781083
/* spotless:off */
1079-
private val hashCode: Int by lazy { Objects.hash(id, commit, dateArchived, dateCreated, failingGoalCount, mlModelId, passingGoalCount, projectId, status, statusMessage, storageUri, totalGoalCount, trainingDatasetId, validationDatasetId, archived, deploymentStatus, links, additionalProperties) }
1084+
private val hashCode: Int by lazy { Objects.hash(id, commit, dateArchived, dateCreated, failingGoalCount, mlModelId, passingGoalCount, bodyProjectId, status, statusMessage, storageUri, totalGoalCount, trainingDatasetId, validationDatasetId, archived, deploymentStatus, links, additionalProperties) }
10801085
/* spotless:on */
10811086

10821087
override fun hashCode(): Int = hashCode
10831088

10841089
override fun toString() =
1085-
"Body{id=$id, commit=$commit, dateArchived=$dateArchived, dateCreated=$dateCreated, failingGoalCount=$failingGoalCount, mlModelId=$mlModelId, passingGoalCount=$passingGoalCount, projectId=$projectId, status=$status, statusMessage=$statusMessage, storageUri=$storageUri, totalGoalCount=$totalGoalCount, trainingDatasetId=$trainingDatasetId, validationDatasetId=$validationDatasetId, archived=$archived, deploymentStatus=$deploymentStatus, links=$links, additionalProperties=$additionalProperties}"
1090+
"Body{id=$id, commit=$commit, dateArchived=$dateArchived, dateCreated=$dateCreated, failingGoalCount=$failingGoalCount, mlModelId=$mlModelId, passingGoalCount=$passingGoalCount, bodyProjectId=$bodyProjectId, status=$status, statusMessage=$statusMessage, storageUri=$storageUri, totalGoalCount=$totalGoalCount, trainingDatasetId=$trainingDatasetId, validationDatasetId=$validationDatasetId, archived=$archived, deploymentStatus=$deploymentStatus, links=$links, additionalProperties=$additionalProperties}"
10861091
}
10871092

10881093
fun toBuilder() = Builder().from(this)
@@ -1094,15 +1099,15 @@ private constructor(
10941099
*
10951100
* The following fields are required:
10961101
* ```java
1097-
* .projectId()
1102+
* .pathProjectId()
10981103
* .id()
10991104
* .commit()
11001105
* .dateArchived()
11011106
* .dateCreated()
11021107
* .failingGoalCount()
11031108
* .mlModelId()
11041109
* .passingGoalCount()
1105-
* .projectId()
1110+
* .bodyProjectId()
11061111
* .status()
11071112
* .statusMessage()
11081113
* .storageUri()
@@ -1118,20 +1123,20 @@ private constructor(
11181123
@NoAutoDetect
11191124
class Builder internal constructor() {
11201125

1121-
private var projectId: String? = null
1126+
private var pathProjectId: String? = null
11221127
private var body: Body.Builder = Body.builder()
11231128
private var additionalHeaders: Headers.Builder = Headers.builder()
11241129
private var additionalQueryParams: QueryParams.Builder = QueryParams.builder()
11251130

11261131
@JvmSynthetic
11271132
internal fun from(commitCreateParams: CommitCreateParams) = apply {
1128-
projectId = commitCreateParams.projectId
1133+
pathProjectId = commitCreateParams.pathProjectId
11291134
body = commitCreateParams.body.toBuilder()
11301135
additionalHeaders = commitCreateParams.additionalHeaders.toBuilder()
11311136
additionalQueryParams = commitCreateParams.additionalQueryParams.toBuilder()
11321137
}
11331138

1134-
fun projectId(projectId: String) = apply { this.projectId = projectId }
1139+
fun pathProjectId(pathProjectId: String) = apply { this.pathProjectId = pathProjectId }
11351140

11361141
/** The project version (commit) id. */
11371142
fun id(id: String) = apply { body.id(id) }
@@ -1235,16 +1240,18 @@ private constructor(
12351240
}
12361241

12371242
/** The project id. */
1238-
fun projectId(projectId: String) = apply { body.projectId(projectId) }
1243+
fun bodyProjectId(bodyProjectId: String) = apply { body.bodyProjectId(bodyProjectId) }
12391244

12401245
/**
1241-
* Sets [Builder.projectId] to an arbitrary JSON value.
1246+
* Sets [Builder.bodyProjectId] to an arbitrary JSON value.
12421247
*
1243-
* You should usually call [Builder.projectId] with a well-typed [String] value instead.
1248+
* You should usually call [Builder.bodyProjectId] with a well-typed [String] value instead.
12441249
* This method is primarily for setting the field to an undocumented or not yet supported
12451250
* value.
12461251
*/
1247-
fun projectId(projectId: JsonField<String>) = apply { body.projectId(projectId) }
1252+
fun bodyProjectId(bodyProjectId: JsonField<String>) = apply {
1253+
body.bodyProjectId(bodyProjectId)
1254+
}
12481255

12491256
/**
12501257
* The commit status. Initially, the commit is `queued`, then, it switches to `running`.
@@ -1513,7 +1520,7 @@ private constructor(
15131520

15141521
fun build(): CommitCreateParams =
15151522
CommitCreateParams(
1516-
checkRequired("projectId", projectId),
1523+
checkRequired("pathProjectId", pathProjectId),
15171524
body.build(),
15181525
additionalHeaders.build(),
15191526
additionalQueryParams.build(),
@@ -2337,11 +2344,11 @@ private constructor(
23372344
return true
23382345
}
23392346

2340-
return /* spotless:off */ other is CommitCreateParams && projectId == other.projectId && body == other.body && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams /* spotless:on */
2347+
return /* spotless:off */ other is CommitCreateParams && pathProjectId == other.pathProjectId && body == other.body && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams /* spotless:on */
23412348
}
23422349

2343-
override fun hashCode(): Int = /* spotless:off */ Objects.hash(projectId, body, additionalHeaders, additionalQueryParams) /* spotless:on */
2350+
override fun hashCode(): Int = /* spotless:off */ Objects.hash(pathProjectId, body, additionalHeaders, additionalQueryParams) /* spotless:on */
23442351

23452352
override fun toString() =
2346-
"CommitCreateParams{projectId=$projectId, body=$body, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams}"
2353+
"CommitCreateParams{pathProjectId=$pathProjectId, body=$body, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams}"
23472354
}

0 commit comments

Comments
 (0)