package fr.emse.gitlab.saref.utils;

import org.apache.jena.query.Dataset;
import org.semanticweb.owlapi.annotations.HasPriority;
import org.semanticweb.owlapi.io.OWLParser;
import org.semanticweb.owlapi.io.OWLParserFactoryImpl;

@HasPriority(100)
public class JenaModelOntologyParserFactory extends OWLParserFactoryImpl {

	private final Dataset dataset;

    /**
     * Default constructor.
     */
    public JenaModelOntologyParserFactory(Dataset dataset) {
        super(new JenaModelDocumentFormatFactory());
		this.dataset = dataset;		
    }

    @Override
    public OWLParser createParser() {
        return new JenaModelOntologyParser(dataset);
    }
}
