RDFa in LinkSmart

Revision for “RDFa in LinkSmart” created on November 5, 2014 @ 15:48:37

RDFa in LinkSmart
<h2>Usage of RDFa attributes</h2> The <a title="Glossary &amp; References" href="http://www.iotworldservices.com/wiki/iotworldserviceswiki/glossary-references/" data-cke-saved-href="default.asp?W91">IoTEntity </a>and <a title="Events – Content Model" href="http://www.iotworldservices.com/wiki/iotworldserviceswiki/events-content-model/" data-cke-saved-href="default.asp?W89">Event </a>models apply the simple but powerful W3C Recommendation <a href="http://www.w3.org/TR/2013/REC-rdfa-core-20130822/" data-cke-saved-href="http://www.w3.org/TR/2013/REC-rdfa-core-20130822/"><strong>RDFa</strong> </a>approach to semantic annotation of data carried in Events and RESTful APIs. As is stated in <a href="http://www.w3.org/TR/rdfa-primer/" data-cke-saved-href="http://www.w3.org/TR/rdfa-primer/">http://www.w3.org/TR/rdfa-primer/</a> "<em>It is worth emphasizing that RDFa uses URLs to identify just about everything... The reason behind this design decision is rooted in data portability, consistency, and information sharing. Using URLs removes the possibility for ambiguities in terminology</em>". RDFa is a way of expressing RDF-style relationships using simple attributes in existing markup languages. A subset of RDFa attributes has been adopted by the IoTEntity and Event models: <ul> <li>@about - used for stating what the data is about (a 'subject' in RDF terminology). It is used for recording identifiers for Event, IoTEntity and IoTProperty resources (see also section on Evaluation Context below).</li> <li>@datatype - to express the datatype of a literal</li> <li>@property - a white space separated list of property references, used for expressing relationships between a subject and either a resource object if given or some literal text (also a 'predicate');</li> <li>@typeof - a white space separated list of type references that indicate the RDF type(s) to associate with a subject;</li> <li>@prefix - a white space separated list of prefix-name IRI pairs of the form "ab:http://tempuri.org</li> </ul> XML Schema datatypes for these attributes have been defines in the RDFaTypeDefinitions.xsd schema file, imported by the <a title="LinkSmart XML Schema" href="http://www.iotworldservices.com/wiki/iotworldserviceswiki/linksmart-xml-schema/" data-cke-saved-href="default.asp?W90">IoTEntity schema</a>. See the <a href="http://www.w3.org/TR/2013/REC-rdfa-core-20130822/" data-cke-saved-href="http://www.w3.org/TR/2013/REC-rdfa-core-20130822/">RDFa Recommendation</a> for full details on usage of these attributes. <h3>CURIEs</h3> The key addressing component of RDF is the IRI (the internationalized resource identifier, IRI, is a generalization of the URI), but these are usually long and unwieldy. RDFa therefore supports a mechanism by which IRIs can be abbreviated, called 'compact URI expressions' or simply, CURIEs. It is <strong>RECOMMENDED </strong>to use CURIEs in IoTEntity and Event document instances. For example, a type definition using the @datatype attribute with the value "xs:int" includes a prefix "xs" followed by a reference "int" and separated by a colon ":". The prefix <strong>MUST </strong>have been earlier defined using a @prefix attribute at an appropriate level. With a prefix definition such as "xs:http://www.w3.org/2001/XMLSchema", the "int" reference points to the "int" datatype as defined in the XML Schema W3C Recommendation. Note the possible usage of multiple CURIE values to assert multiple type classifications according to RDFa. For further information about CURIE syntax, see <a href="http://www.w3.org/TR/rdfa-syntax/#s_curies" data-cke-saved-href="http://www.w3.org/TR/rdfa-syntax/#s_curies">Section 6 of the RDFa Recommendation</a>. CURIE processing is described in <a href="http://www.w3.org/TR/rdfa-syntax/#s_curieprocessing" data-cke-saved-href="http://www.w3.org/TR/rdfa-syntax/#s_curieprocessing">Section 7.4 of the RDFa Recommendation</a>. <h2>Evaluation Context - xml:base and about attributes</h2> The initial evaluation context for relative URIs in the document being processed is usually given by the URI of the document itself, but it can also be explicitly set by using the @xml:base attribute on the Event, IoTEntity or IoTProperty elements (when it appear at the root level). For example, an IoTEntity identifier provided in the @about attribute is relative to the initial evaluation context, and the id of the IoTProperty is relative to the IoTEntity. See <a href="http://www.w3.org/TR/rdfa-syntax/#evaluation-context" data-cke-saved-href="http://www.w3.org/TR/rdfa-syntax/#evaluation-context">Section 7.2 of the RDFa Recommendation</a> for further details.

OldNewDate CreatedAuthorActions
November 5, 2014 @ 15:48:37 Vivian Esquivias