Reputation: 409
I am not very experienced in Java and JRuby but need to parse RDF data using Sesame's RDFXMLParser in JRuby and my python-minded brain just does not want to get into it. I have problems translating the Java example into JRuby. At first I don't know how to define the RDFHandler in a way it would make sense. I also don't get why the parse methods needs a Reader and an URI as I only want to parse local file.
I would highly appreciate example code in JRuby. Many thanks!
Upvotes: 3
Views: 145
Reputation: 22053
I can't help you with the JRuby-specific part of your question, but as for your confusion over how to invoke the parse()
method: if you only want to parse a local file, you would normally do that by simply creating a java.io.FileInputstream
object for your file and providing that to the parser.
Upvotes: 1