Hello,

I'd like to implement a custom task. Its implementation would perform following things:

1. Create a file (in .properties format)

2. Do some magic (the main logic of the task) which uses the file created in step 1.

3. Delete the file created in step 1.

You see that the file from the step 1 is just a temporary one and should not remain after the task is completed.



I have some questions:

1. Is there an Ant API to create a temp file? Or should I just use the standard Java API for this?

2. How would I ensure that the file is deleted after the task completes? Is there some mechanisms for this is Ant? Or should I just carefully program try-catch-finally and delete the file in the finally block (or use try with resources)?

Thank you for any hints.

AL

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org

Reply via email to