From 41139a3438a6dfd3f52ed4cd3e0e7e70ffb01f96 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Fri, 4 Mar 2016 15:06:34 -0500 Subject: track --- org/ao_markup_source_raw.org | 98 -------------------------------------------- 1 file changed, 98 deletions(-) delete mode 100644 org/ao_markup_source_raw.org (limited to 'org/ao_markup_source_raw.org') diff --git a/org/ao_markup_source_raw.org b/org/ao_markup_source_raw.org deleted file mode 100644 index 5923116..0000000 --- a/org/ao_markup_source_raw.org +++ /dev/null @@ -1,98 +0,0 @@ -#+TITLE: sdp markup source raw -#+AUTHOR: Ralph Amissah -#+EMAIL: ralph.amissah@gmail.com -#+STARTUP: indent -#+LANGUAGE: en -#+OPTIONS: H:3 num:nil toc:t \n:nil @:t ::t |:t ^:nil -:t f:t *:t <:t -#+OPTIONS: TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:not-in-toc -#+OPTIONS: author:nil email:nil creator:nil timestamp:nil -#+OPTIONS: ^:nil _:nil -#+EXPORT_SELECT_TAGS: export -#+EXPORT_EXCLUDE_TAGS: noexport -#+FILETAGS: :sdp:ao: -#+TAGS: assert(a) class(c) debug(d) mixin(m) sdp(s) tangle(T) template(t) WEB(W) noexport(n) - -* markup source raw :markup: -[[./sdp.org][sdp]] - -** source string :string: -#+name: ao_markup_source_raw -#+BEGIN_SRC d :exports none -final private string markupSourceString(in char[] fn_src) { - enforce( - exists(fn_src)!=0, - "file not found" - ); - string source_txt_str; - try { - if (exists(fn_src)) { - source_txt_str = readText(fn_src); // ok - } - } - catch (ErrnoException ex) { - // Handle errors - } - catch (UTFException ex) { - // Handle validation errors - } - catch (FileException ex) { - // Handle errors - } - std.utf.validate(source_txt_str); - return source_txt_str; -} -#+END_SRC - -** source line array :array: -#+name: ao_markup_source_raw -#+BEGIN_SRC d :exports none -final private char[][] markupSourceLineArray(in string src_text) { - char[][] source_line_arr = - split(cast(char[]) src_text, rgx.line_delimiter); - return source_line_arr; -} -#+END_SRC - -** insert source content raw line array :array: -#+name: ao_markup_source_raw -#+BEGIN_SRC d :exports none -final char[][] markupInsertSourceContentRawLineArray(in char[] fn_src) { - enforce( - match(fn_src, rgx.src_fn_find_inserts), - "not a sisu markup filename" - ); - auto source_txt_str = markupSourceString(fn_src); - auto source_line_arr = markupSourceLineArray(source_txt_str); - return source_line_arr; -} -#+END_SRC - -** source content raw line array :array: -#+name: ao_markup_source_raw -#+BEGIN_SRC d :exports none -final char[][] markupSourceContentRawLineArray(in char[] fn_src) { - enforce( - match(fn_src, rgx.src_pth), - "not a sisu markup filename" - ); - auto source_txt_str = markupSourceString(fn_src); - auto source_line_arr = markupSourceLineArray(source_txt_str); - return source_line_arr; -} -#+END_SRC - -* tangles :tangle: -** code structure: :ao_markup_source_raw.d: -#+name: tangle_ao_markup_source_raw -#+BEGIN_SRC d :tangle ../lib/sdp/ao_markup_source_raw.d :padline no :exports none :noweb yes -/* - markup source raw - ao_markup_source_raw.d -*/ -mixin template SiSUmarkupRaw() { - class MarkupRaw { - auto rgx = new Rgx(); - <> - } -} -#+END_SRC -- cgit v1.2.3