On 6/25/07, Tobie Langel <[EMAIL PROTECTED]> wrote:
>
>
> > Yes, keep it lower-case and add an "s" so it reads better :)
> > Cow-Class "extends" Animal (and) "includes" Eatable, Breadable ...
>
> Remember that the idea is to distinguish them easily from "instance"
> methods, hence capitalizing or prepending a $ sign.
>

still a no-go for me. Classnames are capitialized, methods and vars
are lowercase. Its always been that way in all the "common" coding
guidlines ..

But if you insist, what about an underscore instead?

 var Cow = new Class({
      _extends: Animal,
      _includes: [Eatable, Breedable],
      initialize: ..
 });

I personally have no problem to remember that the interface is made
out of three reserved names. There is really no need to prefix them,
or stand out. Think: does "initialize" stand out? Also "extend" and
"include" are no methods, so you can't even call them "by accident".
Maybe you even want to overwrite them, to dynamically change the
design model on runtime...

 var Name = new Class({
      extends: null,
      includes: [],
      initialize: function() {}
 });

Bottom line: I wouldn't make them any more special then just that.
There are so many properties and names that are in API without any
extra-candy and no one ever lost a word about that either. Keep it
simple. :)

Best,
Kjell

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype: Core" group.
To post to this group, send email to prototype-core@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-core?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to