Here you can find the source of getInputStreamReaderAsResource(Class> clazz, String fileName)
public static InputStreamReader getInputStreamReaderAsResource(Class<?> clazz, String fileName)
//package com.java2s; //License from project: Open Source License import java.io.InputStream; import java.io.InputStreamReader; public class Main { public static InputStreamReader getInputStreamReaderAsResource(Class<?> clazz, String fileName) { return new InputStreamReader(getInputStreamAsResource(clazz, fileName)); }//from w w w . jav a2 s . co m public static InputStream getInputStreamAsResource(Class<?> clazz, String fileName) { InputStream stream = clazz.getResourceAsStream(fileName); return stream; } }