mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-08-17 20:11:57 +02:00
[java/en] typo (#2763)
This commit is contained in:
@@ -454,7 +454,7 @@ public class LearnJava {
|
|||||||
// simplifies try-catch-finally statements by closing resources
|
// simplifies try-catch-finally statements by closing resources
|
||||||
// automatically.
|
// automatically.
|
||||||
|
|
||||||
// In order to use a try-with-resources, include a an instance of a class
|
// In order to use a try-with-resources, include an instance of a class
|
||||||
// in the try statement. The class must implement java.lang.AutoCloseable.
|
// in the try statement. The class must implement java.lang.AutoCloseable.
|
||||||
try(BufferedReader br = new BufferedReader(new FileReader("foo.txt"))) {
|
try(BufferedReader br = new BufferedReader(new FileReader("foo.txt"))) {
|
||||||
// You can attempt to do something that could throw an exception.
|
// You can attempt to do something that could throw an exception.
|
||||||
|
Reference in New Issue
Block a user