Skip to content

Commit 3a8cd95

Browse files
author
tucotuco
committed
Pre-standard release 2009-02-20.
1 parent dd3c61c commit 3a8cd95

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+5659
-4573
lines changed
+10-10
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
2-
var browserName = navigator.appName;
3-
var browserVer = parseInt(navigator.appVersion);
4-
var version = "";
5-
var msie4 = (browserName == "Microsoft Internet Explorer" && browserVer >= 4);
6-
if ((browserName == "Netscape" && browserVer >= 3) || msie4 || browserName=="Konqueror" || browserName=="Opera") {version = "n3";} else {version = "n2";}
7-
// Blurring links:
8-
function blurLink(theObject) { //
9-
if (msie4) {theObject.blur();}
10-
}
1+
2+
var browserName = navigator.appName;
3+
var browserVer = parseInt(navigator.appVersion);
4+
var version = "";
5+
var msie4 = (browserName == "Microsoft Internet Explorer" && browserVer >= 4);
6+
if ((browserName == "Netscape" && browserVer >= 3) || msie4 || browserName=="Konqueror" || browserName=="Opera") {version = "n3";} else {version = "n2";}
7+
// Blurring links:
8+
function blurLink(theObject) { //
9+
if (msie4) {theObject.blur();}
10+
}
1111

examples/rdfa_content/rdfa2rdf.py

+21-21
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
1-
'''
2-
Very simple example of an RDFa to RDF converter.
3-
4-
Requires RDFLib from http://code.google.com/p/rdflib/
5-
'''
6-
7-
import sys
8-
import logging
9-
from rdflib import ConjunctiveGraph
10-
11-
logging.basicConfig(level=logging.INFO)
12-
if len(sys.argv) < 2:
13-
logging.info('Usage: rdfa2rdf <URL for RDFa>')
14-
sys.exit()
15-
try:
16-
g = ConjunctiveGraph()
17-
res = g.parse(sys.argv[1], format='rdfa')
18-
print g.serialize()
19-
except Exception,e:
20-
logging.error('Exception raised: %s' % str(e))
21-
1+
'''
2+
Very simple example of an RDFa to RDF converter.
3+
4+
Requires RDFLib from http://code.google.com/p/rdflib/
5+
'''
6+
7+
import sys
8+
import logging
9+
from rdflib import ConjunctiveGraph
10+
11+
logging.basicConfig(level=logging.INFO)
12+
if len(sys.argv) < 2:
13+
logging.info('Usage: rdfa2rdf <URL for RDFa>')
14+
sys.exit()
15+
try:
16+
g = ConjunctiveGraph()
17+
res = g.parse(sys.argv[1], format='rdfa')
18+
print g.serialize()
19+
except Exception,e:
20+
logging.error('Exception raised: %s' % str(e))
21+
2222

examples/rdfa_content/sciname_1.html

+22-22
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3-
<html xmlns="http://www.w3.org/1999/xhtml"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/">
6-
<head >
7-
<title>Scientific Name in RDFa</title>
8-
<meta about='sciname_1.html' property='dc:creator' content="Dave Vieglais"/>
9-
<meta about='sciname_1.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
10-
<meta about='sciname_1.html' property='dc:description' content="Demonstrates how to
11-
tag a scientific name with RDFa markup so that a parser can recognize that a string
12-
value represents a scientific name." />
13-
</head>
14-
<body>
15-
<p>This example shows how to tag a scientific name with RDFa markup so that a
16-
parser can recognize that the string
17-
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>
18-
as a scientific name, and the string &quot;<span property='dwc:Family'>Bufonidae</span>
19-
is a family name, but there is no statement that <span style='font-style: italic;'>B. marinus</span> is a
20-
member of the family Bufonidae.</p>
21-
</body>
22-
</html>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3+
<html xmlns="http://www.w3.org/1999/xhtml"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/">
6+
<head >
7+
<title>Scientific Name in RDFa</title>
8+
<meta about='sciname_1.html' property='dc:creator' content="Dave Vieglais"/>
9+
<meta about='sciname_1.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
10+
<meta about='sciname_1.html' property='dc:description' content="Demonstrates how to
11+
tag a scientific name with RDFa markup so that a parser can recognize that a string
12+
value represents a scientific name." />
13+
</head>
14+
<body>
15+
<p>This example shows how to tag a scientific name with RDFa markup so that a
16+
parser can recognize that the string
17+
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>
18+
as a scientific name, and the string &quot;<span property='dwc:Family'>Bufonidae</span>
19+
is a family name, but there is no statement that <span style='font-style: italic;'>B. marinus</span> is a
20+
member of the family Bufonidae.</p>
21+
</body>
22+
</html>

examples/rdfa_content/sciname_2.html

+25-25
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3-
<html xmlns="http://www.w3.org/1999/xhtml"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6-
xmlns:dwct="http://rs.tdwg.org/dwc/dwctype/">
7-
<head >
8-
<title>Scientific Name in RDFa</title>
9-
<meta about='sciname_2.html' property='dc:creator' content="Dave Vieglais"/>
10-
<meta about='sciname_2.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
11-
<meta about='sciname_2.html' property='dc:description' content="Demonstrates how to
12-
tag a scientific name with RDFa markup so that a parser can recognize that a string
13-
value represents a scientific name." />
14-
</head>
15-
<body>
16-
<p>This example shows how to tag a scientific name with RDFa markup so that a
17-
parser can recognize that the string
18-
<span about='#name1' typeof='dwct:PreservedSpecimen'>
19-
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>
20-
as a scientific name, and the string &quot;<span property='dwc:Family'>Bufonidae</span>
21-
is a family name</span>, and since both terms form part of a Darwin Core record,
22-
infers that Bufonidae is the family name for entity named &quot;#name1&quot; and
23-
&quot;<span style='font-style: italic;'>Bufo marinus</span>&quot; is the scientific name.</p>
24-
</body>
25-
</html>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3+
<html xmlns="http://www.w3.org/1999/xhtml"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6+
xmlns:dwct="http://rs.tdwg.org/dwc/dwctype/">
7+
<head >
8+
<title>Scientific Name in RDFa</title>
9+
<meta about='sciname_2.html' property='dc:creator' content="Dave Vieglais"/>
10+
<meta about='sciname_2.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
11+
<meta about='sciname_2.html' property='dc:description' content="Demonstrates how to
12+
tag a scientific name with RDFa markup so that a parser can recognize that a string
13+
value represents a scientific name." />
14+
</head>
15+
<body>
16+
<p>This example shows how to tag a scientific name with RDFa markup so that a
17+
parser can recognize that the string
18+
<span about='#name1' typeof='dwct:PreservedSpecimen'>
19+
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>
20+
as a scientific name, and the string &quot;<span property='dwc:Family'>Bufonidae</span>
21+
is a family name</span>, and since both terms form part of a Darwin Core record,
22+
infers that Bufonidae is the family name for entity named &quot;#name1&quot; and
23+
&quot;<span style='font-style: italic;'>Bufo marinus</span>&quot; is the scientific name.</p>
24+
</body>
25+
</html>
+37-37
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,37 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3-
<html xmlns="http://www.w3.org/1999/xhtml"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6-
xmlns:georss='http://www.georss.org/georss#'
7-
xmlns:oboe='http://code.ecoinformatics.org/code/semtools/trunk/dev/oboe/oboe.owl#'>
8-
<head >
9-
<title>Observation in RDFa</title>
10-
<meta about='sciname_location.html' property='dc:creator' content="Dave Vieglais"/>
11-
<meta about='sciname_location.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
12-
<meta about='sciname_location.html' property='dc:description' content="Demonstrates how to
13-
create the equivalent of a simple observation record within a HTML document that can be
14-
converted to an RDF document." />
15-
</head>
16-
<body>
17-
<p>This example document contains a record of an observation tagged with an lsid of xxx
18-
<span about="lsid:blah.blah" typeof="oboe:Observation">
19-
that includes the scientific name
20-
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>,
21-
</span>
22-
<span about='lsid:blah.blah' typeof="dc:SamplingLocation" >
23-
<span property='dwc:GeodeticDatum' content='epsg:4326' />
24-
a geographic location of
25-
<span property='georss:point' content='-25.273262 152.725067' />
26-
longitude
27-
<span property='dwc:DecimalLongitude'>152.725067</span>
28-
east, latitude
29-
<span property='dwc:DecimalLatitude'>-25.273262</span>,
30-
</span>
31-
and a time of
32-
<span about='lsid:blah.blah' property='dwc:EarliestDateCollected' content="2008-11-10T23:32:00+00:00">
33-
9:32 in the morning of the 12th of November.
34-
</span>
35-
</p>
36-
</body>
37-
</html>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
3+
<html xmlns="http://www.w3.org/1999/xhtml"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6+
xmlns:georss='http://www.georss.org/georss#'
7+
xmlns:oboe='http://code.ecoinformatics.org/code/semtools/trunk/dev/oboe/oboe.owl#'>
8+
<head >
9+
<title>Observation in RDFa</title>
10+
<meta about='sciname_location.html' property='dc:creator' content="Dave Vieglais"/>
11+
<meta about='sciname_location.html' property='dc:date' content="2008-11-14T09:52:00+00:00" />
12+
<meta about='sciname_location.html' property='dc:description' content="Demonstrates how to
13+
create the equivalent of a simple observation record within a HTML document that can be
14+
converted to an RDF document." />
15+
</head>
16+
<body>
17+
<p>This example document contains a record of an observation tagged with an lsid of xxx
18+
<span about="lsid:blah.blah" typeof="oboe:Observation">
19+
that includes the scientific name
20+
<span property='dwc:ScientificName' style='font-style: italic;'>Bufo marinus</span>,
21+
</span>
22+
<span about='lsid:blah.blah' typeof="dc:SamplingLocation" >
23+
<span property='dwc:GeodeticDatum' content='epsg:4326' />
24+
a geographic location of
25+
<span property='georss:point' content='-25.273262 152.725067' />
26+
longitude
27+
<span property='dwc:DecimalLongitude'>152.725067</span>
28+
east, latitude
29+
<span property='dwc:DecimalLatitude'>-25.273262</span>,
30+
</span>
31+
and a time of
32+
<span about='lsid:blah.blah' property='dwc:EarliestDateCollected' content="2008-11-10T23:32:00+00:00">
33+
9:32 in the morning of the 12th of November.
34+
</span>
35+
</p>
36+
</body>
37+
</html>

examples/xml/example_checklist.xml

+21-21
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<DarwinRecordSet
3-
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7-
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwcrec_classes.xsd">
8-
<dwc:Sample>
9-
<dwc:SampleID>12345678</dwc:SampleID>
10-
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
11-
<dwc:CatalogNumber>cgbers-xydw786</dwc:CatalogNumber>
12-
<dc:modified>2001-03-21</dc:modified>
13-
</dwc:Sample>
14-
15-
<dwc:Taxon>
16-
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
17-
<dwc:ScientificName>Robertsonus timmus</dwc:ScientificName>
18-
<dc:modified>1978-06-11</dc:modified>
19-
</dwc:Taxon>
20-
21-
</DarwinRecordSet>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<DarwinRecordSet
3+
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7+
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwcrec_classes.xsd">
8+
<dwc:Sample>
9+
<dwc:SampleID>12345678</dwc:SampleID>
10+
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
11+
<dwc:CatalogNumber>cgbers-xydw786</dwc:CatalogNumber>
12+
<dc:modified>2001-03-21</dc:modified>
13+
</dwc:Sample>
14+
15+
<dwc:Taxon>
16+
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
17+
<dwc:ScientificName>Robertsonus timmus</dwc:ScientificName>
18+
<dc:modified>1978-06-11</dc:modified>
19+
</dwc:Taxon>
20+
21+
</DarwinRecordSet>

examples/xml/example_flat.xml

+17-17
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<DarwinRecordSet
3-
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7-
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ ../../xsd/tdwg_dwc_simple.xsd">
8-
<!-- http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwc_simple.xsd -->
9-
<DarwinRecord>
10-
<dwc:SampleID>12345678</dwc:SampleID>
11-
<dc:modified></dc:modified>
12-
<dwc:CatalogNumber>few</dwc:CatalogNumber>
13-
<dwc:CollectionCode></dwc:CollectionCode>
14-
<dwc:InstitutionCode></dwc:InstitutionCode>
15-
<dwc:BasisOfRecord>FossilSpecimen</dwc:BasisOfRecord>
16-
</DarwinRecord>
17-
</DarwinRecordSet>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<DarwinRecordSet
3+
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7+
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ ../../xsd/tdwg_dwc_simple.xsd">
8+
<!-- http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwc_simple.xsd -->
9+
<DarwinRecord>
10+
<dwc:SampleID>12345678</dwc:SampleID>
11+
<dc:modified></dc:modified>
12+
<dwc:CatalogNumber>few</dwc:CatalogNumber>
13+
<dwc:CollectionCode></dwc:CollectionCode>
14+
<dwc:InstitutionCode></dwc:InstitutionCode>
15+
<dwc:BasisOfRecord>FossilSpecimen</dwc:BasisOfRecord>
16+
</DarwinRecord>
17+
</DarwinRecordSet>

examples/xml/example_normalised.xml

+21-21
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
<?xml version="1.0" encoding="UTF-8"?>
2-
<DarwinRecordSet
3-
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4-
xmlns:dc="http://purl.org/dc/terms/"
5-
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7-
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwcrec_classes.xsd">
8-
<dwc:Sample>
9-
<dwc:SampleID>12345678</dwc:SampleID>
10-
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
11-
<dwc:CatalogNumber>cgbers-xydw786</dwc:CatalogNumber>
12-
<dc:modified>2001-03-21</dc:modified>
13-
</dwc:Sample>
14-
15-
<dwc:Taxon>
16-
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
17-
<dwc:ScientificName>Robertsonus timmus</dwc:ScientificName>
18-
<dc:modified>1978-06-11</dc:modified>
19-
</dwc:Taxon>
20-
21-
</DarwinRecordSet>
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<DarwinRecordSet
3+
xmlns="http://rs.tdwg.org/dwc/dwcrecord/"
4+
xmlns:dc="http://purl.org/dc/terms/"
5+
xmlns:dwc="http://rs.tdwg.org/dwc/terms/"
6+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7+
xsi:schemaLocation="http://rs.tdwg.org/dwc/dwcrecord/ http://darwincore.googlecode.com/svn/trunk/xsd/tdwg_dwcrec_classes.xsd">
8+
<dwc:Sample>
9+
<dwc:SampleID>12345678</dwc:SampleID>
10+
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
11+
<dwc:CatalogNumber>cgbers-xydw786</dwc:CatalogNumber>
12+
<dc:modified>2001-03-21</dc:modified>
13+
</dwc:Sample>
14+
15+
<dwc:Taxon>
16+
<dwc:TaxonID>5432-fc43-432</dwc:TaxonID>
17+
<dwc:ScientificName>Robertsonus timmus</dwc:ScientificName>
18+
<dc:modified>1978-06-11</dc:modified>
19+
</dwc:Taxon>
20+
21+
</DarwinRecordSet>

0 commit comments

Comments
 (0)