title: java.net.MalformedURLException: no protocol
body: <p>I' m writing a class to run xjc in java. my code goes as follows:</p>
  
  <pre><code> URL url = new URL("C:\\Users\\Simran\\Desktop\\books.xsd"); 
   SchemaCompiler sc = XJC.createSchemaCompiler();
   sc.parseSchema(new InputSource(url.toExternalForm()));
   S2JJAXBModel model = sc.bind();
   JCodeModel cm = model.generateCode(null, null);
   cm.build(new FileCodeWriter(new File("C:\\Users\\Simran\\Desktop\\books.xsd")));
  </code></pre>
  
  <p>however I get the following error when I run this:</p>
  
  <pre><code>Exception in thread "main" java.net.MalformedURLException: no protocol: books.xsd
      at java.net.URL.&lt;init&gt;(Unknown Source)
      at java.net.URL.&lt;init&gt;(Unknown Source)
      at java.net.URL.&lt;init&gt;(Unknown Source)
      at jaxbTest.Test1.main(Test1.java:22)
  </code></pre>
  
  <p>Can anyone help with this please?</p>