Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [JET2] What's the difference betwen JET and JET2?
[JET2] What's the difference betwen JET and JET2? [message #39473] Sat, 12 January 2008 14:44 Go to next message
Mikai Yang is currently offline Mikai YangFriend
Messages: 149
Registered: July 2009
Senior Member
Hi,
I go through the news in this news group, finding somebody quote JET
,but somebody quote JET2. I am really confused ,wandering what JET2 is. Is
it just the latest version of JET, or absolutely different one from JET. Can
you explain that to me? or give me some material to read?
Thanks.
Michael.
Re: [JET2] What's the difference betwen JET and JET2? [message #39504 is a reply to message #39473] Sat, 12 January 2008 14:49 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Michael,

There is an older version of JET in EMF in org.eclipse.emf.codegen. The
EMF code generator is still using that version of JET. So this
separated out improved version of JET in the M2T project is often
referred to as JET2.


Michael wrote:
> Hi,
> I go through the news in this news group, finding somebody quote JET
> ,but somebody quote JET2. I am really confused ,wandering what JET2 is. Is
> it just the latest version of JET, or absolutely different one from JET. Can
> you explain that to me? or give me some material to read?
> Thanks.
> Michael.
>
>
>
Re: [JET2] What's the difference betwen JET and JET2? [message #39995 is a reply to message #39473] Tue, 15 January 2008 15:19 Go to previous message
Paul Elder is currently offline Paul ElderFriend
Messages: 849
Registered: July 2009
Senior Member
JET2 (aka EMFT JET aka M2T JET) adds the following to JET (aka
org.eclipse.emf.codegen, aka JET1):

* support for tag libraries instead of just scriptlets and expressions
* a concept of an 'transformation', written entirely in JET templates. The
transformation accepts a 'model' as input, and runs one or more templates
that produce output. There are a number of JET2 tags (workspace tags) that
expand templates, and write the results the the Eclipse workspace without
you having to write any Java code against the Eclipse APIs.

Unfortunately in moving from JET (JET1) to JET2, a number of
incompatibilities were introduced:
1) JET1 templates compile to a Java class with a generate method having
signature:
String generate(Object argument)
JET2 templates compile to a Java class with a generate method having
signature:
void generate(JET2Context context, JET2Writer out)
2) While JET1 templates depend only on the Java classes explicitly
referenced in the template, JET2 templates depend on the org.eclipse.jet
plug-in, which, right now has dependencies on the full Eclipse install (i.e.
won't run in RCP, OSGi or just a plain Java JRE.)

You might for the JET faq useful:

http://wiki.eclipse.org/M2T-JET-FAQ

Paul

"Michael" <my25@macs.hw.ac.uk> wrote in message
news:fmajoe$ugd$1@build.eclipse.org...
> Hi,
> I go through the news in this news group, finding somebody quote JET
> ,but somebody quote JET2. I am really confused ,wandering what JET2 is. Is
> it just the latest version of JET, or absolutely different one from JET.
> Can you explain that to me? or give me some material to read?
> Thanks.
> Michael.
>
Previous Topic:[JET] About JET editor.
Next Topic:[JET] How to handle ident of multiple-line strings generated by a scriplet.
Goto Forum:
  


Current Time: Sat Apr 27 01:14:53 GMT 2024

Powered by FUDForum. Page generated in 0.02634 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top