Class instance calls [ex.=> x()] require a structured text
structure. Doc will then parse each paragraph in the structure
and will find the special structures within each paragraph.
Each special structure will be stored as an instance. Special
structures within another special structure are stored within
the top
structure
EX : -underline this-
=> would be turned into an underline
instance. -underline **this**
would be stored as an underline
instance with a strong instance stored in its string
There are no implemented interfaces.
paragraph_types
(type:
list
)
['doc_bullet', 'doc_numbered', 'doc_description', 'doc_header', 'doc_table']
text_types
(type:
list
)
['doc_literal', 'doc_sgml', 'doc_inner_link', 'doc_named_link', 'doc_href1', 'doc_href2', 'doc_strong', 'doc_emphasize', 'doc_underline', 'doc_sgml', 'doc_xref']
color_paragraphs(raw_paragraphs, type=<type 'type'>, sequence_types=(<type 'list'>, <type 'tuple'>), sts=(<type 'str'>, <type 'unicode'>))
color_text(str, types=None)
Search the paragraph for each special structure
doc_bullet(paragraph, expr=<built-in method match of _sre.SRE_Pattern object at 0x418029b0>)
doc_description(paragraph, delim=<built-in method search of _sre.SRE_Pattern object at 0x417abdf0>, nb=<built-in method search of _sre.SRE_Pattern object at 0x417efb60>)
doc_emphasize(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8a19728>)
doc_header(paragraph)
doc_href(s, expr, punctuation=<built-in method match of _sre.SRE_Pattern object at 0x417bdb80>)
doc_href1(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x4172b760>)
doc_href2(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8a1a318>)
doc_inner_link(s, expr1=<built-in method search of _sre.SRE_Pattern object at 0x417ad7a0>, expr2=<built-in method search of _sre.SRE_Pattern object at 0x417c4320>)
doc_literal(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8a194d0>)
doc_named_link(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x41714980>)
doc_numbered(paragraph, expr=<built-in method match of _sre.SRE_Pattern object at 0x41805020>)
doc_sgml(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8491390>)
SGML text is ignored and outputed as-is
doc_strong(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8a19b28>)
doc_table(paragraph, expr=<built-in method match of _sre.SRE_Pattern object at 0x417abd88>)
doc_underline(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x8a19908>)
doc_xref(s, expr=<built-in method search of _sre.SRE_Pattern object at 0x41804ce0>)
parse(raw_string, text_type, type=<type 'type'>)
Parse accepts a raw_string, an expr to test the raw_string, and the raw_string's subparagraphs.
Parse will continue to search through raw_string until all instances of expr in raw_string are found.
If no instances of expr are found, raw_string is returned. Otherwise a list of substrings and instances is returned