Vous êtes nouveau sur Developpez.com ? Créez votre compte ou connectez-vous afin de pouvoir participer !

Vous devez avoir un compte Developpez.com et être connecté pour pouvoir participer aux discussions.

Vous n'avez pas encore de compte Developpez.com ? Créez-en un en quelques instants, c'est entièrement gratuit !

Si vous disposez déjà d'un compte et qu'il est bien activé, connectez-vous à l'aide du formulaire ci-dessous.

##### Identifiez-vous
 Identifiant Mot de passe Mot de passe oublié ?
##### Créer un compte

L'inscription est gratuite et ne vous prendra que quelques instants !

# Actualité : Programmation Orientée Langage (LOP) avec JetBrains Meta Programming System

Le , par Ricky81

0PARTAGES

 0 0
Bonjour,

24/07/2009

JetBrains MPS (Meta Programming System) est désormais disponible en version 1.0.

Ci-dessous le communiqué de presse :

JetBrains MPS 1.0 Paints the Future of Software Development with a New Programming Paradigm

Implementing the Language Oriented Programming paradigm, JetBrains MPS provides unprecedented freedom in extending programming languages and creating DSLs for developing real-life applications.

Prague, Czech Republic, July 23, 2009 - JetBrains, creators of intelligent and innovative productivity-enhancing tools for software developers, have announced the 1.0 release of their new conceptual software development
environment - Meta Programming System, or MPS.

MPS is a professional language workbench and integrated development environment (IDE) for extending existing languages and using them to develop software. It is also an advanced instrument for creating new custom languages, or Domain Specific Languages, and allows defining new environments for working with these DSLs. By using MPS, and DSLs created with its help, domain experts can solve their domain-specific tasks easily, even if they're not familiar with programming.

To empower developers in adapting programming languages to their specific needs, MPS provides advanced facilities for defining language typesystems, constraints, specialized projectional editors and generators. Utilizing the generative approach, languages in MPS are described on a higher level, after which MPS generates compilable code in other languages, such as Java. A key advantage of MPS is that languages are composable: they can be easily combined with each other, which promotes reuse of languages.

"MPS has come a long way since the original concept back in 2003 and is now a powerful, mature software tool that paints the future of software development," said Sergey Dmitriev, JetBrains CEO and author of the MPS concept. "We've always taken pride in using our own software products, and we're already using MPS as a development platform for several of our latest products. One of them, a web-based issue tracker code-named Charisma, is already available for early access preview."

MPS is free for all users, with a major part of its source code open and available under Apache license.

To learn more about JetBrains MPS, download and test-drive it today. See the
official MPS website at http://www.jetbrains.com/mps?mps1pr.

About JetBrains
JetBrains is a technology-leading software development firm specializing in the creation of intelligent, productivity-enhancing software. The company is widely known for its innovative, award-winning Java integrated development environment, IntelliJ IDEA (see details on the Web at http://www.jetbrains.com/idea/?mps1pr), ReSharper and dotTrace Profiler for .NET developers (see http://www.jetbrains.com/resharper/?mps1pr,
http://www.jetbrains.com/profiler/?mps1pr), RubyMine for Ruby on Rails developers (http://www.jetbrains.com/ruby/?mps1pr), and TeamCity a continuous integration and build management environment (http://www.jetbrains.com/teamcity/?mps1pr). JetBrains maintains its headquarters in Prague, Czech Republic, with its R&D labs located in St.
Petersburg, Russia and Boston, Massachusetts. For more information, see http://www.jetbrains.com/?mps1pr.
* * *
Note to Editors: JetBrains, IntelliJ, IntelliJ IDEA, ReSharper, dotTrace, RubyMine and TeamCity are trademarks or registered trademarks of JetBrains, s.r.o. All other trademarks are the properties of their respective owners.
Egalement une FAQ :

Q: What is JetBrains MPS?
A: JetBrains MPS is a Meta Programming System. It's an implementation of the Language Oriented Programming approach. MPS is designed to create new languages or language extensions, such as programming languages, data languages or domain specific languages. More importantly, MPS allows composing languages with each other. For example, you can add new constructs to Java, or you can create a language specific to your domain and embed Java code inside of it.

Q: What is Language Oriented Programming?
A: Language Oriented Programming (LOP) is a programming paradigm which adds another degree of freedom compared to traditional programming: the ability to create/extend/embed a language with which you write your programs. Most programs are written for specific domains: financial applications, web applications, games, IDEs, etc. In case of, say, a financial application, we might embed first class monetary values in a language; in case of a web application we might move such concepts as controllers or template to the language level, etc. You can read more about this approach in Sergey Dmitriev's article, Language Oriented Programming: The Next Programming Paradigm, at http://www.onboard.jetbrains.com/is1...les/04/10/lop/

Q: Do I need to be familiar with grammars/parsing/compiler construction, etc., in order to create languages with MPS?
A: No, MPS doesn't use any parsers. It works with the abstract syntax tree directly, so it doesn't require any parsing. Compiler construction knowledge might be useful, but you don't have to be an expert in this field in order to use MPS: it contains a predefined set of languages with which users can create their own languages.

Q: How do you edit abstract syntax tree directly? I'm used to plain text editors and find them very convenient.
A: MPS provides a text-like projectional editor, which is used to write languages and programs. It is text-like enough to be learned really quickly.
According to our experience, it takes about 2 weeks in order to become productive with it. Despite the fact that this editor is text-like, there are some key differences with plain-text editors, but they are necessary to allow composing languages.

Q: Why are composable languages important?
A: Language composability means that you can extend/embed languages in any combination. This promotes languages reuse. Languages become more like libraries in the Java world. Imagine that you are writing an application which uses a language for monetary values from one vendor, and a quantitative calculation from another. Since these are languages, you can achieve a much higher level of abstraction than with libraries, and because they are composable, you can reuse them as freely as you reuse Java libraries. You can read more about this in Konstantin Solomatov's article, DSL Adoption with JetBrains MPS, http://architects.dzone.com/articles...-dsls-adoption

Q: What is a projectional editor?
A: A projectional editor is an approach for editing an abstract syntax tree directly. For each node of the abstract syntax tree, a projection is created, which is a part of the screen with textual represention of the node. As the user interacts with the projection, changes are reflected in the node.

Q: Why is it necessary to introduce a projectional editor?
A: Our goal is to work with composable languages. Using a plain-text representation and grammars would present composability problems. Text-based grammars can be ambiguous and as a result, composed languages might not be deterministically parseable. Let's consider an example. Imagine that two parties decided to add string interpolation syntax to Java. String interpolation allows embedding of expressions inside of string literals. So, the first party might use the following syntax: ${expr} and the other might use {expr}. If we write the following code in Java, with both of these extensions added, it will be ambiguous: "Balance of your account is${expr}". We don't know whether $is part of string interpolation syntax or part of a string literal. Of course, this example is quite artificial, but it is a good illustration of the problems which arise when we have different constructs with similar syntax in different language extensions. Q: How do you store program code? A: MPS stores source code in its internal XML-based format. It isn't supposed to be edited directly. Q: How about version control integration? Merge/diff is known to be a problem for products which use XML-based formats. A: Version control integration isn't a problem with MPS. We have diff/merge tools which allow you to work with MPS code as you work with text, provided that you update/diff from MPS IDE. Moreover, our merge allows you to safely merge cases which would be considered as conflicts by a text-based merge. Q: If I create a language, how can I distribute it? A: There are several options for that. First, you can create a packaged version of your language and distribute it as a file. Second, you can create a special distrubutive of MPS which, in addition to the standard set of languages, will include your language. A third option, which is under development now, will allow you to create a stripped-down version of MPS, where particular parts of IDE will be removed or altered, so that you will be able to create a custom MPS-based IDE for your language. Q: Are there any real-world applications implemented with MPS? A: Yes, sure. Our new bug-tracking system, code-named Charisma, is developed entirely with MPS. This issue tracker is a modern Web 2.0 application. In order to create it, a whole stack of web application languages was created: we have languages for HTML templates, controllers, database access, JavaScript, etc. You can see this issue tracker in action here: jetbrains.net/tracker/. In fact, we have more projects under development, but they haven't been announced yet. Q: Do I have to use MPS for the whole project in order to benefit from it? A: No, you don't. MPS has really good integration with existing Java code (and such integration can be added to other languages that you want to work with). You can use MPS-generated code from your favorite IDE, and MPS can reference Java code. If you want to start using MPS in your project, we recommend choosing a module which can benefit most from MPS, and using MPS there. If you like the approach, you can write more and more code with MPS. Q: How is JetBrains MPS code licensed? A: All MPS code is licensed under Apache 2.0 license. Although we have a non-open source part, which is called JetBrains IDE Framework, its license allows you to freely use it in MPS' derivatives. Q: What are system requirements for MPS? A: MPS is a resource intensive application. In order to create simple languages, you will need a 2.0Ghz CPU and at least 3Gb of RAM. If you want to create a larger application, you will need a 2.6Ghz CPU and at least 4Gb of RAM (in such a case feel free to change the -Xmx option in mps.vmoptions file in the bin directory of MPS installation). 10/12/2008 Comme explicité dans ce billet blog, j'aimerai attirer votre attention sur JetBrains Meta Programming System actuellement en beta, mais dont la release 1.0 est prévue pour début 2009. Démarré en 2003, le concept derrière le projet a été décrit en 2004 par le fondateur de JetBrains : Language Oriented Programming (LOP). Depuis 2005, il existe un Early Access Program (EAP) permettant de suivre l'évolution des travaux. Le produit qui en résulte a été utilisé depuis 2006 par JetBrains pour développer certains de leurs produits, démarche qui leur a permis d'accumuler énormément d'expérience sur la problématique, et d'aboutir à un produit mature. Une erreur dans cette actualité ? Signalez-le nous ! Expert confirmé Le 10/12/2008 à 14:10 C'est une approche déjà connue qui consiste à créer son propre méta-modèle (voir ce topic sur développez) pour développer des DSLs, mais qui a le mérite d'être "bien vendue" en offrant une solution complète clé en main. Quant au terme de de Language Oriented Programming (LOP), c'est très "marketing". Il s'agit tout bonnement de méta-modélisation. Le 'BaseLanguage' fourni par JetBrains n'est rien d'autre que l'équivalent d'un MOF ou d'un ECORE. JetBrains respecte les même étapes que Eclipse EMF par exemple : • Création d'un métamodèle (modèle ecore sous Eclipse EMF, Structure Language sous JetBrains) • Création d'un syntaxe textuelle associée (TCS sous Eclipse EMF, Editor Language sous JetBrains) • Projection vers un langage généraliste (Transformation ATL sous Eclipse EMF, Transformation Language sous JetBrains) Disons pour résumer que ça permet de démocratiser l'usage de la méta-modélisation à travers un outil unique, gratuit et bien pensé, et ça, c'est une très bonne chose !  0 0 Expert éminent sénior Le 24/07/2009 à 0:06 JetBrains MPS est désormais disponible en version 1.0. Ci-dessous le communiqué de presse : JetBrains MPS 1.0 Paints the Future of Software Development with a New Programming Paradigm Implementing the Language Oriented Programming paradigm, JetBrains MPS provides unprecedented freedom in extending programming languages and creating DSLs for developing real-life applications. Prague, Czech Republic, July 23, 2009 - JetBrains, creators of intelligent and innovative productivity-enhancing tools for software developers, have announced the 1.0 release of their new conceptual software development environment - Meta Programming System, or MPS. MPS is a professional language workbench and integrated development environment (IDE) for extending existing languages and using them to develop software. It is also an advanced instrument for creating new custom languages, or Domain Specific Languages, and allows defining new environments for working with these DSLs. By using MPS, and DSLs created with its help, domain experts can solve their domain-specific tasks easily, even if they're not familiar with programming. To empower developers in adapting programming languages to their specific needs, MPS provides advanced facilities for defining language typesystems, constraints, specialized projectional editors and generators. Utilizing the generative approach, languages in MPS are described on a higher level, after which MPS generates compilable code in other languages, such as Java. A key advantage of MPS is that languages are composable: they can be easily combined with each other, which promotes reuse of languages. "MPS has come a long way since the original concept back in 2003 and is now a powerful, mature software tool that paints the future of software development," said Sergey Dmitriev, JetBrains CEO and author of the MPS concept. "We've always taken pride in using our own software products, and we're already using MPS as a development platform for several of our latest products. One of them, a web-based issue tracker code-named Charisma, is already available for early access preview." MPS is free for all users, with a major part of its source code open and available under Apache license. To learn more about JetBrains MPS, download and test-drive it today. See the official MPS website at http://www.jetbrains.com/mps?mps1pr. About JetBrains JetBrains is a technology-leading software development firm specializing in the creation of intelligent, productivity-enhancing software. The company is widely known for its innovative, award-winning Java integrated development environment, IntelliJ IDEA (see details on the Web at http://www.jetbrains.com/idea/?mps1pr), ReSharper and dotTrace Profiler for .NET developers (see http://www.jetbrains.com/resharper/?mps1pr, http://www.jetbrains.com/profiler/?mps1pr), RubyMine for Ruby on Rails developers (http://www.jetbrains.com/ruby/?mps1pr), and TeamCity a continuous integration and build management environment (http://www.jetbrains.com/teamcity/?mps1pr). JetBrains maintains its headquarters in Prague, Czech Republic, with its R&D labs located in St. Petersburg, Russia and Boston, Massachusetts. For more information, see http://www.jetbrains.com/?mps1pr. * * * Note to Editors: JetBrains, IntelliJ, IntelliJ IDEA, ReSharper, dotTrace, RubyMine and TeamCity are trademarks or registered trademarks of JetBrains, s.r.o. All other trademarks are the properties of their respective owners. Egalement une FAQ : Q: What is JetBrains MPS? A: JetBrains MPS is a Meta Programming System. It's an implementation of the Language Oriented Programming approach. MPS is designed to create new languages or language extensions, such as programming languages, data languages or domain specific languages. More importantly, MPS allows composing languages with each other. For example, you can add new constructs to Java, or you can create a language specific to your domain and embed Java code inside of it. Q: What is Language Oriented Programming? A: Language Oriented Programming (LOP) is a programming paradigm which adds another degree of freedom compared to traditional programming: the ability to create/extend/embed a language with which you write your programs. Most programs are written for specific domains: financial applications, web applications, games, IDEs, etc. In case of, say, a financial application, we might embed first class monetary values in a language; in case of a web application we might move such concepts as controllers or template to the language level, etc. You can read more about this approach in Sergey Dmitriev's article, Language Oriented Programming: The Next Programming Paradigm, at http://www.onboard.jetbrains.com/is1...les/04/10/lop/ Q: Do I need to be familiar with grammars/parsing/compiler construction, etc., in order to create languages with MPS? A: No, MPS doesn't use any parsers. It works with the abstract syntax tree directly, so it doesn't require any parsing. Compiler construction knowledge might be useful, but you don't have to be an expert in this field in order to use MPS: it contains a predefined set of languages with which users can create their own languages. Q: How do you edit abstract syntax tree directly? I'm used to plain text editors and find them very convenient. A: MPS provides a text-like projectional editor, which is used to write languages and programs. It is text-like enough to be learned really quickly. According to our experience, it takes about 2 weeks in order to become productive with it. Despite the fact that this editor is text-like, there are some key differences with plain-text editors, but they are necessary to allow composing languages. Q: Why are composable languages important? A: Language composability means that you can extend/embed languages in any combination. This promotes languages reuse. Languages become more like libraries in the Java world. Imagine that you are writing an application which uses a language for monetary values from one vendor, and a quantitative calculation from another. Since these are languages, you can achieve a much higher level of abstraction than with libraries, and because they are composable, you can reuse them as freely as you reuse Java libraries. You can read more about this in Konstantin Solomatov's article, DSL Adoption with JetBrains MPS, http://architects.dzone.com/articles...-dsls-adoption Q: What is a projectional editor? A: A projectional editor is an approach for editing an abstract syntax tree directly. For each node of the abstract syntax tree, a projection is created, which is a part of the screen with textual represention of the node. As the user interacts with the projection, changes are reflected in the node. Q: Why is it necessary to introduce a projectional editor? A: Our goal is to work with composable languages. Using a plain-text representation and grammars would present composability problems. Text-based grammars can be ambiguous and as a result, composed languages might not be deterministically parseable. Let's consider an example. Imagine that two parties decided to add string interpolation syntax to Java. String interpolation allows embedding of expressions inside of string literals. So, the first party might use the following syntax:${expr} and the other might use {expr}. If we write the following code in Java, with both of these extensions added, it will be ambiguous: "Balance of your account is ${expr}". We don't know whether$ is part of string interpolation syntax or part of a string literal. Of course, this example is quite artificial, but it is a good illustration of the problems which arise when we have different constructs with similar syntax in different language extensions.

Q: How do you store program code?
A: MPS stores source code in its internal XML-based format. It isn't supposed to be edited directly.

Q: How about version control integration? Merge/diff is known to be a problem for products which use XML-based formats.
A: Version control integration isn't a problem with MPS. We have diff/merge tools which allow you to work with MPS code as you work with text, provided that you update/diff from MPS IDE. Moreover, our merge allows you to safely merge cases which would be considered as conflicts by a text-based merge.

Q: If I create a language, how can I distribute it?
A: There are several options for that. First, you can create a packaged version of your language and distribute it as a file. Second, you can create a special distrubutive of MPS which, in addition to the standard set of languages, will include your language. A third option, which is under development now, will allow you to create a stripped-down version of MPS, where particular parts of IDE will be removed or altered, so that you will be able to create a custom MPS-based IDE for your language.

Q: Are there any real-world applications implemented with MPS?
A: Yes, sure. Our new bug-tracking system, code-named Charisma, is developed entirely with MPS. This issue tracker is a modern Web 2.0 application. In order to create it, a whole stack of web application languages was created:
we have languages for HTML templates, controllers, database access, JavaScript, etc. You can see this issue tracker in action here:
jetbrains.net/tracker/. In fact, we have more projects under development, but they haven't been announced yet.

Q: Do I have to use MPS for the whole project in order to benefit from it?
A: No, you don't. MPS has really good integration with existing Java code (and such integration can be added to other languages that you want to work with). You can use MPS-generated code from your favorite IDE, and MPS can reference Java code.
If you want to start using MPS in your project, we recommend choosing a module which can benefit most from MPS, and using MPS there. If you like the approach, you can write more and more code with MPS.

Q: How is JetBrains MPS code licensed?
A: All MPS code is licensed under Apache 2.0 license. Although we have a non-open source part, which is called JetBrains IDE Framework, its license allows you to freely use it in MPS' derivatives.

Q: What are system requirements for MPS?
A: MPS is a resource intensive application. In order to create simple languages, you will need a 2.0Ghz CPU and at least 3Gb of RAM. If you want to create a larger application, you will need a 2.6Ghz CPU and at least 4Gb of RAM (in such a case feel free to change the -Xmx option in mps.vmoptions file in the bin directory of MPS installation).
Connaissant la qualité des produits édités par JetBrains (IntelliJ IDEA, Resharper et Teamcity pour ne pas en citer), que pensez vous de ce produit ? Quelles sont vos attentes ?
 0 0
Expert éminent
Le 24/07/2009 à 0:30
Très intéressant

Pas encore de retours vu que je suis encore en train de lire leur doc dessus, mais ça me rappèle déjà Xtext (un projet Eclipse).

Ayant joué un peu avec antlr dans le passé, je trouve que le fait qu'on obtient gratuitement un éditeur avec auto-complétion est un atout indéniable.
 0 0
Membre averti
Le 24/07/2009 à 14:15
Envoyé par Hephaistos007
C'est une approche déjà connue qui consiste à créer son propre méta-modèle (voir ce topic sur développez) pour développer des DSLs, mais qui a le mérite d'être "bien vendue" en offrant une solution complète clé en main. Quant au terme de de Language Oriented Programming (LOP), c'est très "marketing". Il s'agit tout bonnement de méta-modélisation. Le 'BaseLanguage' fourni par JetBrains n'est rien d'autre que l'équivalent d'un MOF ou d'un ECORE.

JetBrains respecte les même étapes que Eclipse EMF par exemple :
• Création d'un métamodèle (modèle ecore sous Eclipse EMF, Structure Language sous JetBrains)
• Création d'un syntaxe textuelle associée (TCS sous Eclipse EMF, Editor Language sous JetBrains)
• Projection vers un langage généraliste (Transformation ATL sous Eclipse EMF, Transformation Language sous JetBrains)

Disons pour résumer que ça permet de démocratiser l'usage de la méta-modélisation à travers un outil unique, gratuit et bien pensé, et ça, c'est une très bonne chose !
A ceci près qu'ici on est complètement décorrélé d'UML, donc les langages ne sont plus forcément à dominante graphique.
 0 0
Membre expert
Le 24/07/2009 à 15:40
Language Oriented Programming: The Next Programming Paradigm, at http://www.onboard.jetbrains.com/is1...les/04/10/lop/
J'ai rapidement jeté un coup d'oeil sur ce lien.
Selon moi il ne s'agit pas d'un méta-modèle (il n'y a pas de mapping sémantique) mais d'un macro-langage (un mapping des motifs syntaxiques vers les motifs syntaxiques).

Ce qu'on peut personnaliser c'est la syntaxe, de plus on aurait une vraie déconstruction syntaxique là où aujourd'hui la "coloration syntaxique" n'est en fait qu'une déconstruction lexicale (ça serait déjà en soit un progrès indéniable).

Cette approche n'est en rien un nouveau paradigme de programmation, c'est juste une nouvelle interface de type éditeur de boites (à la UML) appliqué à Java. Ça a toujours existé sous la forme des block-diagrams (il y a des standards ISO pour ce genre de choses). Dans la pratique ça n'a jamais marché, aujourd'hui encore on donne du pseudo-code pour un algo et quasiment jamais un block-diagram. Des outils similaires ont exité dans le monde SmallTalk, ça n'est donc pas vraiment une surprise de les voir arriver dans le monde Java.

À mon avis le système de macro-langage n'est pas le côté le plus interessant. J'aurais préféré un éditeur structuré par la syntaxe (configurable) qui ne prétende pas révolutionner la POO.

Envoyé par big x
Un nouveau métamodèle n'a d'intérêt que si l'on cherche à définir des éléments qui n'existent pas déjà dans UML.
Exactement, et c'est la même chose ici. Que chacun puisse personnaliser la syntaxe ça n'apportera rien à la puissance de Java tant qu'on ne peut pas étendre les constructions sémantiques et le système de typage qui va avec.
 0 0