<HTML>
<HEAD>
<TITLE>[Q] How you know author of methods in some Class ?</TITLE>
</HEAD>
<BODY>
<FONT SIZE="4"><FONT FACE="Calibri, Verdana, Helvetica, Arial"><SPAN STYLE='font-size:11pt'>Folks:<BR>
<BR>
I using some like:<BR>
<BR>
Utilities methodsWithInitials: 'edc' inClass: Object<BR>
<BR>
And for it <BR>
<BR>
CompiledMethod author<BR>
author<BR>
self timeStamp isEmpty<BR>
ifTrue: [^ 'unknown']<BR>
ifFalse: [^ self timeStamp substrings first]<BR>
<BR>
My old implementation is<BR>
<BR>
Utilities class methodsWithInitials:inClass:<BR>
methodsWithInitials: targetInitials inClass: aClass <BR>
"Based on a do-it contributed to the Squeak mailing list by Göran<BR>
Hultgen: Browse methods whose initials (in the time-stamp, as logged to<BR>
disk) match the given initials.<BR>
Print out the complete time-stamp table to the Transcript.<BR>
Answer a list of (initials -> count) associations.<BR>
<BR>
CAUTION: It may take several minutes for this to complete."<BR>
"Time millisecondsToRun: [Utilities methodsWithInitials: 'bf']"<BR>
| methodList methodListClass |<BR>
methodList := aClass methodDict<BR>
select: [:cm | cm author = targetInitials].<BR>
methodListClass := aClass class methodDict<BR>
select: [:cm | cm author = targetInitials].<BR>
^ methodList , methodListClass<BR>
<BR>
<BR>
Pros, Cons, better ways?<BR>
Like to go Trunk if possible...<BR>
<BR>
Edgar</SPAN></FONT></FONT>
</BODY>
</HTML>