[英]Proper way to get all installed methods in Pharo
Sometimes you want to analyze all the methods in the image. 有时您想分析图像中的所有方法。 One way to do this is to work with CompiledMethod allInstances
. 一种方法是使用CompiledMethod allInstances
。 But it is dangerous to do it this way, as 但是这样做很危险,因为
A dialect independent expression would be 方言无关的表达是
ProtoObject withAllSubclasses gather: [:cls |
cls methodDictionary values asArray,
cls class methodDictionary values asArray]
我想到的一件事是:
RPackage organizer packages flatCollect: #methods
我建议使用SystemNavigation
,它是为此设计的类:
SystemNavigation default allMethodsSelect: [:m | true]
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.