ProtoObject.st
author Stefan Vogel <sv@exept.de>
Sat, 30 Oct 2004 16:34:04 +0200
changeset 8625 0e0637c66519
parent 8500 10d47cede03c
child 8728 d70396dc4e96
permissions -rw-r--r--
*** empty log message ***

"{ Package: 'stx:libbasic' }"

nil subclass:#ProtoObject
	instanceVariableNames:''
	classVariableNames:''
	poolDictionaries:''
	category:'Kernel-Objects'
!

!ProtoObject class methodsFor:'documentation'!

documentation
"
    a minimum object without much protocol;
    Provides the minimum required to prevent inspectors from crashing,
    and debuggers from blocking.
    (i.e. instead of inheriting from nil, better inherit from this).

    Named after a similar class found in Dolphin-Smalltalk.

    [author:]
        Claus Gittinger (not much authoring, though)
"
! !

!ProtoObject methodsFor:'error handling'!

doesNotUnderstand:aMessage
    "this message is sent by the runtime system (VM) when
     a message is not understood by some object (i.e. there
     is no method for that selector). The original message has
     been packed into aMessage (i.e. the receiver, selector and
     any arguments) and the original receiver is then sent the
     #doesNotUnderstand: message.
     Here, we raise another signal which usually enters the debugger.
     You can of course redefine #doesNotUnderstand: in your classes
     to implement message delegation, 
     or handle the MessageNotUnderstood exception gracefully."

    <context: #return>

    ^ MessageNotUnderstood raiseRequestWith:aMessage
! !

!ProtoObject methodsFor:'queries'!

class
    "return the receivers class"

%{  /* NOCONTEXT */

    RETURN ( __Class(self) );
%}

"
*** WARNING
***
*** this method has been automatically created,
*** since all nil-subclasses should respond to some minimum required
*** protocol.
***
*** Inspection and/or debugging of instances may not be possible,
*** if you remove/change this method. 
"
! !

!ProtoObject methodsFor:'testing'!

isBehavior
    ^ false
!

isBlock
    ^ false
!

isException
    ^ false
!

isExceptionHandler
    ^ false
!

isJavaObject
    ^ false
! !

!ProtoObject class methodsFor:'documentation'!

version
    ^ '$Header: /cvs/stx/stx/libbasic/ProtoObject.st,v 1.8 2004-08-30 18:00:25 stefan Exp $'
! !