Class ConfigFileLoader


public class ConfigFileLoader extends Object
This class is used to obtain InputStreams for configuration files from a given location String. This allows greater flexibility than these files having to be loaded directly from a file system.
  • Method Details

    • getInputStream

      public static InputStream getInputStream(String location) throws IOException
      Load the resource from the specified location.
      location - The location for the resource of interest. The location may be a URL or a file path. Relative paths will be resolved against CATALINA_BASE.
      The InputStream for the given resource. The caller is responsible for closing this stream when it is no longer used.
      IOException - If an InputStream cannot be created using the provided location
    • getURI

      public static URI getURI(String location)