Code example for BufferedReader

Methods: close

0
			throw new StlParseException("Passed file does not exist."); 
 
		if (!file.isFile())
			throw new StlParseException("This is not a file."); 
 
		final BufferedReader buffer = new BufferedReader(new FileReader(file));
		boolean isASCII = isASCII(buffer);
		buffer.close();
 
		return isASCII;
	} 
 
	/** 
	 * Determine if a given resource appears to be in ASCII format. 
	 *  
	 * @param res 
	 * @param resId 
	 * @return 
	 * @throws IOException 
	 */ 
	public static final boolean isASCII(Resources res, int resId) throws IOException, NotFoundException {