I am trying to read an xsd file to validate schema.
My schema is in location x/y/z/test.xsd
My class reading this file is also in x/y/z/ReadSchema.java
Both there are packaged in my jar.
I am trying to read this file in ReadSchema.java
like below where name is test.xsd
But url is returned as null?
Anything I am doing wrong here ?
private static URL getURLForName(String name)
{
ClassLoader cl = Thread.currentThread().getContextClassLoader();
URL url = cl.getResource(name);
return url;
}