1
0

Helios-References.deploy.js 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668
  1. smalltalk.addPackage('Helios-References');
  2. smalltalk.addClass('HLReferences', smalltalk.HLWidget, ['model', 'sendersListWidget', 'implementorsListWidget', 'classReferencesListWidget', 'regexpListWidget', 'sourceCodeWidget'], 'Helios-References');
  3. smalltalk.addMethod(
  4. smalltalk.method({
  5. selector: "classReferencesListWidget",
  6. fn: function (){
  7. var self=this;
  8. function $HLClassReferencesListWidget(){return smalltalk.HLClassReferencesListWidget||(typeof HLClassReferencesListWidget=="undefined"?nil:HLClassReferencesListWidget)}
  9. return smalltalk.withContext(function($ctx1) {
  10. var $2,$1;
  11. $2=self["@classReferencesListWidget"];
  12. if(($receiver = $2) == nil || $receiver == undefined){
  13. self["@classReferencesListWidget"]=_st($HLClassReferencesListWidget())._on_(_st(self)._model());
  14. self["@classReferencesListWidget"];
  15. $1=_st(self["@classReferencesListWidget"])._next_(_st(self)._regexpListWidget());
  16. } else {
  17. $1=$2;
  18. };
  19. return $1;
  20. }, function($ctx1) {$ctx1.fill(self,"classReferencesListWidget",{},smalltalk.HLReferences)})},
  21. messageSends: ["ifNil:", "on:", "model", "next:", "regexpListWidget"]}),
  22. smalltalk.HLReferences);
  23. smalltalk.addMethod(
  24. smalltalk.method({
  25. selector: "implementorsListWidget",
  26. fn: function (){
  27. var self=this;
  28. function $HLImplementorsListWidget(){return smalltalk.HLImplementorsListWidget||(typeof HLImplementorsListWidget=="undefined"?nil:HLImplementorsListWidget)}
  29. return smalltalk.withContext(function($ctx1) {
  30. var $2,$1;
  31. $2=self["@implementorsListWidget"];
  32. if(($receiver = $2) == nil || $receiver == undefined){
  33. self["@implementorsListWidget"]=_st($HLImplementorsListWidget())._on_(_st(self)._model());
  34. self["@implementorsListWidget"];
  35. $1=_st(self["@implementorsListWidget"])._next_(_st(self)._classReferencesListWidget());
  36. } else {
  37. $1=$2;
  38. };
  39. return $1;
  40. }, function($ctx1) {$ctx1.fill(self,"implementorsListWidget",{},smalltalk.HLReferences)})},
  41. messageSends: ["ifNil:", "on:", "model", "next:", "classReferencesListWidget"]}),
  42. smalltalk.HLReferences);
  43. smalltalk.addMethod(
  44. smalltalk.method({
  45. selector: "model",
  46. fn: function (){
  47. var self=this;
  48. function $HLReferencesModel(){return smalltalk.HLReferencesModel||(typeof HLReferencesModel=="undefined"?nil:HLReferencesModel)}
  49. return smalltalk.withContext(function($ctx1) {
  50. var $2,$3,$4,$1;
  51. $2=self["@model"];
  52. if(($receiver = $2) == nil || $receiver == undefined){
  53. $3=_st($HLReferencesModel())._new();
  54. _st($3)._environment_(_st(_st(self)._manager())._environment());
  55. $4=_st($3)._yourself();
  56. self["@model"]=$4;
  57. $1=self["@model"];
  58. } else {
  59. $1=$2;
  60. };
  61. return $1;
  62. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLReferences)})},
  63. messageSends: ["ifNil:", "environment:", "environment", "manager", "new", "yourself"]}),
  64. smalltalk.HLReferences);
  65. smalltalk.addMethod(
  66. smalltalk.method({
  67. selector: "model:",
  68. fn: function (aModel){
  69. var self=this;
  70. return smalltalk.withContext(function($ctx1) {
  71. self["@model"]=aModel;
  72. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLReferences)})},
  73. messageSends: []}),
  74. smalltalk.HLReferences);
  75. smalltalk.addMethod(
  76. smalltalk.method({
  77. selector: "open",
  78. fn: function (){
  79. var self=this;
  80. function $HLTab(){return smalltalk.HLTab||(typeof HLTab=="undefined"?nil:HLTab)}
  81. function $HLManager(){return smalltalk.HLManager||(typeof HLManager=="undefined"?nil:HLManager)}
  82. return smalltalk.withContext(function($ctx1) {
  83. _st(_st($HLManager())._current())._addTab_(_st($HLTab())._on_labelled_(self,_st(_st(self)._class())._tabLabel()));
  84. return self}, function($ctx1) {$ctx1.fill(self,"open",{},smalltalk.HLReferences)})},
  85. messageSends: ["addTab:", "on:labelled:", "tabLabel", "class", "current"]}),
  86. smalltalk.HLReferences);
  87. smalltalk.addMethod(
  88. smalltalk.method({
  89. selector: "regexpListWidget",
  90. fn: function (){
  91. var self=this;
  92. function $HLRegexpListWidget(){return smalltalk.HLRegexpListWidget||(typeof HLRegexpListWidget=="undefined"?nil:HLRegexpListWidget)}
  93. return smalltalk.withContext(function($ctx1) {
  94. var $2,$1;
  95. $2=self["@regexpListWidget"];
  96. if(($receiver = $2) == nil || $receiver == undefined){
  97. self["@regexpListWidget"]=_st($HLRegexpListWidget())._on_(_st(self)._model());
  98. self["@regexpListWidget"];
  99. $1=_st(self["@regexpListWidget"])._next_(_st(self)._sourceCodeWidget());
  100. } else {
  101. $1=$2;
  102. };
  103. return $1;
  104. }, function($ctx1) {$ctx1.fill(self,"regexpListWidget",{},smalltalk.HLReferences)})},
  105. messageSends: ["ifNil:", "on:", "model", "next:", "sourceCodeWidget"]}),
  106. smalltalk.HLReferences);
  107. smalltalk.addMethod(
  108. smalltalk.method({
  109. selector: "renderContentOn:",
  110. fn: function (html){
  111. var self=this;
  112. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  113. function $HLHorizontalSplitter(){return smalltalk.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  114. function $HLContainer(){return smalltalk.HLContainer||(typeof HLContainer=="undefined"?nil:HLContainer)}
  115. return smalltalk.withContext(function($ctx1) {
  116. _st(html)._with_(_st($HLContainer())._with_(_st($HLHorizontalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st(self)._sendersListWidget(),_st(self)._implementorsListWidget()),_st($HLVerticalSplitter())._with_with_(_st(self)._classReferencesListWidget(),_st(self)._regexpListWidget())),_st(self)._sourceCodeWidget())));
  117. _st(_st(self)._sendersListWidget())._focus();
  118. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLReferences)})},
  119. messageSends: ["with:", "with:with:", "sendersListWidget", "implementorsListWidget", "classReferencesListWidget", "regexpListWidget", "sourceCodeWidget", "focus"]}),
  120. smalltalk.HLReferences);
  121. smalltalk.addMethod(
  122. smalltalk.method({
  123. selector: "search:",
  124. fn: function (aString){
  125. var self=this;
  126. return smalltalk.withContext(function($ctx1) {
  127. _st(_st(self)._model())._search_(aString);
  128. return self}, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},smalltalk.HLReferences)})},
  129. messageSends: ["search:", "model"]}),
  130. smalltalk.HLReferences);
  131. smalltalk.addMethod(
  132. smalltalk.method({
  133. selector: "sendersListWidget",
  134. fn: function (){
  135. var self=this;
  136. function $HLSendersListWidget(){return smalltalk.HLSendersListWidget||(typeof HLSendersListWidget=="undefined"?nil:HLSendersListWidget)}
  137. return smalltalk.withContext(function($ctx1) {
  138. var $2,$1;
  139. $2=self["@sendersListWidget"];
  140. if(($receiver = $2) == nil || $receiver == undefined){
  141. self["@sendersListWidget"]=_st($HLSendersListWidget())._on_(_st(self)._model());
  142. self["@sendersListWidget"];
  143. $1=_st(self["@sendersListWidget"])._next_(_st(self)._implementorsListWidget());
  144. } else {
  145. $1=$2;
  146. };
  147. return $1;
  148. }, function($ctx1) {$ctx1.fill(self,"sendersListWidget",{},smalltalk.HLReferences)})},
  149. messageSends: ["ifNil:", "on:", "model", "next:", "implementorsListWidget"]}),
  150. smalltalk.HLReferences);
  151. smalltalk.addMethod(
  152. smalltalk.method({
  153. selector: "sourceCodeWidget",
  154. fn: function (){
  155. var self=this;
  156. function $HLNavigationCodeWidget(){return smalltalk.HLNavigationCodeWidget||(typeof HLNavigationCodeWidget=="undefined"?nil:HLNavigationCodeWidget)}
  157. return smalltalk.withContext(function($ctx1) {
  158. var $2,$1;
  159. $2=self["@sourceCodeWidget"];
  160. if(($receiver = $2) == nil || $receiver == undefined){
  161. self["@sourceCodeWidget"]=_st($HLNavigationCodeWidget())._new();
  162. $1=self["@sourceCodeWidget"];
  163. } else {
  164. $1=$2;
  165. };
  166. return $1;
  167. }, function($ctx1) {$ctx1.fill(self,"sourceCodeWidget",{},smalltalk.HLReferences)})},
  168. messageSends: ["ifNil:", "new"]}),
  169. smalltalk.HLReferences);
  170. smalltalk.addMethod(
  171. smalltalk.method({
  172. selector: "canBeOpenAsTab",
  173. fn: function (){
  174. var self=this;
  175. return smalltalk.withContext(function($ctx1) {
  176. return false;
  177. }, function($ctx1) {$ctx1.fill(self,"canBeOpenAsTab",{},smalltalk.HLReferences.klass)})},
  178. messageSends: []}),
  179. smalltalk.HLReferences.klass);
  180. smalltalk.addMethod(
  181. smalltalk.method({
  182. selector: "tabLabel",
  183. fn: function (){
  184. var self=this;
  185. return smalltalk.withContext(function($ctx1) {
  186. return "References";
  187. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLReferences.klass)})},
  188. messageSends: []}),
  189. smalltalk.HLReferences.klass);
  190. smalltalk.addMethod(
  191. smalltalk.method({
  192. selector: "tabPriority",
  193. fn: function (){
  194. var self=this;
  195. return smalltalk.withContext(function($ctx1) {
  196. var $1;
  197. $1=(100);
  198. return $1;
  199. }, function($ctx1) {$ctx1.fill(self,"tabPriority",{},smalltalk.HLReferences.klass)})},
  200. messageSends: []}),
  201. smalltalk.HLReferences.klass);
  202. smalltalk.addClass('HLReferencesListWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-References');
  203. smalltalk.addMethod(
  204. smalltalk.method({
  205. selector: "label",
  206. fn: function (){
  207. var self=this;
  208. return smalltalk.withContext(function($ctx1) {
  209. return "List";
  210. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLReferencesListWidget)})},
  211. messageSends: []}),
  212. smalltalk.HLReferencesListWidget);
  213. smalltalk.addMethod(
  214. smalltalk.method({
  215. selector: "model",
  216. fn: function (){
  217. var self=this;
  218. return smalltalk.withContext(function($ctx1) {
  219. var $1;
  220. $1=self["@model"];
  221. return $1;
  222. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLReferencesListWidget)})},
  223. messageSends: []}),
  224. smalltalk.HLReferencesListWidget);
  225. smalltalk.addMethod(
  226. smalltalk.method({
  227. selector: "model:",
  228. fn: function (aModel){
  229. var self=this;
  230. return smalltalk.withContext(function($ctx1) {
  231. self["@model"]=aModel;
  232. _st(self)._observeModel();
  233. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLReferencesListWidget)})},
  234. messageSends: ["observeModel"]}),
  235. smalltalk.HLReferencesListWidget);
  236. smalltalk.addMethod(
  237. smalltalk.method({
  238. selector: "observeModel",
  239. fn: function (){
  240. var self=this;
  241. function $HLSearchReferences(){return smalltalk.HLSearchReferences||(typeof HLSearchReferences=="undefined"?nil:HLSearchReferences)}
  242. return smalltalk.withContext(function($ctx1) {
  243. _st(_st(_st(self)._model())._announcer())._on_do_($HLSearchReferences(),(function(ann){
  244. return smalltalk.withContext(function($ctx2) {
  245. return _st(self)._onSearchReferences_(_st(ann)._searchString());
  246. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  247. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLReferencesListWidget)})},
  248. messageSends: ["on:do:", "onSearchReferences:", "searchString", "announcer", "model"]}),
  249. smalltalk.HLReferencesListWidget);
  250. smalltalk.addMethod(
  251. smalltalk.method({
  252. selector: "onSearchReferences:",
  253. fn: function (aString){
  254. var self=this;
  255. return smalltalk.withContext(function($ctx1) {
  256. _st(self)._subclassResponsibility();
  257. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},smalltalk.HLReferencesListWidget)})},
  258. messageSends: ["subclassResponsibility"]}),
  259. smalltalk.HLReferencesListWidget);
  260. smalltalk.addMethod(
  261. smalltalk.method({
  262. selector: "renderContentOn:",
  263. fn: function (html){
  264. var self=this;
  265. return smalltalk.withContext(function($ctx1) {
  266. _st(self)._renderHeadOn_(html);
  267. smalltalk.HLNavigationListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  268. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLReferencesListWidget)})},
  269. messageSends: ["renderHeadOn:", "renderContentOn:"]}),
  270. smalltalk.HLReferencesListWidget);
  271. smalltalk.addMethod(
  272. smalltalk.method({
  273. selector: "renderHeadOn:",
  274. fn: function (html){
  275. var self=this;
  276. return smalltalk.withContext(function($ctx1) {
  277. var $1,$2;
  278. $1=_st(html)._div();
  279. _st($1)._class_("list-label");
  280. $2=_st($1)._with_((function(){
  281. return smalltalk.withContext(function($ctx2) {
  282. return _st(html)._with_(_st(self)._label());
  283. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  284. return self}, function($ctx1) {$ctx1.fill(self,"renderHeadOn:",{html:html},smalltalk.HLReferencesListWidget)})},
  285. messageSends: ["class:", "div", "with:", "label"]}),
  286. smalltalk.HLReferencesListWidget);
  287. smalltalk.addMethod(
  288. smalltalk.method({
  289. selector: "renderItemLabel:on:",
  290. fn: function (aMethod,html){
  291. var self=this;
  292. return smalltalk.withContext(function($ctx1) {
  293. _st(html)._with_(_st(_st(_st(_st(aMethod)._methodClass())._name()).__comma(" >> #")).__comma(_st(aMethod)._selector()));
  294. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aMethod:aMethod,html:html},smalltalk.HLReferencesListWidget)})},
  295. messageSends: ["with:", ",", "selector", "name", "methodClass"]}),
  296. smalltalk.HLReferencesListWidget);
  297. smalltalk.addMethod(
  298. smalltalk.method({
  299. selector: "on:",
  300. fn: function (aModel){
  301. var self=this;
  302. return smalltalk.withContext(function($ctx1) {
  303. var $2,$3,$1;
  304. $2=_st(self)._new();
  305. _st($2)._model_(aModel);
  306. $3=_st($2)._yourself();
  307. $1=$3;
  308. return $1;
  309. }, function($ctx1) {$ctx1.fill(self,"on:",{aModel:aModel},smalltalk.HLReferencesListWidget.klass)})},
  310. messageSends: ["model:", "new", "yourself"]}),
  311. smalltalk.HLReferencesListWidget.klass);
  312. smalltalk.addClass('HLClassReferencesListWidget', smalltalk.HLReferencesListWidget, [], 'Helios-References');
  313. smalltalk.addMethod(
  314. smalltalk.method({
  315. selector: "label",
  316. fn: function (){
  317. var self=this;
  318. return smalltalk.withContext(function($ctx1) {
  319. return "Class references";
  320. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLClassReferencesListWidget)})},
  321. messageSends: []}),
  322. smalltalk.HLClassReferencesListWidget);
  323. smalltalk.addMethod(
  324. smalltalk.method({
  325. selector: "onSearchReferences:",
  326. fn: function (aString){
  327. var self=this;
  328. return smalltalk.withContext(function($ctx1) {
  329. _st(self)._selectItem_(nil);
  330. _st(self)._items_(_st(_st(self)._model())._classReferencesOf_(aString));
  331. _st(self)._refresh();
  332. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},smalltalk.HLClassReferencesListWidget)})},
  333. messageSends: ["selectItem:", "items:", "classReferencesOf:", "model", "refresh"]}),
  334. smalltalk.HLClassReferencesListWidget);
  335. smalltalk.addClass('HLImplementorsListWidget', smalltalk.HLReferencesListWidget, [], 'Helios-References');
  336. smalltalk.addMethod(
  337. smalltalk.method({
  338. selector: "label",
  339. fn: function (){
  340. var self=this;
  341. return smalltalk.withContext(function($ctx1) {
  342. return "Implementors";
  343. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLImplementorsListWidget)})},
  344. messageSends: []}),
  345. smalltalk.HLImplementorsListWidget);
  346. smalltalk.addMethod(
  347. smalltalk.method({
  348. selector: "onSearchReferences:",
  349. fn: function (aString){
  350. var self=this;
  351. return smalltalk.withContext(function($ctx1) {
  352. _st(self)._selectItem_(nil);
  353. _st(self)._items_(_st(_st(self)._model())._implementorsOf_(aString));
  354. _st(self)._refresh();
  355. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},smalltalk.HLImplementorsListWidget)})},
  356. messageSends: ["selectItem:", "items:", "implementorsOf:", "model", "refresh"]}),
  357. smalltalk.HLImplementorsListWidget);
  358. smalltalk.addClass('HLRegexpListWidget', smalltalk.HLReferencesListWidget, [], 'Helios-References');
  359. smalltalk.addMethod(
  360. smalltalk.method({
  361. selector: "label",
  362. fn: function (){
  363. var self=this;
  364. return smalltalk.withContext(function($ctx1) {
  365. return "Source search";
  366. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLRegexpListWidget)})},
  367. messageSends: []}),
  368. smalltalk.HLRegexpListWidget);
  369. smalltalk.addMethod(
  370. smalltalk.method({
  371. selector: "onSearchReferences:",
  372. fn: function (aString){
  373. var self=this;
  374. return smalltalk.withContext(function($ctx1) {
  375. _st(self)._selectItem_(nil);
  376. _st(self)._items_(_st(_st(self)._model())._regexpReferencesOf_(aString));
  377. _st(self)._refresh();
  378. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},smalltalk.HLRegexpListWidget)})},
  379. messageSends: ["selectItem:", "items:", "regexpReferencesOf:", "model", "refresh"]}),
  380. smalltalk.HLRegexpListWidget);
  381. smalltalk.addClass('HLSendersListWidget', smalltalk.HLReferencesListWidget, [], 'Helios-References');
  382. smalltalk.addMethod(
  383. smalltalk.method({
  384. selector: "label",
  385. fn: function (){
  386. var self=this;
  387. return smalltalk.withContext(function($ctx1) {
  388. return "Senders";
  389. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLSendersListWidget)})},
  390. messageSends: []}),
  391. smalltalk.HLSendersListWidget);
  392. smalltalk.addMethod(
  393. smalltalk.method({
  394. selector: "onSearchReferences:",
  395. fn: function (aString){
  396. var self=this;
  397. return smalltalk.withContext(function($ctx1) {
  398. _st(self)._selectItem_(nil);
  399. _st(self)._items_(_st(_st(self)._model())._sendersOf_(aString));
  400. _st(self)._refresh();
  401. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},smalltalk.HLSendersListWidget)})},
  402. messageSends: ["selectItem:", "items:", "sendersOf:", "model", "refresh"]}),
  403. smalltalk.HLSendersListWidget);
  404. smalltalk.addClass('HLReferencesModel', smalltalk.HLModel, ['methodsCache', 'classesAndMetaclassesCache'], 'Helios-References');
  405. smalltalk.addMethod(
  406. smalltalk.method({
  407. selector: "allMethods",
  408. fn: function (){
  409. var self=this;
  410. return smalltalk.withContext(function($ctx1) {
  411. var $1;
  412. $1=_st(self)._methodsCache();
  413. return $1;
  414. }, function($ctx1) {$ctx1.fill(self,"allMethods",{},smalltalk.HLReferencesModel)})},
  415. messageSends: ["methodsCache"]}),
  416. smalltalk.HLReferencesModel);
  417. smalltalk.addMethod(
  418. smalltalk.method({
  419. selector: "allSelectors",
  420. fn: function (){
  421. var self=this;
  422. return smalltalk.withContext(function($ctx1) {
  423. var $1;
  424. $1=_st(_st(_st(self)._allMethods())._collect_((function(each){
  425. return smalltalk.withContext(function($ctx2) {
  426. return _st(each)._selector();
  427. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._asSet();
  428. return $1;
  429. }, function($ctx1) {$ctx1.fill(self,"allSelectors",{},smalltalk.HLReferencesModel)})},
  430. messageSends: ["asSet", "collect:", "selector", "allMethods"]}),
  431. smalltalk.HLReferencesModel);
  432. smalltalk.addMethod(
  433. smalltalk.method({
  434. selector: "classReferencesOf:",
  435. fn: function (aString){
  436. var self=this;
  437. var references;
  438. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  439. return smalltalk.withContext(function($ctx1) {
  440. var $1,$2;
  441. references=_st($OrderedCollection())._new();
  442. _st(_st(self)._classesAndMetaclasses())._do_((function(each){
  443. return smalltalk.withContext(function($ctx2) {
  444. return _st(_st(_st(each)._methodDictionary())._values())._do_((function(method){
  445. return smalltalk.withContext(function($ctx3) {
  446. $1=_st(_st(method)._referencedClasses())._includes_(aString);
  447. if(smalltalk.assert($1)){
  448. return _st(references)._add_(method);
  449. };
  450. }, function($ctx3) {$ctx3.fillBlock({method:method},$ctx1)})}));
  451. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  452. $2=references;
  453. return $2;
  454. }, function($ctx1) {$ctx1.fill(self,"classReferencesOf:",{aString:aString,references:references},smalltalk.HLReferencesModel)})},
  455. messageSends: ["new", "do:", "ifTrue:", "add:", "includes:", "referencedClasses", "values", "methodDictionary", "classesAndMetaclasses"]}),
  456. smalltalk.HLReferencesModel);
  457. smalltalk.addMethod(
  458. smalltalk.method({
  459. selector: "classesAndMetaclasses",
  460. fn: function (){
  461. var self=this;
  462. return smalltalk.withContext(function($ctx1) {
  463. var $1;
  464. $1=_st(self)._classesAndMetaclassesCache();
  465. return $1;
  466. }, function($ctx1) {$ctx1.fill(self,"classesAndMetaclasses",{},smalltalk.HLReferencesModel)})},
  467. messageSends: ["classesAndMetaclassesCache"]}),
  468. smalltalk.HLReferencesModel);
  469. smalltalk.addMethod(
  470. smalltalk.method({
  471. selector: "classesAndMetaclassesCache",
  472. fn: function (){
  473. var self=this;
  474. return smalltalk.withContext(function($ctx1) {
  475. var $1,$2;
  476. $1=self["@classesAndMetaclassesCache"];
  477. if(($receiver = $1) == nil || $receiver == undefined){
  478. _st(self)._updateClassesAndMetaclassesCache();
  479. } else {
  480. $1;
  481. };
  482. $2=self["@classesAndMetaclassesCache"];
  483. return $2;
  484. }, function($ctx1) {$ctx1.fill(self,"classesAndMetaclassesCache",{},smalltalk.HLReferencesModel)})},
  485. messageSends: ["ifNil:", "updateClassesAndMetaclassesCache"]}),
  486. smalltalk.HLReferencesModel);
  487. smalltalk.addMethod(
  488. smalltalk.method({
  489. selector: "implementorsOf:",
  490. fn: function (aString){
  491. var self=this;
  492. return smalltalk.withContext(function($ctx1) {
  493. var $1;
  494. $1=_st(_st(self)._allMethods())._select_((function(each){
  495. return smalltalk.withContext(function($ctx2) {
  496. return _st(_st(each)._selector()).__eq(aString);
  497. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  498. return $1;
  499. }, function($ctx1) {$ctx1.fill(self,"implementorsOf:",{aString:aString},smalltalk.HLReferencesModel)})},
  500. messageSends: ["select:", "=", "selector", "allMethods"]}),
  501. smalltalk.HLReferencesModel);
  502. smalltalk.addMethod(
  503. smalltalk.method({
  504. selector: "methodsCache",
  505. fn: function (){
  506. var self=this;
  507. return smalltalk.withContext(function($ctx1) {
  508. var $1,$2;
  509. $1=self["@methodsCache"];
  510. if(($receiver = $1) == nil || $receiver == undefined){
  511. _st(self)._updateMethodsCache();
  512. } else {
  513. $1;
  514. };
  515. $2=self["@methodsCache"];
  516. return $2;
  517. }, function($ctx1) {$ctx1.fill(self,"methodsCache",{},smalltalk.HLReferencesModel)})},
  518. messageSends: ["ifNil:", "updateMethodsCache"]}),
  519. smalltalk.HLReferencesModel);
  520. smalltalk.addMethod(
  521. smalltalk.method({
  522. selector: "regexpReferencesOf:",
  523. fn: function (aString){
  524. var self=this;
  525. return smalltalk.withContext(function($ctx1) {
  526. var $1;
  527. $1=_st(_st(self)._allMethods())._select_((function(each){
  528. return smalltalk.withContext(function($ctx2) {
  529. return _st(_st(each)._source())._match_(aString);
  530. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  531. return $1;
  532. }, function($ctx1) {$ctx1.fill(self,"regexpReferencesOf:",{aString:aString},smalltalk.HLReferencesModel)})},
  533. messageSends: ["select:", "match:", "source", "allMethods"]}),
  534. smalltalk.HLReferencesModel);
  535. smalltalk.addMethod(
  536. smalltalk.method({
  537. selector: "search:",
  538. fn: function (aString){
  539. var self=this;
  540. function $HLSearchReferences(){return smalltalk.HLSearchReferences||(typeof HLSearchReferences=="undefined"?nil:HLSearchReferences)}
  541. return smalltalk.withContext(function($ctx1) {
  542. var $1,$2;
  543. _st(self)._updateCaches();
  544. $1=_st($HLSearchReferences())._new();
  545. _st($1)._searchString_(aString);
  546. $2=_st($1)._yourself();
  547. _st(_st(self)._announcer())._announce_($2);
  548. return self}, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},smalltalk.HLReferencesModel)})},
  549. messageSends: ["updateCaches", "announce:", "searchString:", "new", "yourself", "announcer"]}),
  550. smalltalk.HLReferencesModel);
  551. smalltalk.addMethod(
  552. smalltalk.method({
  553. selector: "sendersOf:",
  554. fn: function (aString){
  555. var self=this;
  556. return smalltalk.withContext(function($ctx1) {
  557. var $1;
  558. $1=_st(_st(self)._allMethods())._select_((function(each){
  559. return smalltalk.withContext(function($ctx2) {
  560. return _st(_st(each)._messageSends())._includes_(aString);
  561. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  562. return $1;
  563. }, function($ctx1) {$ctx1.fill(self,"sendersOf:",{aString:aString},smalltalk.HLReferencesModel)})},
  564. messageSends: ["select:", "includes:", "messageSends", "allMethods"]}),
  565. smalltalk.HLReferencesModel);
  566. smalltalk.addMethod(
  567. smalltalk.method({
  568. selector: "updateCaches",
  569. fn: function (){
  570. var self=this;
  571. return smalltalk.withContext(function($ctx1) {
  572. var $1,$2;
  573. $1=self;
  574. _st($1)._updateClassesAndMetaclassesCache();
  575. $2=_st($1)._updateMethodsCache();
  576. return self}, function($ctx1) {$ctx1.fill(self,"updateCaches",{},smalltalk.HLReferencesModel)})},
  577. messageSends: ["updateClassesAndMetaclassesCache", "updateMethodsCache"]}),
  578. smalltalk.HLReferencesModel);
  579. smalltalk.addMethod(
  580. smalltalk.method({
  581. selector: "updateClassesAndMetaclassesCache",
  582. fn: function (){
  583. var self=this;
  584. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  585. return smalltalk.withContext(function($ctx1) {
  586. var $1,$2;
  587. self["@classesAndMetaclassesCache"]=_st(_st(_st(self)._environment())._classes())._inject_into_(_st($OrderedCollection())._new(),(function(acc,each){
  588. return smalltalk.withContext(function($ctx2) {
  589. $1=acc;
  590. _st($1)._add_(each);
  591. _st($1)._add_(_st(each)._class());
  592. $2=_st($1)._yourself();
  593. return $2;
  594. }, function($ctx2) {$ctx2.fillBlock({acc:acc,each:each},$ctx1)})}));
  595. return self}, function($ctx1) {$ctx1.fill(self,"updateClassesAndMetaclassesCache",{},smalltalk.HLReferencesModel)})},
  596. messageSends: ["inject:into:", "new", "add:", "class", "yourself", "classes", "environment"]}),
  597. smalltalk.HLReferencesModel);
  598. smalltalk.addMethod(
  599. smalltalk.method({
  600. selector: "updateMethodsCache",
  601. fn: function (){
  602. var self=this;
  603. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  604. return smalltalk.withContext(function($ctx1) {
  605. self["@methodsCache"]=_st(_st(self)._classesAndMetaclasses())._inject_into_(_st($OrderedCollection())._new(),(function(acc,each){
  606. return smalltalk.withContext(function($ctx2) {
  607. return _st(acc).__comma(_st(each)._methods());
  608. }, function($ctx2) {$ctx2.fillBlock({acc:acc,each:each},$ctx1)})}));
  609. return self}, function($ctx1) {$ctx1.fill(self,"updateMethodsCache",{},smalltalk.HLReferencesModel)})},
  610. messageSends: ["inject:into:", "new", ",", "methods", "classesAndMetaclasses"]}),
  611. smalltalk.HLReferencesModel);