Return-Path: Delivered-To: apmail-jakarta-ant-dev-archive@apache.org Received: (qmail 58105 invoked from network); 30 Jan 2002 07:51:00 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 30 Jan 2002 07:51:00 -0000 Received: (qmail 21987 invoked by uid 97); 30 Jan 2002 07:51:09 -0000 Delivered-To: qmlist-jakarta-archive-ant-dev@jakarta.apache.org Received: (qmail 21950 invoked by uid 97); 30 Jan 2002 07:51:08 -0000 Mailing-List: contact ant-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Developers List" Reply-To: "Ant Developers List" Delivered-To: mailing list ant-dev@jakarta.apache.org Received: (qmail 21939 invoked from network); 30 Jan 2002 07:51:08 -0000 Message-Id: <200201300751.g0U7p5R03537@mail004.syd.optusnet.com.au> Content-Type: text/plain; charset="utf-8" From: Peter Donald To: "Ant Developers List" Subject: Re: [IDEA] Polymorphic types Date: Wed, 30 Jan 2002 18:35:42 +1100 X-Mailer: KMail [version 1.3.2] References: In-Reply-To: X-Wisdom-Cookie: . MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N On Wed, 30 Jan 2002 07:12, Tim Dawson wrote: > I like the idea of polymorphic types, but I'm not sure about this type of > implementation - it requires that the type be a subclass of another type, > and would prohibit interface implementation from working. When I first ran > into a similar issue a while back I got to thinking that what would be a > better approach would be to pair this issue with the whole deployment > descriptor issue, and have each type optionally declare a "property" that > would be used to set it. (the DD issue comes into play because the third > declaration by necessity breaks the ability to use the simple properties > file to map the element name to the class) What you have essentially described is the concept of a role from myrmidon. It is open to debate whether inherited roles/role-subtyping is a good idea or not and whether it should be up to original developer or dynamically determined by runtime. > Does the general idea though, of actually registering the property name > work for people? I think it seems fairly obvious, especially when the > default is to use the element name. I would be very surprised if it could be integrated into Ant1.x successfully or not but feel free to try. However I think that it was +1ed for Ant2 features. -- Cheers, Pete *------------------------------------------------------* | "Nearly all men can stand adversity, but if you want | | to test a man's character, give him power." | | -Abraham Lincoln | *------------------------------------------------------* -- To unsubscribe, e-mail: For additional commands, e-mail: