1 package org.newdawn.slick.util; 2 3 import java.io.InputStream; 4 import java.net.URL; 5 6 /** 7 * A location from which resources can be loaded 8 * 9 * @author kevin 10 */ 11 interface ResourceLocation { 12 13 /** 14 * Get a resource as an input stream 15 * 16 * @param ref The reference to the resource to retrieve 17 * @return A stream from which the resource can be read or 18 * null if the resource can't be found in this location 19 */ 20 public InputStream getResourceAsStream(String ref); 21 22 /** 23 * Get a resource as a URL 24 * 25 * @param ref The reference to the resource to retrieve 26 * @return A URL from which the resource can be read 27 */ 28 public URL getResource(String ref); 29 }