Search in sources :

Example 6 with RDFFormat

use of org.apache.jena.riot.RDFFormat in project jena by apache.

the class ModLangOutput method printRegistered.

private static void printRegistered(PrintStream out) {
    out.println("Streaming languages:");
    Set<Lang> seen = new HashSet<>();
    for (RDFFormat fmt : StreamRDFWriter.registered()) {
        Lang lang = fmt.getLang();
        if (hiddenLanguages.contains(lang))
            continue;
        if (seen.contains(lang))
            continue;
        seen.add(lang);
        out.println("   " + lang.getLabel());
    }
    System.err.println("Non-streaming languages:");
    for (RDFFormat fmt : RDFWriterRegistry.registered()) {
        Lang lang = fmt.getLang();
        if (hiddenLanguages.contains(lang))
            continue;
        if (seen.contains(lang))
            continue;
        seen.add(lang);
        out.println("   " + lang.getLabel());
    }
}
Also used : Lang(org.apache.jena.riot.Lang) HashSet(java.util.HashSet) RDFFormat(org.apache.jena.riot.RDFFormat)

Aggregations

RDFFormat (org.apache.jena.riot.RDFFormat)6 OutputStream (java.io.OutputStream)3 ContentProducer (org.apache.http.entity.ContentProducer)3 EntityTemplate (org.apache.http.entity.EntityTemplate)3 ContentType (org.apache.jena.atlas.web.ContentType)2 HashSet (java.util.HashSet)1 CmdException (jena.cmd.CmdException)1 JsonString (org.apache.jena.atlas.json.JsonString)1 BaseTest (org.apache.jena.atlas.junit.BaseTest)1 Model (org.apache.jena.rdf.model.Model)1 Lang (org.apache.jena.riot.Lang)1 DatasetGraph (org.apache.jena.sparql.core.DatasetGraph)1 Test (org.junit.Test)1