aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/meta/object_setter.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2018-07-02 15:14:32 -0400
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:15 -0400
commitffc3747ff10f260a7ff3705681fdbaefc055e120 (patch)
tree64a98332894efdea4abead09512a48fd1af3c6f1 /src/sdp/meta/object_setter.d
parentobj.metainfo node type info, ancestors (diff)
cosmetic
Diffstat (limited to 'src/sdp/meta/object_setter.d')
-rw-r--r--src/sdp/meta/object_setter.d64
1 files changed, 16 insertions, 48 deletions
diff --git a/src/sdp/meta/object_setter.d b/src/sdp/meta/object_setter.d
index 09ce2ee..a60d2b7 100644
--- a/src/sdp/meta/object_setter.d
+++ b/src/sdp/meta/object_setter.d
@@ -22,34 +22,22 @@ template ObjectSetter() {
int o_n_book_index = 0;
int o_n_blurb = 0;
string object_number_substantive() const @property {
- return (o_n_substantive==0)
- ? ""
- : o_n_substantive.to!string;
+ return (o_n_substantive==0) ? "" : o_n_substantive.to!string;
}
string object_number_non_substantive() const @property {
- return (o_n_non_substantive==0)
- ? ""
- : o_n_non_substantive.to!string;
+ return (o_n_non_substantive==0) ? "" : o_n_non_substantive.to!string;
}
string object_number_glossary() const @property {
- return (o_n_glossary==0)
- ? ""
- : o_n_glossary.to!string;
+ return (o_n_glossary==0) ? "" : o_n_glossary.to!string;
}
string object_number_bibliography() const @property {
- return (o_n_bibliography==0)
- ? ""
- : o_n_bibliography.to!string;
+ return (o_n_bibliography==0) ? "" : o_n_bibliography.to!string;
}
string object_number_book_index() const @property {
- return (o_n_book_index==0)
- ? ""
- : o_n_book_index.to!string;
+ return (o_n_book_index==0) ? "" : o_n_book_index.to!string;
}
string object_number_blurb() const @property {
- return (o_n_blurb==0)
- ? ""
- : o_n_blurb.to!string;
+ return (o_n_blurb==0) ? "" : o_n_blurb.to!string;
}
string object_number_off = "";
bool visible_object_number = false;
@@ -59,9 +47,7 @@ template ObjectSetter() {
string[string][string] node;
int ocn = 0;
string object_number() const @property {
- return (ocn==0)
- ? ""
- : ocn.to!string;
+ return (ocn==0) ? "" : ocn.to!string;
}
int o_n_type = 0;
int heading_lev_markup = 9;
@@ -69,33 +55,15 @@ template ObjectSetter() {
string marked_up_level() const @property {
string _out;
switch (heading_lev_markup) {
- case 0:
- _out = "A";
- break;
- case 1:
- _out = "B";
- break;
- case 2:
- _out = "C";
- break;
- case 3:
- _out = "D";
- break;
- case 4:
- _out = "1";
- break;
- case 5:
- _out = "2";
- break;
- case 6:
- _out = "3";
- break;
- case 7:
- _out = "4";
- break;
- default:
- _out = "";
- break;
+ case 0: _out = "A"; break;
+ case 1: _out = "B"; break;
+ case 2: _out = "C"; break;
+ case 3: _out = "D"; break;
+ case 4: _out = "1"; break;
+ case 5: _out = "2"; break;
+ case 6: _out = "3"; break;
+ case 7: _out = "4"; break;
+ default: _out = ""; break;
}
return _out;
}