Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » source refresh after running ant task
source refresh after running ant task [message #251955] Mon, 10 March 2008 09:45 Go to next message
Eclipse UserFriend
Hello,
I have an ant task that generates code (using JAXB's xjc task). After the
task is run I need to refresh the source tree, to that the newly generated
classes are picked up. Is there any way to do the refresh from within the
ant task?

Thanks,
Zohar
Re: source refresh after running ant task [message #251959 is a reply to message #251955] Mon, 10 March 2008 10:23 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: eclipse-news.rizzoweb.com

zohar wrote:
> Hello,
> I have an ant task that generates code (using JAXB's xjc task). After
> the task is run I need to refresh the source tree, to that the newly
> generated classes are picked up. Is there any way to do the refresh from
> within the ant task?

How are you invoking the Ant script? If you're launching it from inside
Eclipse, it uses a Launch configuration and you can edit that (via the
External Tools dialog - icon on the toolbar looks like a green circle,
white triangle, and red toolbox) and set it up to automatically refresh
the project after Ant runs.

Hope this helps,
Eric
Re: source refresh after running ant task [message #251979 is a reply to message #251955] Tue, 11 March 2008 06:42 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: valere.fedronic.ext.streamezzo.com

Hi,
<eclipse.refreshLocal resource="MyProject/MyFolder" depth="infinite"/>

* resource is a resource path relative to the workspace
* depth can be one of the following: zero, one or infinite

http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse. platform.doc.isv/guide/ant_eclipse_tasks.htm


Valere.


zohar a écrit :
> Hello,
> I have an ant task that generates code (using JAXB's xjc task). After
> the task is run I need to refresh the source tree, to that the newly
> generated classes are picked up. Is there any way to do the refresh from
> within the ant task?
>
> Thanks,
> Zohar
Re: source refresh after running ant task [message #251987 is a reply to message #251979] Tue, 11 March 2008 09:40 Go to previous messageGo to next message
Eclipse UserFriend
I get:

BUILD FAILED
c:\myWork\build.xml:193: Problem: failed to create task or type
eclipse.refreshLocal
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.

"valere fedronic" <valere.fedronic.ext@streamezzo.com> wrote in message
news:fr5nni$ldc$1@build.eclipse.org...
> Hi,
> <eclipse.refreshLocal resource="MyProject/MyFolder" depth="infinite"/>
>
> * resource is a resource path relative to the workspace
> * depth can be one of the following: zero, one or infinite
>
> http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse. platform.doc.isv/guide/ant_eclipse_tasks.htm
>
>
> Valere.
>
>
> zohar a écrit :
>> Hello,
>> I have an ant task that generates code (using JAXB's xjc task). After the
>> task is run I need to refresh the source tree, to that the newly
>> generated classes are picked up. Is there any way to do the refresh from
>> within the ant task?
>>
>> Thanks,
>> Zohar
Re: source refresh after running ant task [message #251990 is a reply to message #251987] Tue, 11 March 2008 09:57 Go to previous message
Eclipse UserFriend
The Ant builds needs to run in the same VM as Eclipse itself. See your
launch configuration for this setting.

Greets
Benny

zohar wrote:
> I get:
>
> BUILD FAILED
> c:\myWork\build.xml:193: Problem: failed to create task or type
> eclipse.refreshLocal
> Cause: The name is undefined.
> Action: Check the spelling.
> Action: Check that any custom tasks/types have been declared.
> Action: Check that any <presetdef>/<macrodef> declarations have taken
> place.
>
> "valere fedronic" <valere.fedronic.ext@streamezzo.com> wrote in message
> news:fr5nni$ldc$1@build.eclipse.org...
>> Hi,
>> <eclipse.refreshLocal resource="MyProject/MyFolder" depth="infinite"/>
>>
>> * resource is a resource path relative to the workspace
>> * depth can be one of the following: zero, one or infinite
>>
>> http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse. platform.doc.isv/guide/ant_eclipse_tasks.htm
>>
>>
>>
>> Valere.
>>
>>
>> zohar a écrit :
>>> Hello,
>>> I have an ant task that generates code (using JAXB's xjc task). After
>>> the task is run I need to refresh the source tree, to that the newly
>>> generated classes are picked up. Is there any way to do the refresh
>>> from within the ant task?
>>>
>>> Thanks,
>>> Zohar
>
Previous Topic:Error creating a Jar file in Java Project
Next Topic:How to prevent cursor re-positioning?
Goto Forum:
  


Current Time: Thu Apr 17 12:19:37 EDT 2025

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

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

Back to the top