Ok so name is a method on object and when you check Pharo it is defined like this:
name "Answer a name for the receiver. This is used generically in the title of certain inspectors, such as the referred-to inspector, and specificially by various subsystems. By default, we let the object just print itself out.. "
^ self printStringAnd printString on object is called which calls printStringLimitedTo: nnn
And that in turn calls 'class name'.
So you need to add the 'name' instance variable to Class and add the name method:
name "Answer the name of the receiver."
name == nil ifTrue: [^super name]
ifFalse: [^name]Of course this can get Cyclic.
What I need to do is ensure that as part of creating a subclass that the setName: method is called with
the appropriate name. I'll check where this is done, and please can you take care of the rest?
On Fri, Dec 23, 2011 at 6:15 PM, Lee Breisacher
<[hidden email]> wrote:
I'm not sure how to handle this. I'm simply doing self class name.
and getting (basically) 'name not understood'. But I'm not sure where to implement #name - presumably an instance method in Class - or how to implement it. A "real" Smalltalk has a 'name' inst var on Class, but here in RL 'self class' is..something internal.
Please advise.
Thanks,
Lee