October 2008
27 posts
5 tags
3 tags
6 tags
6 tags
6 tags
5 tags
7 tags
4 tags
4 tags
3 tags
Some dick’s “stolen” RudePhotos.com and RudyPhotos.com....
3 tags
2 tags
5 tags
6 tags
6 tags
4 tags
6 tags
4 tags
4 tags
4 tags
I haven’t watched any films for the past few days.
I can only write about...
– me - talking about getting proper drunk on Thursday.
What’s a good name for my Ruby blog? RudyCode, RudyGems, RudyRuby?...
– answers on a tweet to @MatthewRudy
5 tags
4 tags
a better :delegate method?
So we have;
class Bum
attr_accessor :pants
delegate :smelly?, :to => :pants
end
We want to ask;
bum.smelly?
clearly if the bum has pants, then it’s only smelly if the pants are smelly that’s cool, but what if the bum has no pants?
>> bum.pants
=> nil
>> bum.smelly?
NoMethodError: You have a nil object when you didn't expect it!
The error occurred...
September 2008
7 posts