I'm just impressed that all of this comes in a scripting language.  So
far my experiences with scripting languages have been limited to CF
which I would love to have these abilities.
Actually, even a simple 'counter += 1' available in cfscript would
make me happier.

Really though, the 'beauty' of Ruby is too hard to list in a simple
email.  I'm impressed with the fact the the number is an object in
Ruby.  So '1' has methods such as 1.upto(6).  Code Blocks are another
interesting feature.  You can define a 'code block' that can be sent
to a function and have that function include that 'code' during the
processing.

If you're interested, here's a link to an online 'Programming Ruby Book'

http://www.rubycentral.com/book/



On 4/25/05, S. Isaac Dealey <[EMAIL PROTECTED]> wrote:
> Sure... I was just commenting because I guess I was grasping at the
> original message "I'm in love with Ruby" and thinking "well, gee, if
> he's that impressed and he's posting about it to a CF list, it must be
> really unique/powerful" and trying to see in his message what the
> "love" was about... I'll give it unique -- I'm not necessarily sold on
> "powerful". :P
> 
> Not a big deal in any event -- I was just commenting.
> 
> 
> > Yes, you're right about being able to just define a new
> > method instead of
> > overriding an operator, but even simple addition (+) is a
> > method itself,
> > right?  Overriding itself (multiple methods with different
> > signatures) is
> > just a nice-to-have feature that is not necessary.
> 
> > - Matt Small
> 
> > -----Original Message-----
> > From: S.Isaac Dealey [mailto:[EMAIL PROTECTED]
> > Sent: Monday, April 25, 2005 9:34 AM
> > To: CF-Community
> > Subject: RE: I'm in love with Ruby
> 
> > Thanks Matt,
> 
> > You're right, I misread it... This makes a lot more
> > sense...
> 
> > Though I'm not sure I see a real advantage to it... I
> > mean...
> > Fullnames = FirstNames + LastNames might just as easily be
> > written
> > Fullnames = ArrayMerge(Firstnames,Lastnames) or
> > Fullnames.setNames(Firstnames,Lastnames)
> 
> > It's certainly interesting tho.
> 
> >> You may be missing the point with operator overriding.
> >> It
> >> exists to allow
> >> new classes to use the operators in a manner that is
> >> familiar but not
> >> intrinsically understood by a computer.
> 
> >> Say for instance you've written a class that is simply a
> >> list of names
> >> contained in an array.  You could have three instances of
> >> this class -
> >> Firstnames, Lastnames, and Fullnames.  Consider this
> >> operation:
> 
> >> Fullnames = Firstnames + Lastnames;
> 
> >> In most languages, this would not make any sense.  It's
> >> not even easily
> >> understood by a human as to the function of this list.
> >> But you can define
> >> the operation of the + sign to be any number of things:
> 
> >> 1)   Firstnames:     Issac, Matthew
> >>      Lastnames:      Dealey, Small
> >>      Fullnames:      Issac Dealy, Matthew Small
> 
> >> 2)   Firstnames:     Issac, Matthew
> >>      Lastnames:      Dealey, Small
> >>      Fullnames:      Issac, Matthew, Dealey, Small
> 
> >> 3)   Firstnames:     Issac, Matthew
> >>      Lastnames:      Dealey, Small
> >>      Fullnames:      IDsesaalcey, MSamtatlhlew
> 
> >> 2)   Firstnames:     Issac, Matthew
> >>      Lastnames:      Dealey, Small
> >>      Fullnames:      Issac, Dealy, Matthew, Small
> 
> >> Keep in mind that this operator overriding will only be
> >> effective for this
> >> particular class.  C= A + B where A, B, C are integers
> >> will still be normal
> >> addition.
> 
> >> - Matt Small
> 
> > s. isaac dealey   954.522.6080
> > new epoch : isn't it time for a change?
> 
> > add features without fixtures with
> > the onTap open source framework
> 
> > http://macromedia.breezecentral.com/p49777853/
> > http://www.sys-con.com/author/?id=4806
> > http://www.fusiontap.com
> 
> > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> >
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:5:155226
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/5
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:5
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.5
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to