1
0
mirror of https://github.com/erusev/parsedown.git synced 2023-08-10 21:13:06 +03:00

improve comments

This commit is contained in:
Emanuil Rusev 2014-01-25 18:47:44 +02:00
parent c7b6d0235d
commit 65ef541fda

View File

@ -16,7 +16,7 @@
class Parsedown class Parsedown
{ {
# #
# Multiton (http://en.wikipedia.org/wiki/Multiton_pattern) # Multiton
static function instance($name = 'default') static function instance($name = 'default')
{ {
@ -41,7 +41,7 @@ class Parsedown
private $breaks_enabled = false; private $breaks_enabled = false;
# #
# Enable GFM line breaks. # Enables GFM line breaks.
function set_breaks_enabled($breaks_enabled) function set_breaks_enabled($breaks_enabled)
{ {
@ -57,11 +57,16 @@ class Parsedown
private $reference_map = array(); private $reference_map = array();
# #
# Actions # Methods
# #
# #
# Convert Markdown to HTML. # Parsedown recognises that Markdown is optimised to be easy-to-read by
# humans, so it tries to read it the way humans do.
#
# First, it breaks texts into lines. Then, it looks at how these lines start
# and relate to each other. Finally, it looks for special characters to
# identify inline elements.
function parse($text) function parse($text)
{ {
@ -88,7 +93,7 @@ class Parsedown
} }
# #
# Methods # Private
# #
private function parse_block_elements(array $lines, $context = '') private function parse_block_elements(array $lines, $context = '')