From 77ac9a9cd697d6245678a3165d389af85495106b Mon Sep 17 00:00:00 2001 From: pengbingting Date: Tue, 18 Dec 2018 15:31:12 +0800 Subject: [PATCH] code format --- .../rest/SentinelClientHttpResponse.java | 62 +++++++++---------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/spring-cloud-alibaba-sentinel/src/main/java/org/springframework/cloud/alibaba/sentinel/rest/SentinelClientHttpResponse.java b/spring-cloud-alibaba-sentinel/src/main/java/org/springframework/cloud/alibaba/sentinel/rest/SentinelClientHttpResponse.java index 03facf28..0d4d42c7 100644 --- a/spring-cloud-alibaba-sentinel/src/main/java/org/springframework/cloud/alibaba/sentinel/rest/SentinelClientHttpResponse.java +++ b/spring-cloud-alibaba-sentinel/src/main/java/org/springframework/cloud/alibaba/sentinel/rest/SentinelClientHttpResponse.java @@ -38,42 +38,42 @@ import java.util.Map; */ public class SentinelClientHttpResponse extends AbstractClientHttpResponse { - private String blockResponse = "RestTemplate request block by sentinel"; + private String blockResponse = "RestTemplate request block by sentinel"; - public SentinelClientHttpResponse() { - } + public SentinelClientHttpResponse() { + } - public SentinelClientHttpResponse(String blockResponse) { - this.blockResponse = blockResponse; - } + public SentinelClientHttpResponse(String blockResponse) { + this.blockResponse = blockResponse; + } - @Override - public int getRawStatusCode() throws IOException { - return HttpStatus.OK.value(); - } + @Override + public int getRawStatusCode() throws IOException { + return HttpStatus.OK.value(); + } - @Override - public String getStatusText() throws IOException { - return blockResponse; - } + @Override + public String getStatusText() throws IOException { + return blockResponse; + } - @Override - public void close() { - // nothing do - } + @Override + public void close() { + // nothing do + } - @Override - public InputStream getBody() throws IOException { - return new ByteArrayInputStream(blockResponse.getBytes()); - } + @Override + public InputStream getBody() throws IOException { + return new ByteArrayInputStream(blockResponse.getBytes()); + } - @Override - public HttpHeaders getHeaders() { - Map> headers = new HashMap<>(); - headers.put(HttpHeaders.CONTENT_TYPE, - Arrays.asList(MediaType.APPLICATION_JSON_UTF8_VALUE)); - HttpHeaders httpHeaders = new HttpHeaders(); - httpHeaders.putAll(headers); - return httpHeaders; - } + @Override + public HttpHeaders getHeaders() { + Map> headers = new HashMap<>(); + headers.put(HttpHeaders.CONTENT_TYPE, + Arrays.asList(MediaType.APPLICATION_JSON_UTF8_VALUE)); + HttpHeaders httpHeaders = new HttpHeaders(); + httpHeaders.putAll(headers); + return httpHeaders; + } }