public void loadFromResource ( String resource , Candidate . CandidateType type ) throws IOException { InputStream candidatesConfig = classloader . getResourceAsStream ( resource ) ; if ( candidatesConfig == null ) { throw new IOException ( "Resource '" + resource + "' not found" ) ; } try { loadFrom ( candidatesConfig , type ) ; } finally { candidatesConfig . close ( ) ; } }
Load a candidate property file