<?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>The Metalevel &#187; DSL</title>
	<atom:link href="http://pjmolina.com/metalevel/category/dsl/feed/" rel="self" type="application/rss+xml" />
	<link>http://pjmolina.com/metalevel</link>
	<description>Abstraction based levitation</description>
	<lastBuildDate>Tue, 17 Jan 2012 20:22:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>¡Hola Sevilla!</title>
		<link>http://pjmolina.com/metalevel/2012/01/hola-sevilla/</link>
		<comments>http://pjmolina.com/metalevel/2012/01/hola-sevilla/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 19:30:04 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[Icinetic]]></category>
		<category><![CDATA[Sevilla]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=767</guid>
		<description><![CDATA[&#160; Model Driven Development is one of my favourite research topics. That’s why when the Icinetic guys contacted and offer me to join them to work together I had few arguments to resist the temptation and enroll. Therefore, today I’m moving to Sevilla, in the south of Spain, to start a new phase of my life to [...]]]></description>
			<content:encoded><![CDATA[<div class="wp-caption aligncenter" style="width: 510px"><img title="Plaza de España, Sevilla" src="http://farm2.staticflickr.com/1351/5158639564_79ed587a54.jpg" alt="" width="500" height="327" /><p class="wp-caption-text">Plaza de España, Sevilla (By CCSA Tom Raftery)</p></div>
<p>&nbsp;</p>
<div>
<p><strong>Model Driven Development</strong> is one of my favourite research topics. That’s why when the <a href="http://www.icinetic.com/">Icinetic</a> guys contacted and offer me to join them to work together I had few arguments to resist the temptation and enroll.</p>
<p>Therefore, today I’m moving to <strong>Sevilla</strong>, in the south of Spain, to start a new phase of my life to work as the Chief Research Officer. Icinetic is an young MDD tool-maker and consultancy company.</p>
<p>I am quite excited to have the chance, the tools and the right team (both with the required business vision and the technical background) to focus on innovation and to create cool MDD &amp; code generation tools.</p>
<p>We are going to enjoy it, for sure!</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2012/01/hola-sevilla/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Modelling the User Interface, the video</title>
		<link>http://pjmolina.com/metalevel/2011/10/modelling-the-user-interface-the-video/</link>
		<comments>http://pjmolina.com/metalevel/2011/10/modelling-the-user-interface-the-video/#comments</comments>
		<pubDate>Wed, 26 Oct 2011 22:24:55 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[User Interface]]></category>
		<category><![CDATA[modeling]]></category>
		<category><![CDATA[ui]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=738</guid>
		<description><![CDATA[The recording of the Code Generation 2011 session about &#8216;Modelling the User Interface&#8217; is finally available online at InfoQ. For further details take a look to the slides and Conceptual User Interface Patterns. During the video you can see a pair of demos:  Essential on action doing full UI inference and code generation and IO, the codename for a [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright" title="InfoQ" src="http://cdn2.infoq.com/styles/i/logo-infoq.gif" alt="" width="127" height="38" />The recording of the Code Generation 2011 <a title="Session details" href="http://www.codegeneration.net/cg2011/sessioninfo.php?session=14" target="_blank">session</a> about <em>&#8216;Modelling the User Interface&#8217;</em> is finally available online at <a title="Modelling the User Interface" href="http://www.infoq.com/presentations/Modeling-the-User-Interface" target="_blank">InfoQ</a>.</p>
<p>For further details take a look to the <a title="Modelling the User Interface" href="http://www.slideshare.net/pjmolina/modelling-the-user-interface" target="_blank">slides</a> and <a title="Conceptual User Interface Patterns" href="http://pjmolina.com/cuip" target="_blank">Conceptual User Interface Patterns</a>.</p>
<p>During the video you can see a pair of demos:</p>
<ul>
<li> <a title="Essential" href="http://pjmolina.com/metalevel/essential/" target="_blank">Essential</a> on action doing full UI inference and code generation</li>
<li>and IO, the codename for a new proof of concept UI specification and WYSIWYG prototyping tool.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2011/10/modelling-the-user-interface-the-video/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Essential on Alt.Net Hispano</title>
		<link>http://pjmolina.com/metalevel/2011/07/essential-on-alt-net-hispano/</link>
		<comments>http://pjmolina.com/metalevel/2011/07/essential-on-alt-net-hispano/#comments</comments>
		<pubDate>Sun, 03 Jul 2011 08:46:15 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=723</guid>
		<description><![CDATA[The Alt.NET Hispano group has published my VAN about Code generation with Essential. The recording was done in Spanish. La comunidad Alt.NET Hispano ha publicado la VAN (desconferencia) sobre Generación de código con Essential que tuvimos el pasado dia 11 de junio. Si estás interesado en MDD, generación de código y como aplicarlo con Essential, [...]]]></description>
			<content:encoded><![CDATA[<p>The <a title="Alt.NET Hispano" href="http://altnethispano.org">Alt.NET Hispano</a> group has published my VAN about <a title="Generación de Código con Essential" href="http://altnethispano.org/wiki/van-2010-05-28-generacion-de-codigo-con-essential.ashx">Code generation with Essential</a>. The recording was done in Spanish.</p>
<p>La comunidad Alt.NET Hispano ha publicado la VAN (desconferencia) sobre <a title="Generación de código con Essential" href="http://altnethispano.org/wiki/van-2010-05-28-generacion-de-codigo-con-essential.ashx">Generación de código con Essential</a> que tuvimos el pasado dia 11 de junio. Si estás interesado en MDD, generación de código y como aplicarlo con Essential, este video grabado para la comunidad en español es un buen punto de partida.</p>
<p>Mi agradecimiento a Alt.NET Hispano por el interés en la materia y la invitación a divulgarlo.</p>
<p><a title="Descarga directa: Essential Video" href="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/van-2011-06-11.flv?downloadOnly=true">Descarga directa del video</a> (562 Mb).</p>
<p>&nbsp;</p>
<p><span id="more-723"></span></p>
<p><object id="scPlayer" width="700" height="468" data="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/flvplayer.swf" type="application/x-shockwave-flash"><param name="movie" value="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/flvplayer.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#FFFFFF" /><param name="flashVars" value="thumb=http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/FirstFrame.jpg&amp;containerwidth=800&amp;containerheight=468&amp;analytics=UA-21341284-1&amp;content=http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/van-2011-06-11.flv&amp;blurover=false" /><param name="allowFullScreen" value="true" /><param name="scale" value="showall" /><param name="allowScriptAccess" value="always" /><param name="base" value="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/" />Unable to display content. Adobe Flash is required.</object></p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2011/07/essential-on-alt-net-hispano/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/van-2011-06-11.flv&amp;amp" length="589272873" type="video/x-flv" />
<enclosure url="http://content.screencast.com/users/AltNetHispano/folders/VAN/media/512cfc98-8e47-48a2-8781-a22bf3f40af9/van-2011-06-11.flv?downloadOnly=true" length="589272873" type="video/x-flv" />
		</item>
		<item>
		<title>First public Essential 0.4.44 Beta!</title>
		<link>http://pjmolina.com/metalevel/2011/05/first-public-essential-beta/</link>
		<comments>http://pjmolina.com/metalevel/2011/05/first-public-essential-beta/#comments</comments>
		<pubDate>Wed, 11 May 2011 09:11:57 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[language workbench]]></category>
		<category><![CDATA[mdsd]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=681</guid>
		<description><![CDATA[The Code Generation 2011 conference and the Language Workbenches Competition 2011 Workshop are quite close in the calendar. I want to celebrate it with the MDD community sharing my work on Essential (a tool designed for acquiring speed with Model Driven Development). On 11th may 2011, version 0.4.44 has been released as the first public beta. Essential [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright" style="margin-left: 10px;" title="Essential Logo" src="/img/LogoEssential300px.png" alt="Essential Logo" width="180" height="99" /></p>
<p>The <a title="Code Generation 2011" href="http://www.codegeneration.net/cg2011/index.php">Code Generation 2011</a> conference and the <a title="LWC2011 Workshop" href="http://www.languageworkbenches.net/workshop.html">Language Workbenches Competition 2011 Workshop</a> are quite close in the calendar.</p>
<p>I want to celebrate it with the MDD community sharing my work on <strong><a title="Essential - MDD tool" href="http://pjmolina.com/metalevel/essential">Essential</a> </strong>(a tool designed for acquiring speed with Model Driven Development). On 11th may 2011, version 0.4.44 has been released as the<strong> first public beta</strong>.</p>
<p>Essential is a meta-modeling and code generation tool providing specific DSLs to define and consume:</p>
<ul>
<li>Metamodels</li>
<li>Models</li>
<li>Templates (using StringTemplate) &amp;</li>
<li>Transformations (Model2Text and Model2Model)</li>
</ul>
<div>With a strong emphasis on model interpretation, prototyping a code generation can be done in an agile way without the need of generating any infrastructure boilerplate or meta-editor plumbling accessories.</div>
<div>The main goals of the tools is to enable software architects to:</div>
<div>
<div>
<ul>
<li>Prototyping software directly from models in a unexpensive way</li>
<li>Evolve theirs software architectures as fast as possible experimenting with design choices</li>
<li>Benchmarking and comparing architectures</li>
<li>Code generation</li>
</ul>
</div>
</div>
<div>For all of you interested in, feel free to <a title="Essential evaluation version download" href="http://pjmolina.com/essential/download-eval/">try it</a>, enjoy and provide feedback.</div>
<p>Try it also with the sample projects created for the <a title="LWC2011 Essential sample models" href="http://code.google.com/p/lwc11-essential/downloads/list">LWC 2011 challenge</a>.</p>
<p><a title="Essential evaluation version download" href="http://pjmolina.com/essential/download-eval/"><img class="alignnone" title="Download Essential" src="/img/blue-box256.png" alt="" width="100" height="100" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2011/05/first-public-essential-beta/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting ready for CG2011</title>
		<link>http://pjmolina.com/metalevel/2011/04/getting-ready-for-cg2011/</link>
		<comments>http://pjmolina.com/metalevel/2011/04/getting-ready-for-cg2011/#comments</comments>
		<pubDate>Mon, 25 Apr 2011 17:56:03 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[User Interface]]></category>
		<category><![CDATA[cg2011]]></category>
		<category><![CDATA[lwc]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=676</guid>
		<description><![CDATA[Code Generation 2011 is the leading European conference on modeling and code generation. It&#8217;s a great opportunity to meet with the experts in the field and share the latest research in the area. The invited speakers this year are very, very interesting: Terrence Parr, well known by its work on teaching compiler construction and the [...]]]></description>
			<content:encoded><![CDATA[<p><a title="Code Generation 2011" href="http://www.codegeneration.net/cg2011"><img class="alignright" title="CG2011 logo" src="http://www.codegeneration.net/cg2011/images/cg2011-225x58.gif" alt="" width="225" height="58" /></a></p>
<p><a title="Code Generation 2011" href="http://www.codegeneration.net/cg2011">Code Generation 2011</a> is the leading European conference on modeling and code generation. It&#8217;s a great opportunity to meet with the experts in the field and share the latest research in the area.</p>
<p>The invited speakers this year are very, very interesting:</p>
<ul>
<li><a title="Terrence Parr" href="http://www.codegeneration.net/cg2011/keynotes.php#parr">Terrence Parr</a>, well known by its work on teaching compiler construction and the great tools <a title="ANTLR" href="http://www.antlr.org">ANTLR </a>and <a title="StringTemplate" href="http://www.stringtemplate.org">StringTemplate</a>, and</li>
<li><a title="Ed Merks" href="http://www.codegeneration.net/cg2011/keynotes.php#merks">Ed Merks</a>, the leader of the Eclipse Modeling Framework</li>
</ul>
<p>As a novelty, previous to the conference itself the first edition of the <a title="LWC 2011" href="http://www.codegeneration.net/cg2011/LWC-CG2011.php">Language Workbenches Competition</a> will take place on May 24<sup>th</sup> in the same venue.</p>
<p>In this edition, I will be there again, more active if ever, taking part with some activities:</p>
<ul>
<li>On May 24<sup>th</sup>, presenting <a title="Essential" href="http://pjmolina.com/metalevel/essential">Essential</a> in the scope of the <a title="LWC 2011" href="http://www.languageworkbenches.net/workshop.html">Language Workbenches Competition</a></li>
<li>On 25<sup>th</sup>, presenting on <a title="Introducing Model Driven Software Development" href="http://www.codegeneration.net/cg2011/sessioninfo.php?session=101">Introducing Model Driven Software Development </a></li>
<li>And, later on, taking part in the panel <a title="Build or buy - who should develop and own your DSLs and generators?" href="http://www.codegeneration.net/cg2011/sessioninfo.php?session=6">Build or Buy &#8211; who should develop and own your DSLs and generators?</a> organized by <a title="Juha-Pekka Tolvanen" href="http://www.metacase.com/blogs/jpt/blogView">Juha-Pekka Tolvanen</a> from <a title="Metacase" href="http://www.metacase.com">Metacase</a></li>
<li>Finally, on 26<sup>th</sup>, discussing about <a title="Modelling the User Interface" href="http://www.codegeneration.net/cg2011/sessioninfo.php?session=14">Modelling the User Interface</a></li>
</ul>
<p>As always, I’m looking forward to meet again the code generation community.</p>
<p>Take a look to the <a title="CG2011 Programme" href="http://www.codegeneration.net/cg2011/programme.php">full programme</a> and don’t miss the chance.</p>
<p>See you in Cambridge!</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2011/04/getting-ready-for-cg2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Essential submission to LWC11</title>
		<link>http://pjmolina.com/metalevel/2011/02/essential-submission-to-lwc11/</link>
		<comments>http://pjmolina.com/metalevel/2011/02/essential-submission-to-lwc11/#comments</comments>
		<pubDate>Fri, 25 Feb 2011 18:21:06 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[language worbench]]></category>
		<category><![CDATA[lwc]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=660</guid>
		<description><![CDATA[As blogged before, at CG2010 a group of interest came up with a proposal for creating a Language Workbenches Competition and the first edition will be taking place in Cambridge May 24th, just before CG2011. I submitted a proposal with Essential for participation in LWC11. It&#8217;s going to be a great forum for comparing language [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright" title="LWC11 - Essential" src="http://code.google.com/p/lwc11-essential/logo?cct=1298648794" alt="" width="153" height="47" />As <a title="LWC11" href="http://pjmolina.com/metalevel/2010/07/language-workbench-competition-2011/">blogged before</a>, at CG2010 a group of interest came up with a proposal for creating a <a title="Language Workbenches Competition" href="http://www.languageworkbenches.net/">Language Workbenches Competition</a> and the first edition will be taking place in Cambridge May 24th, just before <a title="CG2011" href="http://www.codegeneration.net/cg2011">CG2011</a>.</p>
<p>I submitted a <a href="http://lwc11-essential.googlecode.com/files/lwc11-essential.pdf">proposal</a> with <a title="Essential" href="http://pjmolina.com/metalevel/essential/">Essential</a> for participation in LWC11. It&#8217;s going to be a <strong>great forum for comparing language workbenches</strong> capabilities and the state of the art in the area. If interested, track the progress here <a href="http://www.languageworkbenches.net/submissions.html">LCW11</a>.</p>
<p>During the last weeks I&#8217;ve been working a little, replacing the old Microsoft Oslo dependencies to MGrammar inside Essential to an alternative parsing solution. The MS Oslo and later SQL Server Modeling never passed from the CTP stage and finally were discontinued. Therefore, I couldn&#8217;t ship a product in such conditions and finally decided to change it.</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2011/02/essential-submission-to-lwc11/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>StringTemplate: a great template engine for code generation</title>
		<link>http://pjmolina.com/metalevel/2010/11/stringtemplate-a-great-template-engine-for-code-generation/</link>
		<comments>http://pjmolina.com/metalevel/2010/11/stringtemplate-a-great-template-engine-for-code-generation/#comments</comments>
		<pubDate>Fri, 26 Nov 2010 00:34:34 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[cg2011]]></category>
		<category><![CDATA[stringtemplate]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=637</guid>
		<description><![CDATA[When building a new tool for modelling and code generation like Essential, one has to rethink again what template engine use to drive all the machinery. In code generation contexts, template engines are a good field for innovation and your choice will be with you probably for the full lifetime of your tool. In this [...]]]></description>
			<content:encoded><![CDATA[<div>
<p><img class="aligncenter" title="Paper Templates, licensed CC Attribution by Edinburgh City of Print" src="http://farm3.static.flickr.com/2581/4203670446_ef6f914933.jpg" alt="Paper Templates, licensed CC Attribution by Edinburgh City of Print" width="500" height="213" /></p>
<p>When building a new tool for modelling and code generation like <a title="Essential / MDD tool" href="http://pjmolina.com/metalevel/essential/" target="_blank">Essential</a>, one has to rethink again what template engine use to drive all the machinery. In code generation contexts, template engines are a good field for innovation and your choice will be with you probably for the full lifetime of your tool.</p>
<p>In this post, I will try to introduce and explain why <a title="StringTemplate" href="http://www.stringtemplate.org/" target="_blank">StringTemplate</a> is a superb engine for doing code generation and why you should consider it if dealing with a code generation scenario.<span id="more-637"></span></p>
<p>As commented before in <a title="Selecting a template engine for code generation" href="http://pjmolina.com/metalevel/2009/06/choosing-a-template-engine-for-code-generation/" target="_blank">other post</a>, I felt in love with StringTemplate in 2005 when I discovered <a title="ANTLR" href="http://www.antlr.org/" target="_blank">ANTLR</a> and StringTemplate during the development of a MDD workbench for a customer. Prior to that date, I had tested many template engines and also developed on my own a pair of them. For one reason or another, I was not comfortable with the language, the coupling of the template with the transformation control, or the maintainability of the templates in the long term. As the time goes by, this last point arises as crucial to maintain and evolve your architecture.</p>
<p>Therefore, one could say that I am being quite loyal to StringTemplate for the last 5 years, and that too much for technology, moreover, for a product software. And such loyalty is definitely not my merit for not been promiscuous in this issue, but a merit of StringTemplate: I’m still looking for new ways for improvement and didn’t find one better to my needs. (<em>Note: this is probably the best compliment I never paid to a piece of good software.</em>)</p>
<p>Some products shine thanks to the many features they provides, StringTemplate sparkles for avoiding adding features in the wrong place. I will elaborate a bit more on that.</p>
<h2><span style="font-weight: normal;">MVC</span></h2>
<p><strong><a title="Model View Controller Pattern" href="http://en.wikipedia.org/wiki/Model%E2%80%93View%E2%80%93Controller" target="_blank">Model View Controller</a></strong> is an old and good “classic” architectural pattern providing a solution to organize the pieces of a user interface. Originally proposed by <a title="Trygve Reenskaug" href="http://en.wikipedia.org/wiki/Trygve_Reenskaug" target="_blank">Trygve Reenskaug</a>, in Smalltalk in 1979. It has been lately again on fashion, especially in the building of web sites, multi-channel user interfaces and promoting UI testability thanks to the application of the principle of <a title="Separation of Concerns" href="http://en.wikipedia.org/wiki/Separation_of_concerns" target="_blank">Separation of Concerns</a> that the pattern provides.</p>
<p>There are many variants or dialects to MVC out there, but the simple one is enough to describe our scenario: code generation.</p>
<p>Code generation can be seen as a classic MVC domain with the three roles easily identifiable:</p>
<ul>
<li><strong>A model</strong>: the variable data in consideration, the metadata to be generated in this case.</li>
<li><strong>A view</strong>: the template with the form of the target language and providing holes or slots to be later being fill in (the output).</li>
<li>And the transformation <strong>controller</strong>: the piece in charge of selecting with model parts should be selected, combine and finally inserted in which template holes/slots to render the final and concrete view.</li>
</ul>
<p>The main problem with traditional template engines is that there are lots of template engines that mix the last two roles (for example all coming from web development in the flavour of JSP or  ASP variants). The view and the transformation controller are intermingled and this situation, in the long time, is not good. I found this strict separation of responsibilities crucial for the maintainability of the templates.</p>
<p>And StringTemplate does exactly that. It syntax and features, although could be strange for the first time, was carefully selected to not allow you to do control choices in the view. It allows to define templates, declare named holes (or slots) and an inline for-each and if statements.</p>
<p>Let’s review a basic sample of StringTemplate syntax:</p>
<pre class="brush:c-sharp;">group mail;

genMail(msg)::=&lt;&lt;
Mail: Subject $msg.Subject$
From: $msg.From:genAddress()$
To: $msg.To:genAddress(); separator=”, “$
&gt;&gt;

genAddress()::=&lt;&lt;$it.Name$ ($it.Email$)&gt;&gt;</pre>
<p>The sample contains two templates: one for a mail, and a second one for each address. Templates can have parameters explicit parameters like name, but also there is an implicit keyword (it) to reference the current iterating context.</p>
<p>Named holes or slots are defined are marked with $expression$ where expression is a constrained expression resolution of the model properties received.</p>
<p>In the sample, genAddress() template will be invoked to resolve the From and To properties. Assuming that <strong>From</strong> is a monovaluated property and that <strong>To</strong> is a list, the template iterates throw the collection received and evaluates the template for each item. Note the separator modifier used to describe how items should be rendered.</p>
<p>That’s all in the template, the view. It’s forbidden to compute any value inside the template. The idea is that only read operations are going to be done into the model to get the data needed to fill the template.</p>
<h2>How to consume the template?</h2>
<p>From the transformation side (the controller) consuming a template is something such straightforward as the following one:</p>
<pre class="brush:c-sharp;">//1. Select the template
StringTemplate tlp = group.InstanceOf(“genMail”);
//2. Set parameters
tlp.setAttribute(“msg”, message);
//3. Get the result
string result = tlp.ToString();</pre>
<p>It is frequent to find people complaining StringTemplate about not having enough freedom for example to call functions from the inside. But this is not a missing feature, this done on purpose to assure no side effects of such computations. The motto is; if you need to compute something, do it the transformation stage.</p>
<p>This only has covered a very basic intro to StringTemplate. If you are interested you can browse for more contents in the main documentation of StringTemplate.</p>
<p>Of course, <a title="Essential" href="http://pjmolina.com/metalevel/essential/" target="_blank">Essential</a> uses StringTemplate!</p>
<h2>ST &amp; ANTRL on Code Generation 2011</h2>
<p>By the way, the father of StringTemplate and the superb meta-compiler tool called ANTLR is <a title="Terrence Parr" href="http://www.antlr.org/wiki/display/~admin/Home" target="_blank">Terrence Parr</a>. He teaches compiler construction in the <a title="University of San Francisco" href="http://www.cs.usfca.edu/" target="_blank">University of San Francisco</a>.</p>
<p>I was planning to prepare this post for some months, but in the meanwhile, <a title="Mark Dalgarno's blog" href="http://blog.software-acumen.com/" target="_blank">Mark Dalgarno</a> (the main organizer of Code Generation Conferences) has surprises us announcing the next keynote for CG2011.</p>
<p>I am quite happy to see that, as announced by Mark, that in the next edition of <a title="Terrence Parr" href="http://www.codegeneration.net/cg2011/keynotes.php" target="_blank">Code Generation 2011 Terrence is going to be present as one of the invited keynotes</a>!</p>
<p>So, if you are interested in all of these topics, join us and meet Terrence on May 25-27, 2011 in Cambridge, UK on <a title="Code Generation 2011" href="http://www.codegeneration.net/cg2011/" target="_blank">Code Generation 2011</a>.</p>
<p><a title="Call for spekers" href="http://www.codegeneration.net/cg2011/speak.php" target="_blank">The call for speakers for CG2011</a> is open till January 15<sup>th</sup> 2011.</p>
<p><strong>To know more:</strong></p>
<ol>
<li><a title="Enforing String MV in template engines" href="http://www.cs.usfca.edu/~parrt/papers/mvc.templates.pdf" target="_blank">Enforcing Strict Model-View Separation in Template Engines</a>, Terrence Parr</li>
<li><a title="StringTemplate" href="http://www.stringtemplate.org" target="_blank">StringTemplate</a></li>
<li><a title="ANTLR" href="http://www.antlr.org" target="_blank">ANTLR</a></li>
</ol>
</div>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2010/11/stringtemplate-a-great-template-engine-for-code-generation/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Hello World with Essential, the video</title>
		<link>http://pjmolina.com/metalevel/2010/07/hello-world-with-essential/</link>
		<comments>http://pjmolina.com/metalevel/2010/07/hello-world-with-essential/#comments</comments>
		<pubDate>Mon, 26 Jul 2010 15:19:47 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[mde]]></category>
		<category><![CDATA[mdsd]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=612</guid>
		<description><![CDATA[The Hello World sample is a nice starting point to show the syntax and capabilities of every new language. This test is also useful for code generators and Domain Specific Languages (DSLs) also as a proof of concept. Following this honorable tradition, I have created a video showing the capabilities of Essential: the tool I [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright" style="margin-left: 10px;" title="Essential Logo" src="/img/LogoEssential300px.png" alt="Essential Logo" width="180" height="99" /></p>
<p>The <a title="Hello World" href="http://en.wikipedia.org/wiki/Hello_world_program" target="_blank">Hello World sample</a> is a nice starting point to show the syntax and capabilities of every new language. This test is also useful for code generators and Domain Specific Languages (DSLs) also as a proof of concept.</p>
<p>Following this honorable tradition, I have created a video showing the capabilities of <strong><a title="Essential" href="http://pjmolina.com/metalevel/essential/">Essential</a></strong>: the tool I am working on for doing agile Model Driven Development.</p>
<p>In this 10 minutes video you will get a general idea of the DSL the language provides to create:</p>
<ul>
<li>metamodels</li>
<li>models</li>
<li>templates</li>
<li>and control transformations</li>
</ul>
<p>In order to see the details, jump to Vimeo, activate the High Definition mode (HD) and set full screen (sorry embebed version is not good enough).</p>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="500" height="281" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=13587681&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" /><embed type="application/x-shockwave-flash" width="500" height="281" src="http://vimeo.com/moogaloop.swf?clip_id=13587681&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p><a href="http://vimeo.com/13587681">Essential IDE &#8211; Hello World sample</a> from <a href="http://vimeo.com/user3817869">Pedro J. Molina</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>More info about it and 12 usage scenarios in the last Code Generation 2010 presentation about <a title="Tailored Code Generators" href="http://pjmolina.com/metalevel/2010/06/tailored-code-generators-at-cg2010/">Tailored Code Generators</a>.</p>
<p>Share your impressions!</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2010/07/hello-world-with-essential/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Language Workbench Competition 2011</title>
		<link>http://pjmolina.com/metalevel/2010/07/language-workbench-competition-2011/</link>
		<comments>http://pjmolina.com/metalevel/2010/07/language-workbench-competition-2011/#comments</comments>
		<pubDate>Sun, 25 Jul 2010 20:02:45 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[Code Generation]]></category>
		<category><![CDATA[DSL]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[language workbench]]></category>
		<category><![CDATA[lwc2011]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=617</guid>
		<description><![CDATA[Language Workbenches, as defined originally by Martin Fowler, are tools aiming to cope with DSL creation and code generation to increase the level of abstraction of software development. Currently, the main efforts on MDD, MDE, MDSD (model-driven-whatever you prefer&#8230;) are focused in the development of this kind of tools perceived as a hot research area for [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Language Workbenches</strong>, as defined originally by <a href="http://martinfowler.com/articles/languageWorkbench.html" target="_blank">Martin Fowler</a>, are tools aiming to cope with DSL creation and code generation to increase the level of abstraction of software development.</p>
<p>Currently, the main efforts on MDD, MDE, MDSD (model-driven-<em>whatever you prefer</em>&#8230;) are focused in the development of this kind of tools perceived as a hot research area for Software Engineering.</p>
<p>In this scenarion, Cambridge, at <a title="Code Generation 2010" href="http://www.codegeneration.net/cg2010/index.php">Code Generation 2010</a> was the perfect place for sparkling the idea of promoting a contest to show and compare the advances of different language workbenches.</p>
<p>The <strong><a title="Language Workbench Competition 2011" href="http://www.languageworkbenches.net/" target="_blank">Language Workbench Competition</a></strong> born with the objective to serve as a point of comparison between different tools in this exciting and fast moving area.</p>
<p>The competition is now open to the public. So anyone interested can enroll and implement the <a title="LWC2011 Challenge" href="http://www.delphino-consultancy.nl/lwc/LWCTask-1.0.pdf" target="_blank">proposed challenge</a> just published.</p>
<p>On the other hand, if you want to know more about Language Workbenches, modeling and code generation add this <a title="Language Workbench Competition" href="http://www.languageworkbenches.net/">page</a> to you bookmarks and come back in few months to see some proposals.</p>
<p>The promoters of the idea are: <a title="Markus Völter" href="http://www.voelter.de/" target="_blank">Markus Völter</a>, <a title="Eelco Visser" href="http://blog.eelcovisser.net/" target="_blank">Eelco Visser</a>, <a title="Steven Kelly" href="http://www.metacase.com/blogs/stevek/blogView" target="_blank">Steven Kelly</a>, <a title="Angelo Hulshout" href="http://www.hulshout.nl/" target="_blank">Angelo Hulshout</a>, <a title="Jos Warmer" href="http://www.modeldrivensoftware.net/profile/JosWarmer" target="_blank">Jos Warmer</a>, <a title="Bernhard Merkle" href="http://www.modeldrivensoftware.net/profile/BernhardMerkle" target="_blank">Bernhard Merkle</a>, <a title="Karsten Thoms" href="http://kthoms.wordpress.com/" target="_blank">Karsten Thoms</a> and <a title="Pedro J. Molina" href="http://pjmolina.com/metalevel/about/" target="_blank">myself</a>.</p>
<p>So this a <em>call to arms</em> but with sportsmanship!</p>
<p><a title="Angelo Hulshout" href="http://www.hulshout.nl/?p=491" target="_blank">Angelo</a> and <a title="Markus Völter" href="http://voelterblog.blogspot.com/2010/07/language-workbench-competition-2011.html" target="_blank">Markus</a> has already started the calling.</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2010/07/language-workbench-competition-2011/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Tailored Code Generators at CG2010</title>
		<link>http://pjmolina.com/metalevel/2010/06/tailored-code-generators-at-cg2010/</link>
		<comments>http://pjmolina.com/metalevel/2010/06/tailored-code-generators-at-cg2010/#comments</comments>
		<pubDate>Tue, 22 Jun 2010 22:52:15 +0000</pubDate>
		<dc:creator>Pedro J. Molina</dc:creator>
				<category><![CDATA[DSL]]></category>
		<category><![CDATA[Essential]]></category>
		<category><![CDATA[MDD]]></category>
		<category><![CDATA[cg2010]]></category>

		<guid isPermaLink="false">http://pjmolina.com/metalevel/?p=603</guid>
		<description><![CDATA[I presented the following talk: DSL and tool support for Tailored Code Generators at Code Generation 2010, at Cambridge, UK on June 18th. CG2010 Tailored Code Generators View more presentations from Pedro J. Molina. It also was the public presentation of Essential: the tooling supporting my approach for applying MDD. I got a very good [...]]]></description>
			<content:encoded><![CDATA[<p>I presented the following talk: <strong><a title="DSL and tool support for Tailored Code Generators" href="http://www.codegeneration.net/cg2010/sessioninfo.php?session=15" target="_blank">DSL and tool support for Tailored Code Generators</a></strong><strong> </strong> at <strong><a title="Code Generation 2010" href="http://www.codegeneration.net/cg2010/index.php" target="_blank">Code Generation 2010</a></strong>, at Cambridge, UK on June 18th.</p>
<div id="__ss_4579382" style="width: 425px;"><strong><a title="CG2010 Tailored Code Generators" href="http://www.slideshare.net/pjmolina/cg2010-tailored-code-generators-4579382">CG2010 Tailored Code Generators</a></strong><object id="__sse4579382" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="355" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=cg2010tailoredcodegenerators-100622173311-phpapp02&amp;stripped_title=cg2010-tailored-code-generators-4579382" /><param name="name" value="__sse4579382" /><param name="allowfullscreen" value="true" /><embed id="__sse4579382" type="application/x-shockwave-flash" width="425" height="355" src="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=cg2010tailoredcodegenerators-100622173311-phpapp02&amp;stripped_title=cg2010-tailored-code-generators-4579382" name="__sse4579382" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<div style="padding: 5px 0 12px;">View more <a href="http://www.slideshare.net/">presentations</a> from <a href="http://www.slideshare.net/pjmolina">Pedro J. Molina</a>.</div>
</div>
<p>It also was the public presentation of <strong><a title="Essential" href="http://pjmolina.com/metalevel/essential/" target="_self">Essential</a></strong><strong>:</strong> the tooling supporting my approach for applying MDD. I got a very good feedback from the audience and receive many request to test the tool.</p>
<p>People interested in beta testing it can still enroll <a title="Request Essential Evaluation" href="http://bit.ly/9SbgvP" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://pjmolina.com/metalevel/2010/06/tailored-code-generators-at-cg2010/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

