WrappedMethod.st
author claus
Mon, 28 Nov 1994 21:57:03 +0100
changeset 14 530bf06f9c78
parent 10 676ce0471de4
child 16 fcbfbba03d49
permissions -rw-r--r--
*** empty log message ***

"
 COPYRIGHT (c) 1994 by Claus Gittinger
	      All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"

Method subclass:#WrappedMethod
	 instanceVariableNames:''
	 classVariableNames:''
	 poolDictionaries:''
	 category:'Kernel-Methods'
!

WrappedMethod comment:'
COPYRIGHT (c) 1994 by Claus Gittinger
	      All Rights Reserved

$Header: /cvs/stx/stx/libbasic3/WrappedMethod.st,v 1.4 1994-11-28 20:57:03 claus Exp $
'!

!WrappedMethod class methodsFor:'documentation'!

copyright
"
 COPYRIGHT (c) 1994 by Claus Gittinger
	      All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"
!

version
"
$Header: /cvs/stx/stx/libbasic3/WrappedMethod.st,v 1.4 1994-11-28 20:57:03 claus Exp $
"
!

documentation
"
    support for MessageTracer
"
! !

!WrappedMethod methodsFor:'queries'!

isWrapped
    "return true, if the receiver is a wrapped method.
     True is returned here, since the receiver is always a wrapped one"

    ^ true
! !

!WrappedMethod methodsFor:'accessing'!

originalMethod
    "return the method the receiver is wrapping"

    "a kludge: it must be in the literal array somewhere"
    literals do:[:aLiteral |
	aLiteral class == Method ifTrue:[
	    ^ aLiteral
	]
    ].
    ^ nil
!

basicLiterals
    "return my literals"

    ^ literals
!

source
    "return the wrapped methods source"

    ^ self originalMethod source
!

literals
    "return the wrapped methods literals"

    ^ self originalMethod literals
!

numberOfMethodVars
    "return the number of locals in the wrapped method."

    ^ self originalMethod numberOfMethodVars 
!

methodVarNames
    "return the names of the locals of the wrapped method."

    ^ self originalMethod methodVarNames 
!

methodArgAndVarNames
    "return the names of the args and locals of the wrapped method."

    ^ self originalMethod methodArgAndVarNames
! !