I am using Jena, the Java library, in order to parse my RDFS ontology as such:
model = ModelFactory.createOntologyModel(OntModelSpec.RDFS_MEM);
model.read(new FileInputStream(ontologyPath), "");
I then add some statements and save like this:
s = model.createStatement(resource, hasName, user.getName());
model.add(s);
m.write(System.out, "RDF/XML");
The statement is then, obviously, written in the ontology file.
My question is: should it be so? Is it common practice for the ontology and triples to stay in the same file or should they be separate? Also, if they should be separate, how do I do this with Jena?