Get a resource from the GATE resources directory as an InputStream. The resource name should be relative to resourcePath which is equal with gate/resources ; e.g. for a resource stored as gate/resources/jape/Test11.jape , this method should be passed the name jape/Te
(String resourceName)
| 373 | * this method should be passed the name <TT>jape/Test11.jape</TT>. |
| 374 | */ |
| 375 | public static InputStream getGateResourceAsStream(String resourceName) |
| 376 | throws IOException { |
| 377 | |
| 378 | if(resourceName.startsWith("/") || resourceName.startsWith("\\") ) |
| 379 | return getResourceAsStream(resourcePath + resourceName); |
| 380 | else return getResourceAsStream(resourcePath + "/" + resourceName); |
| 381 | } // getResourceAsStream(String) |
| 382 | |
| 383 | /** |
| 384 | * Get a resource from the GATE ClassLoader. The return value is a |