This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-io.git
commit 97af8921a062b85f7d1559b7d3b897906f7b426f Author: Gary Gregory <[email protected]> AuthorDate: Thu Jan 23 09:58:24 2025 -0500 Consistent formatting of code in examples --- src/site/xdoc/description.xml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/site/xdoc/description.xml b/src/site/xdoc/description.xml index 6e8b972ba..314957f84 100644 --- a/src/site/xdoc/description.xml +++ b/src/site/xdoc/description.xml @@ -51,13 +51,13 @@ limitations under the License. </p> <source> - InputStream in = new URL( "https://commons.apache.org" ).openStream(); + InputStream in = new URL("https://commons.apache.org").openStream(); try { - InputStreamReader inR = new InputStreamReader( in ); - BufferedReader buf = new BufferedReader( inR ); + InputStreamReader inR = new InputStreamReader(in); + BufferedReader buf = new BufferedReader(inR); String line; - while ( ( line = buf.readLine() ) != null ) { - System.out.println( line ); + while ((line = buf.readLine()) != null) { + System.out.println(line); } } finally { in.close(); @@ -66,9 +66,9 @@ limitations under the License. With the IOUtils class, that could be done with: </p> <source> - InputStream in = new URL( "https://commons.apache.org" ).openStream(); + InputStream in = new URL("https://commons.apache.org").openStream(); try { - System.out.println( IOUtils.toString( in ) ); + System.out.println(IOUtils.toString(in)); } finally { IOUtils.closeQuietly(in); }</source>
