Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 26959 invoked from network); 30 Jul 2007 06:01:02 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 Jul 2007 06:01:02 -0000 Received: (qmail 35199 invoked by uid 500); 30 Jul 2007 06:00:59 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 35157 invoked by uid 500); 30 Jul 2007 06:00:59 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 35144 invoked by uid 99); 30 Jul 2007 06:00:59 -0000 Received: from Unknown (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 29 Jul 2007 23:00:59 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [193.109.238.66] (HELO dnsinet.rzf-nrw.de) (193.109.238.66) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 30 Jul 2007 06:00:49 +0000 Received: from z011100.bk.fin.local (z011100.bk.fin.local [172.18.101.140]) by dnsinet.rzf-nrw.de (8.14.0/8.14.0) with ESMTP id l6U60Pwg023732 for ; Mon, 30 Jul 2007 08:00:25 +0200 Received: from z011034.bk.fin.local ([130.11.7.34]) by z011100.bk.fin.local with Microsoft SMTPSVC(6.0.3790.0); Mon, 30 Jul 2007 08:00:24 +0200 X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: AW: while-like structure in Ant Date: Mon, 30 Jul 2007 08:00:23 +0200 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: while-like structure in Ant Thread-Index: AcfRZnLKbLGVttwPRxyRCEvRk0MVyABCGu8w From: To: X-OriginalArrivalTime: 30 Jul 2007 06:00:24.0698 (UTC) FILETIME=[EBC28DA0:01C7D26E] X-Virus-Checked: Checked by ClamAV on apache.org Which task? Ant Core doesnt have one. Jan >-----Urspr=FCngliche Nachricht----- >Von: Emir Mahmut BAHSI [mailto:embahsi@yahoo.com]=20 >Gesendet: Sonntag, 29. Juli 2007 00:27 >An: Ant Users List >Betreff: RE: while-like structure in Ant > >Sorry everybody for the late replay. I am trying to implement=20 >that while structure as I explained before. I am using=20 >javascript for that. However, I can not create a http task in=20 >javascript code. That part of the code is: > >myhttp =3D project.createTask("http"); >myhttp.setUrl("a url address"); > >The error is: javax.script.ScriptException:=20 >sun.org.mozilla.javascript.internal.EcmaError: TypeError:=20 >Cannot call method "setUrl" of null <#5> in=20 > at line number 5 > >Any help is appreciated. Thanks in advance. > >Emir Mahmut Bahsi > > > > > > >"Rebhan, Gilbert" wrote: =20 >-----Original Message----- >From: Xavier Hanin [mailto:xavier.hanin@gmail.com]=20 >Sent: Thursday, May 10, 2007 9:17 AM >To: Ant Users List >Subject: Re: while-like structure in Ant > >On 5/10/07, Emir Mahmut BAHSI wrote: >> >> Hi all, >> I have been working on conditional structures and loop structures on >> existing workflow managers for a long time. For this purpose I have >> implemented two simple examples for if-type and switch-type cases >(examples >> are attached). In these examples my program is simply downloading a >file. If >> that file does not exist in the first web address it tries another >address. >> However, I could not implement a loop structure for that. In the loop >case >> the program should try the same address until the file exists. >Actually I >> know this is not a reasonable and useful scenario but I just want to >show >> whether a conditional-loop scenario can be implemented in Ant. >> >> Can u suggest me anything to implement that example. Any help is >> appreciated. > >/* >The ant-contrib project is providing conditional tasks which may help, >but >if you want to have your own syntax and the very specific url >availability >as a condition (like you wrote), maybe using a script (using scriptdef >for >example) would be a good fit. >*/ > >+1 > >i would go via and a scripting language running in >BSF >(JRuby, Groovy, Beanshell ... ) > >or use the AntBuilder@Groovy > >see =3D >http://groovy.codehaus.org/ >http://www.bytemycode.com/snippets/snippet/475/ > >Regards, Gilbert > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: user-unsubscribe@ant.apache.org >For additional commands, e-mail: user-help@ant.apache.org > > > > =20 >--------------------------------- >Take the Internet to Go: Yahoo!Go puts the Internet in your=20 >pocket: mail, news, photos & more.=20 > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org