Home » Modeling » M2T (model-to-text transformation) » Acceleo and TopCased
Acceleo and TopCased [message #525664] |
Wed, 07 April 2010 08:26  |
Eclipse User |
|
|
|
Hi,
The '.emtl' files do exist in both (I've done a search for them),
they are created under the ....\configuration\org.eclipse.osgi\bundles
folder in the installation.
It is the same version of acceleo, I installed it using the update manager.
the org.eclipse.osgi is a different version in Papyrus and TopCased,
it is code from this module that is used to find the .emtl files,
thus I figure it may be this that is causing the issue...but perhaps not!
(I have copied this email to the forum as you request.)
> -----Original Message-----
> From: Laurent Goubet
> Sent: 07 April 2010 13:05
>
>
> David,
>
> Papyrus or TopCased doesn't matter : Acceleo can be used on any model
> compatible with EMF, even if it hasn't been created by a
> graphical tool,
> even if it has been created through a graphical tool not
> integrated with
> Eclipse (MagicDraw, Enterprise Architect, ...) as long as the
> tool can
> export it to an EMF-compatible model. Your version of OSGi does not
> influence Acceleo either.
>
> The problem you face would imply that the two modules that
> are part of
> Acceleo's compatibility layer (org.eclipse.acceleo.compatibility.ui)
> haven't been built (the emtl cannot be found). Yet if you
> have the issue
> with TopCased , you should have it with Papyrus (and vice-versa)...
> except if the two versions of Acceleo you install aren't the
> same. Could
> you double check the qualifier of the Acceleo versions you have? And
> also : these are Acceleo jars you downloaded from
> Eclipse.org, not jars
> you exported yourself?
>
> As a side note, in which context to you use Acceleo? Is that
> a project
> between Obeo and Thales or a project on your side? We'd
> rather you use
> the Eclipse M2T forums (
> http://www.eclipse.org/forums/index.php?t=thread&frm_id= 24& )
> for your
> questions if it isn't a project with Obeo as it allows us to have the
> discussion publicly available.
>
> Laurent Goubet
> Obeo
>
> Akehurst, David wrote:
> > The problem, I think is down to different versions of
> org.eclipse.osgi
> >
> > Papyrus using org.eclipse.osgi_3.5.0.v20090520.jar
> >
> > TopCased is using org.eclipse.osgi_3.5.1.R35x_v20090827.jar
> >
> > Do you know why Acceleo would have problems with v3.5.1 ?
> >
> >
> >
> >> -----Original Message-----
> >> From: Akehurst, David
> >> Sent: 06 April 2010 17:23
> >> Subject: RE: Acceleo and ANT
> >>
> >>
> >> hi,
> >>
> >> I'm having another problem as well.
> >>
> >> I have been using verion 3 of Acceleo with Papyrus,
> >> successfully (otha than the ant build issue).
> >>
> >> I've just tried to install it with the TopCased tool.
> >>
> >> I'm getting an two errors when building an mtl file,
> >>
> >> platform:/plugin/org.eclipse.acceleo.compatibility.ui/org/ec li
> >> pse/acceleo/internal/compatibility/mtl/gen/mt2mtl.emtl :
> >> java.io.FileNotFoundException:
> >> /org/eclipse/acceleo/internal/compatibility/mtl/gen/mt2mtl.e mtl
> >>
> >> platform:/plugin/org.eclipse.acceleo.compatibility.ui/org/ec li
> >> pse/acceleo/internal/compatibility/mtl/gen/ServiceUtils.emtl
> >> : java.io.FileNotFoundException:
> >>
> /org/eclipse/acceleo/internal/compatibility/mtl/gen/ServiceU tils.emtl
> >>
> >>
> >> now the mt2mtl.mtl and ServiceUtils.mtl are in the
> >> org.eclipse.acceleo.compatibility.ui plugin,
> >> but why can it not find the *.emtl files...these are build
> >> from *.mtl files are they not?
> >>
> >>
> >> cheers for you help on these issues.
> >>
> >>
> >>
> >>> -----Original Message-----
> >>> From: Laurent Goubet
> >>> Sent: 06 April 2010 16:31
> >>> To: Akehurst, David
> >>> Subject: Re: Acceleo and ANT
> >>>
> >>>
> >>> David,
> >>>
> >>> Comments below
> >>>
> >>> Akehurst, David wrote:
> >>>
> >>>>> 1) Are you launching the ant build from within Eclipse?
> >>>>>
> >>>>>
> >>>> Yes, and I'd like to set up a builder to do this for me.
> >>>>
> >>>>
> >>>>
> >>> Ok, rules out a fair number of problem causes .
> >>>
> >>>>> 2) Have you built the generated Java file corresponding to
> >>>>>
> >>> your module
> >>>
> >>>>>
> >>>>>
> >>>> file (Eclipse build or standalone javac)?
> >>>>
> >>>> Yes, They execute fine if I use the 'Run As | Launch
> >>>>
> >>> Acceleo Application'
> >>>
> >>>> way of executing the templates (version 3 of acceleo)
> >>>>
> >>>>
> >>>>
> >>> Ok, that too rules out a problem source.
> >>>
> >>>>> 3) Have you altered the build path of the project your
> >>>>>
> >>> module is in (the
> >>>
> >>>>>
> >>>>>
> >>>> generated ant task adds the project's "bin" folder to the
> >>>>
> >>> classpath, nothing
> >>>
> >>>> else)?
> >>>>
> >>>> Have not touched the build path of teh project the model is
> >>>>
> >>> in....do I need
> >>>
> >>>> to do so?
> >>>>
> >>>>
> >>> I tried to carry on two things in one here, sorry for the
> >>> confusion. In
> >>> the project you have your module (.mtl file) is generated a
> >>> corresponding Java class (let's call it "Generate.java").
> >>> Where is this
> >>> class built? You should also have a folder named "tasks" in
> >>> this project
> >>> where the two ant files are generated : the "readme" file
> >>>
> >> you should
> >>
> >>> have renamed and moved elsewhere and that will serve as the
> >>> runner, and
> >>> an "xml" file that should stay there (likewise, let's call it
> >>> "Generate.xml"). Generate.xml expects Generate.class to be
> >>> built in your
> >>> project's "bin" folder, and thus it sports on line 6
> "<pathelement
> >>> location="../myproject/bin"/>". If you use an alternate build
> >>> destination for Generate.java, you have to add it to the ant
> >>> classpath
> >>> through another "pathelement" node.
> >>>
> >>> If you use maven or another such tool, chances are your
> destination
> >>> folder isn't "bin". Check this by right-clicking your project and
> >>> selecting "properties" => "Java build path". On this page,
> >>>
> >> go to the
> >>
> >>> "source" tab and select the source folder where
> >>>
> >> Generate.java stands.
> >>
> >>> Now on the bottom of the tab is a text field displaying
> the output
> >>> folder of this source folder. If it is "myproject/bin"
> ... then the
> >>> issue doesn't lie here. If it is anything else, you'll have
> >>> to alter the
> >>> ant classpath as I described in the above paragraph.
> >>>
> >>>>
> >>>>
> >>>>> 4) Are you positive "<className>" indeed corresponds to
> >>>>>
> >>> the actual class
> >>>
> >>>>>
> >>>>>
> >>>> name?
> >>>>
> >>>> Yes, I'd like to set up the ANT build to run several
> >>>>
> >>> templates, is this
> >>>
> >>>> possible?
> >>>> or is it better to set up a root template that calls all
> >>>>
> >> the others?
> >>
> >>>>
> >>>>
> >>> I'd rather use a single root template calling out all others,
> >>> but that
> >>> is a matter of preferences. You can also create a single
> >>>
> >> module file
> >>
> >>> containing multiple templates anotated with "[comment
> @main/]" and
> >>> calling the generated java file for this module. Your option
> >>> of having a
> >>> single ANT build calling several templates should also work.
> >>>
> >>>>
> >>>>
> >>>>> -----Original Message-----
> >>>>> From: Laurent Goubet
> >>>>> Sent: 06 April 2010 16:02
> >>>>> To: Akehurst, David
> >>>>> Subject: Re: Acceleo and ANT
> >>>>>
> >>>>>
> >>>>> Hi David,
> >>>>>
> >>>>> This could come from a number of sources, we'll need to
> know the
> >>>>> configuration in which you're trying to run the generation :
> >>>>> 1) Are you launching the ant build from within Eclipse?
> >>>>> 2) Have you built the generated Java file corresponding to
> >>>>> your module
> >>>>> file (Eclipse build or standalone javac)?
> >>>>> 3) Have you altered the build path of the project your module
> >>>>> is in (the
> >>>>> generated ant task adds the project's "bin" folder to the
> >>>>>
> >>> classpath,
> >>>
> >>>>> nothing else)?
> >>>>> 4) Are you positive "<className>" indeed corresponds to the
> >>>>> actual class
> >>>>> name?
> >>>>>
> >>>>> If none of these helps, would it be possible for you to
> >>>>> provide us with
> >>>>> your projects so that we can try and debug the issue?
> >>>>>
> >>>>> Laurent Goubet
> >>>>> Obeo
> >>>>>
> >>>>> Akehurst, David wrote:
> >>>>>
> >>>>>
> >>>>>> Hi,
> >>>>>>
> >>>>>> I must be missing something in the instructions,
> >>>>>> the help pages say to copy the generated ANT xml file into
> >>>>>>
> >>>>>>
> >>>>> the project where
> >>>>>
> >>>>>
> >>>>>> the model is.
> >>>>>> then rename it.
> >>>>>>
> >>>>>> when activating ANT, I get an error
> >>>>>>
> >>>>>> 'Could not find <className>. Make sure you have it in your
> >>>>>>
> >>>>>>
> >>>>> classpath'
> >>>>>
> >>>>>
> >>>>>> where <className> refers the the java file generated by
> >>>>>>
> >>> acceleo that
> >>>
> >>>>>> corresponds to the template file.
> >>>>>>
> >>>>>> what am I missing?
> >>>>>>
> >>>>>> cheers
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> David Akehurst
>
|
|
|
Re: Acceleo and TopCased [message #525901 is a reply to message #525664] |
Thu, 08 April 2010 04:39   |
Eclipse User |
|
|
|
This is a multi-part message in MIME format.
--------------040105050400070507030601
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Hi David,
Thanks for carrying this thread here :). Unfortunately ... I fail to see
why you get a failure in one case and not the other. Could you check
your configuration to see if there isn't more than one version of
Acceleo installed in the case of TopCased? This is in Help => About
Eclipse => Installation Details => "Plug-ins" tab and search for the
plugin named "org.eclipse.acceleo.compatibility" there. You should only
have a single one. If you have only one ... I have no idea as to why we
wouldn't be able to retrieve the emtl files in your TopCased use case.
Laurent Goubet
Obeo
D.H.Akehurst wrote:
> Hi,
>
> The '.emtl' files do exist in both (I've done a search for them),
> they are created under the ....\configuration\org.eclipse.osgi\bundles
> folder in the installation.
>
> It is the same version of acceleo, I installed it using the update manager.
> the org.eclipse.osgi is a different version in Papyrus and TopCased,
> it is code from this module that is used to find the .emtl files,
> thus I figure it may be this that is causing the issue...but perhaps not!
>
>
> (I have copied this email to the forum as you request.)
>
>
>> -----Original Message-----
>> From: Laurent Goubet Sent: 07 April 2010 13:05
>>
>>
>> David,
>>
>> Papyrus or TopCased doesn't matter : Acceleo can be used on any model
>> compatible with EMF, even if it hasn't been created by a graphical
>> tool, even if it has been created through a graphical tool not
>> integrated with Eclipse (MagicDraw, Enterprise Architect, ...) as long
>> as the tool can export it to an EMF-compatible model. Your version of
>> OSGi does not influence Acceleo either.
>>
>> The problem you face would imply that the two modules that are part of
>> Acceleo's compatibility layer (org.eclipse.acceleo.compatibility.ui)
>> haven't been built (the emtl cannot be found). Yet if you have the
>> issue with TopCased , you should have it with Papyrus (and
>> vice-versa)... except if the two versions of Acceleo you install
>> aren't the same. Could you double check the qualifier of the Acceleo
>> versions you have? And also : these are Acceleo jars you downloaded
>> from Eclipse.org, not jars you exported yourself?
>>
>> As a side note, in which context to you use Acceleo? Is that a project
>> between Obeo and Thales or a project on your side? We'd rather you use
>> the Eclipse M2T forums (
>> http://www.eclipse.org/forums/index.php?t=thread&frm_id= 24& ) for your
>> questions if it isn't a project with Obeo as it allows us to have the
>> discussion publicly available.
>>
>> Laurent Goubet
>> Obeo
>>
>> Akehurst, David wrote:
>> > The problem, I think is down to different versions of org.eclipse.osgi
>> >
>> > Papyrus using org.eclipse.osgi_3.5.0.v20090520.jar
>> >
>> > TopCased is using org.eclipse.osgi_3.5.1.R35x_v20090827.jar
>> >
>> > Do you know why Acceleo would have problems with v3.5.1 ?
>> >
>> >
>> > >> -----Original Message-----
>> >> From: Akehurst, David >> Sent: 06 April 2010 17:23
>> >> Subject: RE: Acceleo and ANT
>> >>
>> >>
>> >> hi,
>> >>
>> >> I'm having another problem as well.
>> >>
>> >> I have been using verion 3 of Acceleo with Papyrus, >> successfully
>> (otha than the ant build issue).
>> >>
>> >> I've just tried to install it with the TopCased tool.
>> >>
>> >> I'm getting an two errors when building an mtl file,
>> >>
>> >> platform:/plugin/org.eclipse.acceleo.compatibility.ui/org/ec li
>> >> pse/acceleo/internal/compatibility/mtl/gen/mt2mtl.emtl : >>
>> java.io.FileNotFoundException: >>
>> /org/eclipse/acceleo/internal/compatibility/mtl/gen/mt2mtl.e mtl
>> >>
>> >> platform:/plugin/org.eclipse.acceleo.compatibility.ui/org/ec li
>> >> pse/acceleo/internal/compatibility/mtl/gen/ServiceUtils.emtl >> :
>> java.io.FileNotFoundException: >>
>> /org/eclipse/acceleo/internal/compatibility/mtl/gen/ServiceU tils.emtl
>> >>
>> >>
>> >> now the mt2mtl.mtl and ServiceUtils.mtl are in the >>
>> org.eclipse.acceleo.compatibility.ui plugin,
>> >> but why can it not find the *.emtl files...these are build >> from
>> *.mtl files are they not?
>> >>
>> >>
>> >> cheers for you help on these issues.
>> >>
>> >>
>> >> >>> -----Original Message-----
>> >>> From: Laurent Goubet
>> >>> Sent: 06 April 2010 16:31
>> >>> To: Akehurst, David
>> >>> Subject: Re: Acceleo and ANT
>> >>>
>> >>>
>> >>> David,
>> >>>
>> >>> Comments below
>> >>>
>> >>> Akehurst, David wrote:
>> >>> >>>>> 1) Are you launching the ant build from within Eclipse?
>> >>>>> >>>>> >>>> Yes, and I'd like to set up a builder
>> to do this for me.
>> >>>>
>> >>>> >>>> >>> Ok, rules out a fair number of problem causes :p.
>> >>> >>>>> 2) Have you built the generated Java file
>> corresponding to >>>>> >>> your module
>> >>> >>>>> >>>>> >>>> file (Eclipse build or
>> standalone javac)?
>> >>>>
>> >>>> Yes, They execute fine if I use the 'Run As | Launch >>>>
>> >>> Acceleo Application'
>> >>> >>>> way of executing the templates (version 3 of acceleo)
>> >>>>
>> >>>> >>>> >>> Ok, that too rules out a problem source.
>> >>> >>>>> 3) Have you altered the build path of the project your
>> >>>>> >>> module is in (the
>> >>> >>>>> >>>>> >>>> generated ant task adds the
>> project's "bin" folder to the >>>> >>> classpath, nothing
>> >>> >>>> else)?
>> >>>>
>> >>>> Have not touched the build path of teh project the model is
>> >>>> >>> in....do I need
>> >>> >>>> to do so?
>> >>>> >>>> >>> I tried to carry on two things in one here,
>> sorry for the >>> confusion. In >>> the project you have your module
>> (.mtl file) is generated a >>> corresponding Java class (let's call it
>> "Generate.java"). >>> Where is this >>> class built? You should also
>> have a folder named "tasks" in >>> this project >>> where the two ant
>> files are generated : the "readme" file >>> >> you should >>
>> >>> have renamed and moved elsewhere and that will serve as the >>>
>> runner, and >>> an "xml" file that should stay there (likewise, let's
>> call it >>> "Generate.xml"). Generate.xml expects Generate.class to be
>> >>> built in your >>> project's "bin" folder, and thus it sports on
>> line 6 "<pathelement >>> location="../myproject/bin"/>". If you use an
>> alternate build >>> destination for Generate.java, you have to add it
>> to the ant >>> classpath >>> through another "pathelement" node.
>> >>>
>> >>> If you use maven or another such tool, chances are your
>> destination >>> folder isn't "bin". Check this by right-clicking your
>> project and >>> selecting "properties" => "Java build path". On this
>> page, >>> >> go to the >> >>> "source" tab and select the
>> source folder where >>> >> Generate.java stands. >> >>> Now
>> on the bottom of the tab is a text field displaying the output >>>
>> folder of this source folder. If it is "myproject/bin" ... then the
>> >>> issue doesn't lie here. If it is anything else, you'll have >>> to
>> alter the >>> ant classpath as I described in the above paragraph.
>> >>> >>>> >>>> >>>>> 4) Are you positive "<className>"
>> indeed corresponds to >>>>> >>> the actual class
>> >>> >>>>> >>>>> >>>> name?
>> >>>>
>> >>>> Yes, I'd like to set up the ANT build to run several >>>>
>> >>> templates, is this
>> >>> >>>> possible?
>> >>>> or is it better to set up a root template that calls all
>> >>>> >> the others?
>> >> >>>> >>>> >>> I'd rather use a single root template
>> calling out all others, >>> but that >>> is a matter of preferences.
>> You can also create a single >>> >> module file >> >>>
>> containing multiple templates anotated with "[comment @main/]" and >>>
>> calling the generated java file for this module. Your option >>> of
>> having a >>> single ANT build calling several templates should also work.
>> >>> >>>> >>>> >>>>> -----Original Message-----
>> >>>>> From: Laurent Goubet
>> >>>>> Sent: 06 April 2010 16:02
>> >>>>> To: Akehurst, David
>> >>>>> Subject: Re: Acceleo and ANT
>> >>>>>
>> >>>>>
>> >>>>> Hi David,
>> >>>>>
>> >>>>> This could come from a number of sources, we'll need to know the
>> >>>>> configuration in which you're trying to run the generation :
>> >>>>> 1) Are you launching the ant build from within Eclipse?
>> >>>>> 2) Have you built the generated Java file corresponding to >>>>>
>> your module >>>>> file (Eclipse build or standalone javac)?
>> >>>>> 3) Have you altered the build path of the project your module
>> >>>>> is in (the >>>>> generated ant task adds the project's "bin"
>> folder to the >>>>> >>> classpath, >>> >>>>> nothing
>> else)?
>> >>>>> 4) Are you positive "<className>" indeed corresponds to the
>> >>>>> actual class >>>>> name?
>> >>>>>
>> >>>>> If none of these helps, would it be possible for you to >>>>>
>> provide us with >>>>> your projects so that we can try and debug the
>> issue?
>> >>>>>
>> >>>>> Laurent Goubet
>> >>>>> Obeo
>> >>>>>
>> >>>>> Akehurst, David wrote:
>> >>>>> >>>>> >>>>>> Hi,
>> >>>>>>
>> >>>>>> I must be missing something in the instructions,
>> >>>>>> the help pages say to copy the generated ANT xml file into
>> >>>>>> >>>>>> >>>>> the project where
>> >>>>> >>>>> >>>>>> the model is.
>> >>>>>> then rename it.
>> >>>>>>
>> >>>>>> when activating ANT, I get an error
>> >>>>>>
>> >>>>>> 'Could not find <className>. Make sure you have it in your
>> >>>>>> >>>>>> >>>>> classpath'
>> >>>>> >>>>> >>>>>> where <className> refers the the java
>> file generated by >>>>>> >>> acceleo that
>> >>> >>>>>> corresponds to the template file.
>> >>>>>>
>> >>>>>> what am I missing?
>> >>>>>>
>> >>>>>> cheers
>> >>>>>>
>> >>>>>>
>> >>>>>>
>> >>>>>>
>> >>>>>> David Akehurst
>>
--------------040105050400070507030601
Content-Type: text/x-vcard; charset=utf-8;
name="laurent_goubet.vcf"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
filename="laurent_goubet.vcf"
YmVnaW46dmNhcmQNCmZuOkxhdXJlbnQgR291YmV0DQpuOkdvdWJldDtMYXVy ZW50DQpvcmc6
PGEgaHJlZj0iaHR0cDovL3d3dy5vYmVvLmZyIj5PYmVvPC9hPg0KZW1haWw7 aW50ZXJuZXQ6
bGF1cmVudC5nb3ViZXRAb2Jlby5mcg0KdXJsOmh0dHA6Ly93d3cub2Jlby5m cg0KdmVyc2lv
bjoyLjENCmVuZDp2Y2FyZA0KDQo=
--------------040105050400070507030601--
|
|
| | | |
Goto Forum:
Current Time: Sun Jul 13 20:50:36 EDT 2025
Powered by FUDForum. Page generated in 0.06719 seconds
|