- Add the Codota plugin to your IDE and get smart completions
private void myMethod () {BufferedReader b =
InputStream in;new BufferedReader(new InputStreamReader(in))
Reader in;new BufferedReader(in)
File file;new BufferedReader(new FileReader(file))
- Smart code suggestions by Codota
}
/** * Adapts the given Enumeration as an Iterable object for use within a for each loop. * * @param <T> the class type of the Enumeration elements. * @param enumeration the Enumeration to adapt as an Iterable object. * @return an Iterable instance of the Enumeration. * @see java.lang.Iterable * @see java.util.Enumeration */ @NonNull public static <T> Iterable<T> iterable(@Nullable Enumeration<T> enumeration) { return () -> toIterator(nullSafeEnumeration(enumeration)); }
/** * Adapts the given Enumeration as an Iterable object for use within a for each loop. * * @param <T> the class type of the Enumeration elements. * @param enumeration the Enumeration to adapt as an Iterable object. * @return an Iterable instance of the Enumeration. * @see java.lang.Iterable * @see java.util.Enumeration */ @NonNull public static <T> Iterable<T> iterable(@Nullable Enumeration<T> enumeration) { return () -> toIterator(nullSafeEnumeration(enumeration)); }