[Effective Java] Item 9. try-finally보다는 try-with-resource


[Effective Java] Item 9. try-finally보다는 try-with-resource

try-finally static String firstLineOfFile(String path) throws IOException { BufferedReader br = new BufferedReader(new FileReader(path)); try { return br.readLine(); } finally { br.close(); } } 예외..

[Effective Java] Item 9. try-finally보다는 try-with-resource에 대한 요약내용입니다.

자세한 내용은 아래에 원문링크를 확인해주시기 바랍니다.


원문링크 : [Effective Java] Item 9. try-finally보다는 try-with-resource