aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v4/xml_format.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2012-11-15 08:50:04 -0500
committerRalph Amissah <ralph@amissah.com>2012-11-15 08:50:04 -0500
commitb147bcd379f889e60fda61e48aac915eebc016b7 (patch)
treea90e0a9a1229e6b2d98446abac1c063b3c4ade55 /lib/sisu/v4/xml_format.rb
parentv4: sisupod, use common make instruction header for documents (diff)
v4: document headers, metadata rearranged, wide-ranging effect
Diffstat (limited to 'lib/sisu/v4/xml_format.rb')
-rw-r--r--lib/sisu/v4/xml_format.rb44
1 files changed, 22 insertions, 22 deletions
diff --git a/lib/sisu/v4/xml_format.rb b/lib/sisu/v4/xml_format.rb
index 445fd45a..212a2866 100644
--- a/lib/sisu/v4/xml_format.rb
+++ b/lib/sisu/v4/xml_format.rb
@@ -149,21 +149,31 @@ module SiSU_XML_Format
@rdf_date_modified=%{ dc.date.modified="#{@md.date.modified}"\n}
@date_modified=%{<meta name="dc.date.modified" content="#{@md.date.modified}" #{@md.date_modified_scheme} />\n}
end
- if defined? @md.type \
- and @md.type # DublinCore 8 - type (genre eg. report, convention etc)
- @rdf_type=%{ dc.type="#{@md.type}"\n}
- @type=%{<meta name="dc.type" content="#{@md.type}" />\n}
+ if defined? @md.notes.coverage \
+ and @md.notes.coverage=~/\S+/ # DublinCore 14 - coverage
+ @rdf_coverage=%{ dc.coverage="#{@md.notes.coverage}"\n}
+ @coverage=%{<meta name="dc.coverage" content="#{@md.notes.coverage}" />\n}
end
- if defined? @md.classify.format \
- and @md.classify.format=~/\S+/ # DublinCore 9 - format (use your mime type)
- @rdf_format=%{ dc.format="#{@md.classify.format}"\n}
- @format=%{<meta name="dc.format" content="#{@md.classify.format}" />\n}
+ if defined? @md.notes.relation \
+ and @md.notes.relation=~/\S+/ # DublinCore 13 - relation
+ @rdf_relation=%{ dc.relation="#{@md.notes.relation}"\n}
+ @relation=%{<meta name="dc.relation" content="#{@md.notes.relation}" />\n}
end
- if defined? @md.classify.identifier \
- and @md.classify.identifier=~/\S+/ # DublinCore 10 - identifier (your identifier, could use urn which is free)
- @rdf_identifier=%{ dc.identifier="#{@md.classify.identifier}"\n}
- @identifier=%{<meta name="dc.identifier" content="#{@md.identifier}" />\n}
+ if defined? @md.notes.type \
+ and @md.notes.type # DublinCore 8 - type (genre eg. report, convention etc)
+ @rdf_type=%{ dc.type="#{@md.notes.type}"\n}
+ @type=%{<meta name="dc.type" content="#{@md.notes.type}" />\n}
end
+ if defined? @md.notes.format \
+ and @md.notes.format=~/\S+/ # DublinCore 9 - format (use your mime type)
+ @rdf_format=%{ dc.format="#{@md.notes.format}"\n}
+ @format=%{<meta name="dc.format" content="#{@md.notes.format}" />\n}
+ end
+ #if defined? @md.identifier.sisupod \
+ #and @md.identifier.sisupod=~/\S+/ # DublinCore 10 - identifier (your identifier, could use urn which is free)
+ # @rdf_identifier=%{ dc.identifier="#{@md.identifier.sisupod}"\n}
+ # @identifier=%{<meta name="dc.identifier" content="#{@md.identifier.sisupod}" />\n}
+ #end
if defined? @md.original.source \
and @md.original.source=~/\S+/ # DublinCore 11 - source (document source)
@rdf_source=%{ dc.source="#{@md.original.source}"\n}
@@ -174,16 +184,6 @@ module SiSU_XML_Format
@rdf_language=%{ dc.language="#{@md.original.title}"\n}
@language=%{<meta name="dc.language" content="#{@md.language[:name]}" />\n}
end
- if defined? @md.classify.relation \
- and @md.classify.relation=~/\S+/ # DublinCore 13 - relation
- @rdf_relation=%{ dc.relation="#{@md.classify.relation}"\n}
- @relation=%{<meta name="dc.relation" content="#{@md.classify.relation}" />\n}
- end
- if defined? @md.classify.coverage \
- and @md.classify.coverage=~/\S+/ # DublinCore 14 - coverage
- @rdf_coverage=%{ dc.coverage="#{@md.classify.coverage}"\n}
- @coverage=%{<meta name="dc.coverage" content="#{@md.classify.coverage}" />\n}
- end
if defined? @md.rights.all \
and @md.rights.all=~/\S+/ # DublinCore 15 - rights
@rdf_rights=%{ dc.rights="#{@md.rights.all}"\n}