Browse Source

Consistent IOException spelling in class/method names

pull/36513/head
Juergen Hoeller 3 days ago
parent
commit
3a35c4dbd0
  1. 2
      framework-docs/src/main/java/org/springframework/docs/web/webmvc/mvccontroller/mvcannexceptionhandlerexc/ExceptionController.java
  2. 2
      framework-docs/src/main/kotlin/org/springframework/docs/web/webmvc/mvccontroller/mvcannexceptionhandlerexc/ExceptionController.kt
  3. 2
      spring-web/src/test/java/org/springframework/web/client/RestTemplateObservationTests.java
  4. 4
      spring-webmvc/src/test/java/org/springframework/web/servlet/mvc/method/annotation/ExceptionHandlerExceptionResolverTests.java
  5. 2
      spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/session/SockJsSessionTests.java

2
framework-docs/src/main/java/org/springframework/docs/web/webmvc/mvccontroller/mvcannexceptionhandlerexc/ExceptionController.java

@ -29,7 +29,7 @@ public class ExceptionController { @@ -29,7 +29,7 @@ public class ExceptionController {
// tag::narrow[]
@ExceptionHandler({FileSystemException.class, RemoteException.class})
public ResponseEntity<String> handleIoException(IOException ex) {
public ResponseEntity<String> handleIOException(IOException ex) {
return ResponseEntity.internalServerError().body(ex.getMessage());
}
// end::narrow[]

2
framework-docs/src/main/kotlin/org/springframework/docs/web/webmvc/mvccontroller/mvcannexceptionhandlerexc/ExceptionController.kt

@ -27,7 +27,7 @@ class ExceptionController { @@ -27,7 +27,7 @@ class ExceptionController {
// tag::narrow[]
@ExceptionHandler(FileSystemException::class, RemoteException::class)
fun handleIoException(ex: IOException): ResponseEntity<String> {
fun handleIOException(ex: IOException): ResponseEntity<String> {
return ResponseEntity.internalServerError().body(ex.message)
}
// end::narrow[]

2
spring-web/src/test/java/org/springframework/web/client/RestTemplateObservationTests.java

@ -149,7 +149,7 @@ class RestTemplateObservationTests { @@ -149,7 +149,7 @@ class RestTemplateObservationTests {
}
@Test
void executeWithIoExceptionAddsUnknownOutcome() throws Exception {
void executeWithIOExceptionAddsUnknownOutcome() throws Exception {
String url = "https://example.org/resource";
mockSentRequest(GET, url);
given(request.execute()).willThrow(new IOException("Socket failure"));

4
spring-webmvc/src/test/java/org/springframework/web/servlet/mvc/method/annotation/ExceptionHandlerExceptionResolverTests.java

@ -172,7 +172,7 @@ class ExceptionHandlerExceptionResolverTests { @@ -172,7 +172,7 @@ class ExceptionHandlerExceptionResolverTests {
@Test
void resolveNoExceptionHandlerForException() throws NoSuchMethodException {
Exception npe = new NullPointerException();
HandlerMethod handlerMethod = new HandlerMethod(new IoExceptionController(), "handle");
HandlerMethod handlerMethod = new HandlerMethod(new IOExceptionController(), "handle");
this.resolver.afterPropertiesSet();
ModelAndView mav = this.resolver.resolveException(this.request, this.response, handlerMethod, npe);
@ -540,7 +540,7 @@ class ExceptionHandlerExceptionResolverTests { @@ -540,7 +540,7 @@ class ExceptionHandlerExceptionResolverTests {
@Controller
static class IoExceptionController {
static class IOExceptionController {
public void handle() {}

2
spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/session/SockJsSessionTests.java

@ -240,7 +240,7 @@ class SockJsSessionTests extends AbstractSockJsSessionTests<TestSockJsSession> { @@ -240,7 +240,7 @@ class SockJsSessionTests extends AbstractSockJsSessionTests<TestSockJsSession> {
}
@Test
void writeFrameIoException() throws Exception {
void writeFrameIOException() throws Exception {
this.session.setExceptionOnWrite(new IOException());
this.session.delegateConnectionEstablished();

Loading…
Cancel
Save