compared with
Version 3 by Boris Guéry
on Mar 01, 2011 06:45.

This line was removed.
This word was removed. This word was added.
This line was added.

Changes (29)

View Page History
{info:title=New Proposal Template}
This page has been created from a template that uses "zones." To proceed:

Zend_Magic Zend_Markup_Parser_Markdown

[My Name|]
[Boris Guéry|]

1.0 - 1 January 2008: Initial Draft.
0.1 - 1 March 2011: Initial Draft.

Zend_Magic is a simple component that reads my mind and generates code dynamically to do what I want.
Zend_Markup_Parser_Markdown is a parser for the wiki markup Markdown.

* [Harry Houdini Wikipedia Entry|]
* [|]
* [Official Markdown website|]
* [Python Implentation of Markdown|]
* [Wikipedia|]
* [Some article on the writting of a Markdown parser|]
* [PHP implentation of Markdown|]

Most requirements take the form of "foo will do ...." or "foo will not support ...", although different words and sentence structure might be used. Adding functionality to your proposal is requirements creep (bad), unless listed below. Discuss major changes with your team first, and then open a "feature improvement" issue against this component.

* This component *will* correctly reads a developers mind for intent and generate the right configuration file.
* The generated config file *will not* support XML, but will provide an extension point in the API.
* This component *will* use no more memory than twice the size of all data it contains.
* This component *will* parse Markdown accordingly to the [official Markdown syntax|]
* This component *will* fill a Zend_Markup_TokenList
* This component *would* supports Markdown Extra (Extra markup for uncommon elements)
* This component *will* not be aware of the renderer
* This component *will* include a factory method. implement Zend_Markup_Parser_ParserInterface
* This component *will not* allow subclassing. (i.e. when reviewed, we expect to see "final" keyword in code)
* This component *will* only generate data exports strictly complying with RFC 12345.
* This component *will* validate input data against formats supported by ZF component Foo.
* This component *will not* save any data using Zend_Cache or the filesystem. All transient data *will be* saved using Zend_Session.

* Zend_Exception Zend_Markup_Parser_ParserInterface
* Zend_Markup_Token
* Zend_Markup_TokenList

The component is instantiated with a mind-link that ...
The component is mainly provided to be used through Zend_Markup factory method to be rendered with any Zend_Markup_Renderer_*.
However, it could be used as is to return a Zend_Markup_Tokenlist tree instance.

Describe some intermediate state of this component in terms of design notes, additional material added to this page, and / code. Note any significant dependencies here, such as, "Milestone #3 can not be completed until feature Foo has been added to ZF component XYZ." Milestones will be required for acceptance of future proposals. They are not hard, and many times you will only need to think of the first three below.
* Milestone 1: [design notes will be published here|]
* Milestone 2: Working prototype checked into the incubator supporting use cases #1, #2, ...
* Milestone 4: Unit tests exist, work, and are checked into SVN.
* Milestone 5: Initial documentation exists.

If a milestone is already done, begin the description with "\[DONE\]", like this:
* Milestone #: \[DONE\] Unit tests ...

* Zend_Magic_Exception Zend_Magic_Parser_Markdown
* Zend_Magic (factory class)
* Zend_Magic_MindProbe
* Zend_Magic_MindProbe_Intent
* Zend_Magic_Action
* Zend_Magic_CodeGen


... (see good use cases book)
$markdown = <<<EOF
# Zend\_Markup\_Parser\_Markdown

## Requirements

* This component **will** parse Markdown accordingly to the [official Markdown syntax](
* This component **will** fill a Zend\_Markup\_TokenList
* This component **would** supports Markdown Extra (Extra markup for uncommon elements)
* This component **will** not be aware of the renderer
* This component **will** implement Zend\_Markup\_Parser\_ParserInterface

$m = Zend_Markup::factory('Markdown');
echo $m->render($markdown);

// result:



<li>This component <strong>will</strong> parse Markdown accordingly to the <a href="">official Markdown syntax</a></li>
<li>This component <strong>will</strong> fill a Zend_Markup_TokenList</li>
<li>This component <strong>would</strong> supports Markdown Extra (Extra markup for uncommon elements)</li>
<li>This component <strong>will</strong> not be aware of the renderer</li>
<li>This component <strong>will</strong> implement Zend_Markup_Parser_ParserInterface</li>



class Zend_Magic_Exception extends Zend_Exception {}
class Zend_Markup_Parser_Markdown implements Zend_Markup_Parser_ParserInterface {}

class Zend_Magic {