Example usage for org.springframework.http RequestEntity RequestEntity

List of usage examples for org.springframework.http RequestEntity RequestEntity

Introduction

In this page you can find the example usage for org.springframework.http RequestEntity RequestEntity.

Prototype

public RequestEntity(@Nullable T body, @Nullable MultiValueMap<String, String> headers,
        @Nullable HttpMethod method, URI url, @Nullable Type type) 

Source Link

Document

Constructor with method, URL, headers, body and type.

Usage

From source file:org.springframework.boot.test.web.client.TestRestTemplate.java

@SuppressWarnings({ "rawtypes", "unchecked" })
private RequestEntity<?> createRequestEntityWithRootAppliedUri(RequestEntity<?> requestEntity) {
    return new RequestEntity(requestEntity.getBody(), requestEntity.getHeaders(), requestEntity.getMethod(),
            applyRootUriIfNecessary(requestEntity.getUrl()), requestEntity.getType());
}