diff options
author | Ralph Amissah <ralph@amissah.com> | 2016-06-29 22:28:53 -0400 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2019-04-04 14:48:18 -0400 |
commit | 1d30d4b2225be7f152de94b007d81a5d7b7a1c3a (patch) | |
tree | 36a5a30d607b4ace9d9be006700d98fcf1a16f34 /src/sdp/ao_defaults.d | |
parent | registers, minor cleaning (diff) |
associated array instead of json
Diffstat (limited to 'src/sdp/ao_defaults.d')
-rw-r--r-- | src/sdp/ao_defaults.d | 229 |
1 files changed, 147 insertions, 82 deletions
diff --git a/src/sdp/ao_defaults.d b/src/sdp/ao_defaults.d index dda08f7..f344fe7 100644 --- a/src/sdp/ao_defaults.d +++ b/src/sdp/ao_defaults.d @@ -3,89 +3,146 @@ ao_defaults.d +/ template SiSUregisters() { - string make_jsonstr = `{ - "make": { - "bold" : "", - "breaks" : "", - "cover_image" : "", - "css" : "", - "emphasis" : "", - "footer" : "", - "headings" : "", - "home_button_image" : "", - "home_button_text" : "", - "italics" : "", - "num_top" : "", - "substitute" : "", - "texpdf_font" : "" - } - }`; - auto meta_jsonstr = `{ - "classify": { - "dewey" : "", - "keywords" : "", - "loc" : "", - "subject" : "", - "topic_register" : "" - }, - "creator": { - "author" : "", - "author_email" : "", - "illustrator" : "", - "translator" : "" - }, - "date": { - "added_to_site" : "", - "available" : "", - "created" : "", - "issued" : "", - "modified" : "", - "published" : "", - "valid" : "" - }, - "identifier": { - "isbn" : "", - "oclc" : "", - "pg" : "" - }, - "links": { - "link" : "" - }, - "notes": { - "abstract" : "", - "description" : "" - }, - "original": { - "language" : "", - "source" : "", - "title" : "" - }, - "publisher": { - "name" : "" - }, - "rights": { - "copyright" : "", - "cover" : "", - "illustrations" : "", - "license" : "" - }, - "title": { - "edition" : "", - "full" : "", - "language" : "", - "main" : "", - "note" : "", - "sub" : "" - } - }`; // links - auto pointer_head_sub_classify = - [ - "dewey", - "keywords", // - "loc", - "subject", - "topic_register" + string[string][string] conf_aa() { + auto conf_ = [ + "webserv": [ + "url_root" : "", + "path" : "~/sdp_www" , + "images" : "" , + "cgi" : "/usr/local/lib/sdp-cgi" + ], + "webserv_cgi": [ + "host" : "localhost", + "base_path" : "", + "port" : "8081", + "user" : "", + "file_links" : "www.sisudoc.org" + ], + "processing": [ + "path" : "~", + "dir" : "_sisu_processing", + "concord_max" : "400000" + ], + "flag": [ + "act0" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --xhtml --xml-sax --xml-dom --sqlite --manifest --verbose", + "act1" : "--digest --text --html --manifest", + "act2" : "--digest --text --html --epub --pdf --manifest", + "act3" : "--digest --qrcode --text --html --epub --concordance --pdf --manifest", + "act4" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --manifest", + "act5" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --sqlite --manifest", + "act6" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --xhtml --xml-sax --xml-dom --sqlite --manifest", + "act7" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --xhtml --xml-sax --xml-dom --sqlite --source --sisupod --manifest", + "act8" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --xhtml --xml-sax --xml-dom --pg --update --manifest", + "act9" : "--digest --qrcode --text --html --epub --concordance --pdf --odf --docbook --xhtml --xml-sax --xml-dom --pg --update --source --sisupod --manifest" + ], + "default": [ + "papersize" : "a4,letter", + "text_wrap" : "78", + "emphasis" : "bold", + "language" : "en", + "digest" : "sha256" + ], + "permission": [ + "share_source" : "" + ], + "program_select": [ + "editor" : "vim", + "epub_viewer" : "ebook-viewer", + "html_viewer" : "xombrero", + "odf_viewer" : "lowriter", + "pdf_viewer" : "evince", + "xml_viewer" : "xml-viewer" + ], + "search": [ + "flag" : "", + "action" : "", + "db" : "", + "title" : "" + ] ]; + return conf_; + } + string[string][string] make_aa() { + auto make_ = [ + "make": [ + "bold" : "", + "breaks" : "", + "cover_image" : "", + "css" : "", + "emphasis" : "", + "footer" : "", + "headings" : "", + "home_button_image" : "", + "home_button_text" : "", + "italics" : "", + "num_top" : "", + "substitute" : "", + "texpdf_font" : "" + ] + ]; + return make_; + } + string[string][string] meta_aa() { + auto meta_ = [ + "classify": [ + "dewey" : "", + "keywords" : "", + "loc" : "", + "subject" : "", + "topic_register" : "" + ], + "creator": [ + "author" : "", + "author_email" : "", + "illustrator" : "", + "translator" : "" + ], + "date": [ + "added_to_site" : "", + "available" : "", + "created" : "", + "issued" : "", + "modified" : "", + "published" : "", + "valid" : "" + ], + "identifier": [ + "isbn" : "", + "oclc" : "", + "pg" : "" + ], + "links": [ + "link" : "" + ], + "notes": [ + "abstract" : "", + "description" : "" + ], + "original": [ + "language" : "", + "source" : "", + "title" : "" + ], + "publisher": [ + "name" : "" + ], + "rights": [ + "copyright" : "", + "cover" : "", + "illustrations" : "", + "license" : "" + ], + "title": [ + "edition" : "", + "full" : "", + "language" : "", + "main" : "", + "note" : "", + "sub" : "" + ] + ]; + return meta_; + } auto pointer_head_main = [ "classify", @@ -99,6 +156,14 @@ template SiSUregisters() { "rights", "title" ]; + auto pointer_head_sub_classify = + [ + "dewey", + "keywords", + "loc", + "subject", + "topic_register" + ]; auto pointer_head_sub_creator = [ "author", |