Importer-Exporter.deploy.js 81 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063
  1. (function(smalltalk,nil,_st){
  2. smalltalk.addPackage('Importer-Exporter');
  3. smalltalk.addClass('AbstractExporter', smalltalk.Object, [], 'Importer-Exporter');
  4. smalltalk.addMethod(
  5. smalltalk.method({
  6. selector: "chunkEscape:",
  7. fn: function (aString){
  8. var self=this;
  9. return smalltalk.withContext(function($ctx1) {
  10. var $1;
  11. $1=_st(_st(aString)._replace_with_("!","!!"))._trimBoth();
  12. return $1;
  13. }, function($ctx1) {$ctx1.fill(self,"chunkEscape:",{aString:aString},smalltalk.AbstractExporter)})},
  14. messageSends: ["trimBoth", "replace:with:"]}),
  15. smalltalk.AbstractExporter);
  16. smalltalk.addMethod(
  17. smalltalk.method({
  18. selector: "classNameFor:",
  19. fn: function (aClass){
  20. var self=this;
  21. return smalltalk.withContext(function($ctx1) {
  22. var $2,$3,$1;
  23. $2=_st(aClass)._isMetaclass();
  24. if(smalltalk.assert($2)){
  25. $1=_st(_st(_st(aClass)._instanceClass())._name()).__comma(" class");
  26. } else {
  27. $3=_st(aClass)._isNil();
  28. if(smalltalk.assert($3)){
  29. $1="nil";
  30. } else {
  31. $1=_st(aClass)._name();
  32. };
  33. };
  34. return $1;
  35. }, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},smalltalk.AbstractExporter)})},
  36. messageSends: ["ifTrue:ifFalse:", ",", "name", "instanceClass", "isNil", "isMetaclass"]}),
  37. smalltalk.AbstractExporter);
  38. smalltalk.addMethod(
  39. smalltalk.method({
  40. selector: "recipe",
  41. fn: function (){
  42. var self=this;
  43. return smalltalk.withContext(function($ctx1) {
  44. self._subclassResponsibility();
  45. return self}, function($ctx1) {$ctx1.fill(self,"recipe",{},smalltalk.AbstractExporter)})},
  46. messageSends: ["subclassResponsibility"]}),
  47. smalltalk.AbstractExporter);
  48. smalltalk.AbstractExporter.klass.iVarNames = ['default'];
  49. smalltalk.addMethod(
  50. smalltalk.method({
  51. selector: "default",
  52. fn: function (){
  53. var self=this;
  54. return smalltalk.withContext(function($ctx1) {
  55. var $2,$1;
  56. $2=self["@default"];
  57. if(($receiver = $2) == nil || $receiver == undefined){
  58. self["@default"]=self._new();
  59. $1=self["@default"];
  60. } else {
  61. $1=$2;
  62. };
  63. return $1;
  64. }, function($ctx1) {$ctx1.fill(self,"default",{},smalltalk.AbstractExporter.klass)})},
  65. messageSends: ["ifNil:", "new"]}),
  66. smalltalk.AbstractExporter.klass);
  67. smalltalk.addClass('ChunkExporter', smalltalk.AbstractExporter, [], 'Importer-Exporter');
  68. smalltalk.addMethod(
  69. smalltalk.method({
  70. selector: "exportCategoryEpilogueOf:on:",
  71. fn: function (aCategory,aStream){
  72. var self=this;
  73. return smalltalk.withContext(function($ctx1) {
  74. var $1,$2;
  75. $1=aStream;
  76. _st($1)._nextPutAll_(" !");
  77. _st($1)._lf();
  78. $2=_st($1)._lf();
  79. return self}, function($ctx1) {$ctx1.fill(self,"exportCategoryEpilogueOf:on:",{aCategory:aCategory,aStream:aStream},smalltalk.ChunkExporter)})},
  80. messageSends: ["nextPutAll:", "lf"]}),
  81. smalltalk.ChunkExporter);
  82. smalltalk.addMethod(
  83. smalltalk.method({
  84. selector: "exportCategoryPrologueOf:on:",
  85. fn: function (aCategory,aStream){
  86. var self=this;
  87. return smalltalk.withContext(function($ctx1) {
  88. var $1,$2;
  89. $1=aStream;
  90. _st($1)._nextPutAll_("!".__comma(self._classNameFor_(_st(aCategory)._theClass())));
  91. $2=_st($1)._nextPutAll_(_st(" methodsFor: '".__comma(_st(aCategory)._name())).__comma("'!"));
  92. return self}, function($ctx1) {$ctx1.fill(self,"exportCategoryPrologueOf:on:",{aCategory:aCategory,aStream:aStream},smalltalk.ChunkExporter)})},
  93. messageSends: ["nextPutAll:", ",", "classNameFor:", "theClass", "name"]}),
  94. smalltalk.ChunkExporter);
  95. smalltalk.addMethod(
  96. smalltalk.method({
  97. selector: "exportDefinitionOf:on:",
  98. fn: function (aClass,aStream){
  99. var self=this;
  100. return smalltalk.withContext(function($ctx1) {
  101. var $1,$2,$3,$4,$5,$6,$7;
  102. $1=aStream;
  103. _st($1)._nextPutAll_(self._classNameFor_(_st(aClass)._superclass()));
  104. _st($1)._nextPutAll_(" subclass: #".__comma(self._classNameFor_(aClass)));
  105. _st($1)._lf();
  106. _st($1)._tab();
  107. $2=_st($1)._nextPutAll_("instanceVariableNames: '");
  108. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  109. return smalltalk.withContext(function($ctx2) {
  110. return _st(aStream)._nextPutAll_(each);
  111. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  112. return smalltalk.withContext(function($ctx2) {
  113. return _st(aStream)._nextPutAll_(" ");
  114. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  115. $3=aStream;
  116. _st($3)._nextPutAll_("'");
  117. _st($3)._lf();
  118. _st($3)._tab();
  119. _st($3)._nextPutAll_(_st("package: '".__comma(_st(aClass)._category())).__comma("'!"));
  120. $4=_st($3)._lf();
  121. $5=_st(_st(aClass)._comment())._notEmpty();
  122. if(smalltalk.assert($5)){
  123. $6=aStream;
  124. _st($6)._nextPutAll_(_st("!".__comma(self._classNameFor_(aClass))).__comma(" commentStamp!"));
  125. _st($6)._lf();
  126. _st($6)._nextPutAll_(_st(self._chunkEscape_(_st(aClass)._comment())).__comma("!"));
  127. $7=_st($6)._lf();
  128. $7;
  129. };
  130. _st(aStream)._lf();
  131. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.ChunkExporter)})},
  132. messageSends: ["nextPutAll:", "classNameFor:", "superclass", ",", "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "chunkEscape:", "comment", "notEmpty"]}),
  133. smalltalk.ChunkExporter);
  134. smalltalk.addMethod(
  135. smalltalk.method({
  136. selector: "exportMetaDefinitionOf:on:",
  137. fn: function (aClass,aStream){
  138. var self=this;
  139. return smalltalk.withContext(function($ctx1) {
  140. var $1,$2,$3,$4,$5;
  141. $1=_st(_st(_st(aClass)._class())._instanceVariableNames())._isEmpty();
  142. if(! smalltalk.assert($1)){
  143. $2=aStream;
  144. _st($2)._nextPutAll_(self._classNameFor_(_st(aClass)._class()));
  145. $3=_st($2)._nextPutAll_(" instanceVariableNames: '");
  146. $3;
  147. _st(_st(_st(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
  148. return smalltalk.withContext(function($ctx2) {
  149. return _st(aStream)._nextPutAll_(each);
  150. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  151. return smalltalk.withContext(function($ctx2) {
  152. return _st(aStream)._nextPutAll_(" ");
  153. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  154. $4=aStream;
  155. _st($4)._nextPutAll_("'!");
  156. _st($4)._lf();
  157. $5=_st($4)._lf();
  158. $5;
  159. };
  160. return self}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.ChunkExporter)})},
  161. messageSends: ["ifFalse:", "nextPutAll:", "classNameFor:", "class", "do:separatedBy:", "instanceVariableNames", "lf", "isEmpty"]}),
  162. smalltalk.ChunkExporter);
  163. smalltalk.addMethod(
  164. smalltalk.method({
  165. selector: "exportMethod:on:",
  166. fn: function (aMethod,aStream){
  167. var self=this;
  168. return smalltalk.withContext(function($ctx1) {
  169. var $1,$2;
  170. $1=aStream;
  171. _st($1)._lf();
  172. _st($1)._lf();
  173. _st($1)._nextPutAll_(self._chunkEscape_(_st(aMethod)._source()));
  174. _st($1)._lf();
  175. $2=_st($1)._nextPutAll_("!");
  176. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.ChunkExporter)})},
  177. messageSends: ["lf", "nextPutAll:", "chunkEscape:", "source"]}),
  178. smalltalk.ChunkExporter);
  179. smalltalk.addMethod(
  180. smalltalk.method({
  181. selector: "exportPackageDefinitionOf:on:",
  182. fn: function (aPackage,aStream){
  183. var self=this;
  184. return smalltalk.withContext(function($ctx1) {
  185. var $1,$2;
  186. $1=aStream;
  187. _st($1)._nextPutAll_(_st("Smalltalk current createPackage: '".__comma(_st(aPackage)._name())).__comma("'!"));
  188. $2=_st($1)._lf();
  189. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.ChunkExporter)})},
  190. messageSends: ["nextPutAll:", ",", "name", "lf"]}),
  191. smalltalk.ChunkExporter);
  192. smalltalk.addMethod(
  193. smalltalk.method({
  194. selector: "extensionCategoriesOfPackage:",
  195. fn: function (aPackage){
  196. var self=this;
  197. var name,map,result;
  198. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  199. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  200. function $MethodCategory(){return smalltalk.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
  201. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  202. function $Package(){return smalltalk.Package||(typeof Package=="undefined"?nil:Package)}
  203. return smalltalk.withContext(function($ctx1) {
  204. var $1,$2;
  205. name=_st(aPackage)._name();
  206. result=_st($OrderedCollection())._new();
  207. _st(_st($Package())._sortedClasses_(_st(_st($Smalltalk())._current())._classes()))._do_((function(each){
  208. return smalltalk.withContext(function($ctx2) {
  209. return _st([each,_st(each)._class()])._do_((function(aClass){
  210. return smalltalk.withContext(function($ctx3) {
  211. map=_st($Dictionary())._new();
  212. map;
  213. _st(aClass)._protocolsDo_((function(category,methods){
  214. return smalltalk.withContext(function($ctx4) {
  215. $1=_st(category)._match_("^\x5c*".__comma(name));
  216. if(smalltalk.assert($1)){
  217. return _st(map)._at_put_(category,methods);
  218. };
  219. }, function($ctx4) {$ctx4.fillBlock({category:category,methods:methods},$ctx3)})}));
  220. return _st(result)._addAll_(_st(_st(_st(map)._keys())._sorted_((function(a,b){
  221. return smalltalk.withContext(function($ctx4) {
  222. return _st(a).__lt_eq(b);
  223. }, function($ctx4) {$ctx4.fillBlock({a:a,b:b},$ctx3)})})))._collect_((function(category){
  224. return smalltalk.withContext(function($ctx4) {
  225. return _st($MethodCategory())._name_theClass_methods_(category,aClass,_st(map)._at_(category));
  226. }, function($ctx4) {$ctx4.fillBlock({category:category},$ctx3)})})));
  227. }, function($ctx3) {$ctx3.fillBlock({aClass:aClass},$ctx2)})}));
  228. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  229. $2=result;
  230. return $2;
  231. }, function($ctx1) {$ctx1.fill(self,"extensionCategoriesOfPackage:",{aPackage:aPackage,name:name,map:map,result:result},smalltalk.ChunkExporter)})},
  232. messageSends: ["name", "new", "do:", "protocolsDo:", "ifTrue:", "at:put:", "match:", ",", "addAll:", "collect:", "name:theClass:methods:", "at:", "sorted:", "<=", "keys", "class", "sortedClasses:", "classes", "current"]}),
  233. smalltalk.ChunkExporter);
  234. smalltalk.addMethod(
  235. smalltalk.method({
  236. selector: "methodsOfCategory:",
  237. fn: function (aCategory){
  238. var self=this;
  239. return smalltalk.withContext(function($ctx1) {
  240. var $1;
  241. $1=_st(_st(aCategory)._methods())._sorted_((function(a,b){
  242. return smalltalk.withContext(function($ctx2) {
  243. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  244. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  245. return $1;
  246. }, function($ctx1) {$ctx1.fill(self,"methodsOfCategory:",{aCategory:aCategory},smalltalk.ChunkExporter)})},
  247. messageSends: ["sorted:", "<=", "selector", "methods"]}),
  248. smalltalk.ChunkExporter);
  249. smalltalk.addMethod(
  250. smalltalk.method({
  251. selector: "ownCategoriesOfClass:",
  252. fn: function (aClass){
  253. var self=this;
  254. var map;
  255. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  256. function $MethodCategory(){return smalltalk.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
  257. return smalltalk.withContext(function($ctx1) {
  258. var $1,$2;
  259. map=_st($Dictionary())._new();
  260. _st(aClass)._protocolsDo_((function(category,methods){
  261. return smalltalk.withContext(function($ctx2) {
  262. $1=_st(category)._match_("^\x5c*");
  263. if(! smalltalk.assert($1)){
  264. return _st(map)._at_put_(category,methods);
  265. };
  266. }, function($ctx2) {$ctx2.fillBlock({category:category,methods:methods},$ctx1)})}));
  267. $2=_st(_st(_st(map)._keys())._sorted_((function(a,b){
  268. return smalltalk.withContext(function($ctx2) {
  269. return _st(a).__lt_eq(b);
  270. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})})))._collect_((function(category){
  271. return smalltalk.withContext(function($ctx2) {
  272. return _st($MethodCategory())._name_theClass_methods_(category,aClass,_st(map)._at_(category));
  273. }, function($ctx2) {$ctx2.fillBlock({category:category},$ctx1)})}));
  274. return $2;
  275. }, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfClass:",{aClass:aClass,map:map},smalltalk.ChunkExporter)})},
  276. messageSends: ["new", "protocolsDo:", "ifFalse:", "at:put:", "match:", "collect:", "name:theClass:methods:", "at:", "sorted:", "<=", "keys"]}),
  277. smalltalk.ChunkExporter);
  278. smalltalk.addMethod(
  279. smalltalk.method({
  280. selector: "ownCategoriesOfMetaClass:",
  281. fn: function (aClass){
  282. var self=this;
  283. return smalltalk.withContext(function($ctx1) {
  284. var $1;
  285. $1=self._ownCategoriesOfClass_(_st(aClass)._class());
  286. return $1;
  287. }, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfMetaClass:",{aClass:aClass},smalltalk.ChunkExporter)})},
  288. messageSends: ["ownCategoriesOfClass:", "class"]}),
  289. smalltalk.ChunkExporter);
  290. smalltalk.addMethod(
  291. smalltalk.method({
  292. selector: "recipe",
  293. fn: function (){
  294. var self=this;
  295. var exportCategoryRecipe;
  296. function $PluggableExporter(){return smalltalk.PluggableExporter||(typeof PluggableExporter=="undefined"?nil:PluggableExporter)}
  297. return smalltalk.withContext(function($ctx1) {
  298. var $1;
  299. exportCategoryRecipe=[self.__minus_gt("exportCategoryPrologueOf:on:"),[self.__minus_gt("methodsOfCategory:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportCategoryEpilogueOf:on:")];
  300. $1=[self.__minus_gt("exportPackageDefinitionOf:on:"),[_st($PluggableExporter()).__minus_gt("ownClassesOfPackage:"),self.__minus_gt("exportDefinitionOf:on:"),_st([self.__minus_gt("ownCategoriesOfClass:")]).__comma(exportCategoryRecipe),self.__minus_gt("exportMetaDefinitionOf:on:"),_st([self.__minus_gt("ownCategoriesOfMetaClass:")]).__comma(exportCategoryRecipe)],_st([self.__minus_gt("extensionCategoriesOfPackage:")]).__comma(exportCategoryRecipe)];
  301. return $1;
  302. }, function($ctx1) {$ctx1.fill(self,"recipe",{exportCategoryRecipe:exportCategoryRecipe},smalltalk.ChunkExporter)})},
  303. messageSends: ["->", ","]}),
  304. smalltalk.ChunkExporter);
  305. smalltalk.addMethod(
  306. smalltalk.method({
  307. selector: "chunkEscape:",
  308. fn: function (aString){
  309. var self=this;
  310. return smalltalk.withContext(function($ctx1) {
  311. var $1;
  312. $1=_st(_st(aString)._replace_with_("!","!!"))._trimBoth();
  313. return $1;
  314. }, function($ctx1) {$ctx1.fill(self,"chunkEscape:",{aString:aString},smalltalk.ChunkExporter.klass)})},
  315. messageSends: ["trimBoth", "replace:with:"]}),
  316. smalltalk.ChunkExporter.klass);
  317. smalltalk.addMethod(
  318. smalltalk.method({
  319. selector: "classNameFor:",
  320. fn: function (aClass){
  321. var self=this;
  322. return smalltalk.withContext(function($ctx1) {
  323. var $2,$3,$1;
  324. $2=_st(aClass)._isMetaclass();
  325. if(smalltalk.assert($2)){
  326. $1=_st(_st(_st(aClass)._instanceClass())._name()).__comma(" class");
  327. } else {
  328. $3=_st(aClass)._isNil();
  329. if(smalltalk.assert($3)){
  330. $1="nil";
  331. } else {
  332. $1=_st(aClass)._name();
  333. };
  334. };
  335. return $1;
  336. }, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},smalltalk.ChunkExporter.klass)})},
  337. messageSends: ["ifTrue:ifFalse:", ",", "name", "instanceClass", "isNil", "isMetaclass"]}),
  338. smalltalk.ChunkExporter.klass);
  339. smalltalk.addMethod(
  340. smalltalk.method({
  341. selector: "exportCategoryEpilogueOf:on:",
  342. fn: function (category,aStream){
  343. var self=this;
  344. return smalltalk.withContext(function($ctx1) {
  345. var $1,$2;
  346. $1=aStream;
  347. _st($1)._nextPutAll_(" !");
  348. _st($1)._lf();
  349. $2=_st($1)._lf();
  350. return self}, function($ctx1) {$ctx1.fill(self,"exportCategoryEpilogueOf:on:",{category:category,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  351. messageSends: ["nextPutAll:", "lf"]}),
  352. smalltalk.ChunkExporter.klass);
  353. smalltalk.addMethod(
  354. smalltalk.method({
  355. selector: "exportCategoryPrologueOf:on:",
  356. fn: function (category,aStream){
  357. var self=this;
  358. return smalltalk.withContext(function($ctx1) {
  359. var $1,$2;
  360. $1=aStream;
  361. _st($1)._nextPutAll_("!".__comma(self._classNameFor_(_st(category)._theClass())));
  362. $2=_st($1)._nextPutAll_(_st(" methodsFor: '".__comma(_st(category)._name())).__comma("'!"));
  363. return self}, function($ctx1) {$ctx1.fill(self,"exportCategoryPrologueOf:on:",{category:category,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  364. messageSends: ["nextPutAll:", ",", "classNameFor:", "theClass", "name"]}),
  365. smalltalk.ChunkExporter.klass);
  366. smalltalk.addMethod(
  367. smalltalk.method({
  368. selector: "exportDefinitionOf:on:",
  369. fn: function (aClass,aStream){
  370. var self=this;
  371. return smalltalk.withContext(function($ctx1) {
  372. var $1,$2,$3,$4,$5,$6,$7;
  373. $1=aStream;
  374. _st($1)._nextPutAll_(self._classNameFor_(_st(aClass)._superclass()));
  375. _st($1)._nextPutAll_(" subclass: #".__comma(self._classNameFor_(aClass)));
  376. _st($1)._lf();
  377. _st($1)._tab();
  378. $2=_st($1)._nextPutAll_("instanceVariableNames: '");
  379. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  380. return smalltalk.withContext(function($ctx2) {
  381. return _st(aStream)._nextPutAll_(each);
  382. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  383. return smalltalk.withContext(function($ctx2) {
  384. return _st(aStream)._nextPutAll_(" ");
  385. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  386. $3=aStream;
  387. _st($3)._nextPutAll_("'");
  388. _st($3)._lf();
  389. _st($3)._tab();
  390. _st($3)._nextPutAll_(_st("package: '".__comma(_st(aClass)._category())).__comma("'!"));
  391. $4=_st($3)._lf();
  392. $5=_st(_st(aClass)._comment())._notEmpty();
  393. if(smalltalk.assert($5)){
  394. $6=aStream;
  395. _st($6)._nextPutAll_(_st("!".__comma(self._classNameFor_(aClass))).__comma(" commentStamp!"));
  396. _st($6)._lf();
  397. _st($6)._nextPutAll_(_st(self._chunkEscape_(_st(aClass)._comment())).__comma("!"));
  398. $7=_st($6)._lf();
  399. $7;
  400. };
  401. _st(aStream)._lf();
  402. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  403. messageSends: ["nextPutAll:", "classNameFor:", "superclass", ",", "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "chunkEscape:", "comment", "notEmpty"]}),
  404. smalltalk.ChunkExporter.klass);
  405. smalltalk.addMethod(
  406. smalltalk.method({
  407. selector: "exportMetaDefinitionOf:on:",
  408. fn: function (aClass,aStream){
  409. var self=this;
  410. return smalltalk.withContext(function($ctx1) {
  411. var $1,$2,$3,$4,$5;
  412. $1=_st(_st(_st(aClass)._class())._instanceVariableNames())._isEmpty();
  413. if(! smalltalk.assert($1)){
  414. $2=aStream;
  415. _st($2)._nextPutAll_(self._classNameFor_(_st(aClass)._class()));
  416. $3=_st($2)._nextPutAll_(" instanceVariableNames: '");
  417. $3;
  418. _st(_st(_st(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
  419. return smalltalk.withContext(function($ctx2) {
  420. return _st(aStream)._nextPutAll_(each);
  421. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  422. return smalltalk.withContext(function($ctx2) {
  423. return _st(aStream)._nextPutAll_(" ");
  424. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  425. $4=aStream;
  426. _st($4)._nextPutAll_("'!");
  427. _st($4)._lf();
  428. $5=_st($4)._lf();
  429. $5;
  430. };
  431. return self}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  432. messageSends: ["ifFalse:", "nextPutAll:", "classNameFor:", "class", "do:separatedBy:", "instanceVariableNames", "lf", "isEmpty"]}),
  433. smalltalk.ChunkExporter.klass);
  434. smalltalk.addMethod(
  435. smalltalk.method({
  436. selector: "exportMethod:on:",
  437. fn: function (aMethod,aStream){
  438. var self=this;
  439. return smalltalk.withContext(function($ctx1) {
  440. var $1,$2;
  441. $1=aStream;
  442. _st($1)._lf();
  443. _st($1)._lf();
  444. _st($1)._nextPutAll_(self._chunkEscape_(_st(aMethod)._source()));
  445. _st($1)._lf();
  446. $2=_st($1)._nextPutAll_("!");
  447. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  448. messageSends: ["lf", "nextPutAll:", "chunkEscape:", "source"]}),
  449. smalltalk.ChunkExporter.klass);
  450. smalltalk.addMethod(
  451. smalltalk.method({
  452. selector: "exportPackageDefinitionOf:on:",
  453. fn: function (package_,aStream){
  454. var self=this;
  455. return smalltalk.withContext(function($ctx1) {
  456. var $1,$2;
  457. $1=aStream;
  458. _st($1)._nextPutAll_(_st("Smalltalk current createPackage: '".__comma(_st(package_)._name())).__comma("'!"));
  459. $2=_st($1)._lf();
  460. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{package_:package_,aStream:aStream},smalltalk.ChunkExporter.klass)})},
  461. messageSends: ["nextPutAll:", ",", "name", "lf"]}),
  462. smalltalk.ChunkExporter.klass);
  463. smalltalk.addMethod(
  464. smalltalk.method({
  465. selector: "extensionCategoriesOfPackage:",
  466. fn: function (package_){
  467. var self=this;
  468. var name,map,result;
  469. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  470. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  471. function $MethodCategory(){return smalltalk.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
  472. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  473. function $Package(){return smalltalk.Package||(typeof Package=="undefined"?nil:Package)}
  474. return smalltalk.withContext(function($ctx1) {
  475. var $1,$2;
  476. name=_st(package_)._name();
  477. result=_st($OrderedCollection())._new();
  478. _st(_st($Package())._sortedClasses_(_st(_st($Smalltalk())._current())._classes()))._do_((function(each){
  479. return smalltalk.withContext(function($ctx2) {
  480. return _st([each,_st(each)._class()])._do_((function(aClass){
  481. return smalltalk.withContext(function($ctx3) {
  482. map=_st($Dictionary())._new();
  483. map;
  484. _st(aClass)._protocolsDo_((function(category,methods){
  485. return smalltalk.withContext(function($ctx4) {
  486. $1=_st(category)._match_("^\x5c*".__comma(name));
  487. if(smalltalk.assert($1)){
  488. return _st(map)._at_put_(category,methods);
  489. };
  490. }, function($ctx4) {$ctx4.fillBlock({category:category,methods:methods},$ctx3)})}));
  491. return _st(result)._addAll_(_st(_st(_st(map)._keys())._sorted_((function(a,b){
  492. return smalltalk.withContext(function($ctx4) {
  493. return _st(a).__lt_eq(b);
  494. }, function($ctx4) {$ctx4.fillBlock({a:a,b:b},$ctx3)})})))._collect_((function(category){
  495. return smalltalk.withContext(function($ctx4) {
  496. return _st($MethodCategory())._name_theClass_methods_(category,aClass,_st(map)._at_(category));
  497. }, function($ctx4) {$ctx4.fillBlock({category:category},$ctx3)})})));
  498. }, function($ctx3) {$ctx3.fillBlock({aClass:aClass},$ctx2)})}));
  499. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  500. $2=result;
  501. return $2;
  502. }, function($ctx1) {$ctx1.fill(self,"extensionCategoriesOfPackage:",{package_:package_,name:name,map:map,result:result},smalltalk.ChunkExporter.klass)})},
  503. messageSends: ["name", "new", "do:", "protocolsDo:", "ifTrue:", "at:put:", "match:", ",", "addAll:", "collect:", "name:theClass:methods:", "at:", "sorted:", "<=", "keys", "class", "sortedClasses:", "classes", "current"]}),
  504. smalltalk.ChunkExporter.klass);
  505. smalltalk.addMethod(
  506. smalltalk.method({
  507. selector: "methodsOfCategory:",
  508. fn: function (category){
  509. var self=this;
  510. return smalltalk.withContext(function($ctx1) {
  511. var $1;
  512. $1=_st(_st(category)._methods())._sorted_((function(a,b){
  513. return smalltalk.withContext(function($ctx2) {
  514. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  515. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  516. return $1;
  517. }, function($ctx1) {$ctx1.fill(self,"methodsOfCategory:",{category:category},smalltalk.ChunkExporter.klass)})},
  518. messageSends: ["sorted:", "<=", "selector", "methods"]}),
  519. smalltalk.ChunkExporter.klass);
  520. smalltalk.addMethod(
  521. smalltalk.method({
  522. selector: "ownCategoriesOfClass:",
  523. fn: function (aClass){
  524. var self=this;
  525. var map;
  526. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  527. function $MethodCategory(){return smalltalk.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
  528. return smalltalk.withContext(function($ctx1) {
  529. var $1,$2;
  530. map=_st($Dictionary())._new();
  531. _st(aClass)._protocolsDo_((function(category,methods){
  532. return smalltalk.withContext(function($ctx2) {
  533. $1=_st(category)._match_("^\x5c*");
  534. if(! smalltalk.assert($1)){
  535. return _st(map)._at_put_(category,methods);
  536. };
  537. }, function($ctx2) {$ctx2.fillBlock({category:category,methods:methods},$ctx1)})}));
  538. $2=_st(_st(_st(map)._keys())._sorted_((function(a,b){
  539. return smalltalk.withContext(function($ctx2) {
  540. return _st(a).__lt_eq(b);
  541. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})})))._collect_((function(category){
  542. return smalltalk.withContext(function($ctx2) {
  543. return _st($MethodCategory())._name_theClass_methods_(category,aClass,_st(map)._at_(category));
  544. }, function($ctx2) {$ctx2.fillBlock({category:category},$ctx1)})}));
  545. return $2;
  546. }, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfClass:",{aClass:aClass,map:map},smalltalk.ChunkExporter.klass)})},
  547. messageSends: ["new", "protocolsDo:", "ifFalse:", "at:put:", "match:", "collect:", "name:theClass:methods:", "at:", "sorted:", "<=", "keys"]}),
  548. smalltalk.ChunkExporter.klass);
  549. smalltalk.addMethod(
  550. smalltalk.method({
  551. selector: "ownCategoriesOfMetaClass:",
  552. fn: function (aClass){
  553. var self=this;
  554. return smalltalk.withContext(function($ctx1) {
  555. var $1;
  556. $1=self._ownCategoriesOfClass_(_st(aClass)._class());
  557. return $1;
  558. }, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfMetaClass:",{aClass:aClass},smalltalk.ChunkExporter.klass)})},
  559. messageSends: ["ownCategoriesOfClass:", "class"]}),
  560. smalltalk.ChunkExporter.klass);
  561. smalltalk.addMethod(
  562. smalltalk.method({
  563. selector: "recipe",
  564. fn: function (){
  565. var self=this;
  566. var exportCategoryRecipe;
  567. function $PluggableExporter(){return smalltalk.PluggableExporter||(typeof PluggableExporter=="undefined"?nil:PluggableExporter)}
  568. return smalltalk.withContext(function($ctx1) {
  569. var $1;
  570. exportCategoryRecipe=[self.__minus_gt("exportCategoryPrologueOf:on:"),[self.__minus_gt("methodsOfCategory:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportCategoryEpilogueOf:on:")];
  571. $1=[self.__minus_gt("exportPackageDefinitionOf:on:"),[_st($PluggableExporter()).__minus_gt("ownClassesOfPackage:"),self.__minus_gt("exportDefinitionOf:on:"),_st([self.__minus_gt("ownCategoriesOfClass:")]).__comma(exportCategoryRecipe),self.__minus_gt("exportMetaDefinitionOf:on:"),_st([self.__minus_gt("ownCategoriesOfMetaClass:")]).__comma(exportCategoryRecipe)],_st([self.__minus_gt("extensionCategoriesOfPackage:")]).__comma(exportCategoryRecipe)];
  572. return $1;
  573. }, function($ctx1) {$ctx1.fill(self,"recipe",{exportCategoryRecipe:exportCategoryRecipe},smalltalk.ChunkExporter.klass)})},
  574. messageSends: ["->", ","]}),
  575. smalltalk.ChunkExporter.klass);
  576. smalltalk.addClass('Exporter', smalltalk.AbstractExporter, [], 'Importer-Exporter');
  577. smalltalk.addMethod(
  578. smalltalk.method({
  579. selector: "classNameFor:",
  580. fn: function (aClass){
  581. var self=this;
  582. return smalltalk.withContext(function($ctx1) {
  583. var $2,$3,$1;
  584. $2=_st(aClass)._isMetaclass();
  585. if(smalltalk.assert($2)){
  586. $1=_st(_st(_st(aClass)._instanceClass())._name()).__comma(".klass");
  587. } else {
  588. $3=_st(aClass)._isNil();
  589. if(smalltalk.assert($3)){
  590. $1="nil";
  591. } else {
  592. $1=_st(aClass)._name();
  593. };
  594. };
  595. return $1;
  596. }, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},smalltalk.Exporter)})},
  597. messageSends: ["ifTrue:ifFalse:", ",", "name", "instanceClass", "isNil", "isMetaclass"]}),
  598. smalltalk.Exporter);
  599. smalltalk.addMethod(
  600. smalltalk.method({
  601. selector: "exportDefinitionOf:on:",
  602. fn: function (aClass,aStream){
  603. var self=this;
  604. return smalltalk.withContext(function($ctx1) {
  605. var $1,$2,$3,$4,$5,$6,$7;
  606. $1=aStream;
  607. _st($1)._lf();
  608. _st($1)._nextPutAll_("smalltalk.addClass(");
  609. _st($1)._nextPutAll_(_st("'".__comma(self._classNameFor_(aClass))).__comma("', "));
  610. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._superclass())));
  611. $2=_st($1)._nextPutAll_(", [");
  612. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  613. return smalltalk.withContext(function($ctx2) {
  614. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  615. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  616. return smalltalk.withContext(function($ctx2) {
  617. return _st(aStream)._nextPutAll_(", ");
  618. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  619. $3=aStream;
  620. _st($3)._nextPutAll_("], '");
  621. _st($3)._nextPutAll_(_st(_st(aClass)._category()).__comma("'"));
  622. $4=_st($3)._nextPutAll_(");");
  623. $5=_st(_st(aClass)._comment())._notEmpty();
  624. if(smalltalk.assert($5)){
  625. $6=aStream;
  626. _st($6)._lf();
  627. _st($6)._nextPutAll_("smalltalk.");
  628. _st($6)._nextPutAll_(self._classNameFor_(aClass));
  629. _st($6)._nextPutAll_(".comment=");
  630. _st($6)._nextPutAll_(_st(_st(aClass)._comment())._asJavascript());
  631. $7=_st($6)._nextPutAll_(";");
  632. $7;
  633. };
  634. _st(aStream)._lf();
  635. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.Exporter)})},
  636. messageSends: ["lf", "nextPutAll:", ",", "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "asJavascript", "comment", "notEmpty"]}),
  637. smalltalk.Exporter);
  638. smalltalk.addMethod(
  639. smalltalk.method({
  640. selector: "exportMetaDefinitionOf:on:",
  641. fn: function (aClass,aStream){
  642. var self=this;
  643. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  644. return smalltalk.withContext(function($ctx1) {
  645. var $1,$2,$3;
  646. _st(aStream)._lf();
  647. $1=_st(_st(_st(aClass)._class())._instanceVariableNames())._isEmpty();
  648. if(! smalltalk.assert($1)){
  649. $2=aStream;
  650. _st($2)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._class())));
  651. $3=_st($2)._nextPutAll_(".iVarNames = [");
  652. $3;
  653. _st(_st(_st(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
  654. return smalltalk.withContext(function($ctx2) {
  655. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  656. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  657. return smalltalk.withContext(function($ctx2) {
  658. return _st(aStream)._nextPutAll_(",");
  659. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  660. _st(aStream)._nextPutAll_("];".__comma(_st($String())._lf()));
  661. };
  662. return self}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.Exporter)})},
  663. messageSends: ["lf", "ifFalse:", "nextPutAll:", ",", "classNameFor:", "class", "do:separatedBy:", "instanceVariableNames", "isEmpty"]}),
  664. smalltalk.Exporter);
  665. smalltalk.addMethod(
  666. smalltalk.method({
  667. selector: "exportMethod:on:",
  668. fn: function (aMethod,aStream){
  669. var self=this;
  670. return smalltalk.withContext(function($ctx1) {
  671. var $1,$2,$3,$4;
  672. $1=aStream;
  673. _st($1)._nextPutAll_("smalltalk.addMethod(");
  674. _st($1)._lf();
  675. _st($1)._nextPutAll_("smalltalk.method({");
  676. _st($1)._lf();
  677. _st($1)._nextPutAll_(_st("selector: ".__comma(_st(_st(aMethod)._selector())._asJavascript())).__comma(","));
  678. _st($1)._lf();
  679. _st($1)._nextPutAll_(_st("category: '".__comma(_st(aMethod)._category())).__comma("',"));
  680. _st($1)._lf();
  681. _st($1)._nextPutAll_(_st("fn: ".__comma(_st(_st(aMethod)._fn())._compiledSource())).__comma(","));
  682. _st($1)._lf();
  683. _st($1)._nextPutAll_(_st("args: ".__comma(_st(_st(aMethod)._arguments())._asJavascript())).__comma(","));
  684. _st($1)._lf();
  685. _st($1)._nextPutAll_(_st("source: ".__comma(_st(_st(aMethod)._source())._asJavascript())).__comma(","));
  686. _st($1)._lf();
  687. _st($1)._nextPutAll_(_st("messageSends: ".__comma(_st(_st(aMethod)._messageSends())._asJavascript())).__comma(","));
  688. _st($1)._lf();
  689. $2=_st($1)._nextPutAll_("referencedClasses: ".__comma(_st(_st(aMethod)._referencedClasses())._asJavascript()));
  690. $3=aStream;
  691. _st($3)._lf();
  692. _st($3)._nextPutAll_("}),");
  693. _st($3)._lf();
  694. _st($3)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aMethod)._methodClass())));
  695. _st($3)._nextPutAll_(");");
  696. _st($3)._lf();
  697. $4=_st($3)._lf();
  698. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.Exporter)})},
  699. messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "category", "compiledSource", "fn", "arguments", "source", "messageSends", "referencedClasses", "classNameFor:", "methodClass"]}),
  700. smalltalk.Exporter);
  701. smalltalk.addMethod(
  702. smalltalk.method({
  703. selector: "exportPackageDefinitionOf:on:",
  704. fn: function (aPackage,aStream){
  705. var self=this;
  706. return smalltalk.withContext(function($ctx1) {
  707. var $1,$2;
  708. $1=aStream;
  709. _st($1)._nextPutAll_("smalltalk.addPackage(");
  710. _st($1)._nextPutAll_(_st("'".__comma(_st(aPackage)._name())).__comma("');"));
  711. $2=_st($1)._lf();
  712. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.Exporter)})},
  713. messageSends: ["nextPutAll:", ",", "name", "lf"]}),
  714. smalltalk.Exporter);
  715. smalltalk.addMethod(
  716. smalltalk.method({
  717. selector: "exportPackageEpilogueOf:on:",
  718. fn: function (aPackage,aStream){
  719. var self=this;
  720. return smalltalk.withContext(function($ctx1) {
  721. var $1,$2;
  722. $1=aStream;
  723. _st($1)._nextPutAll_("})(global_smalltalk,global_nil,global__st);");
  724. $2=_st($1)._lf();
  725. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageEpilogueOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.Exporter)})},
  726. messageSends: ["nextPutAll:", "lf"]}),
  727. smalltalk.Exporter);
  728. smalltalk.addMethod(
  729. smalltalk.method({
  730. selector: "exportPackagePrologueOf:on:",
  731. fn: function (aPackage,aStream){
  732. var self=this;
  733. return smalltalk.withContext(function($ctx1) {
  734. var $1,$2;
  735. $1=aStream;
  736. _st($1)._nextPutAll_("(function(smalltalk,nil,_st){");
  737. $2=_st($1)._lf();
  738. return self}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.Exporter)})},
  739. messageSends: ["nextPutAll:", "lf"]}),
  740. smalltalk.Exporter);
  741. smalltalk.addMethod(
  742. smalltalk.method({
  743. selector: "extensionMethodsOfPackage:",
  744. fn: function (aPackage){
  745. var self=this;
  746. var name,result;
  747. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  748. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  749. function $Package(){return smalltalk.Package||(typeof Package=="undefined"?nil:Package)}
  750. return smalltalk.withContext(function($ctx1) {
  751. var $1;
  752. name=_st(aPackage)._name();
  753. result=_st($OrderedCollection())._new();
  754. _st(_st($Package())._sortedClasses_(_st(_st($Smalltalk())._current())._classes()))._do_((function(each){
  755. return smalltalk.withContext(function($ctx2) {
  756. return _st([each,_st(each)._class()])._do_((function(aClass){
  757. return smalltalk.withContext(function($ctx3) {
  758. return _st(result)._addAll_(_st(_st(_st(_st(aClass)._methodDictionary())._values())._sorted_((function(a,b){
  759. return smalltalk.withContext(function($ctx4) {
  760. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  761. }, function($ctx4) {$ctx4.fillBlock({a:a,b:b},$ctx3)})})))._select_((function(method){
  762. return smalltalk.withContext(function($ctx4) {
  763. return _st(_st(method)._category())._match_("^\x5c*".__comma(name));
  764. }, function($ctx4) {$ctx4.fillBlock({method:method},$ctx3)})})));
  765. }, function($ctx3) {$ctx3.fillBlock({aClass:aClass},$ctx2)})}));
  766. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  767. $1=result;
  768. return $1;
  769. }, function($ctx1) {$ctx1.fill(self,"extensionMethodsOfPackage:",{aPackage:aPackage,name:name,result:result},smalltalk.Exporter)})},
  770. messageSends: ["name", "new", "do:", "addAll:", "select:", "match:", ",", "category", "sorted:", "<=", "selector", "values", "methodDictionary", "class", "sortedClasses:", "classes", "current"]}),
  771. smalltalk.Exporter);
  772. smalltalk.addMethod(
  773. smalltalk.method({
  774. selector: "ownMethodsOfClass:",
  775. fn: function (aClass){
  776. var self=this;
  777. return smalltalk.withContext(function($ctx1) {
  778. var $1;
  779. $1=_st(_st(_st(_st(aClass)._methodDictionary())._values())._sorted_((function(a,b){
  780. return smalltalk.withContext(function($ctx2) {
  781. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  782. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})})))._reject_((function(each){
  783. return smalltalk.withContext(function($ctx2) {
  784. return _st(_st(each)._category())._match_("^\x5c*");
  785. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  786. return $1;
  787. }, function($ctx1) {$ctx1.fill(self,"ownMethodsOfClass:",{aClass:aClass},smalltalk.Exporter)})},
  788. messageSends: ["reject:", "match:", "category", "sorted:", "<=", "selector", "values", "methodDictionary"]}),
  789. smalltalk.Exporter);
  790. smalltalk.addMethod(
  791. smalltalk.method({
  792. selector: "ownMethodsOfMetaClass:",
  793. fn: function (aClass){
  794. var self=this;
  795. return smalltalk.withContext(function($ctx1) {
  796. var $1;
  797. $1=self._ownMethodsOfClass_(_st(aClass)._class());
  798. return $1;
  799. }, function($ctx1) {$ctx1.fill(self,"ownMethodsOfMetaClass:",{aClass:aClass},smalltalk.Exporter)})},
  800. messageSends: ["ownMethodsOfClass:", "class"]}),
  801. smalltalk.Exporter);
  802. smalltalk.addMethod(
  803. smalltalk.method({
  804. selector: "recipe",
  805. fn: function (){
  806. var self=this;
  807. function $PluggableExporter(){return smalltalk.PluggableExporter||(typeof PluggableExporter=="undefined"?nil:PluggableExporter)}
  808. return smalltalk.withContext(function($ctx1) {
  809. var $1;
  810. $1=[self.__minus_gt("exportPackagePrologueOf:on:"),self.__minus_gt("exportPackageDefinitionOf:on:"),[_st($PluggableExporter()).__minus_gt("ownClassesOfPackage:"),self.__minus_gt("exportDefinitionOf:on:"),[self.__minus_gt("ownMethodsOfClass:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportMetaDefinitionOf:on:"),[self.__minus_gt("ownMethodsOfMetaClass:"),self.__minus_gt("exportMethod:on:")]],[self.__minus_gt("extensionMethodsOfPackage:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportPackageEpilogueOf:on:")];
  811. return $1;
  812. }, function($ctx1) {$ctx1.fill(self,"recipe",{},smalltalk.Exporter)})},
  813. messageSends: ["->"]}),
  814. smalltalk.Exporter);
  815. smalltalk.addMethod(
  816. smalltalk.method({
  817. selector: "classNameFor:",
  818. fn: function (aClass){
  819. var self=this;
  820. return smalltalk.withContext(function($ctx1) {
  821. var $2,$3,$1;
  822. $2=_st(aClass)._isMetaclass();
  823. if(smalltalk.assert($2)){
  824. $1=_st(_st(_st(aClass)._instanceClass())._name()).__comma(".klass");
  825. } else {
  826. $3=_st(aClass)._isNil();
  827. if(smalltalk.assert($3)){
  828. $1="nil";
  829. } else {
  830. $1=_st(aClass)._name();
  831. };
  832. };
  833. return $1;
  834. }, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},smalltalk.Exporter.klass)})},
  835. messageSends: ["ifTrue:ifFalse:", ",", "name", "instanceClass", "isNil", "isMetaclass"]}),
  836. smalltalk.Exporter.klass);
  837. smalltalk.addMethod(
  838. smalltalk.method({
  839. selector: "exportDefinitionOf:on:",
  840. fn: function (aClass,aStream){
  841. var self=this;
  842. return smalltalk.withContext(function($ctx1) {
  843. var $1,$2,$3,$4,$5,$6,$7;
  844. $1=aStream;
  845. _st($1)._lf();
  846. _st($1)._nextPutAll_("smalltalk.addClass(");
  847. _st($1)._nextPutAll_(_st("'".__comma(self._classNameFor_(aClass))).__comma("', "));
  848. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._superclass())));
  849. $2=_st($1)._nextPutAll_(", [");
  850. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  851. return smalltalk.withContext(function($ctx2) {
  852. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  853. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  854. return smalltalk.withContext(function($ctx2) {
  855. return _st(aStream)._nextPutAll_(", ");
  856. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  857. $3=aStream;
  858. _st($3)._nextPutAll_("], '");
  859. _st($3)._nextPutAll_(_st(_st(aClass)._category()).__comma("'"));
  860. $4=_st($3)._nextPutAll_(");");
  861. $5=_st(_st(aClass)._comment())._notEmpty();
  862. if(smalltalk.assert($5)){
  863. $6=aStream;
  864. _st($6)._lf();
  865. _st($6)._nextPutAll_("smalltalk.");
  866. _st($6)._nextPutAll_(self._classNameFor_(aClass));
  867. _st($6)._nextPutAll_(".comment=");
  868. _st($6)._nextPutAll_(_st(_st(aClass)._comment())._asJavascript());
  869. $7=_st($6)._nextPutAll_(";");
  870. $7;
  871. };
  872. _st(aStream)._lf();
  873. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.Exporter.klass)})},
  874. messageSends: ["lf", "nextPutAll:", ",", "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "asJavascript", "comment", "notEmpty"]}),
  875. smalltalk.Exporter.klass);
  876. smalltalk.addMethod(
  877. smalltalk.method({
  878. selector: "exportMetaDefinitionOf:on:",
  879. fn: function (aClass,aStream){
  880. var self=this;
  881. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  882. return smalltalk.withContext(function($ctx1) {
  883. var $1,$2,$3;
  884. _st(aStream)._lf();
  885. $1=_st(_st(_st(aClass)._class())._instanceVariableNames())._isEmpty();
  886. if(! smalltalk.assert($1)){
  887. $2=aStream;
  888. _st($2)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._class())));
  889. $3=_st($2)._nextPutAll_(".iVarNames = [");
  890. $3;
  891. _st(_st(_st(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
  892. return smalltalk.withContext(function($ctx2) {
  893. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  894. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  895. return smalltalk.withContext(function($ctx2) {
  896. return _st(aStream)._nextPutAll_(",");
  897. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  898. _st(aStream)._nextPutAll_("];".__comma(_st($String())._lf()));
  899. };
  900. return self}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.Exporter.klass)})},
  901. messageSends: ["lf", "ifFalse:", "nextPutAll:", ",", "classNameFor:", "class", "do:separatedBy:", "instanceVariableNames", "isEmpty"]}),
  902. smalltalk.Exporter.klass);
  903. smalltalk.addMethod(
  904. smalltalk.method({
  905. selector: "exportMethod:on:",
  906. fn: function (aMethod,aStream){
  907. var self=this;
  908. return smalltalk.withContext(function($ctx1) {
  909. var $1,$2,$3,$4;
  910. $1=aStream;
  911. _st($1)._nextPutAll_("smalltalk.addMethod(");
  912. _st($1)._lf();
  913. _st($1)._nextPutAll_("smalltalk.method({");
  914. _st($1)._lf();
  915. _st($1)._nextPutAll_(_st("selector: ".__comma(_st(_st(aMethod)._selector())._asJavascript())).__comma(","));
  916. _st($1)._lf();
  917. _st($1)._nextPutAll_(_st("category: '".__comma(_st(aMethod)._category())).__comma("',"));
  918. _st($1)._lf();
  919. _st($1)._nextPutAll_(_st("fn: ".__comma(_st(_st(aMethod)._fn())._compiledSource())).__comma(","));
  920. _st($1)._lf();
  921. _st($1)._nextPutAll_(_st("args: ".__comma(_st(_st(aMethod)._arguments())._asJavascript())).__comma(","));
  922. _st($1)._lf();
  923. _st($1)._nextPutAll_(_st("source: ".__comma(_st(_st(aMethod)._source())._asJavascript())).__comma(","));
  924. _st($1)._lf();
  925. _st($1)._nextPutAll_(_st("messageSends: ".__comma(_st(_st(aMethod)._messageSends())._asJavascript())).__comma(","));
  926. _st($1)._lf();
  927. $2=_st($1)._nextPutAll_("referencedClasses: ".__comma(_st(_st(aMethod)._referencedClasses())._asJavascript()));
  928. $3=aStream;
  929. _st($3)._lf();
  930. _st($3)._nextPutAll_("}),");
  931. _st($3)._lf();
  932. _st($3)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aMethod)._methodClass())));
  933. _st($3)._nextPutAll_(");");
  934. _st($3)._lf();
  935. $4=_st($3)._lf();
  936. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.Exporter.klass)})},
  937. messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "category", "compiledSource", "fn", "arguments", "source", "messageSends", "referencedClasses", "classNameFor:", "methodClass"]}),
  938. smalltalk.Exporter.klass);
  939. smalltalk.addMethod(
  940. smalltalk.method({
  941. selector: "exportPackageDefinitionOf:on:",
  942. fn: function (package_,aStream){
  943. var self=this;
  944. return smalltalk.withContext(function($ctx1) {
  945. var $1,$2;
  946. $1=aStream;
  947. _st($1)._nextPutAll_("smalltalk.addPackage(");
  948. _st($1)._nextPutAll_(_st("'".__comma(_st(package_)._name())).__comma("');"));
  949. $2=_st($1)._lf();
  950. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{package_:package_,aStream:aStream},smalltalk.Exporter.klass)})},
  951. messageSends: ["nextPutAll:", ",", "name", "lf"]}),
  952. smalltalk.Exporter.klass);
  953. smalltalk.addMethod(
  954. smalltalk.method({
  955. selector: "exportPackageEpilogueOf:on:",
  956. fn: function (aPackage,aStream){
  957. var self=this;
  958. return smalltalk.withContext(function($ctx1) {
  959. var $1,$2;
  960. $1=aStream;
  961. _st($1)._nextPutAll_("})(global_smalltalk,global_nil,global__st);");
  962. $2=_st($1)._lf();
  963. return self}, function($ctx1) {$ctx1.fill(self,"exportPackageEpilogueOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.Exporter.klass)})},
  964. messageSends: ["nextPutAll:", "lf"]}),
  965. smalltalk.Exporter.klass);
  966. smalltalk.addMethod(
  967. smalltalk.method({
  968. selector: "exportPackagePrologueOf:on:",
  969. fn: function (aPackage,aStream){
  970. var self=this;
  971. return smalltalk.withContext(function($ctx1) {
  972. var $1,$2;
  973. $1=aStream;
  974. _st($1)._nextPutAll_("(function(smalltalk,nil,_st){");
  975. $2=_st($1)._lf();
  976. return self}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},smalltalk.Exporter.klass)})},
  977. messageSends: ["nextPutAll:", "lf"]}),
  978. smalltalk.Exporter.klass);
  979. smalltalk.addMethod(
  980. smalltalk.method({
  981. selector: "extensionMethodsOfPackage:",
  982. fn: function (package_){
  983. var self=this;
  984. var name,result;
  985. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  986. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  987. function $Package(){return smalltalk.Package||(typeof Package=="undefined"?nil:Package)}
  988. return smalltalk.withContext(function($ctx1) {
  989. var $1;
  990. name=_st(package_)._name();
  991. result=_st($OrderedCollection())._new();
  992. _st(_st($Package())._sortedClasses_(_st(_st($Smalltalk())._current())._classes()))._do_((function(each){
  993. return smalltalk.withContext(function($ctx2) {
  994. return _st([each,_st(each)._class()])._do_((function(aClass){
  995. return smalltalk.withContext(function($ctx3) {
  996. return _st(result)._addAll_(_st(_st(_st(_st(aClass)._methodDictionary())._values())._sorted_((function(a,b){
  997. return smalltalk.withContext(function($ctx4) {
  998. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  999. }, function($ctx4) {$ctx4.fillBlock({a:a,b:b},$ctx3)})})))._select_((function(method){
  1000. return smalltalk.withContext(function($ctx4) {
  1001. return _st(_st(method)._category())._match_("^\x5c*".__comma(name));
  1002. }, function($ctx4) {$ctx4.fillBlock({method:method},$ctx3)})})));
  1003. }, function($ctx3) {$ctx3.fillBlock({aClass:aClass},$ctx2)})}));
  1004. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1005. $1=result;
  1006. return $1;
  1007. }, function($ctx1) {$ctx1.fill(self,"extensionMethodsOfPackage:",{package_:package_,name:name,result:result},smalltalk.Exporter.klass)})},
  1008. messageSends: ["name", "new", "do:", "addAll:", "select:", "match:", ",", "category", "sorted:", "<=", "selector", "values", "methodDictionary", "class", "sortedClasses:", "classes", "current"]}),
  1009. smalltalk.Exporter.klass);
  1010. smalltalk.addMethod(
  1011. smalltalk.method({
  1012. selector: "ownMethodsOfClass:",
  1013. fn: function (aClass){
  1014. var self=this;
  1015. return smalltalk.withContext(function($ctx1) {
  1016. var $1;
  1017. $1=_st(_st(_st(_st(aClass)._methodDictionary())._values())._sorted_((function(a,b){
  1018. return smalltalk.withContext(function($ctx2) {
  1019. return _st(_st(a)._selector()).__lt_eq(_st(b)._selector());
  1020. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})})))._reject_((function(each){
  1021. return smalltalk.withContext(function($ctx2) {
  1022. return _st(_st(each)._category())._match_("^\x5c*");
  1023. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1024. return $1;
  1025. }, function($ctx1) {$ctx1.fill(self,"ownMethodsOfClass:",{aClass:aClass},smalltalk.Exporter.klass)})},
  1026. messageSends: ["reject:", "match:", "category", "sorted:", "<=", "selector", "values", "methodDictionary"]}),
  1027. smalltalk.Exporter.klass);
  1028. smalltalk.addMethod(
  1029. smalltalk.method({
  1030. selector: "ownMethodsOfMetaClass:",
  1031. fn: function (aClass){
  1032. var self=this;
  1033. return smalltalk.withContext(function($ctx1) {
  1034. var $1;
  1035. $1=self._ownMethodsOfClass_(_st(aClass)._class());
  1036. return $1;
  1037. }, function($ctx1) {$ctx1.fill(self,"ownMethodsOfMetaClass:",{aClass:aClass},smalltalk.Exporter.klass)})},
  1038. messageSends: ["ownMethodsOfClass:", "class"]}),
  1039. smalltalk.Exporter.klass);
  1040. smalltalk.addMethod(
  1041. smalltalk.method({
  1042. selector: "recipe",
  1043. fn: function (){
  1044. var self=this;
  1045. function $PluggableExporter(){return smalltalk.PluggableExporter||(typeof PluggableExporter=="undefined"?nil:PluggableExporter)}
  1046. return smalltalk.withContext(function($ctx1) {
  1047. var $1;
  1048. $1=[self.__minus_gt("exportPackagePrologueOf:on:"),self.__minus_gt("exportPackageDefinitionOf:on:"),[_st($PluggableExporter()).__minus_gt("ownClassesOfPackage:"),self.__minus_gt("exportDefinitionOf:on:"),[self.__minus_gt("ownMethodsOfClass:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportMetaDefinitionOf:on:"),[self.__minus_gt("ownMethodsOfMetaClass:"),self.__minus_gt("exportMethod:on:")]],[self.__minus_gt("extensionMethodsOfPackage:"),self.__minus_gt("exportMethod:on:")],self.__minus_gt("exportPackageEpilogueOf:on:")];
  1049. return $1;
  1050. }, function($ctx1) {$ctx1.fill(self,"recipe",{},smalltalk.Exporter.klass)})},
  1051. messageSends: ["->"]}),
  1052. smalltalk.Exporter.klass);
  1053. smalltalk.addClass('StrippedExporter', smalltalk.Exporter, [], 'Importer-Exporter');
  1054. smalltalk.addMethod(
  1055. smalltalk.method({
  1056. selector: "exportDefinitionOf:on:",
  1057. fn: function (aClass,aStream){
  1058. var self=this;
  1059. return smalltalk.withContext(function($ctx1) {
  1060. var $1,$2,$3,$4;
  1061. $1=aStream;
  1062. _st($1)._lf();
  1063. _st($1)._nextPutAll_("smalltalk.addClass(");
  1064. _st($1)._nextPutAll_(_st("'".__comma(self._classNameFor_(aClass))).__comma("', "));
  1065. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._superclass())));
  1066. $2=_st($1)._nextPutAll_(", [");
  1067. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  1068. return smalltalk.withContext(function($ctx2) {
  1069. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  1070. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  1071. return smalltalk.withContext(function($ctx2) {
  1072. return _st(aStream)._nextPutAll_(", ");
  1073. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1074. $3=aStream;
  1075. _st($3)._nextPutAll_("], '");
  1076. _st($3)._nextPutAll_(_st(_st(aClass)._category()).__comma("'"));
  1077. $4=_st($3)._nextPutAll_(");");
  1078. _st(aStream)._lf();
  1079. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.StrippedExporter)})},
  1080. messageSends: ["lf", "nextPutAll:", ",", "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category"]}),
  1081. smalltalk.StrippedExporter);
  1082. smalltalk.addMethod(
  1083. smalltalk.method({
  1084. selector: "exportMethod:on:",
  1085. fn: function (aMethod,aStream){
  1086. var self=this;
  1087. return smalltalk.withContext(function($ctx1) {
  1088. var $1,$2;
  1089. $1=aStream;
  1090. _st($1)._nextPutAll_("smalltalk.addMethod(");
  1091. _st($1)._lf();
  1092. _st($1)._nextPutAll_("smalltalk.method({");
  1093. _st($1)._lf();
  1094. _st($1)._nextPutAll_(_st("selector: ".__comma(_st(_st(aMethod)._selector())._asJavascript())).__comma(","));
  1095. _st($1)._lf();
  1096. _st($1)._nextPutAll_(_st("fn: ".__comma(_st(_st(aMethod)._fn())._compiledSource())).__comma(","));
  1097. _st($1)._lf();
  1098. _st($1)._nextPutAll_("messageSends: ".__comma(_st(_st(aMethod)._messageSends())._asJavascript()));
  1099. _st($1)._nextPutAll_("}),");
  1100. _st($1)._lf();
  1101. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aMethod)._methodClass())));
  1102. _st($1)._nextPutAll_(");");
  1103. _st($1)._lf();
  1104. $2=_st($1)._lf();
  1105. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.StrippedExporter)})},
  1106. messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "compiledSource", "fn", "messageSends", "classNameFor:", "methodClass"]}),
  1107. smalltalk.StrippedExporter);
  1108. smalltalk.addMethod(
  1109. smalltalk.method({
  1110. selector: "exportDefinitionOf:on:",
  1111. fn: function (aClass,aStream){
  1112. var self=this;
  1113. return smalltalk.withContext(function($ctx1) {
  1114. var $1,$2,$3,$4;
  1115. $1=aStream;
  1116. _st($1)._lf();
  1117. _st($1)._nextPutAll_("smalltalk.addClass(");
  1118. _st($1)._nextPutAll_(_st("'".__comma(self._classNameFor_(aClass))).__comma("', "));
  1119. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aClass)._superclass())));
  1120. $2=_st($1)._nextPutAll_(", [");
  1121. _st(_st(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
  1122. return smalltalk.withContext(function($ctx2) {
  1123. return _st(aStream)._nextPutAll_(_st("'".__comma(each)).__comma("'"));
  1124. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  1125. return smalltalk.withContext(function($ctx2) {
  1126. return _st(aStream)._nextPutAll_(", ");
  1127. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1128. $3=aStream;
  1129. _st($3)._nextPutAll_("], '");
  1130. _st($3)._nextPutAll_(_st(_st(aClass)._category()).__comma("'"));
  1131. $4=_st($3)._nextPutAll_(");");
  1132. _st(aStream)._lf();
  1133. return self}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},smalltalk.StrippedExporter.klass)})},
  1134. messageSends: ["lf", "nextPutAll:", ",", "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category"]}),
  1135. smalltalk.StrippedExporter.klass);
  1136. smalltalk.addMethod(
  1137. smalltalk.method({
  1138. selector: "exportMethod:on:",
  1139. fn: function (aMethod,aStream){
  1140. var self=this;
  1141. return smalltalk.withContext(function($ctx1) {
  1142. var $1,$2;
  1143. $1=aStream;
  1144. _st($1)._nextPutAll_("smalltalk.addMethod(");
  1145. _st($1)._lf();
  1146. _st($1)._nextPutAll_("smalltalk.method({");
  1147. _st($1)._lf();
  1148. _st($1)._nextPutAll_(_st("selector: ".__comma(_st(_st(aMethod)._selector())._asJavascript())).__comma(","));
  1149. _st($1)._lf();
  1150. _st($1)._nextPutAll_(_st("fn: ".__comma(_st(_st(aMethod)._fn())._compiledSource())).__comma(","));
  1151. _st($1)._lf();
  1152. _st($1)._nextPutAll_("messageSends: ".__comma(_st(_st(aMethod)._messageSends())._asJavascript()));
  1153. _st($1)._nextPutAll_("}),");
  1154. _st($1)._lf();
  1155. _st($1)._nextPutAll_("smalltalk.".__comma(self._classNameFor_(_st(aMethod)._methodClass())));
  1156. _st($1)._nextPutAll_(");");
  1157. _st($1)._lf();
  1158. $2=_st($1)._lf();
  1159. return self}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},smalltalk.StrippedExporter.klass)})},
  1160. messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "compiledSource", "fn", "messageSends", "classNameFor:", "methodClass"]}),
  1161. smalltalk.StrippedExporter.klass);
  1162. smalltalk.addClass('ChunkParser', smalltalk.Object, ['stream'], 'Importer-Exporter');
  1163. smalltalk.addMethod(
  1164. smalltalk.method({
  1165. selector: "nextChunk",
  1166. fn: function (){
  1167. var self=this;
  1168. var char,result,chunk;
  1169. return smalltalk.withContext(function($ctx1) {
  1170. var $1,$2,$3;
  1171. var $early={};
  1172. try {
  1173. result=""._writeStream();
  1174. _st((function(){
  1175. return smalltalk.withContext(function($ctx2) {
  1176. char=_st(self["@stream"])._next();
  1177. char;
  1178. return _st(char)._notNil();
  1179. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._whileTrue_((function(){
  1180. return smalltalk.withContext(function($ctx2) {
  1181. $1=_st(char).__eq("!");
  1182. if(smalltalk.assert($1)){
  1183. $2=_st(_st(self["@stream"])._peek()).__eq("!");
  1184. if(smalltalk.assert($2)){
  1185. _st(self["@stream"])._next();
  1186. } else {
  1187. $3=_st(_st(result)._contents())._trimBoth();
  1188. throw $early=[$3];
  1189. };
  1190. };
  1191. return _st(result)._nextPut_(char);
  1192. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1193. return nil;
  1194. }
  1195. catch(e) {if(e===$early)return e[0]; throw e}
  1196. }, function($ctx1) {$ctx1.fill(self,"nextChunk",{char:char,result:result,chunk:chunk},smalltalk.ChunkParser)})},
  1197. messageSends: ["writeStream", "whileTrue:", "ifTrue:", "ifTrue:ifFalse:", "next", "trimBoth", "contents", "=", "peek", "nextPut:", "notNil"]}),
  1198. smalltalk.ChunkParser);
  1199. smalltalk.addMethod(
  1200. smalltalk.method({
  1201. selector: "stream:",
  1202. fn: function (aStream){
  1203. var self=this;
  1204. return smalltalk.withContext(function($ctx1) {
  1205. self["@stream"]=aStream;
  1206. return self}, function($ctx1) {$ctx1.fill(self,"stream:",{aStream:aStream},smalltalk.ChunkParser)})},
  1207. messageSends: []}),
  1208. smalltalk.ChunkParser);
  1209. smalltalk.addMethod(
  1210. smalltalk.method({
  1211. selector: "on:",
  1212. fn: function (aStream){
  1213. var self=this;
  1214. return smalltalk.withContext(function($ctx1) {
  1215. var $1;
  1216. $1=_st(self._new())._stream_(aStream);
  1217. return $1;
  1218. }, function($ctx1) {$ctx1.fill(self,"on:",{aStream:aStream},smalltalk.ChunkParser.klass)})},
  1219. messageSends: ["stream:", "new"]}),
  1220. smalltalk.ChunkParser.klass);
  1221. smalltalk.addClass('Importer', smalltalk.Object, [], 'Importer-Exporter');
  1222. smalltalk.addMethod(
  1223. smalltalk.method({
  1224. selector: "import:",
  1225. fn: function (aStream){
  1226. var self=this;
  1227. var chunk,result,parser,lastEmpty;
  1228. function $ChunkParser(){return smalltalk.ChunkParser||(typeof ChunkParser=="undefined"?nil:ChunkParser)}
  1229. function $Compiler(){return smalltalk.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
  1230. return smalltalk.withContext(function($ctx1) {
  1231. var $1,$2;
  1232. parser=_st($ChunkParser())._on_(aStream);
  1233. lastEmpty=false;
  1234. _st((function(){
  1235. return smalltalk.withContext(function($ctx2) {
  1236. chunk=_st(parser)._nextChunk();
  1237. chunk;
  1238. return _st(chunk)._isNil();
  1239. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._whileFalse_((function(){
  1240. return smalltalk.withContext(function($ctx2) {
  1241. $1=_st(chunk)._isEmpty();
  1242. if(smalltalk.assert($1)){
  1243. lastEmpty=true;
  1244. return lastEmpty;
  1245. } else {
  1246. result=_st(_st($Compiler())._new())._evaluateExpression_(chunk);
  1247. result;
  1248. $2=lastEmpty;
  1249. if(smalltalk.assert($2)){
  1250. lastEmpty=false;
  1251. lastEmpty;
  1252. return _st(result)._scanFrom_(parser);
  1253. };
  1254. };
  1255. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1256. return self}, function($ctx1) {$ctx1.fill(self,"import:",{aStream:aStream,chunk:chunk,result:result,parser:parser,lastEmpty:lastEmpty},smalltalk.Importer)})},
  1257. messageSends: ["on:", "whileFalse:", "ifTrue:ifFalse:", "evaluateExpression:", "new", "ifTrue:", "scanFrom:", "isEmpty", "nextChunk", "isNil"]}),
  1258. smalltalk.Importer);
  1259. smalltalk.addClass('MethodCategory', smalltalk.Object, ['methods', 'name', 'theClass'], 'Importer-Exporter');
  1260. smalltalk.addMethod(
  1261. smalltalk.method({
  1262. selector: "methods",
  1263. fn: function (){
  1264. var self=this;
  1265. return smalltalk.withContext(function($ctx1) {
  1266. var $1;
  1267. $1=self["@methods"];
  1268. return $1;
  1269. }, function($ctx1) {$ctx1.fill(self,"methods",{},smalltalk.MethodCategory)})},
  1270. messageSends: []}),
  1271. smalltalk.MethodCategory);
  1272. smalltalk.addMethod(
  1273. smalltalk.method({
  1274. selector: "methods:",
  1275. fn: function (aCollection){
  1276. var self=this;
  1277. return smalltalk.withContext(function($ctx1) {
  1278. self["@methods"]=aCollection;
  1279. return self}, function($ctx1) {$ctx1.fill(self,"methods:",{aCollection:aCollection},smalltalk.MethodCategory)})},
  1280. messageSends: []}),
  1281. smalltalk.MethodCategory);
  1282. smalltalk.addMethod(
  1283. smalltalk.method({
  1284. selector: "name",
  1285. fn: function (){
  1286. var self=this;
  1287. return smalltalk.withContext(function($ctx1) {
  1288. var $1;
  1289. $1=self["@name"];
  1290. return $1;
  1291. }, function($ctx1) {$ctx1.fill(self,"name",{},smalltalk.MethodCategory)})},
  1292. messageSends: []}),
  1293. smalltalk.MethodCategory);
  1294. smalltalk.addMethod(
  1295. smalltalk.method({
  1296. selector: "name:",
  1297. fn: function (aString){
  1298. var self=this;
  1299. return smalltalk.withContext(function($ctx1) {
  1300. self["@name"]=aString;
  1301. return self}, function($ctx1) {$ctx1.fill(self,"name:",{aString:aString},smalltalk.MethodCategory)})},
  1302. messageSends: []}),
  1303. smalltalk.MethodCategory);
  1304. smalltalk.addMethod(
  1305. smalltalk.method({
  1306. selector: "theClass",
  1307. fn: function (){
  1308. var self=this;
  1309. return smalltalk.withContext(function($ctx1) {
  1310. var $1;
  1311. $1=self["@theClass"];
  1312. return $1;
  1313. }, function($ctx1) {$ctx1.fill(self,"theClass",{},smalltalk.MethodCategory)})},
  1314. messageSends: []}),
  1315. smalltalk.MethodCategory);
  1316. smalltalk.addMethod(
  1317. smalltalk.method({
  1318. selector: "theClass:",
  1319. fn: function (aClass){
  1320. var self=this;
  1321. return smalltalk.withContext(function($ctx1) {
  1322. self["@theClass"]=aClass;
  1323. return self}, function($ctx1) {$ctx1.fill(self,"theClass:",{aClass:aClass},smalltalk.MethodCategory)})},
  1324. messageSends: []}),
  1325. smalltalk.MethodCategory);
  1326. smalltalk.addMethod(
  1327. smalltalk.method({
  1328. selector: "name:theClass:methods:",
  1329. fn: function (aString,aClass,anArray){
  1330. var self=this;
  1331. return smalltalk.withContext(function($ctx1) {
  1332. var $2,$3,$1;
  1333. $2=self._new();
  1334. _st($2)._name_(aString);
  1335. _st($2)._theClass_(aClass);
  1336. _st($2)._methods_(anArray);
  1337. $3=_st($2)._yourself();
  1338. $1=$3;
  1339. return $1;
  1340. }, function($ctx1) {$ctx1.fill(self,"name:theClass:methods:",{aString:aString,aClass:aClass,anArray:anArray},smalltalk.MethodCategory.klass)})},
  1341. messageSends: ["name:", "new", "theClass:", "methods:", "yourself"]}),
  1342. smalltalk.MethodCategory.klass);
  1343. smalltalk.addClass('PackageHandler', smalltalk.InterfacingObject, [], 'Importer-Exporter');
  1344. smalltalk.addMethod(
  1345. smalltalk.method({
  1346. selector: "ajaxPutAt:data:",
  1347. fn: function (aURL,aString){
  1348. var self=this;
  1349. return smalltalk.withContext(function($ctx1) {
  1350. self._ajax_(smalltalk.HashedCollection._from_(["url".__minus_gt(aURL),"type".__minus_gt("PUT"),"data".__minus_gt(aString),"contentType".__minus_gt("text/plain;charset=UTF-8"),"error".__minus_gt((function(xhr){
  1351. return smalltalk.withContext(function($ctx2) {
  1352. return self._error_(_st(_st(_st("Commiting ".__comma(aURL)).__comma(" failed with reason: \x22")).__comma(_st(xhr)._responseText())).__comma("\x22"));
  1353. }, function($ctx2) {$ctx2.fillBlock({xhr:xhr},$ctx1)})}))]));
  1354. return self}, function($ctx1) {$ctx1.fill(self,"ajaxPutAt:data:",{aURL:aURL,aString:aString},smalltalk.PackageHandler)})},
  1355. messageSends: ["ajax:", "->", "error:", ",", "responseText"]}),
  1356. smalltalk.PackageHandler);
  1357. smalltalk.addMethod(
  1358. smalltalk.method({
  1359. selector: "commit:",
  1360. fn: function (aPackage){
  1361. var self=this;
  1362. function $PluggableExporter(){return smalltalk.PluggableExporter||(typeof PluggableExporter=="undefined"?nil:PluggableExporter)}
  1363. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1364. return smalltalk.withContext(function($ctx1) {
  1365. _st(self._commitChannels())._do_displayingProgress_((function(commitStrategyFactory){
  1366. var fileContents,commitStrategy;
  1367. return smalltalk.withContext(function($ctx2) {
  1368. commitStrategy=_st(commitStrategyFactory)._value_(aPackage);
  1369. commitStrategy;
  1370. fileContents=_st($String())._streamContents_((function(stream){
  1371. return smalltalk.withContext(function($ctx3) {
  1372. return _st(_st($PluggableExporter())._forRecipe_(_st(commitStrategy)._key()))._exportPackage_on_(aPackage,stream);
  1373. }, function($ctx3) {$ctx3.fillBlock({stream:stream},$ctx2)})}));
  1374. fileContents;
  1375. return self._ajaxPutAt_data_(_st(commitStrategy)._value(),fileContents);
  1376. }, function($ctx2) {$ctx2.fillBlock({commitStrategyFactory:commitStrategyFactory,fileContents:fileContents,commitStrategy:commitStrategy},$ctx1)})}),"Committing package ".__comma(_st(aPackage)._name()));
  1377. return self}, function($ctx1) {$ctx1.fill(self,"commit:",{aPackage:aPackage},smalltalk.PackageHandler)})},
  1378. messageSends: ["do:displayingProgress:", "value:", "streamContents:", "exportPackage:on:", "forRecipe:", "key", "ajaxPutAt:data:", "value", ",", "name", "commitChannels"]}),
  1379. smalltalk.PackageHandler);
  1380. smalltalk.addMethod(
  1381. smalltalk.method({
  1382. selector: "commitChannels",
  1383. fn: function (){
  1384. var self=this;
  1385. return smalltalk.withContext(function($ctx1) {
  1386. self._subclassResponsibility();
  1387. return self}, function($ctx1) {$ctx1.fill(self,"commitChannels",{},smalltalk.PackageHandler)})},
  1388. messageSends: ["subclassResponsibility"]}),
  1389. smalltalk.PackageHandler);
  1390. smalltalk.PackageHandler.klass.iVarNames = ['registry'];
  1391. smalltalk.addMethod(
  1392. smalltalk.method({
  1393. selector: "classRegisteredFor:",
  1394. fn: function (aString){
  1395. var self=this;
  1396. return smalltalk.withContext(function($ctx1) {
  1397. var $1;
  1398. $1=_st(self["@registry"])._at_(aString);
  1399. return $1;
  1400. }, function($ctx1) {$ctx1.fill(self,"classRegisteredFor:",{aString:aString},smalltalk.PackageHandler.klass)})},
  1401. messageSends: ["at:"]}),
  1402. smalltalk.PackageHandler.klass);
  1403. smalltalk.addMethod(
  1404. smalltalk.method({
  1405. selector: "for:",
  1406. fn: function (aString){
  1407. var self=this;
  1408. return smalltalk.withContext(function($ctx1) {
  1409. var $1;
  1410. $1=_st(self._classRegisteredFor_(aString))._new();
  1411. return $1;
  1412. }, function($ctx1) {$ctx1.fill(self,"for:",{aString:aString},smalltalk.PackageHandler.klass)})},
  1413. messageSends: ["new", "classRegisteredFor:"]}),
  1414. smalltalk.PackageHandler.klass);
  1415. smalltalk.addMethod(
  1416. smalltalk.method({
  1417. selector: "initialize",
  1418. fn: function (){
  1419. var self=this;
  1420. return smalltalk.withContext(function($ctx1) {
  1421. smalltalk.PackageHandler.klass.superclass.fn.prototype._initialize.apply(_st(self), []);
  1422. self["@registry"]=smalltalk.HashedCollection._from_([]);
  1423. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.PackageHandler.klass)})},
  1424. messageSends: ["initialize"]}),
  1425. smalltalk.PackageHandler.klass);
  1426. smalltalk.addMethod(
  1427. smalltalk.method({
  1428. selector: "register:for:",
  1429. fn: function (aClass,aString){
  1430. var self=this;
  1431. return smalltalk.withContext(function($ctx1) {
  1432. _st(self["@registry"])._at_put_(aString,aClass);
  1433. return self}, function($ctx1) {$ctx1.fill(self,"register:for:",{aClass:aClass,aString:aString},smalltalk.PackageHandler.klass)})},
  1434. messageSends: ["at:put:"]}),
  1435. smalltalk.PackageHandler.klass);
  1436. smalltalk.addMethod(
  1437. smalltalk.method({
  1438. selector: "registerFor:",
  1439. fn: function (aString){
  1440. var self=this;
  1441. function $PackageHandler(){return smalltalk.PackageHandler||(typeof PackageHandler=="undefined"?nil:PackageHandler)}
  1442. return smalltalk.withContext(function($ctx1) {
  1443. _st($PackageHandler())._register_for_(self,aString);
  1444. return self}, function($ctx1) {$ctx1.fill(self,"registerFor:",{aString:aString},smalltalk.PackageHandler.klass)})},
  1445. messageSends: ["register:for:"]}),
  1446. smalltalk.PackageHandler.klass);
  1447. smalltalk.addClass('LegacyPackageHandler', smalltalk.PackageHandler, [], 'Importer-Exporter');
  1448. smalltalk.addMethod(
  1449. smalltalk.method({
  1450. selector: "commitChannels",
  1451. fn: function (){
  1452. var self=this;
  1453. function $Exporter(){return smalltalk.Exporter||(typeof Exporter=="undefined"?nil:Exporter)}
  1454. function $StrippedExporter(){return smalltalk.StrippedExporter||(typeof StrippedExporter=="undefined"?nil:StrippedExporter)}
  1455. function $ChunkExporter(){return smalltalk.ChunkExporter||(typeof ChunkExporter=="undefined"?nil:ChunkExporter)}
  1456. return smalltalk.withContext(function($ctx1) {
  1457. var $1;
  1458. $1=[(function(pkg){
  1459. return smalltalk.withContext(function($ctx2) {
  1460. return _st(_st(_st($Exporter())._default())._recipe()).__minus_gt(_st(_st(_st(_st(pkg)._commitPathJs()).__comma("/")).__comma(_st(pkg)._name())).__comma(".js"));
  1461. }, function($ctx2) {$ctx2.fillBlock({pkg:pkg},$ctx1)})}),(function(pkg){
  1462. return smalltalk.withContext(function($ctx2) {
  1463. return _st(_st(_st($StrippedExporter())._default())._recipe()).__minus_gt(_st(_st(_st(_st(pkg)._commitPathJs()).__comma("/")).__comma(_st(pkg)._name())).__comma(".deploy.js"));
  1464. }, function($ctx2) {$ctx2.fillBlock({pkg:pkg},$ctx1)})}),(function(pkg){
  1465. return smalltalk.withContext(function($ctx2) {
  1466. return _st(_st(_st($ChunkExporter())._default())._recipe()).__minus_gt(_st(_st(_st(_st(pkg)._commitPathSt()).__comma("/")).__comma(_st(pkg)._name())).__comma(".st"));
  1467. }, function($ctx2) {$ctx2.fillBlock({pkg:pkg},$ctx1)})})];
  1468. return $1;
  1469. }, function($ctx1) {$ctx1.fill(self,"commitChannels",{},smalltalk.LegacyPackageHandler)})},
  1470. messageSends: ["->", ",", "name", "commitPathJs", "recipe", "default", "commitPathSt"]}),
  1471. smalltalk.LegacyPackageHandler);
  1472. smalltalk.addMethod(
  1473. smalltalk.method({
  1474. selector: "commitPathJsFor:",
  1475. fn: function (aPackage){
  1476. var self=this;
  1477. return smalltalk.withContext(function($ctx1) {
  1478. var $1;
  1479. $1=_st(self._class())._defaultCommitPathJs();
  1480. return $1;
  1481. }, function($ctx1) {$ctx1.fill(self,"commitPathJsFor:",{aPackage:aPackage},smalltalk.LegacyPackageHandler)})},
  1482. messageSends: ["defaultCommitPathJs", "class"]}),
  1483. smalltalk.LegacyPackageHandler);
  1484. smalltalk.addMethod(
  1485. smalltalk.method({
  1486. selector: "commitPathStFor:",
  1487. fn: function (aPackage){
  1488. var self=this;
  1489. return smalltalk.withContext(function($ctx1) {
  1490. var $1;
  1491. $1=_st(self._class())._defaultCommitPathSt();
  1492. return $1;
  1493. }, function($ctx1) {$ctx1.fill(self,"commitPathStFor:",{aPackage:aPackage},smalltalk.LegacyPackageHandler)})},
  1494. messageSends: ["defaultCommitPathSt", "class"]}),
  1495. smalltalk.LegacyPackageHandler);
  1496. smalltalk.addMethod(
  1497. smalltalk.method({
  1498. selector: "loadPackage:prefix:",
  1499. fn: function (packageName,aString){
  1500. var self=this;
  1501. var url;
  1502. return smalltalk.withContext(function($ctx1) {
  1503. var $1;
  1504. url=_st(_st(_st("/".__comma(aString)).__comma("/js/")).__comma(packageName)).__comma(".js");
  1505. self._ajax_(smalltalk.HashedCollection._from_(["url".__minus_gt(url),"type".__minus_gt("GET"),"dataType".__minus_gt("script"),"complete".__minus_gt((function(jqXHR,textStatus){
  1506. return smalltalk.withContext(function($ctx2) {
  1507. $1=_st(_st(jqXHR)._readyState()).__eq((4));
  1508. if(smalltalk.assert($1)){
  1509. return self._setupPackageNamed_prefix_(packageName,aString);
  1510. };
  1511. }, function($ctx2) {$ctx2.fillBlock({jqXHR:jqXHR,textStatus:textStatus},$ctx1)})})),"error".__minus_gt((function(){
  1512. return smalltalk.withContext(function($ctx2) {
  1513. return self._alert_("Could not load package at: ".__comma(url));
  1514. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))]));
  1515. return self}, function($ctx1) {$ctx1.fill(self,"loadPackage:prefix:",{packageName:packageName,aString:aString,url:url},smalltalk.LegacyPackageHandler)})},
  1516. messageSends: [",", "ajax:", "->", "ifTrue:", "setupPackageNamed:prefix:", "=", "readyState", "alert:"]}),
  1517. smalltalk.LegacyPackageHandler);
  1518. smalltalk.addMethod(
  1519. smalltalk.method({
  1520. selector: "loadPackages:prefix:",
  1521. fn: function (aCollection,aString){
  1522. var self=this;
  1523. return smalltalk.withContext(function($ctx1) {
  1524. _st(aCollection)._do_((function(each){
  1525. return smalltalk.withContext(function($ctx2) {
  1526. return self._loadPackage_prefix_(each,aString);
  1527. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1528. return self}, function($ctx1) {$ctx1.fill(self,"loadPackages:prefix:",{aCollection:aCollection,aString:aString},smalltalk.LegacyPackageHandler)})},
  1529. messageSends: ["do:", "loadPackage:prefix:"]}),
  1530. smalltalk.LegacyPackageHandler);
  1531. smalltalk.addMethod(
  1532. smalltalk.method({
  1533. selector: "setupPackageNamed:prefix:",
  1534. fn: function (packageName,aString){
  1535. var self=this;
  1536. function $Package(){return smalltalk.Package||(typeof Package=="undefined"?nil:Package)}
  1537. return smalltalk.withContext(function($ctx1) {
  1538. var $1,$2;
  1539. $1=_st($Package())._named_(packageName);
  1540. _st($1)._setupClasses();
  1541. _st($1)._commitPathJs_(_st("/".__comma(aString)).__comma("/js"));
  1542. $2=_st($1)._commitPathSt_(_st("/".__comma(aString)).__comma("/st"));
  1543. return self}, function($ctx1) {$ctx1.fill(self,"setupPackageNamed:prefix:",{packageName:packageName,aString:aString},smalltalk.LegacyPackageHandler)})},
  1544. messageSends: ["setupClasses", "named:", "commitPathJs:", ",", "commitPathSt:"]}),
  1545. smalltalk.LegacyPackageHandler);
  1546. smalltalk.LegacyPackageHandler.klass.iVarNames = ['defaultCommitPathJs','defaultCommitPathSt'];
  1547. smalltalk.addMethod(
  1548. smalltalk.method({
  1549. selector: "commitPathsFromLoader",
  1550. fn: function (){
  1551. var self=this;
  1552. return smalltalk.withContext(function($ctx1) {
  1553. var commitPath = typeof amber !== 'undefined' && amber.commitPath;
  1554. if (!commitPath) return;
  1555. if (commitPath.js) self._defaultCommitPathJs_(commitPath.js);
  1556. if (commitPath.st) self._defaultCommitPathSt_(commitPath.st);
  1557. ;
  1558. return self}, function($ctx1) {$ctx1.fill(self,"commitPathsFromLoader",{},smalltalk.LegacyPackageHandler.klass)})},
  1559. messageSends: []}),
  1560. smalltalk.LegacyPackageHandler.klass);
  1561. smalltalk.addMethod(
  1562. smalltalk.method({
  1563. selector: "defaultCommitPathJs",
  1564. fn: function (){
  1565. var self=this;
  1566. return smalltalk.withContext(function($ctx1) {
  1567. var $2,$1;
  1568. $2=self["@defaultCommitPathJs"];
  1569. if(($receiver = $2) == nil || $receiver == undefined){
  1570. self["@defaultCommitPathJs"]="js";
  1571. $1=self["@defaultCommitPathJs"];
  1572. } else {
  1573. $1=$2;
  1574. };
  1575. return $1;
  1576. }, function($ctx1) {$ctx1.fill(self,"defaultCommitPathJs",{},smalltalk.LegacyPackageHandler.klass)})},
  1577. messageSends: ["ifNil:"]}),
  1578. smalltalk.LegacyPackageHandler.klass);
  1579. smalltalk.addMethod(
  1580. smalltalk.method({
  1581. selector: "defaultCommitPathJs:",
  1582. fn: function (aString){
  1583. var self=this;
  1584. return smalltalk.withContext(function($ctx1) {
  1585. self["@defaultCommitPathJs"]=aString;
  1586. return self}, function($ctx1) {$ctx1.fill(self,"defaultCommitPathJs:",{aString:aString},smalltalk.LegacyPackageHandler.klass)})},
  1587. messageSends: []}),
  1588. smalltalk.LegacyPackageHandler.klass);
  1589. smalltalk.addMethod(
  1590. smalltalk.method({
  1591. selector: "defaultCommitPathSt",
  1592. fn: function (){
  1593. var self=this;
  1594. return smalltalk.withContext(function($ctx1) {
  1595. var $2,$1;
  1596. $2=self["@defaultCommitPathSt"];
  1597. if(($receiver = $2) == nil || $receiver == undefined){
  1598. self["@defaultCommitPathSt"]="st";
  1599. $1=self["@defaultCommitPathSt"];
  1600. } else {
  1601. $1=$2;
  1602. };
  1603. return $1;
  1604. }, function($ctx1) {$ctx1.fill(self,"defaultCommitPathSt",{},smalltalk.LegacyPackageHandler.klass)})},
  1605. messageSends: ["ifNil:"]}),
  1606. smalltalk.LegacyPackageHandler.klass);
  1607. smalltalk.addMethod(
  1608. smalltalk.method({
  1609. selector: "defaultCommitPathSt:",
  1610. fn: function (aString){
  1611. var self=this;
  1612. return smalltalk.withContext(function($ctx1) {
  1613. self["@defaultCommitPathSt"]=aString;
  1614. return self}, function($ctx1) {$ctx1.fill(self,"defaultCommitPathSt:",{aString:aString},smalltalk.LegacyPackageHandler.klass)})},
  1615. messageSends: []}),
  1616. smalltalk.LegacyPackageHandler.klass);
  1617. smalltalk.addMethod(
  1618. smalltalk.method({
  1619. selector: "initialize",
  1620. fn: function (){
  1621. var self=this;
  1622. return smalltalk.withContext(function($ctx1) {
  1623. smalltalk.LegacyPackageHandler.klass.superclass.fn.prototype._initialize.apply(_st(self), []);
  1624. self._registerFor_("unknown");
  1625. self._commitPathsFromLoader();
  1626. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.LegacyPackageHandler.klass)})},
  1627. messageSends: ["initialize", "registerFor:", "commitPathsFromLoader"]}),
  1628. smalltalk.LegacyPackageHandler.klass);
  1629. smalltalk.addMethod(
  1630. smalltalk.method({
  1631. selector: "loadPackages:prefix:",
  1632. fn: function (aCollection,aString){
  1633. var self=this;
  1634. return smalltalk.withContext(function($ctx1) {
  1635. var $1;
  1636. $1=_st(self._new())._loadPackages_prefix_(aCollection,aString);
  1637. return $1;
  1638. }, function($ctx1) {$ctx1.fill(self,"loadPackages:prefix:",{aCollection:aCollection,aString:aString},smalltalk.LegacyPackageHandler.klass)})},
  1639. messageSends: ["loadPackages:prefix:", "new"]}),
  1640. smalltalk.LegacyPackageHandler.klass);
  1641. smalltalk.addMethod(
  1642. smalltalk.method({
  1643. selector: "resetCommitPaths",
  1644. fn: function (){
  1645. var self=this;
  1646. return smalltalk.withContext(function($ctx1) {
  1647. self["@defaultCommitPathJs"]=nil;
  1648. self["@defaultCommitPathSt"]=nil;
  1649. return self}, function($ctx1) {$ctx1.fill(self,"resetCommitPaths",{},smalltalk.LegacyPackageHandler.klass)})},
  1650. messageSends: []}),
  1651. smalltalk.LegacyPackageHandler.klass);
  1652. smalltalk.addClass('PluggableExporter', smalltalk.Object, ['recipe'], 'Importer-Exporter');
  1653. smalltalk.addMethod(
  1654. smalltalk.method({
  1655. selector: "exportAllPackages",
  1656. fn: function (){
  1657. var self=this;
  1658. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  1659. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1660. return smalltalk.withContext(function($ctx1) {
  1661. var $1;
  1662. $1=_st($String())._streamContents_((function(stream){
  1663. return smalltalk.withContext(function($ctx2) {
  1664. return _st(_st(_st($Smalltalk())._current())._packages())._do_((function(pkg){
  1665. return smalltalk.withContext(function($ctx3) {
  1666. return self._exportPackage_on_(pkg,stream);
  1667. }, function($ctx3) {$ctx3.fillBlock({pkg:pkg},$ctx2)})}));
  1668. }, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1)})}));
  1669. return $1;
  1670. }, function($ctx1) {$ctx1.fill(self,"exportAllPackages",{},smalltalk.PluggableExporter)})},
  1671. messageSends: ["streamContents:", "do:", "exportPackage:on:", "packages", "current"]}),
  1672. smalltalk.PluggableExporter);
  1673. smalltalk.addMethod(
  1674. smalltalk.method({
  1675. selector: "exportPackage:on:",
  1676. fn: function (aPackage,aStream){
  1677. var self=this;
  1678. return smalltalk.withContext(function($ctx1) {
  1679. _st(self._interpreter())._interpret_for_on_(self._recipe(),aPackage,aStream);
  1680. return self}, function($ctx1) {$ctx1.fill(self,"exportPackage:on:",{aPackage:aPackage,aStream:aStream},smalltalk.PluggableExporter)})},
  1681. messageSends: ["interpret:for:on:", "recipe", "interpreter"]}),
  1682. smalltalk.PluggableExporter);
  1683. smalltalk.addMethod(
  1684. smalltalk.method({
  1685. selector: "interpreter",
  1686. fn: function (){
  1687. var self=this;
  1688. function $RecipeInterpreter(){return smalltalk.RecipeInterpreter||(typeof RecipeInterpreter=="undefined"?nil:RecipeInterpreter)}
  1689. return smalltalk.withContext(function($ctx1) {
  1690. var $1;
  1691. $1=_st($RecipeInterpreter())._new();
  1692. return $1;
  1693. }, function($ctx1) {$ctx1.fill(self,"interpreter",{},smalltalk.PluggableExporter)})},
  1694. messageSends: ["new"]}),
  1695. smalltalk.PluggableExporter);
  1696. smalltalk.addMethod(
  1697. smalltalk.method({
  1698. selector: "recipe",
  1699. fn: function (){
  1700. var self=this;
  1701. return smalltalk.withContext(function($ctx1) {
  1702. var $1;
  1703. $1=self["@recipe"];
  1704. return $1;
  1705. }, function($ctx1) {$ctx1.fill(self,"recipe",{},smalltalk.PluggableExporter)})},
  1706. messageSends: []}),
  1707. smalltalk.PluggableExporter);
  1708. smalltalk.addMethod(
  1709. smalltalk.method({
  1710. selector: "recipe:",
  1711. fn: function (anArray){
  1712. var self=this;
  1713. return smalltalk.withContext(function($ctx1) {
  1714. self["@recipe"]=anArray;
  1715. return self}, function($ctx1) {$ctx1.fill(self,"recipe:",{anArray:anArray},smalltalk.PluggableExporter)})},
  1716. messageSends: []}),
  1717. smalltalk.PluggableExporter);
  1718. smalltalk.addMethod(
  1719. smalltalk.method({
  1720. selector: "forRecipe:",
  1721. fn: function (aRecipe){
  1722. var self=this;
  1723. return smalltalk.withContext(function($ctx1) {
  1724. var $2,$3,$1;
  1725. $2=self._new();
  1726. _st($2)._recipe_(aRecipe);
  1727. $3=_st($2)._yourself();
  1728. $1=$3;
  1729. return $1;
  1730. }, function($ctx1) {$ctx1.fill(self,"forRecipe:",{aRecipe:aRecipe},smalltalk.PluggableExporter.klass)})},
  1731. messageSends: ["recipe:", "new", "yourself"]}),
  1732. smalltalk.PluggableExporter.klass);
  1733. smalltalk.addMethod(
  1734. smalltalk.method({
  1735. selector: "ownClassesOfPackage:",
  1736. fn: function (package_){
  1737. var self=this;
  1738. return smalltalk.withContext(function($ctx1) {
  1739. var $1;
  1740. $1=_st(_st(package_)._sortedClasses())._asSet();
  1741. return $1;
  1742. }, function($ctx1) {$ctx1.fill(self,"ownClassesOfPackage:",{package_:package_},smalltalk.PluggableExporter.klass)})},
  1743. messageSends: ["asSet", "sortedClasses"]}),
  1744. smalltalk.PluggableExporter.klass);
  1745. smalltalk.addClass('RecipeInterpreter', smalltalk.Object, [], 'Importer-Exporter');
  1746. smalltalk.addMethod(
  1747. smalltalk.method({
  1748. selector: "interpret:for:on:",
  1749. fn: function (aRecipe,anObject,aStream){
  1750. var self=this;
  1751. var recipeStream;
  1752. return smalltalk.withContext(function($ctx1) {
  1753. recipeStream=_st(aRecipe)._readStream();
  1754. _st((function(){
  1755. return smalltalk.withContext(function($ctx2) {
  1756. return _st(recipeStream)._atEnd();
  1757. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._whileFalse_((function(){
  1758. return smalltalk.withContext(function($ctx2) {
  1759. return self._interpretStep_for_on_(_st(recipeStream)._next(),anObject,aStream);
  1760. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1761. return self}, function($ctx1) {$ctx1.fill(self,"interpret:for:on:",{aRecipe:aRecipe,anObject:anObject,aStream:aStream,recipeStream:recipeStream},smalltalk.RecipeInterpreter)})},
  1762. messageSends: ["readStream", "whileFalse:", "interpretStep:for:on:", "next", "atEnd"]}),
  1763. smalltalk.RecipeInterpreter);
  1764. smalltalk.addMethod(
  1765. smalltalk.method({
  1766. selector: "interpretStep:for:on:",
  1767. fn: function (aRecipeStep,anObject,aStream){
  1768. var self=this;
  1769. return smalltalk.withContext(function($ctx1) {
  1770. var $1,$2;
  1771. $1=_st(_st(aRecipeStep)._value()).__eq_eq(aRecipeStep);
  1772. if(smalltalk.assert($1)){
  1773. $2=self._interpretSubRecipe_for_on_(aRecipeStep,anObject,aStream);
  1774. return $2;
  1775. };
  1776. _st(_st(aRecipeStep)._key())._perform_withArguments_(_st(aRecipeStep)._value(),[anObject,aStream]);
  1777. return self}, function($ctx1) {$ctx1.fill(self,"interpretStep:for:on:",{aRecipeStep:aRecipeStep,anObject:anObject,aStream:aStream},smalltalk.RecipeInterpreter)})},
  1778. messageSends: ["ifTrue:", "interpretSubRecipe:for:on:", "==", "value", "perform:withArguments:", "key"]}),
  1779. smalltalk.RecipeInterpreter);
  1780. smalltalk.addMethod(
  1781. smalltalk.method({
  1782. selector: "interpretSubRecipe:for:on:",
  1783. fn: function (aRecipe,anObject,aStream){
  1784. var self=this;
  1785. var selection;
  1786. return smalltalk.withContext(function($ctx1) {
  1787. selection=_st(_st(_st(aRecipe)._first())._key())._perform_withArguments_(_st(_st(aRecipe)._first())._value(),[anObject]);
  1788. _st(selection)._do_((function(each){
  1789. return smalltalk.withContext(function($ctx2) {
  1790. return self._interpret_for_on_(_st(aRecipe)._allButFirst(),each,aStream);
  1791. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1792. return self}, function($ctx1) {$ctx1.fill(self,"interpretSubRecipe:for:on:",{aRecipe:aRecipe,anObject:anObject,aStream:aStream,selection:selection},smalltalk.RecipeInterpreter)})},
  1793. messageSends: ["perform:withArguments:", "value", "first", "key", "do:", "interpret:for:on:", "allButFirst"]}),
  1794. smalltalk.RecipeInterpreter);
  1795. smalltalk.addMethod(
  1796. smalltalk.method({
  1797. selector: "recipe",
  1798. fn: function (){
  1799. var self=this;
  1800. return smalltalk.withContext(function($ctx1) {
  1801. var $1;
  1802. $1=self["@recipe"];
  1803. return $1;
  1804. }, function($ctx1) {$ctx1.fill(self,"recipe",{},smalltalk.RecipeInterpreter)})},
  1805. messageSends: []}),
  1806. smalltalk.RecipeInterpreter);
  1807. smalltalk.addMethod(
  1808. smalltalk.method({
  1809. selector: "recipe:",
  1810. fn: function (anArray){
  1811. var self=this;
  1812. return smalltalk.withContext(function($ctx1) {
  1813. self["@recipe"]=anArray;
  1814. return self}, function($ctx1) {$ctx1.fill(self,"recipe:",{anArray:anArray},smalltalk.RecipeInterpreter)})},
  1815. messageSends: []}),
  1816. smalltalk.RecipeInterpreter);
  1817. smalltalk.addMethod(
  1818. smalltalk.method({
  1819. selector: "commit",
  1820. fn: function (){
  1821. var self=this;
  1822. return smalltalk.withContext(function($ctx1) {
  1823. var $1;
  1824. $1=_st(self._transport())._commit_(self);
  1825. return $1;
  1826. }, function($ctx1) {$ctx1.fill(self,"commit",{},smalltalk.Package)})},
  1827. messageSends: ["commit:", "transport"]}),
  1828. smalltalk.Package);
  1829. smalltalk.addMethod(
  1830. smalltalk.method({
  1831. selector: "commitPathJs",
  1832. fn: function (){
  1833. var self=this;
  1834. return smalltalk.withContext(function($ctx1) {
  1835. var $3,$2,$1;
  1836. $3=self["@extension"];
  1837. if(($receiver = $3) == nil || $receiver == undefined){
  1838. self["@extension"]=smalltalk.HashedCollection._from_([]);
  1839. $2=self["@extension"];
  1840. } else {
  1841. $2=$3;
  1842. };
  1843. $1=_st($2)._at_ifAbsentPut_("commitPathJs",(function(){
  1844. return smalltalk.withContext(function($ctx2) {
  1845. return _st(self._transport())._commitPathJsFor_(self);
  1846. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1847. return $1;
  1848. }, function($ctx1) {$ctx1.fill(self,"commitPathJs",{},smalltalk.Package)})},
  1849. messageSends: ["at:ifAbsentPut:", "commitPathJsFor:", "transport", "ifNil:"]}),
  1850. smalltalk.Package);
  1851. smalltalk.addMethod(
  1852. smalltalk.method({
  1853. selector: "commitPathJs:",
  1854. fn: function (aString){
  1855. var self=this;
  1856. return smalltalk.withContext(function($ctx1) {
  1857. var $3,$2,$1;
  1858. $3=self["@extension"];
  1859. if(($receiver = $3) == nil || $receiver == undefined){
  1860. self["@extension"]=smalltalk.HashedCollection._from_([]);
  1861. $2=self["@extension"];
  1862. } else {
  1863. $2=$3;
  1864. };
  1865. $1=_st($2)._at_put_("commitPathJs",aString);
  1866. return $1;
  1867. }, function($ctx1) {$ctx1.fill(self,"commitPathJs:",{aString:aString},smalltalk.Package)})},
  1868. messageSends: ["at:put:", "ifNil:"]}),
  1869. smalltalk.Package);
  1870. smalltalk.addMethod(
  1871. smalltalk.method({
  1872. selector: "commitPathSt",
  1873. fn: function (){
  1874. var self=this;
  1875. return smalltalk.withContext(function($ctx1) {
  1876. var $3,$2,$1;
  1877. $3=self["@extension"];
  1878. if(($receiver = $3) == nil || $receiver == undefined){
  1879. self["@extension"]=smalltalk.HashedCollection._from_([]);
  1880. $2=self["@extension"];
  1881. } else {
  1882. $2=$3;
  1883. };
  1884. $1=_st($2)._at_ifAbsentPut_("commitPathSt",(function(){
  1885. return smalltalk.withContext(function($ctx2) {
  1886. return _st(self._transport())._commitPathStFor_(self);
  1887. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1888. return $1;
  1889. }, function($ctx1) {$ctx1.fill(self,"commitPathSt",{},smalltalk.Package)})},
  1890. messageSends: ["at:ifAbsentPut:", "commitPathStFor:", "transport", "ifNil:"]}),
  1891. smalltalk.Package);
  1892. smalltalk.addMethod(
  1893. smalltalk.method({
  1894. selector: "commitPathSt:",
  1895. fn: function (aString){
  1896. var self=this;
  1897. return smalltalk.withContext(function($ctx1) {
  1898. var $3,$2,$1;
  1899. $3=self["@extension"];
  1900. if(($receiver = $3) == nil || $receiver == undefined){
  1901. self["@extension"]=smalltalk.HashedCollection._from_([]);
  1902. $2=self["@extension"];
  1903. } else {
  1904. $2=$3;
  1905. };
  1906. $1=_st($2)._at_put_("commitPathSt",aString);
  1907. return $1;
  1908. }, function($ctx1) {$ctx1.fill(self,"commitPathSt:",{aString:aString},smalltalk.Package)})},
  1909. messageSends: ["at:put:", "ifNil:"]}),
  1910. smalltalk.Package);
  1911. smalltalk.addMethod(
  1912. smalltalk.method({
  1913. selector: "transport",
  1914. fn: function (){
  1915. var self=this;
  1916. function $PackageHandler(){return smalltalk.PackageHandler||(typeof PackageHandler=="undefined"?nil:PackageHandler)}
  1917. return smalltalk.withContext(function($ctx1) {
  1918. var $1;
  1919. $1=_st($PackageHandler())._for_(self._transportType());
  1920. return $1;
  1921. }, function($ctx1) {$ctx1.fill(self,"transport",{},smalltalk.Package)})},
  1922. messageSends: ["for:", "transportType"]}),
  1923. smalltalk.Package);
  1924. smalltalk.addMethod(
  1925. smalltalk.method({
  1926. selector: "transportType",
  1927. fn: function (){
  1928. var self=this;
  1929. return smalltalk.withContext(function($ctx1) {
  1930. return (self.transport && self.transport.type) || 'unknown';;
  1931. return self}, function($ctx1) {$ctx1.fill(self,"transportType",{},smalltalk.Package)})},
  1932. messageSends: []}),
  1933. smalltalk.Package);
  1934. })(global_smalltalk,global_nil,global__st);