diff --git a/.stats.yml b/.stats.yml index 0ebc21b..acd4ac2 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,2 +1,2 @@ configured_endpoints: 28 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/open-transit%2Fopen-transit-d04668d97c66a80708cb1896ce9638dc2b55670ed447b67d9833f6a5349cc210.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/open-transit%2Fopen-transit-6f08502508c8ad25235971add3124a1cde4f1c3ec705d5df455d750e0adcb90b.yml diff --git a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/References.kt b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/References.kt index 4047213..698d6d7 100644 --- a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/References.kt +++ b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/References.kt @@ -2175,7 +2175,7 @@ private constructor( private var validated: Boolean = false - fun code(): String = code.getRequired("code") + fun code(): Optional = Optional.ofNullable(code.getNullable("code")) fun direction(): Optional = Optional.ofNullable(direction.getNullable("direction")) @@ -2190,13 +2190,11 @@ private constructor( fun name(): String = name.getRequired("name") - fun parent(): Optional = Optional.ofNullable(parent.getNullable("parent")) + fun parent(): String = parent.getRequired("parent") - fun routeIds(): Optional> = - Optional.ofNullable(routeIds.getNullable("routeIds")) + fun routeIds(): List = routeIds.getRequired("routeIds") - fun staticRouteIds(): Optional> = - Optional.ofNullable(staticRouteIds.getNullable("staticRouteIds")) + fun staticRouteIds(): List = staticRouteIds.getRequired("staticRouteIds") fun wheelchairBoarding(): Optional = Optional.ofNullable(wheelchairBoarding.getNullable("wheelchairBoarding")) diff --git a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/ScheduleForRouteRetrieveResponse.kt b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/ScheduleForRouteRetrieveResponse.kt index 202b4a3..37a37a4 100644 --- a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/ScheduleForRouteRetrieveResponse.kt +++ b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/ScheduleForRouteRetrieveResponse.kt @@ -397,7 +397,7 @@ private constructor( private var validated: Boolean = false - fun code(): String = code.getRequired("code") + fun code(): Optional = Optional.ofNullable(code.getNullable("code")) fun direction(): Optional = Optional.ofNullable(direction.getNullable("direction")) @@ -413,13 +413,11 @@ private constructor( fun name(): String = name.getRequired("name") - fun parent(): Optional = Optional.ofNullable(parent.getNullable("parent")) + fun parent(): String = parent.getRequired("parent") - fun routeIds(): Optional> = - Optional.ofNullable(routeIds.getNullable("routeIds")) + fun routeIds(): List = routeIds.getRequired("routeIds") - fun staticRouteIds(): Optional> = - Optional.ofNullable(staticRouteIds.getNullable("staticRouteIds")) + fun staticRouteIds(): List = staticRouteIds.getRequired("staticRouteIds") fun wheelchairBoarding(): Optional = Optional.ofNullable(wheelchairBoarding.getNullable("wheelchairBoarding")) diff --git a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/SearchForStopListResponse.kt b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/SearchForStopListResponse.kt index c2d718a..f8c82df 100644 --- a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/SearchForStopListResponse.kt +++ b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/SearchForStopListResponse.kt @@ -292,7 +292,7 @@ private constructor( private var validated: Boolean = false - fun code(): String = code.getRequired("code") + fun code(): Optional = Optional.ofNullable(code.getNullable("code")) fun direction(): Optional = Optional.ofNullable(direction.getNullable("direction")) @@ -308,13 +308,11 @@ private constructor( fun name(): String = name.getRequired("name") - fun parent(): Optional = Optional.ofNullable(parent.getNullable("parent")) + fun parent(): String = parent.getRequired("parent") - fun routeIds(): Optional> = - Optional.ofNullable(routeIds.getNullable("routeIds")) + fun routeIds(): List = routeIds.getRequired("routeIds") - fun staticRouteIds(): Optional> = - Optional.ofNullable(staticRouteIds.getNullable("staticRouteIds")) + fun staticRouteIds(): List = staticRouteIds.getRequired("staticRouteIds") fun wheelchairBoarding(): Optional = Optional.ofNullable(wheelchairBoarding.getNullable("wheelchairBoarding")) diff --git a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopRetrieveResponse.kt b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopRetrieveResponse.kt index 4867608..c94ac1e 100644 --- a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopRetrieveResponse.kt +++ b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopRetrieveResponse.kt @@ -260,7 +260,7 @@ private constructor( private var validated: Boolean = false - fun code(): String = code.getRequired("code") + fun code(): Optional = Optional.ofNullable(code.getNullable("code")) fun direction(): Optional = Optional.ofNullable(direction.getNullable("direction")) @@ -276,13 +276,11 @@ private constructor( fun name(): String = name.getRequired("name") - fun parent(): Optional = Optional.ofNullable(parent.getNullable("parent")) + fun parent(): String = parent.getRequired("parent") - fun routeIds(): Optional> = - Optional.ofNullable(routeIds.getNullable("routeIds")) + fun routeIds(): List = routeIds.getRequired("routeIds") - fun staticRouteIds(): Optional> = - Optional.ofNullable(staticRouteIds.getNullable("staticRouteIds")) + fun staticRouteIds(): List = staticRouteIds.getRequired("staticRouteIds") fun wheelchairBoarding(): Optional = Optional.ofNullable(wheelchairBoarding.getNullable("wheelchairBoarding")) diff --git a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopsForLocationListResponse.kt b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopsForLocationListResponse.kt index 3d8cf8d..c729baa 100644 --- a/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopsForLocationListResponse.kt +++ b/onebusaway-sdk-java-core/src/main/kotlin/org/onebusaway/models/StopsForLocationListResponse.kt @@ -158,6 +158,7 @@ private constructor( class Data private constructor( private val limitExceeded: JsonField, + private val outOfRange: JsonField, private val list: JsonField>, private val references: JsonField, private val additionalProperties: Map, @@ -167,12 +168,17 @@ private constructor( fun limitExceeded(): Boolean = limitExceeded.getRequired("limitExceeded") + fun outOfRange(): Optional = + Optional.ofNullable(outOfRange.getNullable("outOfRange")) + fun list(): List = list.getRequired("list") fun references(): References = references.getRequired("references") @JsonProperty("limitExceeded") @ExcludeMissing fun _limitExceeded() = limitExceeded + @JsonProperty("outOfRange") @ExcludeMissing fun _outOfRange() = outOfRange + @JsonProperty("list") @ExcludeMissing fun _list() = list @JsonProperty("references") @ExcludeMissing fun _references() = references @@ -184,6 +190,7 @@ private constructor( fun validate(): Data = apply { if (!validated) { limitExceeded() + outOfRange() list().forEach { it.validate() } references().validate() validated = true @@ -200,6 +207,7 @@ private constructor( class Builder { private var limitExceeded: JsonField = JsonMissing.of() + private var outOfRange: JsonField = JsonMissing.of() private var list: JsonField> = JsonMissing.of() private var references: JsonField = JsonMissing.of() private var additionalProperties: MutableMap = mutableMapOf() @@ -207,6 +215,7 @@ private constructor( @JvmSynthetic internal fun from(data: Data) = apply { this.limitExceeded = data.limitExceeded + this.outOfRange = data.outOfRange this.list = data.list this.references = data.references additionalProperties(data.additionalProperties) @@ -220,6 +229,12 @@ private constructor( this.limitExceeded = limitExceeded } + fun outOfRange(outOfRange: Boolean) = outOfRange(JsonField.of(outOfRange)) + + @JsonProperty("outOfRange") + @ExcludeMissing + fun outOfRange(outOfRange: JsonField) = apply { this.outOfRange = outOfRange } + fun list(list: List) = list(JsonField.of(list)) @JsonProperty("list") @@ -251,6 +266,7 @@ private constructor( fun build(): Data = Data( limitExceeded, + outOfRange, list.map { it.toImmutable() }, references, additionalProperties.toImmutable(), @@ -517,20 +533,20 @@ private constructor( return true } - return /* spotless:off */ other is Data && this.limitExceeded == other.limitExceeded && this.list == other.list && this.references == other.references && this.additionalProperties == other.additionalProperties /* spotless:on */ + return /* spotless:off */ other is Data && this.limitExceeded == other.limitExceeded && this.outOfRange == other.outOfRange && this.list == other.list && this.references == other.references && this.additionalProperties == other.additionalProperties /* spotless:on */ } private var hashCode: Int = 0 override fun hashCode(): Int { if (hashCode == 0) { - hashCode = /* spotless:off */ Objects.hash(limitExceeded, list, references, additionalProperties) /* spotless:on */ + hashCode = /* spotless:off */ Objects.hash(limitExceeded, outOfRange, list, references, additionalProperties) /* spotless:on */ } return hashCode } override fun toString() = - "Data{limitExceeded=$limitExceeded, list=$list, references=$references, additionalProperties=$additionalProperties}" + "Data{limitExceeded=$limitExceeded, outOfRange=$outOfRange, list=$list, references=$references, additionalProperties=$additionalProperties}" } override fun equals(other: Any?): Boolean { diff --git a/onebusaway-sdk-java-core/src/test/kotlin/org/onebusaway/models/ReferencesTest.kt b/onebusaway-sdk-java-core/src/test/kotlin/org/onebusaway/models/ReferencesTest.kt index 3f3b282..85bbd9b 100644 --- a/onebusaway-sdk-java-core/src/test/kotlin/org/onebusaway/models/ReferencesTest.kt +++ b/onebusaway-sdk-java-core/src/test/kotlin/org/onebusaway/models/ReferencesTest.kt @@ -127,15 +127,15 @@ class ReferencesTest { listOf( References.Stop.builder() .id("id") - .code("code") .lat(42.23) .lon(42.23) .name("name") - .direction("direction") - .locationType(123L) .parent("parent") .routeIds(listOf("string")) .staticRouteIds(listOf("string")) + .code("code") + .direction("direction") + .locationType(123L) .wheelchairBoarding("wheelchairBoarding") .build() ) @@ -271,15 +271,15 @@ class ReferencesTest { .containsExactly( References.Stop.builder() .id("id") - .code("code") .lat(42.23) .lon(42.23) .name("name") - .direction("direction") - .locationType(123L) .parent("parent") .routeIds(listOf("string")) .staticRouteIds(listOf("string")) + .code("code") + .direction("direction") + .locationType(123L) .wheelchairBoarding("wheelchairBoarding") .build() )