Hi All,

I am simply trying to generate the source from a class at runtime using
below code:
              
                 URL url = new URL("http://xxxx/xxx.xsd";);
                
                
                
                SourceGenerator srcGen = new SourceGenerator();
                srcGen.generateSource(new InputSource(url.openStream()), 
"test");

But I am getting a null pointer exception.. I am pretty new to Castor and I
am looking for help. Please.



Error:
java.lang.NullPointerException
        at java.util.Hashtable.put(Unknown Source)
        at
org.exolab.castor.builder.BuilderConfiguration.setLocationPackageMapping(BuilderConfiguration.java:618)
        at
org.exolab.castor.builder.SourceGenerator.generateSource(SourceGenerator.java:702)
        at
org.exolab.castor.builder.SourceGenerator.generateSource(SourceGenerator.java:651)

XSD (xxx is internal address):

<?xml version="1.0" encoding="UTF-8"?>

  
  
  
  
    
      
    
    
  
  
    
      
    
    
  
  
    
      
    
    
    
  
  
    
      
    
    
  
  
    
      
    
    
    
  
  
    
      
    
    
  
  
    
      
    
    
  
  
    
      
    
    
  
  
    
      
    
    
  
  
    
      
    
    
    
  
  
    
    
  
  
    
    
  
  
    
    
  
  
  
  
  
  
  
  
  
  
  
  
  
  





-- 
View this message in context: 
http://www.nabble.com/Error-while-generating-source-tp20425041p20425041.html
Sent from the Castor - User mailing list archive at Nabble.com.

Reply via email to