<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Michael Wolbert's Blog &#187; Model Driven Software Development</title>
	<atom:link href="http://michaelwolbert.nl/blog/tag/model-driven-software-development/feed/" rel="self" type="application/rss+xml" />
	<link>http://michaelwolbert.nl/blog</link>
	<description></description>
	<lastBuildDate>Thu, 06 May 2010 12:44:32 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>World&#8217;s most tiny blogparser written in MGrammar</title>
		<link>http://michaelwolbert.nl/blog/2009/03/worlds-most-tiny-blogparser-written-in-mgrammar/</link>
		<comments>http://michaelwolbert.nl/blog/2009/03/worlds-most-tiny-blogparser-written-in-mgrammar/#comments</comments>
		<pubDate>Mon, 02 Mar 2009 16:50:16 +0000</pubDate>
		<dc:creator>Michael</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Microsoft Oslo]]></category>
		<category><![CDATA[Study]]></category>
		<category><![CDATA[Avanade]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[MGrammar]]></category>
		<category><![CDATA[Model Driven Software Development]]></category>

		<guid isPermaLink="false">http://michaelwolbert.nl/blog/?p=159</guid>
		<description><![CDATA[My first small parser I&#8217;ve written in MGrammar. Nothing fancy though..
I&#8217;ve defined the way I&#8217;d like to create my blogs, posts and blogrolls in a textual way:

Blog
    With Title OsloBlog
    Section Posts
        Post With Title MGrammar And Desc MGrammar
    [...]]]></description>
			<content:encoded><![CDATA[<p>My first small parser I&#8217;ve written in <a href="http://msdn.microsoft.com/en-us/library/dd129869.aspx" target="_self">MGrammar</a>. Nothing fancy though..</p>
<p>I&#8217;ve defined the way I&#8217;d like to create my blogs, posts and blogrolls in a textual way:</p>
<pre>
<div class="codesnip-container" >Blog
    With Title OsloBlog
    Section Posts
        Post With Title MGrammar And Desc MGrammar
        Post With Title Quadrant And Desc Quadrant
    End Section
    Section Blogroll
        Link With Title Oslo And Url http://microsoft.com
        Link With Title Michael And Url http://michaelwolbert.nl
    End Section
End Blog
Blog
    With Title MichaelBlog
    Section Posts
        Post With Title Avanade And Desc Ava
        Post With Title Testing123 And Desc Testing123456789
    End Section
End Blog</div>
</pre>
<p>With our grammar (parser) we can now create projections of our textual DSL:</p>
<pre>
<div class="codesnip-container" >Blog[
    Title[
      "MichaelBlog"
    ],
    Sections[
      Posts[
        Post[
          Title[
            "Avanade"
          ],
          Desc[
            "Ava"
          ]
        ],
        Post[
          Title[
            "Testing123"
          ],
          Desc[
            "Testing123456789"
          ]
        ]
      ]
    ]
  ]</div>
</pre>
<p>Next step would be to push this projections to Oslo&#8217;s repository (just a plain ol&#8217; SQL 2008 database), so a runtime can access it. We could also create a runtime which uses a set of classes to parse our textual DSL directly to the runtime. But that will be covered later on.</p>
<p>See this <a href="http://michaelwolbert.nl/blog/wp-content/uploads/2009/03/mgrammarblog.jpg" target="_self">Intellipad screenshot</a> for the textual DSL, the MGrammar and the projections (from L to R).</p>
<p>Some nice samples can be found in the <a href="http://msdn.microsoft.com/en-us/oslo/cc749619.aspx" target="_self">&#8220;M&#8221; Language Gallery</a>. Especially <a href="http://www.infoq.com/articles/natural-language-date-dsl-oslo">Natural Language Dates</a> has some good pointers to get started.</p>
]]></content:encoded>
			<wfw:commentRss>http://michaelwolbert.nl/blog/2009/03/worlds-most-tiny-blogparser-written-in-mgrammar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

