Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 206F0200CAC for ; Mon, 5 Jun 2017 01:41:10 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 14B50160BE3; Sun, 4 Jun 2017 23:41:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 5A2AE160BE0 for ; Mon, 5 Jun 2017 01:41:09 +0200 (CEST) Received: (qmail 71113 invoked by uid 500); 4 Jun 2017 23:41:08 -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 71101 invoked by uid 99); 4 Jun 2017 23:41:07 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 04 Jun 2017 23:41:07 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 7BA2DCF192 for ; Sun, 4 Jun 2017 23:41:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.497 X-Spam-Level: X-Spam-Status: No, score=-1.497 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.796, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id UwjpP_sjxLRh for ; Sun, 4 Jun 2017 23:41:05 +0000 (UTC) Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id BB7D95FC64 for ; Sun, 4 Jun 2017 23:41:04 +0000 (UTC) Received: from [192.168.178.23] ([94.219.35.152]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0Lz3nU-1dvCyu157o-014D0q; Mon, 05 Jun 2017 01:40:57 +0200 From: Al Le Subject: Re: How to define a task with nested elements in Ant? To: Ant Users List , =?UTF-8?B?SmFuIE1hdMOocm5lIChqaG0p?= References: <96467fb5-de62-532a-6b56-43ef710a153b@gmx.de> <003901d2dcb2$3fd77560$bf866020$@de> Message-ID: <62b66eef-ccd1-e7bf-8250-a160fb9b2d62@gmx.de> Date: Mon, 5 Jun 2017 01:41:07 +0200 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <003901d2dcb2$3fd77560$bf866020$@de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-DE Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K0:eCi/QQKbhyPYds2hmsJxGQbbG5mz69LyGn4wxBLEMBLxi4ZNVty QUbL6fa5Z7Pq9XAGhrbCfjZXZ5YS4bAPMbGHE8pGsKnPv2QCs1Pw9eEauUvxycT/NmM7+ob Qr7lZqKK4oqhVdIZrG0N59Rtj7NyZfdtVAvXQEJSm3WE1l0z2kJqQwRRYAiYT8ZLFoEMiTR XCdNwyMCAcScwg/65bo9A== X-UI-Out-Filterresults: notjunk:1;V01:K0:mTMvO0O4eLA=:wZyXn6Z4+IL7Wq3XEO4h4I MeBwHzVu3vulv1696tn0gAIJk5guC1C4BB46mykIEtknry/JKhxDRcMgJFrxIAcmC8GaSMnQb N5LMJASPA1FAFb3pMYrtBUg1SP4HqIkggCxgxMIQHGWszg1SHnsbRAtF0zprbSFRRXpsuSKnB s6EFrUw0FXYOyJIWtxkZkBYkEh3VFDwcTh8U0/hZ0s4l/B93fzjConIOHFOZkCttYtzVFYezn vqHAtWdOihj6PnOhBlwp/FP9NocVuKqIIehhZdpI6/+oW1eewG9tQAJXGXjJZh7RqGWwXpB10 wK3lwE8BbV5/6rVL9VWTB4BVefpw+iFXzliSV6npV99W7PajIcRrqqYwI0CwY8OeSC//7BaXn ipCfPJGpG+8jafbyX8UTZ7pOKPadeurmpNisydT6SEDOybbujc/NEbBv7Tim6ty/kr7KKHWRl lMtq8LCt4JYLZBwa3YyAfOtIK+MXknXHgd/YIt/2vRI5u5CUFypHKb5r9goVtMav6EcTGXr/X dWimbJsSR4VoDUsQXupGmOxIiUXFNqlU9P2PDM9MIkmHqJ2maakKsN9YCXZ/Fa6ISxHk01jXn EmbZgKYn0uX8fM/ydrDSeurjrZsDV4+5kKqVEjdG8YsR1bt/Tow7HzQfQRELOPpwDbmXmZfhw RDrKFtryfu8b2U1XQgqLLUL+cCRR/Y0vAXjoLHsgZepYrDgYrjtwvjDf2aEMWSzXkx7rz4M/7 DtxMGBlB/rcEs6LcKk/ej1kTB2OW2ki0GxtIhwnW9YHiitvDoz2FAXfby/jo6DdhMukHt6phW EGJ+rVt archived-at: Sun, 04 Jun 2017 23:41:10 -0000 Hrm... It would be cool if there existed a task which would allow to construct the translation of the task in Ant into some other existing tasks, e.g. using XPath. I.e. you'd 1. Define the syntax of a new task; not with 'attribute' and 'element' (like in macrodef) but via e.g. XSD. 2. Define how instances of this task should translate into existing Ant tasks, e.g. using XSL. The first thing would be used by Ant to check whether the task is used properly. The second thing would be used to execute such a task: first, Ant would apply the XSL to the task instance which would yield a fragment consisting of known ant tasks; then Ant would execute this fragment. Have such thought been played with in the Ant community? I think, it would be a powerful tool to create custom tasks without having to code in Java. Just thinking aloud... Am 03.06.2017 um 23:42 schrieb Jan Matèrne (jhm): > I dont know any easy way. > Simplest thing would be writing that kind in Java. > And if you dont want to download that jar from your buildfile you could the jar creation inline: > - generate the code () > - compile () > - archive that () > - include that () > > Via