java.net.MalformedURLException: pas de protocole

Je m' écrire une classe pour exécuter xjc en java. mon code va comme suit:

 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")));

cependant j'obtiens l'erreur suivante lorsque je l'exécute:

Exception in thread "main" java.net.MalformedURLException: no protocol: books.xsd
    at java.net.URL.<init>(Unknown Source)
    at java.net.URL.<init>(Unknown Source)
    at java.net.URL.<init>(Unknown Source)
    at jaxbTest.Test1.main(Test1.java:22)

N'importe qui peut aider avec ce s'il vous plaît?

Avez-vous essayé sc.parseSchema(new InputSource("C:\\Users\\Simran\\Desktop\\books.xsd")); Comme je l'ai suggéré, avant ?
ya j'avais essayé cette & ça n'a pas fonctionné

OriginalL'auteur simran | 2010-12-29