spring-framework / org.springframework.web.client / getForEntity

getForEntity

inline fun <reified T> RestOperations.getForEntity(url: URI): ResponseEntity<T>
inline fun <reified T> RestOperations.getForEntity(url: String, uriVariables: Map<String, *>): ResponseEntity<T>

Extension for RestOperations.getForEntity providing a getForEntity<Foo>(...) variant leveraging Kotlin reified type parameters. Like the original Java method, this extension is subject to type erasure. Use exchange if you need to retain actual generic type arguments.

Author
Sebastien Deleuze

Since
5.0.2

inline fun <reified T> RestOperations.getForEntity(url: String, vararg uriVariables: Any): ResponseEntity<T>

Extension for RestOperations.getForEntity providing a getForEntity<Foo>(...) variant leveraging Kotlin reified type parameters. Like the original Java method, this extension is subject to type erasure. Use exchange if you need to retain actual generic type arguments.

Author
Jon Schneider

Author
Sebastien Deleuze

Since
5.0