------ Apache Any23 - Supported Formats ------ The Apache Software Foundation ------ 2011-2012 ~~ Licensed to the Apache Software Foundation (ASF) under one or more ~~ contributor license agreements. See the NOTICE file distributed with ~~ this work for additional information regarding copyright ownership. ~~ The ASF licenses this file to You under the Apache License, Version 2.0 ~~ (the "License"); you may not use this file except in compliance with ~~ the License. You may obtain a copy of the License at ~~ ~~ http://www.apache.org/licenses/LICENSE-2.0 ~~ ~~ Unless required by applicable law or agreed to in writing, software ~~ distributed under the License is distributed on an "AS IS" BASIS, ~~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ~~ See the License for the specific language governing permissions and ~~ limitations under the License. Supported Formats in Apache Any23 <> supports all the main standard formats introduced by the <> community. * <> The following list shows the accepted input formats and for each one the support level. * <<(X)HTML>> with <>, <>, <> and <>. <> fully supports the {{{http://www.w3.org/TR/html5/}(X)HTML5}} input format and in particular provides a set of extractors for processing embedded {{{http://www.w3.org/TR/rdfa-syntax/}RDFa 1.0}}, {{{http://www.w3.org/TR/rdfa-core/}RDFa 1.1}}, {{{http://microformats.org/}Microformats}} and {{{http://www.w3.org/TR/microdata/}Microdata}}. * <> <> fully supports the {{{http://www.w3.org/TeamSubmission/turtle/}Turtle}} specification. * <> <> fully supports the {{{http://www.w3.org/TR/rdf-testcases/#ntriples}N-Triples}} specification. * <> <> fully supports the {{{http://sw.apache.org/2008/07/n-quads/}N-Quads}} specification. * <> <> fully supports the {{{http://www.w3.org/TR/rdf-syntax-grammar/}RDF/XML}} specification. * <> <> allows you to represent header-provided {{{http://www.ietf.org/rfc/rfc4180.txt}CSV}} files with RDF using a specific {{{./dev-csv-extractor.html}algorithm}}. * <> The supported output formats are enlisted below. * <> <> is able to produce output in {{{http://www.w3.org/TeamSubmission/turtle/}Turtle}}. * <> <> is able to produce output in {{{http://www.w3.org/TR/rdf-testcases/#ntriples}N-Triples}}. * <> <> is able to produce output in {{{http://sw.apache.org/2008/07/n-quads/}N-Quads}}. * <> <> is able to produce output in {{{http://www.w3.org/TR/rdf-syntax-grammar/}RDF/XML}}. * <> <> is able to produce output in {{{http://www.json.org/}JSON}} . See the specific {{{json-statements}format}}. * <> <> is able to produce a detailed report of the latest document extraction if required. See further details {{{./service.html#report-format}here}}. * JSON Statements Format {json-statements} Apache Any23 is able to produce JSON output following the format described below. Given the following example statements (expressed in N-Quads format): +------------------------------------------------------------------------------- _:bn1 . "language literal"@en . "123"^^ . +------------------------------------------------------------------------------- these will be represented as: +------------------------------------------------------------------------------- { "quads" : [ [ { "type" : "bnode", "value" : "bn1" }, "http://pred/1", { "type" : "uri", "value" : "http://value/1" }, "http://graph/1" ], [ { "type" : "uri", "value" : "http://sub/2" }, "http://pred/2", { "type" : "literal", "value" : "language literal", "lang" : "en", "datatype" : null }, "http://graph/2" ], [ { "type" : "uri", "value" : "http://sub/3" }, "http://pred/3", { "type" : "literal", "value" : "123", "lang" : null, "datatype" : "http://datatype" }, "http://graph/3" ] ] } +------------------------------------------------------------------------------- The <> structure is described by the following <> rules, where quotes are omitted to improve readability: +------------------------------------------------------------------------------- ::= { "quads" : } ::= [ + ] ::= [ , , , ] ::= { "type" : , "value" : } ::= ::= { "type" : , "value" : , "lang" : , "datatype" : } ::= | null ::= "uri" | "bnode" ::= "uri" | "bnode"| "literal" ::= String ::= String | null ::= | null ::= String +-------------------------------------------------------------------------------