W3C home > Mailing lists > Public > public-webapi@w3.org > February 2007

Re: Proposal: getElementsBySelector()

From: Erik Arvidsson <erik.arvidsson@gmail.com>
Date: Thu, 8 Feb 2007 08:52:34 -0800
Message-ID: <6eeb8bd10702080852s60264110i5743ed4627c8f407@mail.gmail.com>
To: "Christophe Jolif" <cjolif@ilog.fr>
Cc: "Charles McCathieNevile" <chaals@opera.com>, "Anne van Kesteren" <annevk@opera.com>, "Web API WG (public)" <public-webapi@w3.org>
Dojo changed this to dodo.query, see
http://blog.dojotoolkit.org/2007/02/04/dojoquery-a-css-query-engine-for-dojo

On 2/6/07, Christophe Jolif <cjolif@ilog.fr> wrote:
>
> Charles McCathieNevile wrote:
> > On Sun, 28 Jan 2007 13:41:10 +0530, Anne van Kesteren <annevk@opera.com> wrote:
> >
> >> Given the input from Björn I suppose there's no real need for a method
> >> that returns a single element node (assuming implementations make that
> >> optimization). Given that, I propose we rename .getAll() to
> >> .getElementsBySelector() and drop .get() (on both Document and Element).
> >>
> >> One advantage is that it's consistent with the naming people already use
> >> for custom written functions that have this functionality. In theory it's
> >> also not harder to type than .getElementsByTagName(). The only thing that
> >> makes it differ from the other getElementsBy* method(s) is that it doesn't
> >> return a live NodeList. I don't see that as a major problem.
> >>
> >> If there are no strong objections I'll implement this in the specification.
> >
> > Not having heard strong objections, and having had support for
> > getElementsBySelector() that is at least as strong as anything else, I think (with
> > my chair's hat) this can be taken as the current resolution of the naming debate.
> >
> > Which would also resolve ISSUE-110.
> >
> > Any objections?
>
> +1
>
> And I notice dojo has a
>
> dojo.getElementsByClass function, so it looks like very similar to the
> current naming for a similar functionality in existing widespread
> toolkit out there.
>
> --
> Christophe
>
>
>


-- 
erik
Received on Monday, 12 February 2007 05:02:12 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:18:57 GMT