Browse Source

Polishing

pull/23521/head
Sebastien Deleuze 6 years ago
parent
commit
a2e740c896
  1. 2
      spring-test/src/main/kotlin/org/springframework/test/web/reactive/server/WebTestClientExtensions.kt
  2. 1
      spring-webflux/src/main/kotlin/org/springframework/web/reactive/function/client/WebClientExtensions.kt
  3. 1
      spring-webflux/src/main/kotlin/org/springframework/web/reactive/function/server/ServerResponseExtensions.kt
  4. 2
      spring-webmvc/src/test/kotlin/org/springframework/web/servlet/view/script/ScriptTemplateWithBindingsExtensions.kt
  5. 2
      spring-webmvc/src/test/resources/org/springframework/web/servlet/view/script/kotlin/template.kts

2
spring-test/src/main/kotlin/org/springframework/test/web/reactive/server/WebTestClientExtensions.kt

@ -30,7 +30,6 @@ import org.springframework.test.web.reactive.server.WebTestClient.* @@ -30,7 +30,6 @@ import org.springframework.test.web.reactive.server.WebTestClient.*
* @author Sebastien Deleuze
* @since 5.0
*/
@Suppress("EXTENSION_SHADOWED_BY_MEMBER")
inline fun <reified T : Any, S : Publisher<T>> RequestBodySpec.body(publisher: S): RequestHeadersSpec<*>
= body(publisher, object : ParameterizedTypeReference<T>() {})
@ -125,6 +124,5 @@ inline fun <reified E : Any> ResponseSpec.expectBodyList(): ListBodySpec<E> = @@ -125,6 +124,5 @@ inline fun <reified E : Any> ResponseSpec.expectBodyList(): ListBodySpec<E> =
* @author Sebastien Deleuze
* @since 5.0
*/
@Suppress("EXTENSION_SHADOWED_BY_MEMBER")
inline fun <reified T : Any> ResponseSpec.returnResult(): FluxExchangeResult<T> =
returnResult(object : ParameterizedTypeReference<T>() {})

1
spring-webflux/src/main/kotlin/org/springframework/web/reactive/function/client/WebClientExtensions.kt

@ -35,7 +35,6 @@ import reactor.core.publisher.Mono @@ -35,7 +35,6 @@ import reactor.core.publisher.Mono
* @author Sebastien Deleuze
* @since 5.0
*/
@Suppress("EXTENSION_SHADOWED_BY_MEMBER")
inline fun <reified T : Any, S : Publisher<T>> RequestBodySpec.body(publisher: S): RequestHeadersSpec<*> =
body(publisher, object : ParameterizedTypeReference<T>() {})

1
spring-webflux/src/main/kotlin/org/springframework/web/reactive/function/server/ServerResponseExtensions.kt

@ -32,7 +32,6 @@ import reactor.core.publisher.Mono @@ -32,7 +32,6 @@ import reactor.core.publisher.Mono
* @author Sebastien Deleuze
* @since 5.0
*/
@Suppress("EXTENSION_SHADOWED_BY_MEMBER")
inline fun <reified T : Any> ServerResponse.BodyBuilder.body(publisher: Publisher<T>): Mono<ServerResponse> =
body(publisher, object : ParameterizedTypeReference<T>() {})

2
spring-webmvc/src/test/kotlin/org/springframework/web/servlet/view/script/ScriptTemplateWithBindingsExtensions.kt

@ -1,6 +1,6 @@ @@ -1,6 +1,6 @@
@file:Suppress("UNCHECKED_CAST")
package org.springframework.web.reactive.result.view.script
package org.springframework.web.servlet.view.script
import kotlin.script.templates.standard.ScriptTemplateWithBindings

2
spring-webmvc/src/test/resources/org/springframework/web/servlet/view/script/kotlin/template.kts

@ -1,4 +1,4 @@ @@ -1,4 +1,4 @@
import org.springframework.web.reactive.result.view.script.*
import org.springframework.web.servlet.view.script.*
"""${include("header") }
<p>${i18n("hello")} $foo</p>

Loading…
Cancel
Save