[Biojava-l] pdb parser example

Matthew Pocock matthew_pocock@yahoo.co.uk
Mon, 04 Mar 2002 17:38:28 +0000


OK - using a fully quailfied FILE url worked. Also, I got rid of the 
capabilities message by ading sax/ to the capability names in 
Pdb2XMLConverter lines 97/98

	    oParser.setFeature("http://xml.org/sax/features/namespaces",true);
	    oParser.setFeature("http://xml.org/sax/features/namespace-prefixes",
			       true);


Thanks,

Matthew

Simon Brocklehurst wrote:
> 
> Matthew Pocock wrote:
> 
> 
>>Hi.
>>
>>I've tried to run the PDB parser example, but hit a snag.
>>
>>C:\stuff\biojava\biojava-live\demos>java eventbasedparsing.Pdb2XML
>>files\pdb\hgh_ori.pdb
>>WARNING: ignoring attempt to set illegal combination of parser features
>><?xml version="1.0"?>
>>no protocol: files\pdb\hgh_ori.pdb
>>Couldn't open file
>>
>>Am I being stupid (typing something wrong, incorrect xml parser,
>>generaly fooling around) or is it broken?
>>
> 
> I don't think it's broken [ce n'est pas possible ;-)] - I think this is due
> to the modifications put in by to make the SAX drivers compatible with XSLT
> out of the box which removed the ability to resolve simple file paths.
> 
> In other words, you can't specify pathnames as a simple string. Rather, you
> need to specify the path to the file as some kind of URI/URL just as you
> would in a web browser e.g. file://files/pdb/hgh_ori.pdb
> 
> At least I think this is likely to be the problem... let me know...
> 
> S.
> --
> Simon M. Brocklehurst, Ph.D.
> Head of Bioinformatics & Advanced IS
> Cambridge Antibody Technology
> The Science Park, Melbourn, Cambridgeshire, UK
> http://www.CambridgeAntibody.com/
> mailto:simon.brocklehurst@CambridgeAntibody.com
> 
> 
>