aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/output
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2018-06-20 11:42:14 -0400
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:15 -0400
commitb86c91d6136476de3a35e0077db28caccacd816e (patch)
tree4aad808156bb045eadfc9191d593732832e5de2f /src/sdp/output
parentnaming is_of_ (is_ of_) (diff)
doc object metainfo consolidation
Diffstat (limited to 'src/sdp/output')
-rw-r--r--src/sdp/output/epub3.d88
-rw-r--r--src/sdp/output/html.d78
-rw-r--r--src/sdp/output/sqlite.d78
-rw-r--r--src/sdp/output/xmls.d118
4 files changed, 181 insertions, 181 deletions
diff --git a/src/sdp/output/epub3.d b/src/sdp/output/epub3.d
index 74856e1..0e864f7 100644
--- a/src/sdp/output/epub3.d
+++ b/src/sdp/output/epub3.d
@@ -104,20 +104,20 @@ template outputEPub3() {
debug(epubmanifest) {
foreach (s; doc_matters.xml.keys_seq.seg) {
foreach (obj; doc_abstraction[s]) {
- if (obj.typeinfo.is_a == "heading") {
- if (obj.node.heading_lev_markup == 4) {
+ if (obj.metainfo.is_a == "heading") {
+ if (obj.metainfo.heading_lev_markup == 4) {
writefln(
"%s~ [%s.xhtml] %s",
obj.marked_up_level,
obj.tags.segment_anchor_tag,
obj.text
);
- } else if (obj.node.heading_lev_markup > 4) {
+ } else if (obj.metainfo.heading_lev_markup > 4) {
writefln(
"%s~ [%s.xhtml#%s] %s",
obj.marked_up_level,
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
obj.text
);
}
@@ -146,27 +146,27 @@ template outputEPub3() {
);
foreach (sect; doc_matters.xml.keys_seq.seg) {
foreach (obj; doc_abstraction[sect]) {
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
string _txt = obj.text.replaceAll(rgx.inline_notes_al_gen, "").strip;
foreach_reverse (n; 0 .. 7) {
string k = n.to!string;
- switch (obj.node.dom_collapsed[n]) {
+ switch (obj.metainfo.dom_collapsed[n]) {
case DomTags.close :
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "</li>" ~ "\n";
toc ~= markup.indent_by_spaces_provided(n, " ") ~ "</ol>" ~ "\n";
break;
case DomTags.close_and_open :
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "</li>" ~ "\n";
- if (obj.node.heading_lev_markup < 4) {
+ if (obj.metainfo.heading_lev_markup < 4) {
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "<li>" ~ "\n"
~ markup.indent_by_spaces_provided((n + 2), " ")
~ "<a href=\"" ~ obj.tags.segment_anchor_tag ~ ".xhtml" ~ "\">"
~ _txt
~ "</a>" ~ "\n";
} else {
- string hashtag =(obj.node.heading_lev_markup == 4)
+ string hashtag =(obj.metainfo.heading_lev_markup == 4)
? ""
- : ("#" ~ obj.node.ocn.to!string);
+ : ("#" ~ obj.metainfo.ocn.to!string);
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "<li>" ~ "\n"
~ markup.indent_by_spaces_provided((n + 2), " ")
~ "<a href=\"" ~ obj.tags.segment_anchor_tag ~ ".xhtml" ~ hashtag ~ "\">"
@@ -176,16 +176,16 @@ template outputEPub3() {
break;
case DomTags.open :
toc ~= markup.indent_by_spaces_provided(n, " ") ~ "<ol>" ~ "\n";
- if (obj.node.heading_lev_markup < 4) {
+ if (obj.metainfo.heading_lev_markup < 4) {
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "<li>" ~ "\n"
~ markup.indent_by_spaces_provided((n + 2), " ")
~ "<a href=\"" ~ obj.tags.segment_anchor_tag ~ ".xhtml" ~ "\">"
~ _txt
~ "</a>" ~ "\n";
} else {
- string hashtag =(obj.node.heading_lev_markup == 4)
+ string hashtag =(obj.metainfo.heading_lev_markup == 4)
? ""
- : ("#" ~ obj.node.ocn.to!string);
+ : ("#" ~ obj.metainfo.ocn.to!string);
toc ~= markup.indent_by_spaces_provided((n + 1), " ") ~ "<li>" ~ "\n"
~ markup.indent_by_spaces_provided((n + 2), " ")
~ "<a href=\"" ~ obj.tags.segment_anchor_tag ~ ".xhtml" ~ hashtag ~ "\">"
@@ -243,11 +243,11 @@ template outputEPub3() {
);
foreach (sect; doc_matters.xml.keys_seq.seg) {
foreach (obj; doc_abstraction[sect]) {
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
string _txt = obj.text.replaceAll(rgx.inline_notes_al_gen, "").strip;
- string hashtag =(obj.node.heading_lev_markup <= 4) ? "" : ("#" ~ obj.node.ocn.to!string);
+ string hashtag =(obj.metainfo.heading_lev_markup <= 4) ? "" : ("#" ~ obj.metainfo.ocn.to!string);
foreach_reverse (k; 0 .. 7) {
- switch (obj.node.dom_markedup[k]) {
+ switch (obj.metainfo.dom_markedup[k]) {
case DomTags.close :
toc ~= "\n </navPoint>";
break;
@@ -310,12 +310,12 @@ template outputEPub3() {
foreach (part; doc_matters.xml.keys_seq.seg) {
foreach (obj; doc_abstraction[part]) {
string _txt = xhtml_format.special_characters(obj, obj.text);
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
assert(part == "head" || "toc_seg" || "body" || "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.node.heading_lev_markup) {
+ switch (obj.metainfo.heading_lev_markup) {
case 0: .. case 3:
/+ fill buffer, and replace with new levels from 1 to 3 +/
- switch (obj.node.heading_lev_markup) {
+ switch (obj.metainfo.heading_lev_markup) {
case 0:
top_level_headings[0] = "";
top_level_headings[1] = "";
@@ -357,23 +357,23 @@ template outputEPub3() {
break;
case 8: .. case 9:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a, ": ", obj.node.heading_lev_markup);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a, ": ", obj.metainfo.heading_lev_markup);
writeln(__FILE__, ":", __LINE__, ": ", obj.text);
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a, ": ", obj.node.heading_lev_markup);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a, ": ", obj.metainfo.heading_lev_markup);
}
break;
}
} else {
assert(part == "head" || "toc_seg" || "body" || "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.typeinfo.is_of_part) {
+ switch (obj.metainfo.is_of_part) {
case "frontmatter": assert(part == "head" || "toc_seg");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "toc":
auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
@@ -381,22 +381,22 @@ template outputEPub3() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "body": assert(part == "body");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "para":
auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
@@ -404,13 +404,13 @@ template outputEPub3() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
case "block":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "quote":
auto t = xhtml_format.quote_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
@@ -442,23 +442,23 @@ template outputEPub3() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "backmatter":
assert(part == "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "endnote": assert(part == "endnotes");
auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
@@ -485,14 +485,14 @@ template outputEPub3() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
@@ -501,14 +501,14 @@ template outputEPub3() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_part);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_part);
}
break;
}
}
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
assert(obj.text.length > 0);
- if (obj.node.heading_lev_markup <= 4) {
+ if (obj.metainfo.heading_lev_markup <= 4) {
oepbs_content_parts["manifest_documents"] ~=
format(q"¶ <item id="%s.xhtml" href="%s.xhtml" media-type="application/xhtml+xml" />
¶",
@@ -526,28 +526,28 @@ template outputEPub3() {
obj.tags.segment_anchor_tag,
obj.tags.segment_anchor_tag,
);
- } else if (obj.node.heading_lev_markup > 4) {
+ } else if (obj.metainfo.heading_lev_markup > 4) {
oepbs_content_parts["manifest_documents"] ~=
format(q"¶ <item id="%s.xhtml#%s" href="%s.xhtml#%s" media-type="application/xhtml+xml" />
¶",
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
);
oepbs_content_parts["spine"] ~=
format(q"¶ <itemref idref="%s.xhtml#%s" linear="yes" />
¶",
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
);
oepbs_content_parts["guide"] ~=
format(q"¶ <reference type="%s#%s" href="%s#%s" />
¶",
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
obj.tags.segment_anchor_tag,
- obj.node.object_number,
+ obj.metainfo.object_number,
);
}
}
diff --git a/src/sdp/output/html.d b/src/sdp/output/html.d
index d9992a8..46cd4ee 100644
--- a/src/sdp/output/html.d
+++ b/src/sdp/output/html.d
@@ -28,11 +28,11 @@ template outputHTML() {
foreach (obj; doc_abstraction[part]) {
delimit = xhtml_format.div_delimit(part, previous_part);
string _txt = xhtml_format.special_characters(obj, obj.text);
- switch (obj.typeinfo.is_of_part) {
+ switch (obj.metainfo.is_of_part) {
case "frontmatter": assert(part == "head" || "toc_scroll");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
break;
@@ -41,22 +41,22 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "body": assert(part == "body" || "head"); // surprise
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
break;
@@ -65,13 +65,13 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
case "block":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "quote":
doc_html ~= xhtml_format.quote_scroll(obj, _txt);
break;
@@ -94,23 +94,23 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "backmatter":
assert(part == "endnotes" || "glossary" || "bibliography" || "bookindex_scroll" || "blurb" || "tail");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
doc_html ~= delimit ~ xhtml_format.heading_scroll(obj, _txt, suffix);
break;
@@ -131,14 +131,14 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
@@ -147,8 +147,8 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_part);
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_part);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
writeln(__FILE__, ":", __LINE__, ": ", obj.text);
}
break;
@@ -200,12 +200,12 @@ template outputHTML() {
foreach (obj; doc_abstraction[part]) {
delimit = xhtml_format.div_delimit(part, previous_part);
string _txt = xhtml_format.special_characters(obj, obj.text);
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
assert(part == "head" || "toc_seg" || "body" || "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.node.heading_lev_markup) {
+ switch (obj.metainfo.heading_lev_markup) {
case 0: .. case 3:
/+ fill buffer, and replace with new levels from 1 to 3 +/
- switch (obj.node.heading_lev_markup) {
+ switch (obj.metainfo.heading_lev_markup) {
case 0:
top_level_headings[0] = "";
top_level_headings[1] = "";
@@ -226,7 +226,7 @@ template outputHTML() {
goto default;
default:
auto t = xhtml_format.heading_seg(obj, _txt, suffix, "seg");
- top_level_headings[obj.node.heading_lev_markup] = t[0];
+ top_level_headings[obj.metainfo.heading_lev_markup] = t[0];
break;
}
break;
@@ -252,45 +252,45 @@ template outputHTML() {
break;
case 8: .. case 9:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a, ": ", obj.node.heading_lev_markup);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a, ": ", obj.metainfo.heading_lev_markup);
writeln(__FILE__, ":", __LINE__, ": ", obj.text);
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a, ": ", obj.node.heading_lev_markup);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a, ": ", obj.metainfo.heading_lev_markup);
}
break;
}
} else {
assert(part == "head" || "toc_seg" || "body" || "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.typeinfo.is_of_part) {
+ switch (obj.metainfo.is_of_part) {
case "frontmatter": assert(part == "head" || "toc_seg");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "toc":
auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
case "body": assert(part == "body");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "para":
auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
@@ -298,13 +298,13 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
case "block":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "quote":
auto t = xhtml_format.quote_seg(obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0].to!string;
@@ -336,23 +336,23 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "backmatter":
assert(part == "endnotes" || "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail");
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "endnote": assert(part == "endnotes");
auto t = xhtml_format.para_seg(obj, _txt, suffix, "seg");
doc_html[segment_filename] ~= t[0];
@@ -379,14 +379,14 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
@@ -395,7 +395,7 @@ template outputHTML() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_part);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_part);
}
break;
}
diff --git a/src/sdp/output/sqlite.d b/src/sdp/output/sqlite.d
index b4be286..1aa578d 100644
--- a/src/sdp/output/sqlite.d
+++ b/src/sdp/output/sqlite.d
@@ -246,7 +246,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s"><b>
%s
</b></p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt,
);
return o;
@@ -259,7 +259,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s" indent="h%si%s">
%s
</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
obj.attrib.indent_hang,
obj.attrib.indent_base,
_txt
@@ -273,7 +273,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s">
%s
</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
return o;
@@ -285,7 +285,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s">
%s
</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
return o;
@@ -296,7 +296,7 @@ template SQLiteFormatAndLoadObject() {
string _txt = munge_html(obj);
string o = format(q"¶
<p class="%s">%s</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt.stripRight
);
return o;
@@ -306,7 +306,7 @@ template SQLiteFormatAndLoadObject() {
) {
string _txt = munge_html(obj);
string o = format(q"¶<p class="%s">%s</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
return o;
@@ -316,7 +316,7 @@ template SQLiteFormatAndLoadObject() {
) {
string _txt = html_special_characters_code(obj.text);
string o = format(q"¶<p class="%s">%s</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
return o;
@@ -375,7 +375,7 @@ template SQLiteFormatAndLoadObject() {
</table>
%s
</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt,
_note
);
@@ -888,12 +888,12 @@ template SQLiteInsertDocObjectsLoop() {
);
¶",
_metadata_tid,
- obj.node.ocn,
+ obj.metainfo.ocn,
SQLinsertDelimiter!()(obj_txt["text"]),
SQLinsertDelimiter!()(obj_txt["html"]),
- obj.node.heading_lev_markup,
- obj.typeinfo.is_of_type,
- obj.typeinfo.is_a,
+ obj.metainfo.heading_lev_markup,
+ obj.metainfo.is_of_type,
+ obj.metainfo.is_a,
);
return _insert_doc_objects_row;
}
@@ -903,32 +903,32 @@ template SQLiteInsertDocObjectsLoop() {
string[] _insert_doc_objects;
foreach (part; doc_matters.xml.keys_seq.sql) {
foreach (obj; doc_abstraction[part]) {
- switch (obj.typeinfo.is_of_part) {
+ switch (obj.metainfo.is_of_part) {
case "frontmatter": assert(part == "head", part);
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
obj_txt = format_and_sqlite_load.heading(obj);
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "body": // assert(part == "body", part); // TODO broken
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
debug (asserts) { // TODO consider and fix or remove
if (part != "body") {
@@ -942,13 +942,13 @@ template SQLiteInsertDocObjectsLoop() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
case "block":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "quote":
obj_txt = format_and_sqlite_load.quote(obj);
break;
@@ -971,23 +971,23 @@ template SQLiteInsertDocObjectsLoop() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
break;
case "backmatter":
assert(part == "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail", part);
- switch (obj.typeinfo.is_of_type) {
+ switch (obj.metainfo.is_of_type) {
case "para":
- switch (obj.typeinfo.is_a) {
+ switch (obj.metainfo.is_a) {
case "heading":
obj_txt = format_and_sqlite_load.heading(obj);
break;
@@ -1005,14 +1005,14 @@ template SQLiteInsertDocObjectsLoop() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_type);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_type);
}
break;
}
@@ -1021,28 +1021,28 @@ template SQLiteInsertDocObjectsLoop() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of_part); // check where empty value could come from
- writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_of_part); // check where empty value could come from
+ writeln(__FILE__, ":", __LINE__, ": ", obj.metainfo.is_a);
writeln(__FILE__, ":", __LINE__, ": ", obj.text); // check where empty value could come from
}
break;
}
- if (obj.typeinfo.is_a == "heading") {
+ if (obj.metainfo.is_a == "heading") {
if ((doc_matters.opt.action.verbose)) {
writeln(
- "markup: ", obj.node.heading_lev_markup,
- "> ", obj.node.dom_markedup,
- "; collapsed: ", obj.node.heading_lev_collapsed,
- "> ", obj.node.dom_collapsed,
- "; ocn: ", obj.node.ocn,
- " node: ", obj.node.node,
- "; parent: ", obj.node.parent_lev_markup,
- "; ocn: ", obj.node.parent_ocn,
+ "markup: ", obj.metainfo.heading_lev_markup,
+ "> ", obj.metainfo.dom_markedup,
+ "; collapsed: ", obj.metainfo.heading_lev_collapsed,
+ "> ", obj.metainfo.dom_collapsed,
+ "; ocn: ", obj.metainfo.ocn,
+ " node: ", obj.metainfo.node,
+ "; parent: ", obj.metainfo.parent_lev_markup,
+ "; ocn: ", obj.metainfo.parent_ocn,
"; ",
);
}
}
- if (!(obj.typeinfo.is_a == "comment")) {
+ if (!(obj.metainfo.is_a == "comment")) {
_insert_doc_objects ~= insertDocObjectsRow(obj);
}
} // loop closes
diff --git a/src/sdp/output/xmls.d b/src/sdp/output/xmls.d
index e5d27c9..e977e6c 100644
--- a/src/sdp/output/xmls.d
+++ b/src/sdp/output/xmls.d
@@ -60,7 +60,7 @@ template outputXHTMLs() {
.replaceAll(rgx.xhtml_less_than, "&#60;")
.replaceAll(rgx.xhtml_greater_than, "&#62;")
.replaceAll(rgx.nbsp_char, " ");
- if (!(obj.typeinfo.is_a == "code")) {
+ if (!(obj.metainfo.is_a == "code")) {
_txt = (_txt)
.replaceAll(rgx.xhtml_line_break, "<br />");
}
@@ -363,7 +363,7 @@ template outputXHTMLs() {
writeln(__LINE__,
" (missed) markup link identified (",
obj.has.inline_links,
- "): ", obj.typeinfo.is_a, ": ",
+ "): ", obj.metainfo.is_a, ": ",
obj.text
);
}
@@ -373,7 +373,7 @@ template outputXHTMLs() {
writeln(__LINE__,
" (missed) markup link identified (",
obj.has.inline_links,
- "): ", obj.typeinfo.is_a, ": ",
+ "): ", obj.metainfo.is_a, ": ",
obj.text
);
}
@@ -393,12 +393,12 @@ template outputXHTMLs() {
}
debug(markup_endnotes) {
if (_txt.match(rgx.inline_notes_delimiter_al_regular_number_note)) {
- writeln(__LINE__, " (missed) markup endnote: ", obj.typeinfo.is_a, ": ", obj.text);
+ writeln(__LINE__, " (missed) markup endnote: ", obj.metainfo.is_a, ": ", obj.text);
}
}
debug(markup) {
if (_txt.match(rgx.inline_notes_delimiter_al_regular_number_note)) {
- writeln(__LINE__, " (missed) markup endnote: ", obj.typeinfo.is_a, ": ", obj.text);
+ writeln(__LINE__, " (missed) markup endnote: ", obj.metainfo.is_a, ": ", obj.text);
}
}
return _txt;
@@ -433,7 +433,7 @@ template outputXHTMLs() {
);
} else if (_txt.match(rgx.inline_notes_delimiter_al_regular_number_note)) {
debug(markup) {
- writeln(__LINE__, " endnote: ", obj.typeinfo.is_a, ": ", obj.text);
+ writeln(__LINE__, " endnote: ", obj.metainfo.is_a, ": ", obj.text);
}
}
auto t = tuple(
@@ -574,12 +574,12 @@ template outputXHTMLs() {
auto tags = _xhtml_anchor_tags(obj.tags.anchor_tags);
string _horizontal_rule = "<hr />";
if ((_xml_type != "html")
- || (obj.node.heading_lev_markup == 0 || obj.node.heading_lev_markup > 4)) {
+ || (obj.metainfo.heading_lev_markup == 0 || obj.metainfo.heading_lev_markup > 4)) {
_horizontal_rule = "";
}
_txt = font_face(_txt);
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶%s
<div class="substance">
<h%s class="%s">%s
@@ -587,11 +587,11 @@ template outputXHTMLs() {
</h%s>
</div>¶",
_horizontal_rule,
- obj.node.heading_lev_markup,
- obj.typeinfo.is_a,
+ obj.metainfo.heading_lev_markup,
+ obj.metainfo.is_a,
tags,
_txt,
- obj.node.heading_lev_markup,
+ obj.metainfo.heading_lev_markup,
);
} else {
o = format(q"¶%s
@@ -602,15 +602,15 @@ template outputXHTMLs() {
</h%s>
</div>¶",
_horizontal_rule,
- obj.node.object_number,
- obj.node.object_number,
- obj.node.heading_lev_markup,
- obj.typeinfo.is_a,
- obj.node.object_number,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.heading_lev_markup,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
tags,
_txt,
- obj.node.heading_lev_markup,
+ obj.metainfo.heading_lev_markup,
);
}
return o;
@@ -649,13 +649,13 @@ template outputXHTMLs() {
_txt = font_face(_txt);
string o;
_txt = (obj.attrib.bullet) ? ("●&#160;&#160;" ~ _txt) : _txt;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s" indent="h%si%s">%s
%s
</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
obj.attrib.indent_hang,
obj.attrib.indent_base,
tags,
@@ -668,12 +668,12 @@ template outputXHTMLs() {
%s
</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
obj.attrib.indent_hang,
obj.attrib.indent_base,
- obj.node.object_number,
+ obj.metainfo.object_number,
tags,
_txt
);
@@ -712,13 +712,13 @@ template outputXHTMLs() {
) {
_txt = font_face(_txt);
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s">
%s
</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
} else {
@@ -728,10 +728,10 @@ template outputXHTMLs() {
%s
</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
_txt
);
}
@@ -769,13 +769,13 @@ template outputXHTMLs() {
) {
_txt = font_face(_txt);
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s">
%s
</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
} else {
@@ -785,10 +785,10 @@ template outputXHTMLs() {
%s
</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
_txt
);
}
@@ -827,11 +827,11 @@ template outputXHTMLs() {
) {
_txt = font_face(_txt);
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s">%s</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt.stripRight
);
} else {
@@ -839,10 +839,10 @@ template outputXHTMLs() {
<label class="ocn"><a href="#%s" class="lnkocn">%s</a></label>
<p class="%s" id="%s">%s</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
_txt.stripRight
);
}
@@ -881,11 +881,11 @@ template outputXHTMLs() {
) {
_txt = font_face(_txt);
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s">%s</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
} else {
@@ -893,10 +893,10 @@ template outputXHTMLs() {
<label class="ocn"><a href="#%s" class="lnkocn">%s</a></label>
<p class="%s" id="%s">%s</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
_txt
);
}
@@ -981,10 +981,10 @@ template outputXHTMLs() {
%s
</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
tags,
_txt,
_note
@@ -999,7 +999,7 @@ template outputXHTMLs() {
o = format(q"¶ <p class="%s" indent="h%si%s">
%s
</p>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
obj.attrib.indent_hang,
obj.attrib.indent_base,
_txt
@@ -1011,11 +1011,11 @@ template outputXHTMLs() {
string _txt,
) {
string o;
- if (obj.node.object_number.empty) {
+ if (obj.metainfo.object_number.empty) {
o = format(q"¶ <div class="substance">
<p class="%s">%s</p>
</div>¶",
- obj.typeinfo.is_a,
+ obj.metainfo.is_a,
_txt
);
} else {
@@ -1023,10 +1023,10 @@ template outputXHTMLs() {
<label class="ocn"><a href="#%s" class="lnkocn">%s</a></label>
<p class="%s" id="%s">%s</p>
</div>¶",
- obj.node.object_number,
- obj.node.object_number,
- obj.typeinfo.is_a,
- obj.node.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.object_number,
+ obj.metainfo.is_a,
+ obj.metainfo.object_number,
_txt
);
}