Implement java.io.Closeable where appropriate
Issue: SPR-9962
This commit is contained in:
parent
d6e1a4a26a
commit
ea95da126a
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -16,6 +16,8 @@
|
|||
|
||||
package org.springframework.context;
|
||||
|
||||
import java.io.Closeable;
|
||||
|
||||
import org.springframework.beans.BeansException;
|
||||
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
||||
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
|
||||
|
@ -36,7 +38,7 @@ import org.springframework.core.env.Environment;
|
|||
* @author Chris Beams
|
||||
* @since 03.11.2003
|
||||
*/
|
||||
public interface ConfigurableApplicationContext extends ApplicationContext, Lifecycle {
|
||||
public interface ConfigurableApplicationContext extends ApplicationContext, Lifecycle, Closeable {
|
||||
|
||||
/**
|
||||
* Any number of these characters are considered delimiters between
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -16,6 +16,7 @@
|
|||
|
||||
package org.springframework.jdbc.support.lob;
|
||||
|
||||
import java.io.Closeable;
|
||||
import java.io.InputStream;
|
||||
import java.io.Reader;
|
||||
import java.sql.PreparedStatement;
|
||||
|
@ -56,7 +57,7 @@ import java.sql.SQLException;
|
|||
* @see java.sql.PreparedStatement#setAsciiStream
|
||||
* @see java.sql.PreparedStatement#setCharacterStream
|
||||
*/
|
||||
public interface LobCreator {
|
||||
public interface LobCreator extends Closeable {
|
||||
|
||||
/**
|
||||
* Set the given content as bytes on the given statement, using the given
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
package org.springframework.http.client;
|
||||
|
||||
import java.io.Closeable;
|
||||
import java.io.IOException;
|
||||
|
||||
import org.springframework.http.HttpInputMessage;
|
||||
|
@ -30,7 +31,7 @@ import org.springframework.http.HttpStatus;
|
|||
* @author Arjen Poutsma
|
||||
* @since 3.0
|
||||
*/
|
||||
public interface ClientHttpResponse extends HttpInputMessage {
|
||||
public interface ClientHttpResponse extends HttpInputMessage, Closeable {
|
||||
|
||||
/**
|
||||
* Return the HTTP status code of the response.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2009 the original author or authors.
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -16,6 +16,8 @@
|
|||
|
||||
package org.springframework.http.server;
|
||||
|
||||
import java.io.Closeable;
|
||||
|
||||
import org.springframework.http.HttpOutputMessage;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
||||
|
@ -25,7 +27,7 @@ import org.springframework.http.HttpStatus;
|
|||
* @author Arjen Poutsma
|
||||
* @since 3.0
|
||||
*/
|
||||
public interface ServerHttpResponse extends HttpOutputMessage {
|
||||
public interface ServerHttpResponse extends HttpOutputMessage, Closeable {
|
||||
|
||||
/**
|
||||
* Set the HTTP status code of the response.
|
||||
|
|
Loading…
Reference in New Issue