Title:

DC-TEXT: A Text Syntax for Dublin Core Metadata

Creator:
Pete Johnston
Date Issued:
2006-01-13
Identifier:
http://www.ukoln.ac.uk/metadata/dcmi/dc-text/2006-01-13/
Replaces:
Not applicable
Is Replaced By:
http://www.ukoln.ac.uk/metadata/dcmi/dc-text/2006-03-14/
Latest Version:
http://www.ukoln.ac.uk/metadata/dcmi/dc-text/
Description of Document: This document specifies a Text Syntax for representing Dublin Core metadata description sets.

Contents

  1. Introduction
  2. The DCMI Abstract Model and DC-XML
  3. The DC-TEXT Syntax
  4. Examples
  5. Notes
  6. References

1. Introduction

This document specifies a Text Syntax for representing DC metadata description sets in XML. The format is referred to as "DC-TEXT"

The DCMI Abstract Model [DCMIAM] describes the components which make up DC metadata description sets and the relationships between them. A plain text format for serialisation of such description sets is useful as a means of presenting examples in a way which highlights the constructs of the Abstract Model, and also as a means of comparing the information represented in other formats such as DC-XML, RDF/XML and XHTML/HTML.

2. The DCMI Abstract Model (Summary)

According to the DCMI Abstract Model [DCMIAM]:

3. Grammar

A DC-TEXT document is a sequence of Unicode characters encoded in UTF-8 defined by the grammar below. It is specified by means of the version of Extended BNF used in XML 1.0 (Third Edition) [XML]

DCAM Text - EBNF
[1] dcamTextDoc ::= namespaceDeclaration* ws* comment* ws* descriptionSet ws* comment* ws*
[2] namespaceDeclaration ::= '@prefix' ws+ prefixName? ':' ws+ uriref
[3] descriptionSet ::= 'DescriptionSet(' ws* comment* ws* description ws* comment* ws* ')'
[4] description ::= 'Description(' ws* comment* ws* (descriptionId ws* comment* ws*)? (resourceURI ws* comment* ws*)? (statement ws* comment* ws*)+ ')'
[5] statement ::= 'Statement(' ws* comment* ws* propertyURI ws* comment* ws* (vocabEncSchemeURI ws* comment* ws*)? (valueURI ws* comment* ws*)? (valueRepresentation ws* comment* ws*)* (descriptionReference ws* comment* ws*)? ')'
[6] valueRepresentation ::= valueString | richRepresentation
[7] valueString ::= 'ValueString(' ws* comment* ws* quotedString ws* comment* ws* (languageTag ws* comment* ws*)? (valueURI ws* comment* ws*)? (syntaxEncSchemeURI ws* comment* ws*)? ')'
[8] languageTag ::= 'Language(' ws* language ws* ')'
[9] richRepresentation ::= 'RichRepresentation(' ws* comment* ws* quotedString ws* comment* ws* ')'
[10] descriptionReference ::= 'DescriptionRef(' ws* name ws* ')'
[11] descriptionId ::= 'DescriptionId(' ws* name ws* ')'
[12] resourceURI ::= 'ResourceURI(' ws* resourceRef ws* ')'
[13] propertyURI ::= 'PropertyURI(' ws* resourceRef ws* ')'
[14] valueURI ::= 'ValueURI(' ws* resourceRef ws* ')'
[15] vocabEncSchemeURI ::= 'VocabEncSchemeURI(' ws* resourceRef ws* ')'
[16] syntaxEncSchemeURI ::= 'SyntaxEncSchemeURI(' ws* resourceRef ws* ')'
[17] resourceRef ::= uriref | qname

The following productions are borrowed from Turtle [TURTLE]:

DCAM Text - EBNF - continued
[18] comment ::= '#' ( [^#xA#xD] )*
[19] ws ::= #x9 | #xA | #xD | #x20
[20] qname ::= prefixName? ':' name?
[21] uriref ::= '<' relativeURI '>'
[22] language ::= [a-z]+ ('-' [a-z0-9]+ )*
[23] nameStartChar ::= [A-Z] | "_" | [a-z] | [#x00C0-#x00D6] | [#x00D8-#x00F6] | [#x00F8-#x02FF] | [#x0370-#x037D] | [#x037F-#x1FFF] | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF]
[24] nameChar ::= nameStartChar | '-' | [0-9] | #x00B7 | [#x0300-#x036F] | [#x203F-#x2040]
[25] name ::= nameStartChar nameChar*
[26] prefixName ::= ( nameStartChar - '_' ) nameChar*
[27] relativeURI ::= ucharacter*
[28] quotedString ::= string | longString
[29] string ::= #x22 scharacter* #x22
[30] longString ::= #x22 #x22 #x22 lcharacter* #x22 #x22 #x22
[31] character ::= '\u' hex hex hex hex |
'\U' hex hex hex hex hex hex hex hex |
'\\' |
[#x20-#x5B] | [#x5D-#x10FFFF]
See String Escapes for full details.
[32] echaracter ::= character | '\t' | '\n' | '\r'
See String Escapes for full details.
[33] hex ::= [#x30-#x39] | [#x41-#x46]
hexadecimal digit (0-9, uppercase A-F)
[34] ucharacter ::= ( character - #x3E ) | '\>'
[35] scharacter ::= ( echaracter - #x22 ) | '\"'
[36] lcharacter ::= echaracter | '\"' | #x9 | #xA | #xD

3.1 Qualified Names and URIs

The DCMI Abstract Model uses URIs to refer to resources. In the DC-TEXT syntax, URIs may be written in full or may be represented as QNames. A QName is made up of two parts, a prefix and a name, seprated by a colon (":"). In DC-TEXT, wherever a QName is used, it is used to represent a URI. The URI represented by the QName is determined by appending the name part of the QName to the URI with which the prefix is associated in a namespace declaration.

Note that the limitations on the characters which can occur in a name mean that there are URIs that can not be expressed as QNames.

3.2 String Escapes

See Turtle.

3.3 Rich Representations

Binary data as Base64 encoded data. How to indicate when string is Base64 encoded?

4. Examples

4.1 Single Description in Description Set, Statements Using Value Strings and Value URIs

The first example is of a description set containing a single description with a single simple statement using a value string to represent the value:

DescriptionSet(
  Description(
    Resource URI( <http://example.org/pages/home> )
    Statement(
      Property URI( <http://purl.org/dc/elements/1.1/title> )
      Value String( "PeteJ"s Home Page" )
      )
    )
  )

Example 1: Value Strings

Using the QName mechanism to abbreviate the resource URI and the property URI, the same description set might be encoded as follows.

@prefix page: <http://example.org/pages/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page" )
      )
    )
  )

Example 2: QNames

The value string may be associated with a language tag:

@prefix page: <http://example.org/pages/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page"
        Language(en-GB)
        )
      )
    )
  )

Example 3: Language Tags

A statement may include multiple value strings to represent the value:

@prefix page: <http://example.org/pages/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page"
        Language(en-GB)
        )
      Value String( "El Home Page de PeteJ"
        Language(es-ES)
        )
      )
    )
  )

Example 4: Multiple Value Strings

A statement may include a value URI to identify the value:

@prefix page: <http://example.org/pages/> .
@prefix person: <http://example.org/persons/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page"
        Language(en-GB)
        )
      Value String( "El Home Page de PeteJ"
        Language(es-ES)
        )
      )
    Statement(
      Property URI( dc:creator )
      Value URI ( person:PeteJ )
      )
    )
  )

Example 5: Value URIs

4.2 Vocabulary and Syntax Encoding Scheme URIs

A statement may include a vocabulary encoding scheme URI:

@prefix page: <http://example.org/pages/> .
@prefix person: <http://example.org/persons/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix dcterms: <http://purl.org/dc/terms/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page"
        Language(en-GB)
        )
      Value String( "El Home Page de PeteJ"
        Language(es-ES)
        )
      )
    Statement(
      Property URI( dc:creator )
      Value URI ( person:PeteJ )
      )
    Statement(
      Property URI( dc:subject )
      Vocabulary Encoding Scheme URI ( dcterms:LCSH )
      Value String ( "Information technology")
      )
    )
  )

Example 6: Vocabulary Encoding Scheme URIs

A value string may be associated with a syntax encoding scheme URI:

@prefix page: <http://example.org/pages/> .
@prefix person: <http://example.org/persons/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix xs: <http://www.w3.org/2001/XMLSchema#> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page"
        Language(en-GB)
        )
      Value String( "El Home Page de PeteJ"
        Language(es-ES)
        )
      )
    Statement(
      Property URI( dc:creator )
      Value URI ( person:PeteJ )
      )
    Statement(
      Property URI( dc:subject )
      Vocabulary Encoding Scheme URI( dcterms:LCSH )
      Value String ( "Information technology" )
      )
    Statement(
      Property URI( dcterms:modified )
      Value String( "2006-02-14"
        Syntax Encoding Scheme URI( xs:date )
      )
    )
  )

Example 7: Syntax Encoding Scheme URIs

4.3 Multiple Descriptions in Description Set

A description set may contain multiple descriptions

@prefix page: <http://example.org/pages/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page" )
      )
    )
  Description(
    Resource URI( page:althome )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Alternative Home Page" )
      )
    )
  )

Example 8: Multiple Descriptions

A description may be the description of a resource which is a value in a statement in another description within the description set. If the resource has been assigned a URI, then that URI appears as a value URI in the statements where the resource is the value and as a resource URI in the description of that resource.

@prefix page: <http://example.org/pages/> .
@prefix person: <http://example.org/persons/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page" )
      )
    Statement(
      Property URI( dc:creator )
      Value URI ( person:PeteJ )
      )
    )
  Description(
    Resource URI( page:althome )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Alternative Home Page" )
      )
    Statement(
      Property URI( dc:creator )
      Value URI ( person:PeteJ )
      )
    )
  Description(
    Resource URI( person:PeteJ )
    Statement(
      Property URI( foaf:name )
      Value String ( "Pete J" )
      )
    )
  )
  

Example 9: Multiple Related Descriptions

In some cases it may be that the resources do not have URIs assigned, but such a resource may still be a value in a ststement, and the subject of another description. In DC-TEXT, the association between the value of one statement and the description of that resource is made by labelling the description using a DescriptionId component. The value of the DescriptionId component may then be cited using the DescriptionRef component of one or more statements in the same description set.

@prefix page: <http://example.org/pages/> .
@prefix person: <http://example.org/persons/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .

DescriptionSet(
  Description(
    Resource URI( page:home )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Home Page" )
      )
    Statement(
      Property URI( dc:creator )
      Description Ref ( descPeteJ )
      )
    )
  Description(
    Resource URI( page:althome )
    Statement(
      Property URI( dc:title )
      Value String( "PeteJ"s Alternative Home Page" )
      )
    Statement(
      Property URI( dc:creator )
      Description Ref ( descPeteJ )
      )
    )
  Description(
    Description Id ( descPeteJ )
    Statement(
      Property URI( foaf:name )
      Value String ( "Pete J" )
      )
    )
  )
  

Example 10: Multiple Related Descriptions

Notes

References

[DCMIAM]
DCMI Abstract Model
http://dublincore.org/documents/abstract-model/

[XML]
Extensible Markup Language (XML) 1.0 (Third Edition). W3C Recommendation 04 February 2004.
http://www.w3.org/TR/REC-xml

[XML]
XML Schema Part 0: Primer Second Edition. W3C Recommendation 28 October 2004.
http://www.w3.org/TR/xmlschema-0/

[TURTLE]


Valid XHTML 1.0!Valid CSS!