@@ -335,7 +335,7 @@ public static Collection<File> listFiles(
335335 * @see org.apache.commons.io.filefilter.NameFileFilter
336336 * @since Commons IO 1.2
337337 */
338- public static Iterator iterateFiles (
338+ public static Iterator < File > iterateFiles (
339339 File directory , IOFileFilter fileFilter , IOFileFilter dirFilter ) {
340340 return listFiles (directory , fileFilter , dirFilter ).iterator ();
341341 }
@@ -367,7 +367,7 @@ private static String[] toSuffixes(String[] extensions) {
367367 * @param recursive if true all subdirectories are searched as well
368368 * @return an collection of java.io.File with the matching files
369369 */
370- public static Collection listFiles (
370+ public static Collection < File > listFiles (
371371 File directory , String [] extensions , boolean recursive ) {
372372 IOFileFilter filter ;
373373 if (extensions == null ) {
@@ -392,7 +392,7 @@ public static Collection listFiles(
392392 * @return an iterator of java.io.File with the matching files
393393 * @since Commons IO 1.2
394394 */
395- public static Iterator iterateFiles (
395+ public static Iterator < File > iterateFiles (
396396 File directory , String [] extensions , boolean recursive ) {
397397 return listFiles (directory , extensions , recursive ).iterator ();
398398 }
@@ -1151,7 +1151,7 @@ public static byte[] readFileToByteArray(File file) throws IOException {
11511151 * @throws java.io.UnsupportedEncodingException if the encoding is not supported by the VM
11521152 * @since Commons IO 1.1
11531153 */
1154- public static List readLines (File file , String encoding ) throws IOException {
1154+ public static List < String > readLines (File file , String encoding ) throws IOException {
11551155 InputStream in = null ;
11561156 try {
11571157 in = openInputStream (file );
@@ -1170,7 +1170,7 @@ public static List readLines(File file, String encoding) throws IOException {
11701170 * @throws IOException in case of an I/O error
11711171 * @since Commons IO 1.3
11721172 */
1173- public static List readLines (File file ) throws IOException {
1173+ public static List < String > readLines (File file ) throws IOException {
11741174 return readLines (file , null );
11751175 }
11761176
@@ -1330,7 +1330,7 @@ public static void writeByteArrayToFile(File file, byte[] data) throws IOExcepti
13301330 * @throws java.io.UnsupportedEncodingException if the encoding is not supported by the VM
13311331 * @since Commons IO 1.1
13321332 */
1333- public static void writeLines (File file , String encoding , Collection lines ) throws IOException {
1333+ public static void writeLines (File file , String encoding , Collection <?> lines ) throws IOException {
13341334 writeLines (file , encoding , lines , null );
13351335 }
13361336
@@ -1344,7 +1344,7 @@ public static void writeLines(File file, String encoding, Collection lines) thro
13441344 * @throws IOException in case of an I/O error
13451345 * @since Commons IO 1.3
13461346 */
1347- public static void writeLines (File file , Collection lines ) throws IOException {
1347+ public static void writeLines (File file , Collection <?> lines ) throws IOException {
13481348 writeLines (file , null , lines , null );
13491349 }
13501350
@@ -1364,7 +1364,8 @@ public static void writeLines(File file, Collection lines) throws IOException {
13641364 * @throws java.io.UnsupportedEncodingException if the encoding is not supported by the VM
13651365 * @since Commons IO 1.1
13661366 */
1367- public static void writeLines (File file , String encoding , Collection lines , String lineEnding ) throws IOException {
1367+ public static void writeLines (File file , String encoding , Collection <?> lines , String lineEnding )
1368+ throws IOException {
13681369 OutputStream out = null ;
13691370 try {
13701371 out = openOutputStream (file );
@@ -1385,7 +1386,7 @@ public static void writeLines(File file, String encoding, Collection lines, Stri
13851386 * @throws IOException in case of an I/O error
13861387 * @since Commons IO 1.3
13871388 */
1388- public static void writeLines (File file , Collection lines , String lineEnding ) throws IOException {
1389+ public static void writeLines (File file , Collection <?> lines , String lineEnding ) throws IOException {
13891390 writeLines (file , null , lines , lineEnding );
13901391 }
13911392
0 commit comments