aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/output/sqlite.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2018-06-12 15:38:38 -0400
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:15 -0400
commit6f8fddb2dfa5faad56af2a0bfd0bf3b694695136 (patch)
tree6b8af78c4cbb2a7a601de5430f41ab4a93503d67 /src/sdp/output/sqlite.d
parent0.26.2 image(s) without dimensions (diff)
0.26.3 object info changes
Diffstat (limited to 'src/sdp/output/sqlite.d')
-rw-r--r--src/sdp/output/sqlite.d90
1 files changed, 45 insertions, 45 deletions
diff --git a/src/sdp/output/sqlite.d b/src/sdp/output/sqlite.d
index e9667ae..f45eec6 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.is_a,
+ obj.typeinfo.is_a,
_txt,
);
return o;
@@ -255,13 +255,13 @@ template SQLiteFormatAndLoadObject() {
auto return ref const O obj,
) {
string _txt = munge_html(obj);
- _txt = (obj.bullet) ? ("●&#160;&#160;" ~ _txt) : _txt;
+ _txt = (obj.attrib.bullet) ? ("●&#160;&#160;" ~ _txt) : _txt;
string o = format(q"¶<p class="%s" indent="h%si%s">
%s
</p>¶",
- obj.is_a,
- obj.indent_hang,
- obj.indent_base,
+ obj.typeinfo.is_a,
+ obj.attrib.indent_hang,
+ obj.attrib.indent_base,
_txt
);
return o;
@@ -273,7 +273,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s">
%s
</p>¶",
- obj.is_a,
+ obj.typeinfo.is_a,
_txt
);
return o;
@@ -285,7 +285,7 @@ template SQLiteFormatAndLoadObject() {
string o = format(q"¶<p class="%s">
%s
</p>¶",
- obj.is_a,
+ obj.typeinfo.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.is_a,
+ obj.typeinfo.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.is_a,
+ obj.typeinfo.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.is_a,
+ obj.typeinfo.is_a,
_txt
);
return o;
@@ -340,14 +340,14 @@ template SQLiteFormatAndLoadObject() {
&& (_table_rows.length <= row_idx+2)) { // check row_idx+2 (rather than == ++row_idx)
_tablenote ~= cell;
} else {
- string _col_is = (row_idx == 0 && obj.table_heading) ? "th" : "td";
+ string _col_is = (row_idx == 0 && obj.table.heading) ? "th" : "td";
string _align = ("style=\"text-align:"
- ~ ((obj.table_column_aligns[col_idx] == "l")
+ ~ ((obj.table.column_aligns[col_idx] == "l")
? "left\"" : "right\""));
_table ~= "<"
~ _col_is
~ " width=\""
- ~ obj.table_column_widths[col_idx].to!string
+ ~ obj.table.column_widths[col_idx].to!string
~ "%\" "
~ _align
~ ">";
@@ -375,7 +375,7 @@ template SQLiteFormatAndLoadObject() {
</table>
%s
</p>¶",
- obj.is_a,
+ obj.typeinfo.is_a,
_txt,
_note
);
@@ -888,12 +888,12 @@ template SQLiteInsertDocObjectsLoop() {
);
¶",
_metadata_tid,
- obj.ocn,
+ obj.node.ocn,
SQLinsertDelimiter!()(obj_txt["text"]),
SQLinsertDelimiter!()(obj_txt["html"]),
- obj.heading_lev_markup,
- obj.is_of,
- obj.is_a,
+ obj.node.heading_lev_markup,
+ obj.typeinfo.is_of,
+ obj.typeinfo.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.of_part) {
+ switch (obj.typeinfo.of_part) {
case "frontmatter": assert(part == "head", part);
- switch (obj.is_of) {
+ switch (obj.typeinfo.is_of) {
case "para":
- switch (obj.is_a) {
+ switch (obj.typeinfo.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.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.is_of);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of);
}
break;
}
break;
case "body": // assert(part == "body", part); // TODO broken
- switch (obj.is_of) {
+ switch (obj.typeinfo.is_of) {
case "para":
- switch (obj.is_a) {
+ switch (obj.typeinfo.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.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
}
break;
}
break;
case "block":
- switch (obj.is_a) {
+ switch (obj.typeinfo.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.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.is_of);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of);
}
break;
}
break;
case "backmatter":
assert(part == "glossary" || "bibliography" || "bookindex_seg" || "blurb" || "tail", part);
- switch (obj.is_of) {
+ switch (obj.typeinfo.is_of) {
case "para":
- switch (obj.is_a) {
+ switch (obj.typeinfo.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.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
}
break;
}
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.is_of);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_of);
}
break;
}
@@ -1021,28 +1021,28 @@ template SQLiteInsertDocObjectsLoop() {
break;
default:
if ((doc_matters.opt.action.debug_do)) {
- writeln(__FILE__, ":", __LINE__, ": ", obj.of_part); // check where empty value could come from
- writeln(__FILE__, ":", __LINE__, ": ", obj.is_a);
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.of_part); // check where empty value could come from
+ writeln(__FILE__, ":", __LINE__, ": ", obj.typeinfo.is_a);
writeln(__FILE__, ":", __LINE__, ": ", obj.text); // check where empty value could come from
}
break;
}
- if (obj.is_a == "heading") {
+ if (obj.typeinfo.is_a == "heading") {
if ((doc_matters.opt.action.verbose)) {
writeln(
- "markup: ", obj.heading_lev_markup,
- "> ", obj.dom_markedup,
- "; collapsed: ", obj.heading_lev_collapsed,
- "> ", obj.dom_collapsed,
- "; ocn: ", obj.ocn,
- " node: ", obj.node,
- "; parent: ", obj.parent_lev_markup,
- "; ocn: ", obj.parent_ocn,
+ "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,
"; ",
);
}
}
- if (!(obj.is_a == "comment")) {
+ if (!(obj.typeinfo.is_a == "comment")) {
_insert_doc_objects ~= insertDocObjectsRow(obj);
}
} // loop closes