Skip to main content



      Home
Home » Modeling » EMF » EMF.ECORE2JAVA run ant from java(EMF.ECORE2JAVA run ant from java)
EMF.ECORE2JAVA run ant from java [message #1225695] Mon, 30 December 2013 09:32 Go to next message
Eclipse UserFriend
Hello friends

I'm trying to run an ant task from java emf for the generation of code and I get the following error

Exception: _C: \ ....... \ build.xml: 37: The following error occurred while executing this line:
C: \ ................ \ build.xml: 29: Problem: failed to create task or type emf.Ecore2Java
Cause: The name is undefined.
Action: Check the spelling.
Action: Check That any custom tasks / types Have Been Declared.
Action: Check That <presetdef> any / declarations have taken place <macrodef>.


Can you help me with this?

thanks

  • Attachment: probleam.png
    (Size: 34.75KB, Downloaded 192 times)
Re: EMF.ECORE2JAVA run ant from java [message #1225703 is a reply to message #1225695] Mon, 30 December 2013 09:53 Go to previous messageGo to next message
Eclipse UserFriend
Again, I'm not expert at how to invoke Ant programmatically. I'm not
sure anyone on this forum is such an expert. Nor is it clear to me why
you need such a button. The ant task requires parameters you can more
easily configure in your GenModel and once you have a GenModel you can
easily generate from it. There's even Alt-Shift-G for generating all
models in your workspace.

On 30/12/2013 3:32 PM, javs javs wrote:
> Hello friends
>
> I'm trying to run an ant task from java emf for the generation of code and I get the following error
>
> Exception: _C: \ ....... \ build.xml: 37: The following error occurred while executing this line:
> C: \ ................ \ build.xml: 29: Problem: failed to create task or type emf.Ecore2Java
> Cause: The name is undefined.
> Action: Check the spelling.
> Action: Check That any custom tasks / types Have Been Declared.
> Action: Check That <presetdef> any / declarations have taken place <macrodef>.
>
>
> Can you help me with this?
>
> thanks
>
>
Re: EMF.ECORE2JAVA run ant from java [message #1225722 is a reply to message #1225703] Mon, 30 December 2013 10:36 Go to previous messageGo to next message
Eclipse UserFriend
I want to run it through a button to call it from a plugin, but I could not do it, and I need



Re: EMF.ECORE2JAVA run ant from java [message #1225725 is a reply to message #1225703] Mon, 30 December 2013 10:44 Go to previous message
Eclipse UserFriend
HI

I'm not an expert either, although I have many scars to show for my
attempts.

Getting the ANT classpath right is really hard. Eclipse provides
integration for plugins but you're not really using a plugin since
you've contrived to have a custom classpath within a plugin classpath.
You therefore need at least to put the EMF ant tasks library on your
classpath.

Ed M recommends a GenModel, which is fine if a GenModel is enough.

I recommend an MWE script which gives you the power to sequence more
than just GenModel.

Regards

Ed Willink

On 30/12/2013 14:53, Ed Merks wrote:
> Again, I'm not expert at how to invoke Ant programmatically. I'm not
> sure anyone on this forum is such an expert. Nor is it clear to me
> why you need such a button. The ant task requires parameters you can
> more easily configure in your GenModel and once you have a GenModel
> you can easily generate from it. There's even Alt-Shift-G for
> generating all models in your workspace.
>
> On 30/12/2013 3:32 PM, javs javs wrote:
>> Hello friends
>>
>> I'm trying to run an ant task from java emf for the generation of
>> code and I get the following error
>>
>> Exception: _C: \ ....... \ build.xml: 37: The following error
>> occurred while executing this line:
>> C: \ ................ \ build.xml: 29: Problem: failed to create task
>> or type emf.Ecore2Java
>> Cause: The name is undefined.
>> Action: Check the spelling.
>> Action: Check That any custom tasks / types Have Been Declared.
>> Action: Check That <presetdef> any / declarations have taken place
>> <macrodef>.
>>
>>
>> Can you help me with this?
>>
>> thanks
>>
>>
>
Previous Topic:[EMF] XML Serialization sequentially
Next Topic:[EMF Validation] IBatchValidator.validate returns "No constraints were evaluated."
Goto Forum:
  


Current Time: Tue Jul 08 18:31:58 EDT 2025

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

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

Back to the top