Kernel.js 313 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314
  1. smalltalk.addPackage('Kernel', {});
  2. smalltalk.addClass('Object', smalltalk.nil, [], 'Kernel');
  3. smalltalk.addMethod(
  4. unescape('__eq'),
  5. smalltalk.method({
  6. selector: unescape('%3D'),
  7. category: 'comparing',
  8. fn: function (anObject){
  9. var self=this;
  10. return smalltalk.send(self, "__eq_eq", [anObject]);
  11. return self;},
  12. args: ["anObject"],
  13. source: unescape('%3D%20anObject%0A%09%5Eself%20%3D%3D%20anObject'),
  14. messageSends: [unescape("%3D%3D")],
  15. referencedClasses: []
  16. }),
  17. smalltalk.Object);
  18. smalltalk.addMethod(
  19. unescape('_%7E_eq'),
  20. smalltalk.method({
  21. selector: unescape('%7E%3D'),
  22. category: 'comparing',
  23. fn: function (anObject){
  24. var self=this;
  25. return smalltalk.send(smalltalk.send(self, "__eq", [anObject]), "__eq", [false]);
  26. return self;},
  27. args: ["anObject"],
  28. source: unescape('%7E%3D%20anObject%0A%09%5E%28self%20%3D%20anObject%29%20%3D%20false'),
  29. messageSends: [unescape("%3D")],
  30. referencedClasses: []
  31. }),
  32. smalltalk.Object);
  33. smalltalk.addMethod(
  34. unescape('_initialize'),
  35. smalltalk.method({
  36. selector: unescape('initialize'),
  37. category: 'initialization',
  38. fn: function (){
  39. var self=this;
  40. return self;},
  41. args: [],
  42. source: unescape('initialize'),
  43. messageSends: [],
  44. referencedClasses: []
  45. }),
  46. smalltalk.Object);
  47. smalltalk.addMethod(
  48. unescape('_yourself'),
  49. smalltalk.method({
  50. selector: unescape('yourself'),
  51. category: 'accessing',
  52. fn: function (){
  53. var self=this;
  54. return self;
  55. return self;},
  56. args: [],
  57. source: unescape('yourself%0A%09%5Eself'),
  58. messageSends: [],
  59. referencedClasses: []
  60. }),
  61. smalltalk.Object);
  62. smalltalk.addMethod(
  63. unescape('_class'),
  64. smalltalk.method({
  65. selector: unescape('class'),
  66. category: 'accessing',
  67. fn: function (){
  68. var self=this;
  69. return self.klass;
  70. return self;},
  71. args: [],
  72. source: unescape('class%0A%09%3Creturn%20self.klass%3E'),
  73. messageSends: [],
  74. referencedClasses: []
  75. }),
  76. smalltalk.Object);
  77. smalltalk.addMethod(
  78. unescape('_size'),
  79. smalltalk.method({
  80. selector: unescape('size'),
  81. category: 'accessing',
  82. fn: function (){
  83. var self=this;
  84. smalltalk.send(self, "_error_", ["Object not indexable"]);
  85. return self;},
  86. args: [],
  87. source: unescape('size%0A%09self%20error%3A%20%27Object%20not%20indexable%27'),
  88. messageSends: ["error:"],
  89. referencedClasses: []
  90. }),
  91. smalltalk.Object);
  92. smalltalk.addMethod(
  93. unescape('_copy'),
  94. smalltalk.method({
  95. selector: unescape('copy'),
  96. category: 'copying',
  97. fn: function (){
  98. var self=this;
  99. return smalltalk.send(smalltalk.send(self, "_shallowCopy", []), "_postCopy", []);
  100. return self;},
  101. args: [],
  102. source: unescape('copy%0A%09%5Eself%20shallowCopy%20postCopy'),
  103. messageSends: ["postCopy", "shallowCopy"],
  104. referencedClasses: []
  105. }),
  106. smalltalk.Object);
  107. smalltalk.addMethod(
  108. unescape('_shallowCopy'),
  109. smalltalk.method({
  110. selector: unescape('shallowCopy'),
  111. category: 'copying',
  112. fn: function (){
  113. var self=this;
  114. var copy = self.klass._new();
  115. for(var i in self) {
  116. if(/^@.+/.test(i)) {
  117. copy[i] = self[i];
  118. }
  119. }
  120. return copy;
  121. ;
  122. return self;},
  123. args: [],
  124. source: unescape('shallowCopy%0A%09%3C%0A%09%20%20%20%20var%20copy%20%3D%20self.klass._new%28%29%3B%0A%09%20%20%20%20for%28var%20i%20in%20self%29%20%7B%0A%09%09if%28/%5E@.+/.test%28i%29%29%20%7B%0A%09%09%20%20%20%20copy%5Bi%5D%20%3D%20self%5Bi%5D%3B%0A%09%09%7D%0A%09%20%20%20%20%7D%0A%09%20%20%20%20return%20copy%3B%0A%09%3E'),
  125. messageSends: [],
  126. referencedClasses: []
  127. }),
  128. smalltalk.Object);
  129. smalltalk.addMethod(
  130. unescape('_deepCopy'),
  131. smalltalk.method({
  132. selector: unescape('deepCopy'),
  133. category: 'copying',
  134. fn: function (){
  135. var self=this;
  136. var copy = self.klass._new();
  137. for(var i in self) {
  138. if(/^@.+/.test(i)) {
  139. copy[i] = self[i]._deepCopy();
  140. }
  141. }
  142. return copy;
  143. ;
  144. return self;},
  145. args: [],
  146. source: unescape('deepCopy%0A%09%3C%20%20%20%20%0A%09%20%20%20%20var%20copy%20%3D%20self.klass._new%28%29%3B%0A%09%20%20%20%20for%28var%20i%20in%20self%29%20%7B%0A%09%09if%28/%5E@.+/.test%28i%29%29%20%7B%0A%09%09%20%20%20%20copy%5Bi%5D%20%3D%20self%5Bi%5D._deepCopy%28%29%3B%0A%09%09%7D%0A%09%20%20%20%20%7D%0A%09%20%20%20%20return%20copy%3B%0A%09%3E'),
  147. messageSends: [],
  148. referencedClasses: []
  149. }),
  150. smalltalk.Object);
  151. smalltalk.addMethod(
  152. unescape('_postCopy'),
  153. smalltalk.method({
  154. selector: unescape('postCopy'),
  155. category: 'copying',
  156. fn: function (){
  157. var self=this;
  158. return self;},
  159. args: [],
  160. source: unescape('postCopy'),
  161. messageSends: [],
  162. referencedClasses: []
  163. }),
  164. smalltalk.Object);
  165. smalltalk.addMethod(
  166. unescape('__minus_gt'),
  167. smalltalk.method({
  168. selector: unescape('-%3E'),
  169. category: 'converting',
  170. fn: function (anObject){
  171. var self=this;
  172. return smalltalk.send((smalltalk.Association || Association), "_key_value_", [self, anObject]);
  173. return self;},
  174. args: ["anObject"],
  175. source: unescape('-%3E%20anObject%0A%09%5EAssociation%20key%3A%20self%20value%3A%20anObject'),
  176. messageSends: ["key:value:"],
  177. referencedClasses: ["Association"]
  178. }),
  179. smalltalk.Object);
  180. smalltalk.addMethod(
  181. unescape('_asString'),
  182. smalltalk.method({
  183. selector: unescape('asString'),
  184. category: 'converting',
  185. fn: function (){
  186. var self=this;
  187. return smalltalk.send(self, "_printString", []);
  188. return self;},
  189. args: [],
  190. source: unescape('asString%0A%09%5Eself%20printString'),
  191. messageSends: ["printString"],
  192. referencedClasses: []
  193. }),
  194. smalltalk.Object);
  195. smalltalk.addMethod(
  196. unescape('_asJavascript'),
  197. smalltalk.method({
  198. selector: unescape('asJavascript'),
  199. category: 'converting',
  200. fn: function (){
  201. var self=this;
  202. return smalltalk.send(self, "_asString", []);
  203. return self;},
  204. args: [],
  205. source: unescape('asJavascript%0A%09%5Eself%20asString'),
  206. messageSends: ["asString"],
  207. referencedClasses: []
  208. }),
  209. smalltalk.Object);
  210. smalltalk.addMethod(
  211. unescape('_perform_'),
  212. smalltalk.method({
  213. selector: unescape('perform%3A'),
  214. category: 'message handling',
  215. fn: function (aSymbol){
  216. var self=this;
  217. return smalltalk.send(self, "_perform_withArguments_", [aSymbol, []]);
  218. return self;},
  219. args: ["aSymbol"],
  220. source: unescape('perform%3A%20aSymbol%0A%09%5Eself%20perform%3A%20aSymbol%20withArguments%3A%20%23%28%29'),
  221. messageSends: ["perform:withArguments:"],
  222. referencedClasses: []
  223. }),
  224. smalltalk.Object);
  225. smalltalk.addMethod(
  226. unescape('_perform_withArguments_'),
  227. smalltalk.method({
  228. selector: unescape('perform%3AwithArguments%3A'),
  229. category: 'message handling',
  230. fn: function (aSymbol, aCollection){
  231. var self=this;
  232. return smalltalk.send(self, "_basicPerform_withArguments_", [smalltalk.send(aSymbol, "_asSelector", []), aCollection]);
  233. return self;},
  234. args: ["aSymbol", "aCollection"],
  235. source: unescape('perform%3A%20aSymbol%20withArguments%3A%20aCollection%0A%09%5Eself%20basicPerform%3A%20aSymbol%20asSelector%20withArguments%3A%20aCollection'),
  236. messageSends: ["basicPerform:withArguments:", "asSelector"],
  237. referencedClasses: []
  238. }),
  239. smalltalk.Object);
  240. smalltalk.addMethod(
  241. unescape('_instVarAt_'),
  242. smalltalk.method({
  243. selector: unescape('instVarAt%3A'),
  244. category: 'accessing',
  245. fn: function (aString){
  246. var self=this;
  247. return self['@'+aString];
  248. return self;},
  249. args: ["aString"],
  250. source: unescape('instVarAt%3A%20aString%0A%09%3Creturn%20self%5B%27@%27+aString%5D%3E'),
  251. messageSends: [],
  252. referencedClasses: []
  253. }),
  254. smalltalk.Object);
  255. smalltalk.addMethod(
  256. unescape('_instVarAt_put_'),
  257. smalltalk.method({
  258. selector: unescape('instVarAt%3Aput%3A'),
  259. category: 'accessing',
  260. fn: function (aString, anObject){
  261. var self=this;
  262. self['@' + aString] = anObject;
  263. return self;},
  264. args: ["aString", "anObject"],
  265. source: unescape('instVarAt%3A%20aString%20put%3A%20anObject%0A%09%3Cself%5B%27@%27%20+%20aString%5D%20%3D%20anObject%3E'),
  266. messageSends: [],
  267. referencedClasses: []
  268. }),
  269. smalltalk.Object);
  270. smalltalk.addMethod(
  271. unescape('_basicAt_'),
  272. smalltalk.method({
  273. selector: unescape('basicAt%3A'),
  274. category: 'accessing',
  275. fn: function (aString){
  276. var self=this;
  277. return self[aString];
  278. return self;},
  279. args: ["aString"],
  280. source: unescape('basicAt%3A%20aString%0A%09%3Creturn%20self%5BaString%5D%3E'),
  281. messageSends: [],
  282. referencedClasses: []
  283. }),
  284. smalltalk.Object);
  285. smalltalk.addMethod(
  286. unescape('_basicAt_put_'),
  287. smalltalk.method({
  288. selector: unescape('basicAt%3Aput%3A'),
  289. category: 'accessing',
  290. fn: function (aString, anObject){
  291. var self=this;
  292. return self[aString] = anObject;
  293. return self;},
  294. args: ["aString", "anObject"],
  295. source: unescape('basicAt%3A%20aString%20put%3A%20anObject%0A%09%3Creturn%20self%5BaString%5D%20%3D%20anObject%3E'),
  296. messageSends: [],
  297. referencedClasses: []
  298. }),
  299. smalltalk.Object);
  300. smalltalk.addMethod(
  301. unescape('_error_'),
  302. smalltalk.method({
  303. selector: unescape('error%3A'),
  304. category: 'error handling',
  305. fn: function (aString){
  306. var self=this;
  307. smalltalk.send((smalltalk.Error || Error), "_signal_", [aString]);
  308. return self;},
  309. args: ["aString"],
  310. source: unescape('error%3A%20aString%0A%09Error%20signal%3A%20aString'),
  311. messageSends: ["signal:"],
  312. referencedClasses: ["Error"]
  313. }),
  314. smalltalk.Object);
  315. smalltalk.addMethod(
  316. unescape('_subclassResponsibility'),
  317. smalltalk.method({
  318. selector: unescape('subclassResponsibility'),
  319. category: 'error handling',
  320. fn: function (){
  321. var self=this;
  322. smalltalk.send(self, "_error_", ["This method is a responsibility of a subclass"]);
  323. return self;},
  324. args: [],
  325. source: unescape('subclassResponsibility%0A%09self%20error%3A%20%27This%20method%20is%20a%20responsibility%20of%20a%20subclass%27'),
  326. messageSends: ["error:"],
  327. referencedClasses: []
  328. }),
  329. smalltalk.Object);
  330. smalltalk.addMethod(
  331. unescape('_shouldNotImplement'),
  332. smalltalk.method({
  333. selector: unescape('shouldNotImplement'),
  334. category: 'error handling',
  335. fn: function (){
  336. var self=this;
  337. smalltalk.send(self, "_error_", [smalltalk.send("This method should not be implemented in ", "__comma", [smalltalk.send(smalltalk.send(self, "_class", []), "_name", [])])]);
  338. return self;},
  339. args: [],
  340. source: unescape('shouldNotImplement%0A%09self%20error%3A%20%27This%20method%20should%20not%20be%20implemented%20in%20%27%2C%20self%20class%20name'),
  341. messageSends: ["error:", unescape("%2C"), "name", "class"],
  342. referencedClasses: []
  343. }),
  344. smalltalk.Object);
  345. smalltalk.addMethod(
  346. unescape('_try_catch_'),
  347. smalltalk.method({
  348. selector: unescape('try%3Acatch%3A'),
  349. category: 'error handling',
  350. fn: function (aBlock, anotherBlock){
  351. var self=this;
  352. try{aBlock()} catch(e) {anotherBlock(e)};
  353. return self;},
  354. args: ["aBlock", "anotherBlock"],
  355. source: unescape('try%3A%20aBlock%20catch%3A%20anotherBlock%0A%09%3Ctry%7BaBlock%28%29%7D%20catch%28e%29%20%7BanotherBlock%28e%29%7D%3E'),
  356. messageSends: [],
  357. referencedClasses: []
  358. }),
  359. smalltalk.Object);
  360. smalltalk.addMethod(
  361. unescape('_printString'),
  362. smalltalk.method({
  363. selector: unescape('printString'),
  364. category: 'printing',
  365. fn: function (){
  366. var self=this;
  367. return smalltalk.send("a ", "__comma", [smalltalk.send(smalltalk.send(self, "_class", []), "_name", [])]);
  368. return self;},
  369. args: [],
  370. source: unescape('printString%0A%09%5E%27a%20%27%2C%20self%20class%20name'),
  371. messageSends: [unescape("%2C"), "name", "class"],
  372. referencedClasses: []
  373. }),
  374. smalltalk.Object);
  375. smalltalk.addMethod(
  376. unescape('_printNl'),
  377. smalltalk.method({
  378. selector: unescape('printNl'),
  379. category: 'printing',
  380. fn: function (){
  381. var self=this;
  382. console.log(self);
  383. return self;},
  384. args: [],
  385. source: unescape('printNl%0A%09%3Cconsole.log%28self%29%3E'),
  386. messageSends: [],
  387. referencedClasses: []
  388. }),
  389. smalltalk.Object);
  390. smalltalk.addMethod(
  391. unescape('_isKindOf_'),
  392. smalltalk.method({
  393. selector: unescape('isKindOf%3A'),
  394. category: 'testing',
  395. fn: function (aClass){
  396. var self=this;
  397. return ((($receiver = smalltalk.send(self, "_isMemberOf_", [aClass])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return true;})() : (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_inheritsFrom_", [aClass]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return true;}), (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_inheritsFrom_", [aClass]);})]));
  398. return self;},
  399. args: ["aClass"],
  400. source: unescape('isKindOf%3A%20aClass%0A%09%5E%28self%20isMemberOf%3A%20aClass%29%0A%09%20%20%20%20ifTrue%3A%20%5Btrue%5D%0A%09%20%20%20%20ifFalse%3A%20%5Bself%20class%20inheritsFrom%3A%20aClass%5D'),
  401. messageSends: ["ifTrue:ifFalse:", "isMemberOf:", "inheritsFrom:", "class"],
  402. referencedClasses: []
  403. }),
  404. smalltalk.Object);
  405. smalltalk.addMethod(
  406. unescape('_isMemberOf_'),
  407. smalltalk.method({
  408. selector: unescape('isMemberOf%3A'),
  409. category: 'testing',
  410. fn: function (aClass){
  411. var self=this;
  412. return smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [aClass]);
  413. return self;},
  414. args: ["aClass"],
  415. source: unescape('isMemberOf%3A%20aClass%0A%09%5Eself%20class%20%3D%20aClass'),
  416. messageSends: [unescape("%3D"), "class"],
  417. referencedClasses: []
  418. }),
  419. smalltalk.Object);
  420. smalltalk.addMethod(
  421. unescape('_ifNil_'),
  422. smalltalk.method({
  423. selector: unescape('ifNil%3A'),
  424. category: 'testing',
  425. fn: function (aBlock){
  426. var self=this;
  427. return self;
  428. return self;},
  429. args: ["aBlock"],
  430. source: unescape('ifNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself'),
  431. messageSends: [],
  432. referencedClasses: []
  433. }),
  434. smalltalk.Object);
  435. smalltalk.addMethod(
  436. unescape('_ifNil_ifNotNil_'),
  437. smalltalk.method({
  438. selector: unescape('ifNil%3AifNotNil%3A'),
  439. category: 'testing',
  440. fn: function (aBlock, anotherBlock){
  441. var self=this;
  442. return smalltalk.send(anotherBlock, "_value", []);
  443. return self;},
  444. args: ["aBlock", "anotherBlock"],
  445. source: unescape('ifNil%3A%20aBlock%20ifNotNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EanotherBlock%20value'),
  446. messageSends: ["value"],
  447. referencedClasses: []
  448. }),
  449. smalltalk.Object);
  450. smalltalk.addMethod(
  451. unescape('_ifNotNil_'),
  452. smalltalk.method({
  453. selector: unescape('ifNotNil%3A'),
  454. category: 'testing',
  455. fn: function (aBlock){
  456. var self=this;
  457. return smalltalk.send(aBlock, "_value", []);
  458. return self;},
  459. args: ["aBlock"],
  460. source: unescape('ifNotNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  461. messageSends: ["value"],
  462. referencedClasses: []
  463. }),
  464. smalltalk.Object);
  465. smalltalk.addMethod(
  466. unescape('_ifNotNil_ifNil_'),
  467. smalltalk.method({
  468. selector: unescape('ifNotNil%3AifNil%3A'),
  469. category: 'testing',
  470. fn: function (aBlock, anotherBlock){
  471. var self=this;
  472. return smalltalk.send(aBlock, "_value", []);
  473. return self;},
  474. args: ["aBlock", "anotherBlock"],
  475. source: unescape('ifNotNil%3A%20aBlock%20ifNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  476. messageSends: ["value"],
  477. referencedClasses: []
  478. }),
  479. smalltalk.Object);
  480. smalltalk.addMethod(
  481. unescape('_isNil'),
  482. smalltalk.method({
  483. selector: unescape('isNil'),
  484. category: 'testing',
  485. fn: function (){
  486. var self=this;
  487. return false;
  488. return self;},
  489. args: [],
  490. source: unescape('isNil%0A%09%5Efalse'),
  491. messageSends: [],
  492. referencedClasses: []
  493. }),
  494. smalltalk.Object);
  495. smalltalk.addMethod(
  496. unescape('_notNil'),
  497. smalltalk.method({
  498. selector: unescape('notNil'),
  499. category: 'testing',
  500. fn: function (){
  501. var self=this;
  502. return smalltalk.send(smalltalk.send(self, "_isNil", []), "_not", []);
  503. return self;},
  504. args: [],
  505. source: unescape('notNil%0A%09%5Eself%20isNil%20not'),
  506. messageSends: ["not", "isNil"],
  507. referencedClasses: []
  508. }),
  509. smalltalk.Object);
  510. smalltalk.addMethod(
  511. unescape('_isClass'),
  512. smalltalk.method({
  513. selector: unescape('isClass'),
  514. category: 'testing',
  515. fn: function (){
  516. var self=this;
  517. return false;
  518. return self;},
  519. args: [],
  520. source: unescape('isClass%0A%09%5Efalse'),
  521. messageSends: [],
  522. referencedClasses: []
  523. }),
  524. smalltalk.Object);
  525. smalltalk.addMethod(
  526. unescape('_isMetaclass'),
  527. smalltalk.method({
  528. selector: unescape('isMetaclass'),
  529. category: 'testing',
  530. fn: function (){
  531. var self=this;
  532. return false;
  533. return self;},
  534. args: [],
  535. source: unescape('isMetaclass%0A%09%5Efalse'),
  536. messageSends: [],
  537. referencedClasses: []
  538. }),
  539. smalltalk.Object);
  540. smalltalk.addMethod(
  541. unescape('_isNumber'),
  542. smalltalk.method({
  543. selector: unescape('isNumber'),
  544. category: 'testing',
  545. fn: function (){
  546. var self=this;
  547. return false;
  548. return self;},
  549. args: [],
  550. source: unescape('isNumber%0A%09%5Efalse'),
  551. messageSends: [],
  552. referencedClasses: []
  553. }),
  554. smalltalk.Object);
  555. smalltalk.addMethod(
  556. unescape('_isString'),
  557. smalltalk.method({
  558. selector: unescape('isString'),
  559. category: 'testing',
  560. fn: function (){
  561. var self=this;
  562. return false;
  563. return self;},
  564. args: [],
  565. source: unescape('isString%0A%09%5Efalse'),
  566. messageSends: [],
  567. referencedClasses: []
  568. }),
  569. smalltalk.Object);
  570. smalltalk.addMethod(
  571. unescape('_isParseFailure'),
  572. smalltalk.method({
  573. selector: unescape('isParseFailure'),
  574. category: 'testing',
  575. fn: function (){
  576. var self=this;
  577. return false;
  578. return self;},
  579. args: [],
  580. source: unescape('isParseFailure%0A%09%5Efalse'),
  581. messageSends: [],
  582. referencedClasses: []
  583. }),
  584. smalltalk.Object);
  585. smalltalk.addMethod(
  586. unescape('_basicPerform_'),
  587. smalltalk.method({
  588. selector: unescape('basicPerform%3A'),
  589. category: 'message handling',
  590. fn: function (aSymbol){
  591. var self=this;
  592. return smalltalk.send(self, "_basicPerform_withArguments_", [aSymbol, []]);
  593. return self;},
  594. args: ["aSymbol"],
  595. source: unescape('basicPerform%3A%20aSymbol%20%0A%09%5Eself%20basicPerform%3A%20aSymbol%20withArguments%3A%20%23%28%29'),
  596. messageSends: ["basicPerform:withArguments:"],
  597. referencedClasses: []
  598. }),
  599. smalltalk.Object);
  600. smalltalk.addMethod(
  601. unescape('_basicPerform_withArguments_'),
  602. smalltalk.method({
  603. selector: unescape('basicPerform%3AwithArguments%3A'),
  604. category: 'message handling',
  605. fn: function (aSymbol, aCollection){
  606. var self=this;
  607. return self[aSymbol].apply(self, aCollection);;
  608. return self;},
  609. args: ["aSymbol", "aCollection"],
  610. source: unescape('basicPerform%3A%20aSymbol%20withArguments%3A%20aCollection%0A%09%3Creturn%20self%5BaSymbol%5D.apply%28self%2C%20aCollection%29%3B%3E'),
  611. messageSends: [],
  612. referencedClasses: []
  613. }),
  614. smalltalk.Object);
  615. smalltalk.addMethod(
  616. unescape('_basicDelete_'),
  617. smalltalk.method({
  618. selector: unescape('basicDelete%3A'),
  619. category: 'accessing',
  620. fn: function (aString){
  621. var self=this;
  622. delete self[aString]; return aString;
  623. return self;},
  624. args: ["aString"],
  625. source: unescape('basicDelete%3A%20aString%0A%20%20%20%20%3Cdelete%20self%5BaString%5D%3B%20return%20aString%3E'),
  626. messageSends: [],
  627. referencedClasses: []
  628. }),
  629. smalltalk.Object);
  630. smalltalk.addMethod(
  631. unescape('_doesNotUnderstand_'),
  632. smalltalk.method({
  633. selector: unescape('doesNotUnderstand%3A'),
  634. category: 'error handling',
  635. fn: function (aMessage){
  636. var self=this;
  637. (function($rec){smalltalk.send($rec, "_receiver_", [self]);smalltalk.send($rec, "_message_", [aMessage]);return smalltalk.send($rec, "_signal", []);})(smalltalk.send((smalltalk.MessageNotUnderstood || MessageNotUnderstood), "_new", []));
  638. return self;},
  639. args: ["aMessage"],
  640. source: unescape('doesNotUnderstand%3A%20aMessage%0A%09MessageNotUnderstood%20new%0A%09%09receiver%3A%20self%3B%0A%09%09message%3A%20aMessage%3B%0A%09%09signal'),
  641. messageSends: ["receiver:", "message:", "signal", "new"],
  642. referencedClasses: ["MessageNotUnderstood"]
  643. }),
  644. smalltalk.Object);
  645. smalltalk.addMethod(
  646. unescape('_asJSON'),
  647. smalltalk.method({
  648. selector: unescape('asJSON'),
  649. category: 'converting',
  650. fn: function (){
  651. var self=this;
  652. return smalltalk.send((smalltalk.JSON || JSON), "_parse_", [smalltalk.send(self, "_asJSONString", [])]);
  653. return self;},
  654. args: [],
  655. source: unescape('asJSON%0A%09%5EJSON%20parse%3A%20self%20asJSONString'),
  656. messageSends: ["parse:", "asJSONString"],
  657. referencedClasses: ["JSON"]
  658. }),
  659. smalltalk.Object);
  660. smalltalk.addMethod(
  661. unescape('_halt'),
  662. smalltalk.method({
  663. selector: unescape('halt'),
  664. category: 'error handling',
  665. fn: function (){
  666. var self=this;
  667. smalltalk.send(self, "_error_", ["Halt encountered"]);
  668. return self;},
  669. args: [],
  670. source: unescape('halt%0A%09self%20error%3A%20%27Halt%20encountered%27'),
  671. messageSends: ["error:"],
  672. referencedClasses: []
  673. }),
  674. smalltalk.Object);
  675. smalltalk.addMethod(
  676. unescape('_log_block_'),
  677. smalltalk.method({
  678. selector: unescape('log%3Ablock%3A'),
  679. category: 'printing',
  680. fn: function (aString, aBlock){
  681. var self=this;
  682. var result=nil;
  683. smalltalk.send((typeof console == 'undefined' ? nil : console), "_log_", [smalltalk.send(smalltalk.send(aString, "__comma", [" time: "]), "__comma", [smalltalk.send(smalltalk.send((smalltalk.Date || Date), "_millisecondsToRun_", [(function(){return result=smalltalk.send(aBlock, "_value", []);})]), "_printString", [])])]);
  684. return result;
  685. return self;},
  686. args: ["aString", "aBlock"],
  687. source: unescape('log%3A%20aString%20block%3A%20aBlock%0A%0A%09%7C%20result%20%7C%0A%09console%20log%3A%20%20aString%2C%20%20%27%20time%3A%20%27%2C%20%28Date%20millisecondsToRun%3A%20%5Bresult%20%3A%3D%20aBlock%20value%5D%29%20printString.%0A%09%5Eresult'),
  688. messageSends: ["log:", unescape("%2C"), "printString", "millisecondsToRun:", "value"],
  689. referencedClasses: ["Date"]
  690. }),
  691. smalltalk.Object);
  692. smalltalk.addMethod(
  693. unescape('__eq_eq'),
  694. smalltalk.method({
  695. selector: unescape('%3D%3D'),
  696. category: 'comparing',
  697. fn: function (anObject){
  698. var self=this;
  699. return self === anObject;
  700. return self;},
  701. args: ["anObject"],
  702. source: unescape('%3D%3D%20anObject%0A%09%3Creturn%20self%20%3D%3D%3D%20anObject%3E'),
  703. messageSends: [],
  704. referencedClasses: []
  705. }),
  706. smalltalk.Object);
  707. smalltalk.addMethod(
  708. unescape('_%7E%7E'),
  709. smalltalk.method({
  710. selector: unescape('%7E%7E'),
  711. category: 'comparing',
  712. fn: function (anObject){
  713. var self=this;
  714. return smalltalk.send(smalltalk.send(self, "__eq_eq", [anObject]), "__eq", [false]);
  715. return self;},
  716. args: ["anObject"],
  717. source: unescape('%7E%7E%20anObject%0A%09%5E%28self%20%3D%3D%20anObject%29%20%3D%20false'),
  718. messageSends: [unescape("%3D"), unescape("%3D%3D")],
  719. referencedClasses: []
  720. }),
  721. smalltalk.Object);
  722. smalltalk.addMethod(
  723. unescape('_deprecatedAPI'),
  724. smalltalk.method({
  725. selector: unescape('deprecatedAPI'),
  726. category: 'error handling',
  727. fn: function (){
  728. var self=this;
  729. smalltalk.send((typeof console == 'undefined' ? nil : console), "_warn_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.getThisContext()), "_home", []), "_asString", []), "__comma", [unescape("%20is%20deprecated%21%20%28in%20")]), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.getThisContext()), "_home", []), "_home", []), "_asString", [])]), "__comma", [unescape("%29")])]);
  730. return self;},
  731. args: [],
  732. source: unescape('deprecatedAPI%0A%09%22Just%20a%20simple%20way%20to%20deprecate%20methods.%0A%09%23deprecatedAPI%20is%20in%20the%20%27error%20handling%27%20protocol%20even%20if%20it%20doesn%27t%20throw%20an%20error%2C%0A%09but%20it%20could%20in%20the%20future.%22%0A%09console%20warn%3A%20thisContext%20home%20asString%2C%20%27%20is%20deprecated%21%20%28in%20%27%2C%20thisContext%20home%20home%20asString%2C%20%27%29%27'),
  733. messageSends: ["warn:", unescape("%2C"), "asString", "home"],
  734. referencedClasses: []
  735. }),
  736. smalltalk.Object);
  737. smalltalk.addMethod(
  738. unescape('_storeString'),
  739. smalltalk.method({
  740. selector: unescape('storeString'),
  741. category: 'printing',
  742. fn: function (){
  743. var self=this;
  744. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(s){return smalltalk.send(self, "_storeOn_", [s]);})]);
  745. return self;},
  746. args: [],
  747. source: unescape('storeString%0A%09%22Answer%20a%20String%20representation%20of%20the%20receiver%20from%20which%20the%20receiver%20%0A%09can%20be%20reconstructed.%22%0A%0A%09%5E%20String%20streamContents%3A%20%5B%3As%20%7C%20self%20storeOn%3A%20s%5D'),
  748. messageSends: ["streamContents:", "storeOn:"],
  749. referencedClasses: ["String"]
  750. }),
  751. smalltalk.Object);
  752. smalltalk.addMethod(
  753. unescape('_storeOn_'),
  754. smalltalk.method({
  755. selector: unescape('storeOn%3A'),
  756. category: 'printing',
  757. fn: function (aStream){
  758. var self=this;
  759. smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(self, "_printString", [])]);
  760. return self;},
  761. args: ["aStream"],
  762. source: unescape('storeOn%3A%20aStream%0A%09aStream%20nextPutAll%3A%20self%20printString'),
  763. messageSends: ["nextPutAll:", "printString"],
  764. referencedClasses: []
  765. }),
  766. smalltalk.Object);
  767. smalltalk.addMethod(
  768. unescape('_asJSONString'),
  769. smalltalk.method({
  770. selector: unescape('asJSONString'),
  771. category: 'converting',
  772. fn: function (){
  773. var self=this;
  774. return smalltalk.send((smalltalk.JSON || JSON), "_stringify_", [self]);
  775. return self;},
  776. args: [],
  777. source: unescape('asJSONString%0A%09%5EJSON%20stringify%3A%20self'),
  778. messageSends: ["stringify:"],
  779. referencedClasses: ["JSON"]
  780. }),
  781. smalltalk.Object);
  782. smalltalk.addMethod(
  783. unescape('_initialize'),
  784. smalltalk.method({
  785. selector: unescape('initialize'),
  786. category: 'initialization',
  787. fn: function (){
  788. var self=this;
  789. return self;},
  790. args: [],
  791. source: unescape('initialize%0A%09%22no%20op%22'),
  792. messageSends: [],
  793. referencedClasses: []
  794. }),
  795. smalltalk.Object.klass);
  796. smalltalk.addClass('Smalltalk', smalltalk.Object, [], 'Kernel');
  797. smalltalk.addMethod(
  798. unescape('_classes'),
  799. smalltalk.method({
  800. selector: unescape('classes'),
  801. category: 'accessing',
  802. fn: function (){
  803. var self=this;
  804. return self.classes();
  805. return self;},
  806. args: [],
  807. source: unescape('classes%0A%09%3Creturn%20self.classes%28%29%3E'),
  808. messageSends: [],
  809. referencedClasses: []
  810. }),
  811. smalltalk.Smalltalk);
  812. smalltalk.addMethod(
  813. unescape('_at_'),
  814. smalltalk.method({
  815. selector: unescape('at%3A'),
  816. category: 'accessing',
  817. fn: function (aString){
  818. var self=this;
  819. return self[aString];
  820. return self;},
  821. args: ["aString"],
  822. source: unescape('at%3A%20aString%0A%09%3Creturn%20self%5BaString%5D%3E'),
  823. messageSends: [],
  824. referencedClasses: []
  825. }),
  826. smalltalk.Smalltalk);
  827. smalltalk.addMethod(
  828. unescape('_removeClass_'),
  829. smalltalk.method({
  830. selector: unescape('removeClass%3A'),
  831. category: 'classes',
  832. fn: function (aClass){
  833. var self=this;
  834. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_asString", []), "__comma", [unescape("%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21")])]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_asString", []), "__comma", [unescape("%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21")])]);})]));
  835. smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_values", []), "_do_", [(function(each){return smalltalk.send(aClass, "_removeCompiledMethod_", [each]);})]);
  836. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_methodDictionary", []), "_values", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(aClass, "_class", []), "_removeCompiledMethod_", [each]);})]);
  837. smalltalk.send(self, "_basicDelete_", [smalltalk.send(aClass, "_name", [])]);
  838. return self;},
  839. args: ["aClass"],
  840. source: unescape('removeClass%3A%20aClass%0A%09aClass%20isMetaclass%20ifTrue%3A%20%5Bself%20error%3A%20aClass%20asString%2C%20%27%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21%27%5D.%0A%09aClass%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09aClass%20removeCompiledMethod%3A%20each%5D.%0A%09aClass%20class%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09aClass%20class%20removeCompiledMethod%3A%20each%5D.%0A%09self%20basicDelete%3A%20aClass%20name'),
  841. messageSends: ["ifTrue:", "isMetaclass", "error:", unescape("%2C"), "asString", "do:", "values", "methodDictionary", "removeCompiledMethod:", "class", "basicDelete:", "name"],
  842. referencedClasses: []
  843. }),
  844. smalltalk.Smalltalk);
  845. smalltalk.addMethod(
  846. unescape('_basicParse_'),
  847. smalltalk.method({
  848. selector: unescape('basicParse%3A'),
  849. category: 'accessing',
  850. fn: function (aString){
  851. var self=this;
  852. return smalltalk.parser.parse(aString);
  853. return self;},
  854. args: ["aString"],
  855. source: unescape('basicParse%3A%20aString%0A%09%3Creturn%20smalltalk.parser.parse%28aString%29%3E'),
  856. messageSends: [],
  857. referencedClasses: []
  858. }),
  859. smalltalk.Smalltalk);
  860. smalltalk.addMethod(
  861. unescape('_parse_'),
  862. smalltalk.method({
  863. selector: unescape('parse%3A'),
  864. category: 'accessing',
  865. fn: function (aString){
  866. var self=this;
  867. var result=nil;
  868. smalltalk.send(self, "_try_catch_", [(function(){return result=smalltalk.send(self, "_basicParse_", [aString]);}), (function(ex){return smalltalk.send(smalltalk.send(self, "_parseError_parsing_", [ex, aString]), "_signal", []);})]);
  869. return result;
  870. return self;},
  871. args: ["aString"],
  872. source: unescape('parse%3A%20aString%0A%09%7C%20result%20%7C%20%0A%09self%20try%3A%20%5Bresult%20%3A%3D%20self%20basicParse%3A%20aString%5D%20catch%3A%20%5B%3Aex%20%7C%20%28self%20parseError%3A%20ex%20parsing%3A%20aString%29%20signal%5D.%0A%09%5Eresult'),
  873. messageSends: ["try:catch:", "basicParse:", "signal", "parseError:parsing:"],
  874. referencedClasses: []
  875. }),
  876. smalltalk.Smalltalk);
  877. smalltalk.addMethod(
  878. unescape('_parseError_parsing_'),
  879. smalltalk.method({
  880. selector: unescape('parseError%3Aparsing%3A'),
  881. category: 'accessing',
  882. fn: function (anException, aString){
  883. var self=this;
  884. var row=nil;
  885. var col=nil;
  886. var message=nil;
  887. var lines=nil;
  888. var badLine=nil;
  889. var code=nil;
  890. row = anException.line;
  891. col = anException.column;
  892. message = anException.message;;
  893. lines=smalltalk.send(aString, "_lines", []);
  894. badLine=smalltalk.send(lines, "_at_", [row]);
  895. badLine=smalltalk.send(smalltalk.send(smalltalk.send(badLine, "_copyFrom_to_", [(1), ((($receiver = col).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]))]), "__comma", [unescape("%20%3D%3D%3D%3E")]), "__comma", [smalltalk.send(badLine, "_copyFrom_to_", [col, smalltalk.send(badLine, "_size", [])])]);
  896. smalltalk.send(lines, "_at_put_", [row, badLine]);
  897. code=smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(s){return smalltalk.send(lines, "_withIndexDo_", [(function(l, i){return smalltalk.send(s, "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(i, "_asString", []), "__comma", [": "]), "__comma", [l]), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])])]);})]);})]);
  898. return smalltalk.send(smalltalk.send((smalltalk.Error || Error), "_new", []), "_messageText_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send("Parse error on line ", "__comma", [row]), "__comma", [" column "]), "__comma", [col]), "__comma", [" : "]), "__comma", [message]), "__comma", [unescape("%20Below%20is%20code%20with%20line%20numbers%20and%20%3D%3D%3D%3E%20marker%20inserted%3A")]), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])]), "__comma", [code])]);
  899. return self;},
  900. args: ["anException", "aString"],
  901. source: unescape('parseError%3A%20anException%20parsing%3A%20aString%0A%09%7C%20row%20col%20message%20lines%20badLine%20code%20%7C%0A%09%3Crow%20%3D%20anException.line%3B%0A%09col%20%3D%20anException.column%3B%0A%09message%20%3D%20anException.message%3B%3E.%0A%09lines%20%3A%3D%20aString%20lines.%0A%09badLine%20%3A%3D%20lines%20at%3A%20row.%0A%09badLine%20%3A%3D%20%28badLine%20copyFrom%3A%201%20to%3A%20col%20-%201%29%2C%20%27%20%3D%3D%3D%3E%27%2C%20%28badLine%20copyFrom%3A%20%20col%20to%3A%20badLine%20size%29.%0A%09lines%20at%3A%20row%20put%3A%20badLine.%0A%09code%20%3A%3D%20String%20streamContents%3A%20%5B%3As%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20lines%20withIndexDo%3A%20%5B%3Al%20%3Ai%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20s%20nextPutAll%3A%20i%20asString%2C%20%27%3A%20%27%2C%20l%2C%20String%20lf%5D%5D.%0A%09%5E%20Error%20new%20messageText%3A%20%28%27Parse%20error%20on%20line%20%27%20%2C%20row%20%2C%20%27%20column%20%27%20%2C%20col%20%2C%20%27%20%3A%20%27%20%2C%20message%20%2C%20%27%20Below%20is%20code%20with%20line%20numbers%20and%20%3D%3D%3D%3E%20marker%20inserted%3A%27%20%2C%20String%20lf%2C%20code%29'),
  902. messageSends: ["lines", "at:", unescape("%2C"), "copyFrom:to:", unescape("-"), "size", "at:put:", "streamContents:", "withIndexDo:", "nextPutAll:", "asString", "lf", "messageText:", "new"],
  903. referencedClasses: ["String", "Error"]
  904. }),
  905. smalltalk.Smalltalk);
  906. smalltalk.addMethod(
  907. unescape('_packages'),
  908. smalltalk.method({
  909. selector: unescape('packages'),
  910. category: 'packages',
  911. fn: function (){
  912. var self=this;
  913. return self.packages.all();
  914. return self;},
  915. args: [],
  916. source: unescape('packages%0A%09%22Return%20all%20Package%20instances%20in%20the%20system.%22%0A%0A%09%3Creturn%20self.packages.all%28%29%3E'),
  917. messageSends: [],
  918. referencedClasses: []
  919. }),
  920. smalltalk.Smalltalk);
  921. smalltalk.addMethod(
  922. unescape('_packageAt_'),
  923. smalltalk.method({
  924. selector: unescape('packageAt%3A'),
  925. category: 'packages',
  926. fn: function (packageName){
  927. var self=this;
  928. return self.packages[packageName];
  929. return self;},
  930. args: ["packageName"],
  931. source: unescape('packageAt%3A%20packageName%0A%20%20%20%20%20%20%20%3Creturn%20self.packages%5BpackageName%5D%3E'),
  932. messageSends: [],
  933. referencedClasses: []
  934. }),
  935. smalltalk.Smalltalk);
  936. smalltalk.addMethod(
  937. unescape('_packageAt_ifAbsent_'),
  938. smalltalk.method({
  939. selector: unescape('packageAt%3AifAbsent%3A'),
  940. category: 'packages',
  941. fn: function (packageName, aBlock){
  942. var self=this;
  943. return smalltalk.send(smalltalk.send(self, "_packageAt_", [packageName]), "_ifNil_", [aBlock]);
  944. return self;},
  945. args: ["packageName", "aBlock"],
  946. source: unescape('packageAt%3A%20packageName%20ifAbsent%3A%20aBlock%0A%20%20%20%20%20%20%20%5E%28self%20packageAt%3A%20packageName%29%20ifNil%3A%20aBlock'),
  947. messageSends: ["ifNil:", "packageAt:"],
  948. referencedClasses: []
  949. }),
  950. smalltalk.Smalltalk);
  951. smalltalk.addMethod(
  952. unescape('_createPackage_'),
  953. smalltalk.method({
  954. selector: unescape('createPackage%3A'),
  955. category: 'private',
  956. fn: function (packageName){
  957. var self=this;
  958. return smalltalk.addPackage(packageName, nil);
  959. return self;},
  960. args: ["packageName"],
  961. source: unescape('createPackage%3A%20packageName%0A%09%22Create%20and%20bind%20a%20new%20package%20with%20given%20name%20and%20return%20it.%22%0A%0A%20%20%20%20%20%20%3Creturn%20smalltalk.addPackage%28packageName%2C%20nil%29%3E'),
  962. messageSends: [],
  963. referencedClasses: []
  964. }),
  965. smalltalk.Smalltalk);
  966. smalltalk.addMethod(
  967. unescape('_deletePackage_'),
  968. smalltalk.method({
  969. selector: unescape('deletePackage%3A'),
  970. category: 'private',
  971. fn: function (packageName){
  972. var self=this;
  973. delete smalltalk.packages[packageName];
  974. return self;},
  975. args: ["packageName"],
  976. source: unescape('deletePackage%3A%20packageName%0A%09%22Deletes%20a%20package%20by%20deleting%20its%20binding%2C%20but%20does%20not%20check%20if%20it%20contains%20classes%20etc.%0A%09To%20remove%20a%20package%2C%20use%20%23removePackage%20instead.%22%0A%0A%20%20%20%20%20%20%20%3Cdelete%20smalltalk.packages%5BpackageName%5D%3E'),
  977. messageSends: [],
  978. referencedClasses: []
  979. }),
  980. smalltalk.Smalltalk);
  981. smalltalk.addMethod(
  982. unescape('_removePackage_'),
  983. smalltalk.method({
  984. selector: unescape('removePackage%3A'),
  985. category: 'packages',
  986. fn: function (packageName){
  987. var self=this;
  988. var pkg=nil;
  989. pkg=smalltalk.send(self, "_packageAt_ifAbsent_", [packageName, (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Missing package: ", "__comma", [packageName])]);})]);
  990. smalltalk.send(smalltalk.send(pkg, "_classes", []), "_do_", [(function(each){return smalltalk.send(self, "_removeClass_", [each]);})]);
  991. smalltalk.send(self, "_deletePackage_", [packageName]);
  992. return self;},
  993. args: ["packageName"],
  994. source: unescape('removePackage%3A%20packageName%0A%09%22Removes%20a%20package%20and%20all%20its%20classes.%22%0A%0A%09%7C%20pkg%20%7C%0A%09pkg%20%3A%3D%20self%20packageAt%3A%20packageName%20ifAbsent%3A%20%5Bself%20error%3A%20%27Missing%20package%3A%20%27%2C%20packageName%5D.%0A%09pkg%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%20%20%20%20%09self%20removeClass%3A%20each%5D.%0A%09self%20deletePackage%3A%20packageName'),
  995. messageSends: ["packageAt:ifAbsent:", "error:", unescape("%2C"), "do:", "classes", "removeClass:", "deletePackage:"],
  996. referencedClasses: []
  997. }),
  998. smalltalk.Smalltalk);
  999. smalltalk.addMethod(
  1000. unescape('_renamePackage_to_'),
  1001. smalltalk.method({
  1002. selector: unescape('renamePackage%3Ato%3A'),
  1003. category: 'packages',
  1004. fn: function (packageName, newName){
  1005. var self=this;
  1006. var pkg=nil;
  1007. pkg=smalltalk.send(self, "_packageAt_ifAbsent_", [packageName, (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Missing package: ", "__comma", [packageName])]);})]);
  1008. (($receiver = smalltalk.send(self, "_packageAt_", [newName])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Already exists a package called: ", "__comma", [newName])]);})() : nil;
  1009. smalltalk.packages[newName] = smalltalk.packages[packageName];
  1010. smalltalk.send(pkg, "_name_", [newName]);
  1011. smalltalk.send(self, "_deletePackage_", [packageName]);
  1012. return self;},
  1013. args: ["packageName", "newName"],
  1014. source: unescape('renamePackage%3A%20packageName%20to%3A%20newName%0A%09%22Rename%20a%20package.%22%0A%0A%09%7C%20pkg%20%7C%0A%09pkg%20%3A%3D%20self%20packageAt%3A%20packageName%20ifAbsent%3A%20%5Bself%20error%3A%20%27Missing%20package%3A%20%27%2C%20packageName%5D.%0A%09%28self%20packageAt%3A%20newName%29%20ifNotNil%3A%20%5Bself%20error%3A%20%27Already%20exists%20a%20package%20called%3A%20%27%2C%20newName%5D.%0A%09%3Csmalltalk.packages%5BnewName%5D%20%3D%20smalltalk.packages%5BpackageName%5D%3E.%0A%09pkg%20name%3A%20newName.%0A%09self%20deletePackage%3A%20packageName.'),
  1015. messageSends: ["packageAt:ifAbsent:", "error:", unescape("%2C"), "ifNotNil:", "packageAt:", "name:", "deletePackage:"],
  1016. referencedClasses: []
  1017. }),
  1018. smalltalk.Smalltalk);
  1019. smalltalk.addMethod(
  1020. unescape('_reservedWords'),
  1021. smalltalk.method({
  1022. selector: unescape('reservedWords'),
  1023. category: 'accessing',
  1024. fn: function (){
  1025. var self=this;
  1026. return self.reservedWords;
  1027. return self;},
  1028. args: [],
  1029. source: unescape('reservedWords%0A%09%22JavaScript%20reserved%20words%22%0A%09%3Creturn%20self.reservedWords%3E'),
  1030. messageSends: [],
  1031. referencedClasses: []
  1032. }),
  1033. smalltalk.Smalltalk);
  1034. smalltalk.addMethod(
  1035. unescape('_createPackage_properties_'),
  1036. smalltalk.method({
  1037. selector: unescape('createPackage%3Aproperties%3A'),
  1038. category: 'private',
  1039. fn: function (packageName, aDict){
  1040. var self=this;
  1041. var object=nil;
  1042. object = {};;
  1043. smalltalk.send(aDict, "_keysAndValuesDo_", [(function(key, value){return object[key] = value;})]);
  1044. return smalltalk.addPackage(packageName, object);
  1045. return self;},
  1046. args: ["packageName", "aDict"],
  1047. source: unescape('createPackage%3A%20packageName%20properties%3A%20aDict%0A%09%22Create%20and%20bind%20a%20new%20package%20with%20given%20name%20and%20return%20it.%22%0A%0A%09%7C%20object%20%7C%0A%09%3Cobject%20%3D%20%7B%7D%3B%3E.%0A%09aDict%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09%3Cobject%5Bkey%5D%20%3D%20value%3E.%0A%09%5D.%0A%20%20%20%20%20%20%20%3Creturn%20smalltalk.addPackage%28packageName%2C%20object%29%3E'),
  1048. messageSends: ["keysAndValuesDo:"],
  1049. referencedClasses: []
  1050. }),
  1051. smalltalk.Smalltalk);
  1052. smalltalk.addMethod(
  1053. unescape('_readJSObject_'),
  1054. smalltalk.method({
  1055. selector: unescape('readJSObject%3A'),
  1056. category: 'accessing',
  1057. fn: function (anObject){
  1058. var self=this;
  1059. return self.readJSObject(anObject);
  1060. return self;},
  1061. args: ["anObject"],
  1062. source: unescape('readJSObject%3A%20anObject%0A%09%3Creturn%20self.readJSObject%28anObject%29%3E'),
  1063. messageSends: [],
  1064. referencedClasses: []
  1065. }),
  1066. smalltalk.Smalltalk);
  1067. smalltalk.Smalltalk.klass.iVarNames = ['current'];
  1068. smalltalk.addMethod(
  1069. unescape('_current'),
  1070. smalltalk.method({
  1071. selector: unescape('current'),
  1072. category: 'accessing',
  1073. fn: function (){
  1074. var self=this;
  1075. return smalltalk;
  1076. return self;},
  1077. args: [],
  1078. source: unescape('current%0A%09%3Creturn%20smalltalk%3E'),
  1079. messageSends: [],
  1080. referencedClasses: []
  1081. }),
  1082. smalltalk.Smalltalk.klass);
  1083. smalltalk.addClass('Package', smalltalk.Object, [], 'Kernel');
  1084. smalltalk.Package.comment=unescape('A%20Package%20is%20similar%20to%20a%20%22class%20category%22%20typically%20found%20in%20other%20Smalltalks%20like%20Pharo%20or%20Squeak.%20Amber%20does%20not%20have%20class%20categories%20anymore%2C%20it%20had%20in%20the%20beginning%20but%20now%20each%20class%20in%20the%20system%20knows%20which%20package%20it%20belongs%20to.%0A%0AA%20Package%20has%20a%20name%2C%20an%20Array%20of%20%22requires%22%2C%20a%20comment%20and%20a%20Dictionary%20with%20other%20optional%20key%20value%20attributes.%20A%20Package%20can%20also%20be%20queried%20for%20its%20classes%2C%20but%20it%20will%20then%20resort%20to%20a%20reverse%20scan%20of%20all%20classes%20to%20find%20them.%0APackages%20are%20manipulated%20through%20%22Smalltalk%20current%22%2C%20like%20for%20example%20finding%20one%20based%20on%20a%20name%3A%0A%0A%09Smalltalk%20current%20packageAt%3A%20%27Kernel%27%0A%0A...but%20you%20can%20also%20use%3A%0A%0A%09Package%20named%3A%20%27Kernel%27%0A%0AA%20Package%20differs%20slightly%20from%20a%20Monticello%20package%20which%20can%20span%20multiple%20class%20categories%20using%20a%20naming%20convention%20based%20on%20hyphenation.%20But%20just%20as%20in%20Monticello%20a%20Package%20supports%20%22class%20extensions%22%20so%20a%20Package%0Acan%20define%20behaviors%20in%20foreign%20classes%20using%20a%20naming%20convention%20for%20method%20categories%20where%20the%20category%20starts%20with%20an%20asterisk%20and%20then%20the%20name%20of%20the%20owning%20package%20follows.%20This%20can%20easily%20be%20seen%20in%20for%20example%20class%0AString%20where%20the%20method%20category%20%22*IDE%22%20defines%20%23inspectOn%3A%20which%20thus%20is%20a%20method%20belonging%20to%20the%20IDE%20package.')
  1085. smalltalk.addMethod(
  1086. unescape('_name'),
  1087. smalltalk.method({
  1088. selector: unescape('name'),
  1089. category: 'accessing',
  1090. fn: function (){
  1091. var self=this;
  1092. return self.pkgName;
  1093. return self;},
  1094. args: [],
  1095. source: unescape('name%0A%09%3Creturn%20self.pkgName%3E'),
  1096. messageSends: [],
  1097. referencedClasses: []
  1098. }),
  1099. smalltalk.Package);
  1100. smalltalk.addMethod(
  1101. unescape('_name_'),
  1102. smalltalk.method({
  1103. selector: unescape('name%3A'),
  1104. category: 'accessing',
  1105. fn: function (aString){
  1106. var self=this;
  1107. return self.pkgName = aString;
  1108. return self;},
  1109. args: ["aString"],
  1110. source: unescape('name%3A%20aString%0A%09%3Creturn%20self.pkgName%20%3D%20aString%3E'),
  1111. messageSends: [],
  1112. referencedClasses: []
  1113. }),
  1114. smalltalk.Package);
  1115. smalltalk.addMethod(
  1116. unescape('_classes'),
  1117. smalltalk.method({
  1118. selector: unescape('classes'),
  1119. category: 'classes',
  1120. fn: function (){
  1121. var self=this;
  1122. return smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_select_", [(function(c){return smalltalk.send(smalltalk.send(c, "_package", []), "__eq_eq", [self]);})]);
  1123. return self;},
  1124. args: [],
  1125. source: unescape('classes%0A%09%22We%20need%20to%20do%20a%20reverse%20scan.%22%0A%09%5ESmalltalk%20current%20classes%20select%3A%20%5B%3Ac%20%7C%20c%20package%20%3D%3D%20self%5D'),
  1126. messageSends: ["select:", "classes", "current", unescape("%3D%3D"), "package"],
  1127. referencedClasses: ["Smalltalk"]
  1128. }),
  1129. smalltalk.Package);
  1130. smalltalk.addMethod(
  1131. unescape('_printString'),
  1132. smalltalk.method({
  1133. selector: unescape('printString'),
  1134. category: 'printing',
  1135. fn: function (){
  1136. var self=this;
  1137. return smalltalk.send(self, "_name", []);
  1138. return self;},
  1139. args: [],
  1140. source: unescape('printString%0A%09%5Eself%20name'),
  1141. messageSends: ["name"],
  1142. referencedClasses: []
  1143. }),
  1144. smalltalk.Package);
  1145. smalltalk.addMethod(
  1146. unescape('_dependencies'),
  1147. smalltalk.method({
  1148. selector: unescape('dependencies'),
  1149. category: 'accessing',
  1150. fn: function (){
  1151. var self=this;
  1152. return smalltalk.send(self, "_propertyAt_ifAbsent_", ["dependencies", (function(){return [];})]);
  1153. return self;},
  1154. args: [],
  1155. source: unescape('dependencies%0A%09%5Eself%20propertyAt%3A%20%27dependencies%27%20ifAbsent%3A%20%5B%23%28%29%5D'),
  1156. messageSends: ["propertyAt:ifAbsent:"],
  1157. referencedClasses: []
  1158. }),
  1159. smalltalk.Package);
  1160. smalltalk.addMethod(
  1161. unescape('_dependencies_'),
  1162. smalltalk.method({
  1163. selector: unescape('dependencies%3A'),
  1164. category: 'accessing',
  1165. fn: function (anArray){
  1166. var self=this;
  1167. return smalltalk.send(self, "_propertyAt_put_", ["dependencies", anArray]);
  1168. return self;},
  1169. args: ["anArray"],
  1170. source: unescape('dependencies%3A%20anArray%0A%09%5Eself%20propertyAt%3A%20%27dependencies%27%20put%3A%20anArray'),
  1171. messageSends: ["propertyAt:put:"],
  1172. referencedClasses: []
  1173. }),
  1174. smalltalk.Package);
  1175. smalltalk.addMethod(
  1176. unescape('_properties'),
  1177. smalltalk.method({
  1178. selector: unescape('properties'),
  1179. category: 'accessing',
  1180. fn: function (){
  1181. var self=this;
  1182. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_readJSObject_", [smalltalk.send(self, "_basicAt_", ["properties"])]);
  1183. return self;},
  1184. args: [],
  1185. source: unescape('properties%0A%09%5ESmalltalk%20current%20readJSObject%3A%20%28self%20basicAt%3A%20%27properties%27%29'),
  1186. messageSends: ["readJSObject:", "current", "basicAt:"],
  1187. referencedClasses: ["Smalltalk"]
  1188. }),
  1189. smalltalk.Package);
  1190. smalltalk.addMethod(
  1191. unescape('_propertiesAsJSON'),
  1192. smalltalk.method({
  1193. selector: unescape('propertiesAsJSON'),
  1194. category: 'private',
  1195. fn: function (){
  1196. var self=this;
  1197. return JSON.stringify(self.properties);
  1198. return self;},
  1199. args: [],
  1200. source: unescape('propertiesAsJSON%0A%09%3Creturn%20JSON.stringify%28self.properties%29%3E'),
  1201. messageSends: [],
  1202. referencedClasses: []
  1203. }),
  1204. smalltalk.Package);
  1205. smalltalk.addMethod(
  1206. unescape('_properties_'),
  1207. smalltalk.method({
  1208. selector: unescape('properties%3A'),
  1209. category: 'accessing',
  1210. fn: function (aDict){
  1211. var self=this;
  1212. var object=nil;
  1213. object = {};;
  1214. smalltalk.send(aDict, "_keysAndValuesDo_", [(function(key, value){return object[key] = value;})]);
  1215. return self.properties = object;
  1216. return self;},
  1217. args: ["aDict"],
  1218. source: unescape('properties%3A%20aDict%0A%09%22We%20store%20it%20as%20a%20javascript%20object.%22%0A%09%0A%09%7C%20object%20%7C%0A%09%3Cobject%20%3D%20%7B%7D%3B%3E.%0A%09aDict%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09%3Cobject%5Bkey%5D%20%3D%20value%3E.%0A%09%5D.%0A%09%3Creturn%20self.properties%20%3D%20object%3E'),
  1219. messageSends: ["keysAndValuesDo:"],
  1220. referencedClasses: []
  1221. }),
  1222. smalltalk.Package);
  1223. smalltalk.addMethod(
  1224. unescape('_jsProperties'),
  1225. smalltalk.method({
  1226. selector: unescape('jsProperties'),
  1227. category: 'private',
  1228. fn: function (){
  1229. var self=this;
  1230. return self.properties;
  1231. return self;},
  1232. args: [],
  1233. source: unescape('jsProperties%0A%09%3Creturn%20self.properties%3E'),
  1234. messageSends: [],
  1235. referencedClasses: []
  1236. }),
  1237. smalltalk.Package);
  1238. smalltalk.addMethod(
  1239. unescape('_jsProperties_'),
  1240. smalltalk.method({
  1241. selector: unescape('jsProperties%3A'),
  1242. category: 'private',
  1243. fn: function (aJSObject){
  1244. var self=this;
  1245. return self.properties = aJSObject;
  1246. return self;},
  1247. args: ["aJSObject"],
  1248. source: unescape('jsProperties%3A%20aJSObject%0A%09%3Creturn%20self.properties%20%3D%20aJSObject%3E'),
  1249. messageSends: [],
  1250. referencedClasses: []
  1251. }),
  1252. smalltalk.Package);
  1253. smalltalk.addMethod(
  1254. unescape('_propertyAt_'),
  1255. smalltalk.method({
  1256. selector: unescape('propertyAt%3A'),
  1257. category: 'properties',
  1258. fn: function (key){
  1259. var self=this;
  1260. return self.properties[key];
  1261. return self;},
  1262. args: ["key"],
  1263. source: unescape('propertyAt%3A%20key%0A%0A%09%3Creturn%20self.properties%5Bkey%5D%3E'),
  1264. messageSends: [],
  1265. referencedClasses: []
  1266. }),
  1267. smalltalk.Package);
  1268. smalltalk.addMethod(
  1269. unescape('_propertyAt_put_'),
  1270. smalltalk.method({
  1271. selector: unescape('propertyAt%3Aput%3A'),
  1272. category: 'properties',
  1273. fn: function (key, value){
  1274. var self=this;
  1275. return self.properties[key] = value;
  1276. return self;},
  1277. args: ["key", "value"],
  1278. source: unescape('propertyAt%3A%20key%20put%3A%20value%0A%0A%09%3Creturn%20self.properties%5Bkey%5D%20%3D%20value%3E'),
  1279. messageSends: [],
  1280. referencedClasses: []
  1281. }),
  1282. smalltalk.Package);
  1283. smalltalk.addMethod(
  1284. unescape('_propertyAt_ifAbsent_'),
  1285. smalltalk.method({
  1286. selector: unescape('propertyAt%3AifAbsent%3A'),
  1287. category: 'properties',
  1288. fn: function (key, block){
  1289. var self=this;
  1290. return (($receiver = smalltalk.send(self, "_propertyAt_", [key])) == nil || $receiver == undefined) ? (function(){return smalltalk.send(block, "_value", []);})() : $receiver;
  1291. return self;},
  1292. args: ["key", "block"],
  1293. source: unescape('propertyAt%3A%20key%20ifAbsent%3A%20block%0A%0A%09%5E%28self%20propertyAt%3A%20key%29%20ifNil%3A%20%5Bblock%20value%5D'),
  1294. messageSends: ["ifNil:", "propertyAt:", "value"],
  1295. referencedClasses: []
  1296. }),
  1297. smalltalk.Package);
  1298. smalltalk.addMethod(
  1299. unescape('_named_'),
  1300. smalltalk.method({
  1301. selector: unescape('named%3A'),
  1302. category: 'not yet classified',
  1303. fn: function (aPackageName){
  1304. var self=this;
  1305. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_", [aPackageName]);
  1306. return self;},
  1307. args: ["aPackageName"],
  1308. source: unescape('named%3A%20aPackageName%0A%0A%09%5ESmalltalk%20current%20packageAt%3A%20aPackageName'),
  1309. messageSends: ["packageAt:", "current"],
  1310. referencedClasses: ["Smalltalk"]
  1311. }),
  1312. smalltalk.Package.klass);
  1313. smalltalk.addMethod(
  1314. unescape('_named_ifAbsent_'),
  1315. smalltalk.method({
  1316. selector: unescape('named%3AifAbsent%3A'),
  1317. category: 'not yet classified',
  1318. fn: function (aPackageName, aBlock){
  1319. var self=this;
  1320. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_ifAbsent_", [aPackageName, aBlock]);
  1321. return self;},
  1322. args: ["aPackageName", "aBlock"],
  1323. source: unescape('named%3A%20aPackageName%20ifAbsent%3A%20aBlock%0A%0A%09%5ESmalltalk%20current%20packageAt%3A%20aPackageName%20ifAbsent%3A%20aBlock'),
  1324. messageSends: ["packageAt:ifAbsent:", "current"],
  1325. referencedClasses: ["Smalltalk"]
  1326. }),
  1327. smalltalk.Package.klass);
  1328. smalltalk.addClass('Behavior', smalltalk.Object, [], 'Kernel');
  1329. smalltalk.addMethod(
  1330. unescape('_new'),
  1331. smalltalk.method({
  1332. selector: unescape('new'),
  1333. category: 'instance creation',
  1334. fn: function (){
  1335. var self=this;
  1336. return smalltalk.send(smalltalk.send(self, "_basicNew", []), "_initialize", []);
  1337. return self;},
  1338. args: [],
  1339. source: unescape('new%0A%09%5Eself%20basicNew%20initialize'),
  1340. messageSends: ["initialize", "basicNew"],
  1341. referencedClasses: []
  1342. }),
  1343. smalltalk.Behavior);
  1344. smalltalk.addMethod(
  1345. unescape('_basicNew'),
  1346. smalltalk.method({
  1347. selector: unescape('basicNew'),
  1348. category: 'instance creation',
  1349. fn: function (){
  1350. var self=this;
  1351. return new self.fn();
  1352. return self;},
  1353. args: [],
  1354. source: unescape('basicNew%0A%09%3Creturn%20new%20self.fn%28%29%3E'),
  1355. messageSends: [],
  1356. referencedClasses: []
  1357. }),
  1358. smalltalk.Behavior);
  1359. smalltalk.addMethod(
  1360. unescape('_name'),
  1361. smalltalk.method({
  1362. selector: unescape('name'),
  1363. category: 'accessing',
  1364. fn: function (){
  1365. var self=this;
  1366. return self.className || nil;
  1367. return self;},
  1368. args: [],
  1369. source: unescape('name%0A%09%3Creturn%20self.className%20%7C%7C%20nil%3E'),
  1370. messageSends: [],
  1371. referencedClasses: []
  1372. }),
  1373. smalltalk.Behavior);
  1374. smalltalk.addMethod(
  1375. unescape('_superclass'),
  1376. smalltalk.method({
  1377. selector: unescape('superclass'),
  1378. category: 'accessing',
  1379. fn: function (){
  1380. var self=this;
  1381. return self.superclass || nil;
  1382. return self;},
  1383. args: [],
  1384. source: unescape('superclass%0A%09%3Creturn%20self.superclass%20%7C%7C%20nil%3E'),
  1385. messageSends: [],
  1386. referencedClasses: []
  1387. }),
  1388. smalltalk.Behavior);
  1389. smalltalk.addMethod(
  1390. unescape('_subclasses'),
  1391. smalltalk.method({
  1392. selector: unescape('subclasses'),
  1393. category: 'accessing',
  1394. fn: function (){
  1395. var self=this;
  1396. return smalltalk.subclasses(self);
  1397. return self;},
  1398. args: [],
  1399. source: unescape('subclasses%0A%09%3Creturn%20smalltalk.subclasses%28self%29%3E'),
  1400. messageSends: [],
  1401. referencedClasses: []
  1402. }),
  1403. smalltalk.Behavior);
  1404. smalltalk.addMethod(
  1405. unescape('_allSubclasses'),
  1406. smalltalk.method({
  1407. selector: unescape('allSubclasses'),
  1408. category: 'accessing',
  1409. fn: function (){
  1410. var self=this;
  1411. var result=nil;
  1412. result=smalltalk.send(self, "_subclasses", []);
  1413. smalltalk.send(smalltalk.send(self, "_subclasses", []), "_do_", [(function(each){return smalltalk.send(result, "_addAll_", [smalltalk.send(each, "_allSubclasses", [])]);})]);
  1414. return result;
  1415. return self;},
  1416. args: [],
  1417. source: unescape('allSubclasses%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20self%20subclasses.%0A%09self%20subclasses%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20result%20addAll%3A%20each%20allSubclasses%5D.%0A%09%5Eresult'),
  1418. messageSends: ["subclasses", "do:", "addAll:", "allSubclasses"],
  1419. referencedClasses: []
  1420. }),
  1421. smalltalk.Behavior);
  1422. smalltalk.addMethod(
  1423. unescape('_withAllSubclasses'),
  1424. smalltalk.method({
  1425. selector: unescape('withAllSubclasses'),
  1426. category: 'accessing',
  1427. fn: function (){
  1428. var self=this;
  1429. return (function($rec){smalltalk.send($rec, "_addAll_", [smalltalk.send(self, "_allSubclasses", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.Array || Array), "_with_", [self]));
  1430. return self;},
  1431. args: [],
  1432. source: unescape('withAllSubclasses%0A%09%5E%28Array%20with%3A%20self%29%20addAll%3A%20self%20allSubclasses%3B%20yourself'),
  1433. messageSends: ["addAll:", "allSubclasses", "yourself", "with:"],
  1434. referencedClasses: ["Array"]
  1435. }),
  1436. smalltalk.Behavior);
  1437. smalltalk.addMethod(
  1438. unescape('_prototype'),
  1439. smalltalk.method({
  1440. selector: unescape('prototype'),
  1441. category: 'accessing',
  1442. fn: function (){
  1443. var self=this;
  1444. return self.fn.prototype;
  1445. return self;},
  1446. args: [],
  1447. source: unescape('prototype%0A%09%3Creturn%20self.fn.prototype%3E'),
  1448. messageSends: [],
  1449. referencedClasses: []
  1450. }),
  1451. smalltalk.Behavior);
  1452. smalltalk.addMethod(
  1453. unescape('_methodDictionary'),
  1454. smalltalk.method({
  1455. selector: unescape('methodDictionary'),
  1456. category: 'accessing',
  1457. fn: function (){
  1458. var self=this;
  1459. var dict = smalltalk.Dictionary._new();
  1460. var methods = self.fn.prototype.methods;
  1461. for(var i in methods) {
  1462. if(methods[i].selector) {
  1463. dict._at_put_(methods[i].selector, methods[i]);
  1464. }
  1465. };
  1466. return dict;
  1467. return self;},
  1468. args: [],
  1469. source: unescape('methodDictionary%0A%09%3Cvar%20dict%20%3D%20smalltalk.Dictionary._new%28%29%3B%0A%09var%20methods%20%3D%20self.fn.prototype.methods%3B%0A%09for%28var%20i%20in%20methods%29%20%7B%0A%09%09if%28methods%5Bi%5D.selector%29%20%7B%0A%09%09%09dict._at_put_%28methods%5Bi%5D.selector%2C%20methods%5Bi%5D%29%3B%0A%09%09%7D%0A%09%7D%3B%0A%09return%20dict%3E'),
  1470. messageSends: [],
  1471. referencedClasses: []
  1472. }),
  1473. smalltalk.Behavior);
  1474. smalltalk.addMethod(
  1475. unescape('_methodsFor_'),
  1476. smalltalk.method({
  1477. selector: unescape('methodsFor%3A'),
  1478. category: 'accessing',
  1479. fn: function (aString){
  1480. var self=this;
  1481. return (function($rec){smalltalk.send($rec, "_class_category_", [self, aString]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.ClassCategoryReader || ClassCategoryReader), "_new", []));
  1482. return self;},
  1483. args: ["aString"],
  1484. source: unescape('methodsFor%3A%20aString%0A%09%5EClassCategoryReader%20new%0A%09%20%20%20%20class%3A%20self%20category%3A%20aString%3B%0A%09%20%20%20%20yourself'),
  1485. messageSends: ["class:category:", "yourself", "new"],
  1486. referencedClasses: ["ClassCategoryReader"]
  1487. }),
  1488. smalltalk.Behavior);
  1489. smalltalk.addMethod(
  1490. unescape('_addCompiledMethod_'),
  1491. smalltalk.method({
  1492. selector: unescape('addCompiledMethod%3A'),
  1493. category: 'accessing',
  1494. fn: function (aMethod){
  1495. var self=this;
  1496. smalltalk.addMethod(aMethod.selector._asSelector(), aMethod, self);
  1497. return self;},
  1498. args: ["aMethod"],
  1499. source: unescape('addCompiledMethod%3A%20aMethod%0A%09%3Csmalltalk.addMethod%28aMethod.selector._asSelector%28%29%2C%20aMethod%2C%20self%29%3E'),
  1500. messageSends: [],
  1501. referencedClasses: []
  1502. }),
  1503. smalltalk.Behavior);
  1504. smalltalk.addMethod(
  1505. unescape('_instanceVariableNames'),
  1506. smalltalk.method({
  1507. selector: unescape('instanceVariableNames'),
  1508. category: 'accessing',
  1509. fn: function (){
  1510. var self=this;
  1511. return self.iVarNames;
  1512. return self;},
  1513. args: [],
  1514. source: unescape('instanceVariableNames%0A%09%3Creturn%20self.iVarNames%3E'),
  1515. messageSends: [],
  1516. referencedClasses: []
  1517. }),
  1518. smalltalk.Behavior);
  1519. smalltalk.addMethod(
  1520. unescape('_comment'),
  1521. smalltalk.method({
  1522. selector: unescape('comment'),
  1523. category: 'accessing',
  1524. fn: function (){
  1525. var self=this;
  1526. return (($receiver = smalltalk.send(self, "_basicAt_", ["comment"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  1527. return self;},
  1528. args: [],
  1529. source: unescape('comment%0A%20%20%20%20%5E%28self%20basicAt%3A%20%27comment%27%29%20ifNil%3A%20%5B%27%27%5D'),
  1530. messageSends: ["ifNil:", "basicAt:"],
  1531. referencedClasses: []
  1532. }),
  1533. smalltalk.Behavior);
  1534. smalltalk.addMethod(
  1535. unescape('_comment_'),
  1536. smalltalk.method({
  1537. selector: unescape('comment%3A'),
  1538. category: 'accessing',
  1539. fn: function (aString){
  1540. var self=this;
  1541. smalltalk.send(self, "_basicAt_put_", ["comment", aString]);
  1542. return self;},
  1543. args: ["aString"],
  1544. source: unescape('comment%3A%20aString%0A%20%20%20%20self%20basicAt%3A%20%27comment%27%20put%3A%20aString'),
  1545. messageSends: ["basicAt:put:"],
  1546. referencedClasses: []
  1547. }),
  1548. smalltalk.Behavior);
  1549. smalltalk.addMethod(
  1550. unescape('_commentStamp'),
  1551. smalltalk.method({
  1552. selector: unescape('commentStamp'),
  1553. category: 'accessing',
  1554. fn: function (){
  1555. var self=this;
  1556. return (function($rec){smalltalk.send($rec, "_class_", [self]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.ClassCommentReader || ClassCommentReader), "_new", []));
  1557. return self;},
  1558. args: [],
  1559. source: unescape('commentStamp%0A%20%20%20%20%5EClassCommentReader%20new%0A%09class%3A%20self%3B%0A%09yourself'),
  1560. messageSends: ["class:", "yourself", "new"],
  1561. referencedClasses: ["ClassCommentReader"]
  1562. }),
  1563. smalltalk.Behavior);
  1564. smalltalk.addMethod(
  1565. unescape('_removeCompiledMethod_'),
  1566. smalltalk.method({
  1567. selector: unescape('removeCompiledMethod%3A'),
  1568. category: 'accessing',
  1569. fn: function (aMethod){
  1570. var self=this;
  1571. delete self.fn.prototype[aMethod.selector._asSelector()];
  1572. delete self.fn.prototype.methods[aMethod.selector];
  1573. smalltalk.init(self);;
  1574. return self;},
  1575. args: ["aMethod"],
  1576. source: unescape('removeCompiledMethod%3A%20aMethod%0A%09%3Cdelete%20self.fn.prototype%5BaMethod.selector._asSelector%28%29%5D%3B%0A%09delete%20self.fn.prototype.methods%5BaMethod.selector%5D%3B%0A%09smalltalk.init%28self%29%3B%3E'),
  1577. messageSends: [],
  1578. referencedClasses: []
  1579. }),
  1580. smalltalk.Behavior);
  1581. smalltalk.addMethod(
  1582. unescape('_inheritsFrom_'),
  1583. smalltalk.method({
  1584. selector: unescape('inheritsFrom%3A'),
  1585. category: 'instance creation',
  1586. fn: function (aClass){
  1587. var self=this;
  1588. return smalltalk.send(smalltalk.send(aClass, "_allSubclasses", []), "_includes_", [self]);
  1589. return self;},
  1590. args: ["aClass"],
  1591. source: unescape('inheritsFrom%3A%20aClass%0A%09%5EaClass%20allSubclasses%20includes%3A%20self'),
  1592. messageSends: ["includes:", "allSubclasses"],
  1593. referencedClasses: []
  1594. }),
  1595. smalltalk.Behavior);
  1596. smalltalk.addMethod(
  1597. unescape('_protocols'),
  1598. smalltalk.method({
  1599. selector: unescape('protocols'),
  1600. category: 'accessing',
  1601. fn: function (){
  1602. var self=this;
  1603. var protocols=nil;
  1604. protocols=smalltalk.send((smalltalk.Array || Array), "_new", []);
  1605. smalltalk.send(smalltalk.send(self, "_methodDictionary", []), "_do_", [(function(each){return ((($receiver = smalltalk.send(protocols, "_includes_", [smalltalk.send(each, "_category", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(protocols, "_add_", [smalltalk.send(each, "_category", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(protocols, "_add_", [smalltalk.send(each, "_category", [])]);})]));})]);
  1606. return smalltalk.send(protocols, "_sort", []);
  1607. return self;},
  1608. args: [],
  1609. source: unescape('protocols%0A%20%20%20%20%7C%20protocols%20%7C%0A%20%20%20%20protocols%20%3A%3D%20Array%20new.%0A%20%20%20%20self%20methodDictionary%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20%28protocols%20includes%3A%20each%20category%29%20ifFalse%3A%20%5B%0A%09%09protocols%20add%3A%20each%20category%5D%5D.%0A%20%20%20%20%5Eprotocols%20sort'),
  1610. messageSends: ["new", "do:", "methodDictionary", "ifFalse:", "includes:", "category", "add:", "sort"],
  1611. referencedClasses: ["Array"]
  1612. }),
  1613. smalltalk.Behavior);
  1614. smalltalk.addMethod(
  1615. unescape('_protocolsDo_'),
  1616. smalltalk.method({
  1617. selector: unescape('protocolsDo%3A'),
  1618. category: 'accessing',
  1619. fn: function (aBlock){
  1620. var self=this;
  1621. var methodsByCategory=nil;
  1622. methodsByCategory=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  1623. smalltalk.send(smalltalk.send(smalltalk.send(self, "_methodDictionary", []), "_values", []), "_do_", [(function(m){return smalltalk.send(smalltalk.send(methodsByCategory, "_at_ifAbsentPut_", [smalltalk.send(m, "_category", []), (function(){return smalltalk.send((smalltalk.Array || Array), "_new", []);})]), "_add_", [m]);})]);
  1624. smalltalk.send(smalltalk.send(self, "_protocols", []), "_do_", [(function(category){return smalltalk.send(aBlock, "_value_value_", [category, smalltalk.send(methodsByCategory, "_at_", [category])]);})]);
  1625. return self;},
  1626. args: ["aBlock"],
  1627. source: unescape('protocolsDo%3A%20aBlock%0A%09%22Execute%20aBlock%20for%20each%20method%20category%20with%0A%09its%20collection%20of%20methods%20in%20the%20sort%20order%20of%20category%20name.%22%0A%0A%09%7C%20methodsByCategory%20%7C%0A%09methodsByCategory%20%3A%3D%20Dictionary%20new.%0A%09self%20methodDictionary%20values%20do%3A%20%5B%3Am%20%7C%0A%09%09%28methodsByCategory%20at%3A%20m%20category%20ifAbsentPut%3A%20%5BArray%20new%5D%29%0A%20%09%09%09add%3A%20m%5D.%20%0A%09self%20protocols%20do%3A%20%5B%3Acategory%20%7C%0A%09%09aBlock%20value%3A%20category%20value%3A%20%28methodsByCategory%20at%3A%20category%29%5D'),
  1628. messageSends: ["new", "do:", "values", "methodDictionary", "add:", "at:ifAbsentPut:", "category", "protocols", "value:value:", "at:"],
  1629. referencedClasses: ["Dictionary", "Array"]
  1630. }),
  1631. smalltalk.Behavior);
  1632. smalltalk.addMethod(
  1633. unescape('_allInstanceVariableNames'),
  1634. smalltalk.method({
  1635. selector: unescape('allInstanceVariableNames'),
  1636. category: 'accessing',
  1637. fn: function (){
  1638. var self=this;
  1639. var result=nil;
  1640. result=smalltalk.send(smalltalk.send(self, "_instanceVariableNames", []), "_copy", []);
  1641. (($receiver = smalltalk.send(self, "_superclass", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(result, "_addAll_", [smalltalk.send(smalltalk.send(self, "_superclass", []), "_allInstanceVariableNames", [])]);})() : nil;
  1642. return result;
  1643. return self;},
  1644. args: [],
  1645. source: unescape('allInstanceVariableNames%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20self%20instanceVariableNames%20copy.%0A%09self%20superclass%20ifNotNil%3A%20%5B%0A%09%20%20%20%20result%20addAll%3A%20self%20superclass%20allInstanceVariableNames%5D.%0A%09%5Eresult'),
  1646. messageSends: ["copy", "instanceVariableNames", "ifNotNil:", "superclass", "addAll:", "allInstanceVariableNames"],
  1647. referencedClasses: []
  1648. }),
  1649. smalltalk.Behavior);
  1650. smalltalk.addMethod(
  1651. unescape('_methodAt_'),
  1652. smalltalk.method({
  1653. selector: unescape('methodAt%3A'),
  1654. category: 'accessing',
  1655. fn: function (aString){
  1656. var self=this;
  1657. return smalltalk.methods(self)[aString];
  1658. return self;},
  1659. args: ["aString"],
  1660. source: unescape('methodAt%3A%20aString%0A%09%3Creturn%20smalltalk.methods%28self%29%5BaString%5D%3E'),
  1661. messageSends: [],
  1662. referencedClasses: []
  1663. }),
  1664. smalltalk.Behavior);
  1665. smalltalk.addMethod(
  1666. unescape('_methodsFor_stamp_'),
  1667. smalltalk.method({
  1668. selector: unescape('methodsFor%3Astamp%3A'),
  1669. category: 'accessing',
  1670. fn: function (aString, aStamp){
  1671. var self=this;
  1672. return smalltalk.send(self, "_methodsFor_", [aString]);
  1673. return self;},
  1674. args: ["aString", "aStamp"],
  1675. source: unescape('methodsFor%3A%20aString%20stamp%3A%20aStamp%0A%09%22Added%20for%20compatibility%2C%20right%20now%20ignores%20stamp.%22%0A%09%5Eself%20methodsFor%3A%20aString'),
  1676. messageSends: ["methodsFor:"],
  1677. referencedClasses: []
  1678. }),
  1679. smalltalk.Behavior);
  1680. smalltalk.addMethod(
  1681. unescape('_commentStamp_prior_'),
  1682. smalltalk.method({
  1683. selector: unescape('commentStamp%3Aprior%3A'),
  1684. category: 'accessing',
  1685. fn: function (aStamp, prior){
  1686. var self=this;
  1687. return smalltalk.send(self, "_commentStamp", []);
  1688. return self;},
  1689. args: ["aStamp", "prior"],
  1690. source: unescape('commentStamp%3A%20aStamp%20prior%3A%20prior%0A%20%20%20%20%20%20%20%20%5Eself%20commentStamp'),
  1691. messageSends: ["commentStamp"],
  1692. referencedClasses: []
  1693. }),
  1694. smalltalk.Behavior);
  1695. smalltalk.addMethod(
  1696. unescape('_compile_'),
  1697. smalltalk.method({
  1698. selector: unescape('compile%3A'),
  1699. category: 'compiling',
  1700. fn: function (aString){
  1701. var self=this;
  1702. smalltalk.send(self, "_compile_category_", [aString, ""]);
  1703. return self;},
  1704. args: ["aString"],
  1705. source: unescape('compile%3A%20aString%0A%09self%20compile%3A%20aString%20category%3A%20%27%27'),
  1706. messageSends: ["compile:category:"],
  1707. referencedClasses: []
  1708. }),
  1709. smalltalk.Behavior);
  1710. smalltalk.addMethod(
  1711. unescape('_compile_category_'),
  1712. smalltalk.method({
  1713. selector: unescape('compile%3Acategory%3A'),
  1714. category: 'compiling',
  1715. fn: function (aString, anotherString){
  1716. var self=this;
  1717. var method=nil;
  1718. method=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [aString, self]);
  1719. smalltalk.send(method, "_category_", [anotherString]);
  1720. smalltalk.send(self, "_addCompiledMethod_", [method]);
  1721. return self;},
  1722. args: ["aString", "anotherString"],
  1723. source: unescape('compile%3A%20aString%20category%3A%20anotherString%0A%09%7C%20method%20%7C%0A%09method%20%3A%3D%20Compiler%20new%20load%3A%20aString%20forClass%3A%20self.%0A%09method%20category%3A%20anotherString.%0A%09self%20addCompiledMethod%3A%20method'),
  1724. messageSends: ["load:forClass:", "new", "category:", "addCompiledMethod:"],
  1725. referencedClasses: ["Compiler"]
  1726. }),
  1727. smalltalk.Behavior);
  1728. smalltalk.addClass('Class', smalltalk.Behavior, [], 'Kernel');
  1729. smalltalk.addMethod(
  1730. unescape('_category'),
  1731. smalltalk.method({
  1732. selector: unescape('category'),
  1733. category: 'accessing',
  1734. fn: function (){
  1735. var self=this;
  1736. return (($receiver = smalltalk.send(self, "_package", [])) == nil || $receiver == undefined) ? (function(){return "Unclassified";})() : (function(){return smalltalk.send(smalltalk.send(self, "_package", []), "_name", []);})();
  1737. return self;},
  1738. args: [],
  1739. source: unescape('category%0A%09%5Eself%20package%20ifNil%3A%20%5B%27Unclassified%27%5D%20ifNotNil%3A%20%5Bself%20package%20name%5D'),
  1740. messageSends: ["ifNil:ifNotNil:", "package", "name"],
  1741. referencedClasses: []
  1742. }),
  1743. smalltalk.Class);
  1744. smalltalk.addMethod(
  1745. unescape('_subclass_instanceVariableNames_'),
  1746. smalltalk.method({
  1747. selector: unescape('subclass%3AinstanceVariableNames%3A'),
  1748. category: 'class creation',
  1749. fn: function (aString, anotherString){
  1750. var self=this;
  1751. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, anotherString, nil]);
  1752. return self;},
  1753. args: ["aString", "anotherString"],
  1754. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%0A%09%22Kept%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%20package%3A%20nil'),
  1755. messageSends: ["subclass:instanceVariableNames:package:"],
  1756. referencedClasses: []
  1757. }),
  1758. smalltalk.Class);
  1759. smalltalk.addMethod(
  1760. unescape('_subclass_instanceVariableNames_category_'),
  1761. smalltalk.method({
  1762. selector: unescape('subclass%3AinstanceVariableNames%3Acategory%3A'),
  1763. category: 'class creation',
  1764. fn: function (aString, aString2, aString3){
  1765. var self=this;
  1766. smalltalk.send(self, "_deprecatedAPI", []);
  1767. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  1768. return self;},
  1769. args: ["aString", "aString2", "aString3"],
  1770. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20category%3A%20aString3%0A%09%22Kept%20for%20compatibility.%22%0A%09self%20deprecatedAPI.%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  1771. messageSends: ["deprecatedAPI", "subclass:instanceVariableNames:package:"],
  1772. referencedClasses: []
  1773. }),
  1774. smalltalk.Class);
  1775. smalltalk.addMethod(
  1776. unescape('_isClass'),
  1777. smalltalk.method({
  1778. selector: unescape('isClass'),
  1779. category: 'testing',
  1780. fn: function (){
  1781. var self=this;
  1782. return true;
  1783. return self;},
  1784. args: [],
  1785. source: unescape('isClass%0A%09%5Etrue'),
  1786. messageSends: [],
  1787. referencedClasses: []
  1788. }),
  1789. smalltalk.Class);
  1790. smalltalk.addMethod(
  1791. unescape('_printString'),
  1792. smalltalk.method({
  1793. selector: unescape('printString'),
  1794. category: 'printing',
  1795. fn: function (){
  1796. var self=this;
  1797. return smalltalk.send(self, "_name", []);
  1798. return self;},
  1799. args: [],
  1800. source: unescape('printString%0A%09%5Eself%20name'),
  1801. messageSends: ["name"],
  1802. referencedClasses: []
  1803. }),
  1804. smalltalk.Class);
  1805. smalltalk.addMethod(
  1806. unescape('_rename_'),
  1807. smalltalk.method({
  1808. selector: unescape('rename%3A'),
  1809. category: 'accessing',
  1810. fn: function (aString){
  1811. var self=this;
  1812. smalltalk[aString] = self;
  1813. delete smalltalk[self.className];
  1814. self.className = aString;
  1815. ;
  1816. return self;},
  1817. args: ["aString"],
  1818. source: unescape('rename%3A%20aString%0A%09%3C%0A%09%09smalltalk%5BaString%5D%20%3D%20self%3B%0A%09%09delete%20smalltalk%5Bself.className%5D%3B%0A%09%09self.className%20%3D%20aString%3B%0A%09%3E'),
  1819. messageSends: [],
  1820. referencedClasses: []
  1821. }),
  1822. smalltalk.Class);
  1823. smalltalk.addMethod(
  1824. unescape('_subclass_instanceVariableNames_classVariableNames_poolDictionaries_category_'),
  1825. smalltalk.method({
  1826. selector: unescape('subclass%3AinstanceVariableNames%3AclassVariableNames%3ApoolDictionaries%3Acategory%3A'),
  1827. category: 'class creation',
  1828. fn: function (aString, aString2, classVars, pools, aString3){
  1829. var self=this;
  1830. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  1831. return self;},
  1832. args: ["aString", "aString2", "classVars", "pools", "aString3"],
  1833. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20classVariableNames%3A%20classVars%20poolDictionaries%3A%20pools%20category%3A%20aString3%0A%09%22Just%20ignore%20class%20variables%20and%20pools.%20Added%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  1834. messageSends: ["subclass:instanceVariableNames:package:"],
  1835. referencedClasses: []
  1836. }),
  1837. smalltalk.Class);
  1838. smalltalk.addMethod(
  1839. unescape('_package'),
  1840. smalltalk.method({
  1841. selector: unescape('package'),
  1842. category: 'accessing',
  1843. fn: function (){
  1844. var self=this;
  1845. return self.pkg;
  1846. return self;},
  1847. args: [],
  1848. source: unescape('package%0A%09%3Creturn%20self.pkg%3E'),
  1849. messageSends: [],
  1850. referencedClasses: []
  1851. }),
  1852. smalltalk.Class);
  1853. smalltalk.addMethod(
  1854. unescape('_package_'),
  1855. smalltalk.method({
  1856. selector: unescape('package%3A'),
  1857. category: 'accessing',
  1858. fn: function (aPackage){
  1859. var self=this;
  1860. self.pkg = aPackage;
  1861. return self;},
  1862. args: ["aPackage"],
  1863. source: unescape('package%3A%20aPackage%0A%09%3Cself.pkg%20%3D%20aPackage%3E'),
  1864. messageSends: [],
  1865. referencedClasses: []
  1866. }),
  1867. smalltalk.Class);
  1868. smalltalk.addMethod(
  1869. unescape('_subclass_instanceVariableNames_package_'),
  1870. smalltalk.method({
  1871. selector: unescape('subclass%3AinstanceVariableNames%3Apackage%3A'),
  1872. category: 'class creation',
  1873. fn: function (aString, aString2, aString3){
  1874. var self=this;
  1875. return smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_superclass_subclass_instanceVariableNames_package_", [self, aString, aString2, aString3]);
  1876. return self;},
  1877. args: ["aString", "aString2", "aString3"],
  1878. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%5EClassBuilder%20new%0A%09%20%20%20%20superclass%3A%20self%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  1879. messageSends: ["superclass:subclass:instanceVariableNames:package:", "new"],
  1880. referencedClasses: ["ClassBuilder"]
  1881. }),
  1882. smalltalk.Class);
  1883. smalltalk.addClass('Metaclass', smalltalk.Behavior, [], 'Kernel');
  1884. smalltalk.addMethod(
  1885. unescape('_instanceClass'),
  1886. smalltalk.method({
  1887. selector: unescape('instanceClass'),
  1888. category: 'accessing',
  1889. fn: function (){
  1890. var self=this;
  1891. return self.instanceClass;
  1892. return self;},
  1893. args: [],
  1894. source: unescape('instanceClass%0A%09%3Creturn%20self.instanceClass%3E'),
  1895. messageSends: [],
  1896. referencedClasses: []
  1897. }),
  1898. smalltalk.Metaclass);
  1899. smalltalk.addMethod(
  1900. unescape('_instanceVariableNames_'),
  1901. smalltalk.method({
  1902. selector: unescape('instanceVariableNames%3A'),
  1903. category: 'accessing',
  1904. fn: function (aCollection){
  1905. var self=this;
  1906. smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_class_instanceVariableNames_", [self, aCollection]);
  1907. return self;},
  1908. args: ["aCollection"],
  1909. source: unescape('instanceVariableNames%3A%20aCollection%0A%09ClassBuilder%20new%0A%09%20%20%20%20class%3A%20self%20instanceVariableNames%3A%20aCollection'),
  1910. messageSends: ["class:instanceVariableNames:", "new"],
  1911. referencedClasses: ["ClassBuilder"]
  1912. }),
  1913. smalltalk.Metaclass);
  1914. smalltalk.addMethod(
  1915. unescape('_isMetaclass'),
  1916. smalltalk.method({
  1917. selector: unescape('isMetaclass'),
  1918. category: 'testing',
  1919. fn: function (){
  1920. var self=this;
  1921. return true;
  1922. return self;},
  1923. args: [],
  1924. source: unescape('isMetaclass%0A%09%5Etrue'),
  1925. messageSends: [],
  1926. referencedClasses: []
  1927. }),
  1928. smalltalk.Metaclass);
  1929. smalltalk.addMethod(
  1930. unescape('_printString'),
  1931. smalltalk.method({
  1932. selector: unescape('printString'),
  1933. category: 'printing',
  1934. fn: function (){
  1935. var self=this;
  1936. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_instanceClass", []), "_name", []), "__comma", [" class"]);
  1937. return self;},
  1938. args: [],
  1939. source: unescape('printString%0A%09%5Eself%20instanceClass%20name%2C%20%27%20class%27'),
  1940. messageSends: [unescape("%2C"), "name", "instanceClass"],
  1941. referencedClasses: []
  1942. }),
  1943. smalltalk.Metaclass);
  1944. smalltalk.addClass('CompiledMethod', smalltalk.Object, [], 'Kernel');
  1945. smalltalk.addMethod(
  1946. unescape('_source'),
  1947. smalltalk.method({
  1948. selector: unescape('source'),
  1949. category: 'accessing',
  1950. fn: function (){
  1951. var self=this;
  1952. return (($receiver = smalltalk.send(self, "_basicAt_", ["source"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  1953. return self;},
  1954. args: [],
  1955. source: unescape('source%0A%09%5E%28self%20basicAt%3A%20%27source%27%29%20ifNil%3A%20%5B%27%27%5D'),
  1956. messageSends: ["ifNil:", "basicAt:"],
  1957. referencedClasses: []
  1958. }),
  1959. smalltalk.CompiledMethod);
  1960. smalltalk.addMethod(
  1961. unescape('_source_'),
  1962. smalltalk.method({
  1963. selector: unescape('source%3A'),
  1964. category: 'accessing',
  1965. fn: function (aString){
  1966. var self=this;
  1967. smalltalk.send(self, "_basicAt_put_", ["source", aString]);
  1968. return self;},
  1969. args: ["aString"],
  1970. source: unescape('source%3A%20aString%0A%09self%20basicAt%3A%20%27source%27%20put%3A%20aString'),
  1971. messageSends: ["basicAt:put:"],
  1972. referencedClasses: []
  1973. }),
  1974. smalltalk.CompiledMethod);
  1975. smalltalk.addMethod(
  1976. unescape('_category'),
  1977. smalltalk.method({
  1978. selector: unescape('category'),
  1979. category: 'accessing',
  1980. fn: function (){
  1981. var self=this;
  1982. return (($receiver = smalltalk.send(self, "_basicAt_", ["category"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  1983. return self;},
  1984. args: [],
  1985. source: unescape('category%0A%09%5E%28self%20basicAt%3A%20%27category%27%29%20ifNil%3A%20%5B%27%27%5D'),
  1986. messageSends: ["ifNil:", "basicAt:"],
  1987. referencedClasses: []
  1988. }),
  1989. smalltalk.CompiledMethod);
  1990. smalltalk.addMethod(
  1991. unescape('_category_'),
  1992. smalltalk.method({
  1993. selector: unescape('category%3A'),
  1994. category: 'accessing',
  1995. fn: function (aString){
  1996. var self=this;
  1997. smalltalk.send(self, "_basicAt_put_", ["category", aString]);
  1998. return self;},
  1999. args: ["aString"],
  2000. source: unescape('category%3A%20aString%0A%09self%20basicAt%3A%20%27category%27%20put%3A%20aString'),
  2001. messageSends: ["basicAt:put:"],
  2002. referencedClasses: []
  2003. }),
  2004. smalltalk.CompiledMethod);
  2005. smalltalk.addMethod(
  2006. unescape('_selector'),
  2007. smalltalk.method({
  2008. selector: unescape('selector'),
  2009. category: 'accessing',
  2010. fn: function (){
  2011. var self=this;
  2012. return smalltalk.send(self, "_basicAt_", ["selector"]);
  2013. return self;},
  2014. args: [],
  2015. source: unescape('selector%0A%09%5Eself%20basicAt%3A%20%27selector%27'),
  2016. messageSends: ["basicAt:"],
  2017. referencedClasses: []
  2018. }),
  2019. smalltalk.CompiledMethod);
  2020. smalltalk.addMethod(
  2021. unescape('_selector_'),
  2022. smalltalk.method({
  2023. selector: unescape('selector%3A'),
  2024. category: 'accessing',
  2025. fn: function (aString){
  2026. var self=this;
  2027. smalltalk.send(self, "_basicAt_put_", ["selector", aString]);
  2028. return self;},
  2029. args: ["aString"],
  2030. source: unescape('selector%3A%20aString%0A%09self%20basicAt%3A%20%27selector%27%20put%3A%20aString'),
  2031. messageSends: ["basicAt:put:"],
  2032. referencedClasses: []
  2033. }),
  2034. smalltalk.CompiledMethod);
  2035. smalltalk.addMethod(
  2036. unescape('_fn'),
  2037. smalltalk.method({
  2038. selector: unescape('fn'),
  2039. category: 'accessing',
  2040. fn: function (){
  2041. var self=this;
  2042. return smalltalk.send(self, "_basicAt_", ["fn"]);
  2043. return self;},
  2044. args: [],
  2045. source: unescape('fn%0A%09%5Eself%20basicAt%3A%20%27fn%27'),
  2046. messageSends: ["basicAt:"],
  2047. referencedClasses: []
  2048. }),
  2049. smalltalk.CompiledMethod);
  2050. smalltalk.addMethod(
  2051. unescape('_fn_'),
  2052. smalltalk.method({
  2053. selector: unescape('fn%3A'),
  2054. category: 'accessing',
  2055. fn: function (aBlock){
  2056. var self=this;
  2057. smalltalk.send(self, "_basicAt_put_", ["fn", aBlock]);
  2058. return self;},
  2059. args: ["aBlock"],
  2060. source: unescape('fn%3A%20aBlock%0A%09self%20basicAt%3A%20%27fn%27%20put%3A%20aBlock'),
  2061. messageSends: ["basicAt:put:"],
  2062. referencedClasses: []
  2063. }),
  2064. smalltalk.CompiledMethod);
  2065. smalltalk.addMethod(
  2066. unescape('_messageSends'),
  2067. smalltalk.method({
  2068. selector: unescape('messageSends'),
  2069. category: 'accessing',
  2070. fn: function (){
  2071. var self=this;
  2072. return smalltalk.send(self, "_basicAt_", ["messageSends"]);
  2073. return self;},
  2074. args: [],
  2075. source: unescape('messageSends%0A%09%5Eself%20basicAt%3A%20%27messageSends%27'),
  2076. messageSends: ["basicAt:"],
  2077. referencedClasses: []
  2078. }),
  2079. smalltalk.CompiledMethod);
  2080. smalltalk.addMethod(
  2081. unescape('_methodClass'),
  2082. smalltalk.method({
  2083. selector: unescape('methodClass'),
  2084. category: 'accessing',
  2085. fn: function (){
  2086. var self=this;
  2087. return smalltalk.send(self, "_basicAt_", ["methodClass"]);
  2088. return self;},
  2089. args: [],
  2090. source: unescape('methodClass%0A%09%5Eself%20basicAt%3A%20%27methodClass%27'),
  2091. messageSends: ["basicAt:"],
  2092. referencedClasses: []
  2093. }),
  2094. smalltalk.CompiledMethod);
  2095. smalltalk.addMethod(
  2096. unescape('_referencedClasses'),
  2097. smalltalk.method({
  2098. selector: unescape('referencedClasses'),
  2099. category: 'accessing',
  2100. fn: function (){
  2101. var self=this;
  2102. return smalltalk.send(self, "_basicAt_", ["referencedClasses"]);
  2103. return self;},
  2104. args: [],
  2105. source: unescape('referencedClasses%0A%09%5Eself%20basicAt%3A%20%27referencedClasses%27'),
  2106. messageSends: ["basicAt:"],
  2107. referencedClasses: []
  2108. }),
  2109. smalltalk.CompiledMethod);
  2110. smalltalk.addMethod(
  2111. unescape('_arguments'),
  2112. smalltalk.method({
  2113. selector: unescape('arguments'),
  2114. category: 'accessing',
  2115. fn: function (){
  2116. var self=this;
  2117. return self.args || [];
  2118. return self;},
  2119. args: [],
  2120. source: unescape('arguments%0A%09%3Creturn%20self.args%20%7C%7C%20%5B%5D%3E'),
  2121. messageSends: [],
  2122. referencedClasses: []
  2123. }),
  2124. smalltalk.CompiledMethod);
  2125. smalltalk.addClass('Number', smalltalk.Object, [], 'Kernel');
  2126. smalltalk.addMethod(
  2127. unescape('__eq'),
  2128. smalltalk.method({
  2129. selector: unescape('%3D'),
  2130. category: 'comparing',
  2131. fn: function (aNumber){
  2132. var self=this;
  2133. try{((($receiver = smalltalk.send(smalltalk.send(aNumber, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  2134. return Number(self) == aNumber;
  2135. return self;
  2136. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  2137. args: ["aNumber"],
  2138. source: unescape('%3D%20aNumber%0A%09aNumber%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%20%0A%09%3Creturn%20Number%28self%29%20%3D%3D%20aNumber%3E'),
  2139. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  2140. referencedClasses: []
  2141. }),
  2142. smalltalk.Number);
  2143. smalltalk.addMethod(
  2144. unescape('__gt'),
  2145. smalltalk.method({
  2146. selector: unescape('%3E'),
  2147. category: 'comparing',
  2148. fn: function (aNumber){
  2149. var self=this;
  2150. return self > aNumber;
  2151. return self;},
  2152. args: ["aNumber"],
  2153. source: unescape('%3E%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3E%3E%20aNumber%3E'),
  2154. messageSends: [],
  2155. referencedClasses: []
  2156. }),
  2157. smalltalk.Number);
  2158. smalltalk.addMethod(
  2159. unescape('__lt'),
  2160. smalltalk.method({
  2161. selector: unescape('%3C'),
  2162. category: 'comparing',
  2163. fn: function (aNumber){
  2164. var self=this;
  2165. return self < aNumber;
  2166. return self;},
  2167. args: ["aNumber"],
  2168. source: unescape('%3C%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3C%20aNumber%3E'),
  2169. messageSends: [],
  2170. referencedClasses: []
  2171. }),
  2172. smalltalk.Number);
  2173. smalltalk.addMethod(
  2174. unescape('__gt_eq'),
  2175. smalltalk.method({
  2176. selector: unescape('%3E%3D'),
  2177. category: 'comparing',
  2178. fn: function (aNumber){
  2179. var self=this;
  2180. return self >= aNumber;
  2181. return self;},
  2182. args: ["aNumber"],
  2183. source: unescape('%3E%3D%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3E%3E%3D%20aNumber%3E'),
  2184. messageSends: [],
  2185. referencedClasses: []
  2186. }),
  2187. smalltalk.Number);
  2188. smalltalk.addMethod(
  2189. unescape('__lt_eq'),
  2190. smalltalk.method({
  2191. selector: unescape('%3C%3D'),
  2192. category: 'comparing',
  2193. fn: function (aNumber){
  2194. var self=this;
  2195. return self <= aNumber;
  2196. return self;},
  2197. args: ["aNumber"],
  2198. source: unescape('%3C%3D%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3C%3D%20aNumber%3E'),
  2199. messageSends: [],
  2200. referencedClasses: []
  2201. }),
  2202. smalltalk.Number);
  2203. smalltalk.addMethod(
  2204. unescape('__plus'),
  2205. smalltalk.method({
  2206. selector: unescape('+'),
  2207. category: 'arithmetic',
  2208. fn: function (aNumber){
  2209. var self=this;
  2210. return self + aNumber;
  2211. return self;},
  2212. args: ["aNumber"],
  2213. source: unescape('+%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20+%20aNumber%3E'),
  2214. messageSends: [],
  2215. referencedClasses: []
  2216. }),
  2217. smalltalk.Number);
  2218. smalltalk.addMethod(
  2219. unescape('__minus'),
  2220. smalltalk.method({
  2221. selector: unescape('-'),
  2222. category: 'arithmetic',
  2223. fn: function (aNumber){
  2224. var self=this;
  2225. return self - aNumber;
  2226. return self;},
  2227. args: ["aNumber"],
  2228. source: unescape('-%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20-%20aNumber%3E'),
  2229. messageSends: [],
  2230. referencedClasses: []
  2231. }),
  2232. smalltalk.Number);
  2233. smalltalk.addMethod(
  2234. unescape('__star'),
  2235. smalltalk.method({
  2236. selector: unescape('*'),
  2237. category: 'arithmetic',
  2238. fn: function (aNumber){
  2239. var self=this;
  2240. return self * aNumber;
  2241. return self;},
  2242. args: ["aNumber"],
  2243. source: unescape('*%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20*%20aNumber%3E'),
  2244. messageSends: [],
  2245. referencedClasses: []
  2246. }),
  2247. smalltalk.Number);
  2248. smalltalk.addMethod(
  2249. unescape('__slash'),
  2250. smalltalk.method({
  2251. selector: unescape('/'),
  2252. category: 'arithmetic',
  2253. fn: function (aNumber){
  2254. var self=this;
  2255. return self / aNumber;
  2256. return self;},
  2257. args: ["aNumber"],
  2258. source: unescape('/%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20/%20aNumber%3E'),
  2259. messageSends: [],
  2260. referencedClasses: []
  2261. }),
  2262. smalltalk.Number);
  2263. smalltalk.addMethod(
  2264. unescape('_max_'),
  2265. smalltalk.method({
  2266. selector: unescape('max%3A'),
  2267. category: 'arithmetic',
  2268. fn: function (aNumber){
  2269. var self=this;
  2270. return Math.max(self, aNumber);;
  2271. return self;},
  2272. args: ["aNumber"],
  2273. source: unescape('max%3A%20aNumber%0A%09%3Creturn%20Math.max%28self%2C%20aNumber%29%3B%3E'),
  2274. messageSends: [],
  2275. referencedClasses: []
  2276. }),
  2277. smalltalk.Number);
  2278. smalltalk.addMethod(
  2279. unescape('_min_'),
  2280. smalltalk.method({
  2281. selector: unescape('min%3A'),
  2282. category: 'arithmetic',
  2283. fn: function (aNumber){
  2284. var self=this;
  2285. return Math.min(self, aNumber);;
  2286. return self;},
  2287. args: ["aNumber"],
  2288. source: unescape('min%3A%20aNumber%0A%09%3Creturn%20Math.min%28self%2C%20aNumber%29%3B%3E'),
  2289. messageSends: [],
  2290. referencedClasses: []
  2291. }),
  2292. smalltalk.Number);
  2293. smalltalk.addMethod(
  2294. unescape('_rounded'),
  2295. smalltalk.method({
  2296. selector: unescape('rounded'),
  2297. category: 'converting',
  2298. fn: function (){
  2299. var self=this;
  2300. return Math.round(self);;
  2301. return self;},
  2302. args: [],
  2303. source: unescape('rounded%0A%09%3Creturn%20Math.round%28self%29%3B%3E'),
  2304. messageSends: [],
  2305. referencedClasses: []
  2306. }),
  2307. smalltalk.Number);
  2308. smalltalk.addMethod(
  2309. unescape('_truncated'),
  2310. smalltalk.method({
  2311. selector: unescape('truncated'),
  2312. category: 'converting',
  2313. fn: function (){
  2314. var self=this;
  2315. var result=nil;
  2316. ((($receiver = self >= (0)).klass === smalltalk.Boolean) ? ($receiver ? (function(){return result = Math.floor(self);;})() : (function(){return result = (Math.floor(self * (-1)) * (-1));;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return result = Math.floor(self);;}), (function(){return result = (Math.floor(self * (-1)) * (-1));;})]));
  2317. return result;
  2318. return self;},
  2319. args: [],
  2320. source: unescape('truncated%0A%7Cresult%7C%0A%0A%20%20%20%20self%20%3E%3D%200%20%0A%20%20%20%20%20%20%20%20ifTrue%3A%20%5B%3Cresult%20%3D%20Math.floor%28self%29%3B%3E%5D%0A%20%20%20%20%20%20%20%20ifFalse%3A%20%5B%3Cresult%20%3D%20%28Math.floor%28self%20*%20%28-1%29%29%20*%20%28-1%29%29%3B%3E%5D.%0A%0A%20%20%20%20%5E%20result'),
  2321. messageSends: ["ifTrue:ifFalse:", unescape("%3E%3D")],
  2322. referencedClasses: []
  2323. }),
  2324. smalltalk.Number);
  2325. smalltalk.addMethod(
  2326. unescape('_to_'),
  2327. smalltalk.method({
  2328. selector: unescape('to%3A'),
  2329. category: 'converting',
  2330. fn: function (aNumber){
  2331. var self=this;
  2332. var array=nil;
  2333. var first=nil;
  2334. var last=nil;
  2335. var count=nil;
  2336. first=smalltalk.send(self, "_truncated", []);
  2337. last=((($receiver = smalltalk.send(aNumber, "_truncated", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));
  2338. count=(1);
  2339. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  2340. smalltalk.send(((($receiver = last).klass === smalltalk.Number) ? $receiver -first : smalltalk.send($receiver, "__minus", [first])), "_timesRepeat_", [(function(){smalltalk.send(array, "_at_put_", [count, first]);count=((($receiver = count).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return first=((($receiver = first).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})]);
  2341. return array;
  2342. return self;},
  2343. args: ["aNumber"],
  2344. source: unescape('to%3A%20aNumber%0A%09%7C%20array%20first%20last%20count%20%7C%0A%09first%20%3A%3D%20self%20truncated.%0A%09last%20%3A%3D%20aNumber%20truncated%20+%201.%0A%09count%20%3A%3D%201.%0A%09array%20%3A%3D%20Array%20new.%0A%09%28last%20-%20first%29%20timesRepeat%3A%20%5B%0A%09%20%20%20%20array%20at%3A%20count%20put%3A%20first.%0A%09%20%20%20%20count%20%3A%3D%20count%20+%201.%0A%09%20%20%20%20first%20%3A%3D%20first%20+%201%5D.%0A%09%5Earray'),
  2345. messageSends: ["truncated", unescape("+"), "new", "timesRepeat:", unescape("-"), "at:put:"],
  2346. referencedClasses: ["Array"]
  2347. }),
  2348. smalltalk.Number);
  2349. smalltalk.addMethod(
  2350. unescape('_timesRepeat_'),
  2351. smalltalk.method({
  2352. selector: unescape('timesRepeat%3A'),
  2353. category: 'enumerating',
  2354. fn: function (aBlock){
  2355. var self=this;
  2356. var integer=nil;
  2357. var count=nil;
  2358. integer=smalltalk.send(self, "_truncated", []);
  2359. count=(1);
  2360. (function(){while(!(function(){return ((($receiver = count).klass === smalltalk.Number) ? $receiver >self : smalltalk.send($receiver, "__gt", [self]));})()) {(function(){smalltalk.send(aBlock, "_value", []);return count=((($receiver = count).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})()}})();
  2361. return self;},
  2362. args: ["aBlock"],
  2363. source: unescape('timesRepeat%3A%20aBlock%0A%09%7C%20integer%20count%20%7C%0A%09integer%20%3A%3D%20self%20truncated.%0A%09count%20%3A%3D%201.%0A%09%5Bcount%20%3E%20self%5D%20whileFalse%3A%20%5B%0A%09%20%20%20%20aBlock%20value.%0A%09%20%20%20%20count%20%3A%3D%20count%20+%201%5D'),
  2364. messageSends: ["truncated", "whileFalse:", unescape("%3E"), "value", unescape("+")],
  2365. referencedClasses: []
  2366. }),
  2367. smalltalk.Number);
  2368. smalltalk.addMethod(
  2369. unescape('_to_do_'),
  2370. smalltalk.method({
  2371. selector: unescape('to%3Ado%3A'),
  2372. category: 'enumerating',
  2373. fn: function (stop, aBlock){
  2374. var self=this;
  2375. var nextValue=nil;
  2376. nextValue=self;
  2377. (function(){while((function(){return ((($receiver = nextValue).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [nextValue]);return nextValue=((($receiver = nextValue).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})()}})();
  2378. return self;},
  2379. args: ["stop", "aBlock"],
  2380. source: unescape('to%3A%20stop%20do%3A%20aBlock%0A%09%22Evaluate%20aBlock%20for%20each%20number%20from%20self%20to%20aNumber.%22%0A%09%7C%20nextValue%20%7C%0A%09nextValue%20%3A%3D%20self.%0A%09%5BnextValue%20%3C%3D%20stop%5D%0A%09%09whileTrue%3A%20%0A%09%09%09%5BaBlock%20value%3A%20nextValue.%0A%09%09%09nextValue%20%3A%3D%20nextValue%20+%201%5D'),
  2381. messageSends: ["whileTrue:", unescape("%3C%3D"), "value:", unescape("+")],
  2382. referencedClasses: []
  2383. }),
  2384. smalltalk.Number);
  2385. smalltalk.addMethod(
  2386. unescape('_asString'),
  2387. smalltalk.method({
  2388. selector: unescape('asString'),
  2389. category: 'converting',
  2390. fn: function (){
  2391. var self=this;
  2392. return smalltalk.send(self, "_printString", []);
  2393. return self;},
  2394. args: [],
  2395. source: unescape('asString%0A%09%5Eself%20printString'),
  2396. messageSends: ["printString"],
  2397. referencedClasses: []
  2398. }),
  2399. smalltalk.Number);
  2400. smalltalk.addMethod(
  2401. unescape('_asJavascript'),
  2402. smalltalk.method({
  2403. selector: unescape('asJavascript'),
  2404. category: 'converting',
  2405. fn: function (){
  2406. var self=this;
  2407. return smalltalk.send(smalltalk.send(unescape("%28"), "__comma", [smalltalk.send(self, "_printString", [])]), "__comma", [unescape("%29")]);
  2408. return self;},
  2409. args: [],
  2410. source: unescape('asJavascript%0A%09%5E%27%28%27%2C%20self%20printString%2C%20%27%29%27'),
  2411. messageSends: [unescape("%2C"), "printString"],
  2412. referencedClasses: []
  2413. }),
  2414. smalltalk.Number);
  2415. smalltalk.addMethod(
  2416. unescape('_printString'),
  2417. smalltalk.method({
  2418. selector: unescape('printString'),
  2419. category: 'printing',
  2420. fn: function (){
  2421. var self=this;
  2422. return String(self);
  2423. return self;},
  2424. args: [],
  2425. source: unescape('printString%0A%09%3Creturn%20String%28self%29%3E'),
  2426. messageSends: [],
  2427. referencedClasses: []
  2428. }),
  2429. smalltalk.Number);
  2430. smalltalk.addMethod(
  2431. unescape('_isNumber'),
  2432. smalltalk.method({
  2433. selector: unescape('isNumber'),
  2434. category: 'testing',
  2435. fn: function (){
  2436. var self=this;
  2437. return true;
  2438. return self;},
  2439. args: [],
  2440. source: unescape('isNumber%0A%09%5Etrue'),
  2441. messageSends: [],
  2442. referencedClasses: []
  2443. }),
  2444. smalltalk.Number);
  2445. smalltalk.addMethod(
  2446. unescape('_atRandom'),
  2447. smalltalk.method({
  2448. selector: unescape('atRandom'),
  2449. category: 'converting',
  2450. fn: function (){
  2451. var self=this;
  2452. return ((($receiver = smalltalk.send(((($receiver = smalltalk.send(smalltalk.send((smalltalk.Random || Random), "_new", []), "_next", [])).klass === smalltalk.Number) ? $receiver *self : smalltalk.send($receiver, "__star", [self])), "_truncated", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));
  2453. return self;},
  2454. args: [],
  2455. source: unescape('atRandom%0A%20%20%20%20%5E%28Random%20new%20next%20*%20self%29%20truncated%20+%201'),
  2456. messageSends: [unescape("+"), "truncated", unescape("*"), "next", "new"],
  2457. referencedClasses: ["Random"]
  2458. }),
  2459. smalltalk.Number);
  2460. smalltalk.addMethod(
  2461. unescape('__at'),
  2462. smalltalk.method({
  2463. selector: unescape('@'),
  2464. category: 'converting',
  2465. fn: function (aNumber){
  2466. var self=this;
  2467. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [self, aNumber]);
  2468. return self;},
  2469. args: ["aNumber"],
  2470. source: unescape('@%20aNumber%0A%09%5EPoint%20x%3A%20self%20y%3A%20aNumber'),
  2471. messageSends: ["x:y:"],
  2472. referencedClasses: ["Point"]
  2473. }),
  2474. smalltalk.Number);
  2475. smalltalk.addMethod(
  2476. unescape('_asPoint'),
  2477. smalltalk.method({
  2478. selector: unescape('asPoint'),
  2479. category: 'converting',
  2480. fn: function (){
  2481. var self=this;
  2482. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [self, self]);
  2483. return self;},
  2484. args: [],
  2485. source: unescape('asPoint%0A%09%5EPoint%20x%3A%20self%20y%3A%20self'),
  2486. messageSends: ["x:y:"],
  2487. referencedClasses: ["Point"]
  2488. }),
  2489. smalltalk.Number);
  2490. smalltalk.addMethod(
  2491. unescape('_clearInterval'),
  2492. smalltalk.method({
  2493. selector: unescape('clearInterval'),
  2494. category: 'timeouts/intervals',
  2495. fn: function (){
  2496. var self=this;
  2497. clearInterval(Number(self));
  2498. return self;},
  2499. args: [],
  2500. source: unescape('clearInterval%0A%09%3CclearInterval%28Number%28self%29%29%3E'),
  2501. messageSends: [],
  2502. referencedClasses: []
  2503. }),
  2504. smalltalk.Number);
  2505. smalltalk.addMethod(
  2506. unescape('_clearTimeout'),
  2507. smalltalk.method({
  2508. selector: unescape('clearTimeout'),
  2509. category: 'timeouts/intervals',
  2510. fn: function (){
  2511. var self=this;
  2512. clearTimeout(Number(self));
  2513. return self;},
  2514. args: [],
  2515. source: unescape('clearTimeout%0A%09%3CclearTimeout%28Number%28self%29%29%3E'),
  2516. messageSends: [],
  2517. referencedClasses: []
  2518. }),
  2519. smalltalk.Number);
  2520. smalltalk.addMethod(
  2521. unescape('_even'),
  2522. smalltalk.method({
  2523. selector: unescape('even'),
  2524. category: 'testing',
  2525. fn: function (){
  2526. var self=this;
  2527. return smalltalk.send((0), "__eq", [smalltalk.send(self, "_\\\\", [(2)])]);
  2528. return self;},
  2529. args: [],
  2530. source: unescape('even%0A%09%5E%200%20%3D%20%28self%20%5C%5C%202%29'),
  2531. messageSends: [unescape("%3D"), unescape("%5C%5C%5C%5C")],
  2532. referencedClasses: []
  2533. }),
  2534. smalltalk.Number);
  2535. smalltalk.addMethod(
  2536. unescape('_odd'),
  2537. smalltalk.method({
  2538. selector: unescape('odd'),
  2539. category: 'testing',
  2540. fn: function (){
  2541. var self=this;
  2542. return smalltalk.send(smalltalk.send(self, "_even", []), "_not", []);
  2543. return self;},
  2544. args: [],
  2545. source: unescape('odd%0A%09%5E%20self%20even%20not'),
  2546. messageSends: ["not", "even"],
  2547. referencedClasses: []
  2548. }),
  2549. smalltalk.Number);
  2550. smalltalk.addMethod(
  2551. unescape('_negated'),
  2552. smalltalk.method({
  2553. selector: unescape('negated'),
  2554. category: 'arithmetic',
  2555. fn: function (){
  2556. var self=this;
  2557. return (0) - self;
  2558. return self;},
  2559. args: [],
  2560. source: unescape('negated%0A%09%5E0%20-%20self'),
  2561. messageSends: [unescape("-")],
  2562. referencedClasses: []
  2563. }),
  2564. smalltalk.Number);
  2565. smalltalk.addMethod(
  2566. unescape('__eq_eq'),
  2567. smalltalk.method({
  2568. selector: unescape('%3D%3D'),
  2569. category: 'comparing',
  2570. fn: function (aNumber){
  2571. var self=this;
  2572. try{((($receiver = smalltalk.send(smalltalk.send(aNumber, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  2573. return Number(self) === Number(aNumber);
  2574. return self;
  2575. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  2576. args: ["aNumber"],
  2577. source: unescape('%3D%3D%20aNumber%0A%09aNumber%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%20%0A%09%3Creturn%20Number%28self%29%20%3D%3D%3D%20Number%28aNumber%29%3E'),
  2578. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  2579. referencedClasses: []
  2580. }),
  2581. smalltalk.Number);
  2582. smalltalk.addMethod(
  2583. unescape('_printShowingDecimalPlaces_'),
  2584. smalltalk.method({
  2585. selector: unescape('printShowingDecimalPlaces%3A'),
  2586. category: 'printing',
  2587. fn: function (placesDesired){
  2588. var self=this;
  2589. return self.toFixed(placesDesired);
  2590. return self;},
  2591. args: ["placesDesired"],
  2592. source: unescape('printShowingDecimalPlaces%3A%20placesDesired%0A%09%3Creturn%20self.toFixed%28placesDesired%29%3E'),
  2593. messageSends: [],
  2594. referencedClasses: []
  2595. }),
  2596. smalltalk.Number);
  2597. smalltalk.addMethod(
  2598. unescape('_%5C'),
  2599. smalltalk.method({
  2600. selector: unescape('%5C'),
  2601. category: '',
  2602. fn: function (aNumber){
  2603. var self=this;
  2604. return self % aNumber;
  2605. return self;},
  2606. args: ["aNumber"],
  2607. source: unescape(''),
  2608. messageSends: [],
  2609. referencedClasses: []
  2610. }),
  2611. smalltalk.Number);
  2612. smalltalk.addMethod(
  2613. unescape('_to_by_'),
  2614. smalltalk.method({
  2615. selector: unescape('to%3Aby%3A'),
  2616. category: 'converting',
  2617. fn: function (stop, step){
  2618. var self=this;
  2619. var array=nil;
  2620. var value=nil;
  2621. var pos=nil;
  2622. value=self;
  2623. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  2624. pos=(1);
  2625. ((($receiver = smalltalk.send(step, "__eq", [(0)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})]));
  2626. ((($receiver = ((($receiver = step).klass === smalltalk.Number) ? $receiver <(0) : smalltalk.send($receiver, "__lt", [(0)]))).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})() : (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();}), (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})]));
  2627. return array;
  2628. return self;},
  2629. args: ["stop", "step"],
  2630. source: unescape('to%3A%20stop%20by%3A%20step%0A%09%7C%20array%20value%20pos%20%7C%0A%09value%20%3A%3D%20self.%0A%09array%20%3A%3D%20Array%20new.%0A%09pos%20%3A%3D%201.%0A%09step%20%3D%200%20ifTrue%3A%20%5Bself%20error%3A%20%27step%20must%20be%20non-zero%27%5D.%0A%09step%20%3C%200%0A%09%09ifTrue%3A%20%5B%5B%20value%20%3E%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09array%20at%3A%20pos%20put%3A%20value.%0A%09%20%20%20%20%09%09%09pos%20%3A%3D%20pos%20+%201.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D%0A%09%09ifFalse%3A%20%5B%5B%20value%20%3C%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09array%20at%3A%20pos%20put%3A%20value.%0A%09%20%20%09%09%09pos%20%3A%3D%20pos%20+%201.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D.%0A%09%5Earray'),
  2631. messageSends: ["new", "ifTrue:", unescape("%3D"), "error:", "ifTrue:ifFalse:", unescape("%3C"), "whileTrue:", unescape("%3E%3D"), "at:put:", unescape("+"), unescape("%3C%3D")],
  2632. referencedClasses: ["Array"]
  2633. }),
  2634. smalltalk.Number);
  2635. smalltalk.addMethod(
  2636. unescape('_to_by_do_'),
  2637. smalltalk.method({
  2638. selector: unescape('to%3Aby%3Ado%3A'),
  2639. category: 'enumerating',
  2640. fn: function (stop, step, aBlock){
  2641. var self=this;
  2642. var value=nil;
  2643. value=self;
  2644. ((($receiver = smalltalk.send(step, "__eq", [(0)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})]));
  2645. ((($receiver = ((($receiver = step).klass === smalltalk.Number) ? $receiver <(0) : smalltalk.send($receiver, "__lt", [(0)]))).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})() : (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();}), (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})]));
  2646. return self;},
  2647. args: ["stop", "step", "aBlock"],
  2648. source: unescape('to%3A%20stop%20by%3A%20step%20do%3A%20aBlock%0A%09%7C%20value%20%7C%0A%09value%20%3A%3D%20self.%0A%09step%20%3D%200%20ifTrue%3A%20%5Bself%20error%3A%20%27step%20must%20be%20non-zero%27%5D.%0A%09step%20%3C%200%0A%09%09ifTrue%3A%20%5B%5B%20value%20%3E%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09aBlock%20value%3A%20value.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D%0A%09%09ifFalse%3A%20%5B%5B%20value%20%3C%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09aBlock%20value%3A%20value.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D'),
  2649. messageSends: ["ifTrue:", unescape("%3D"), "error:", "ifTrue:ifFalse:", unescape("%3C"), "whileTrue:", unescape("%3E%3D"), "value:", unescape("+"), unescape("%3C%3D")],
  2650. referencedClasses: []
  2651. }),
  2652. smalltalk.Number);
  2653. smalltalk.addMethod(
  2654. unescape('_deepCopy'),
  2655. smalltalk.method({
  2656. selector: unescape('deepCopy'),
  2657. category: 'copying',
  2658. fn: function (){
  2659. var self=this;
  2660. return smalltalk.send(self, "_copy", []);
  2661. return self;},
  2662. args: [],
  2663. source: unescape('deepCopy%0A%09%5Eself%20copy'),
  2664. messageSends: ["copy"],
  2665. referencedClasses: []
  2666. }),
  2667. smalltalk.Number);
  2668. smalltalk.addMethod(
  2669. unescape('_copy'),
  2670. smalltalk.method({
  2671. selector: unescape('copy'),
  2672. category: 'copying',
  2673. fn: function (){
  2674. var self=this;
  2675. return self;
  2676. return self;},
  2677. args: [],
  2678. source: unescape('copy%0A%09%5Eself'),
  2679. messageSends: [],
  2680. referencedClasses: []
  2681. }),
  2682. smalltalk.Number);
  2683. smalltalk.addMethod(
  2684. unescape('_%5C%5C'),
  2685. smalltalk.method({
  2686. selector: unescape('%5C%5C'),
  2687. category: 'arithmetic',
  2688. fn: function (aNumber){
  2689. var self=this;
  2690. return self % aNumber;
  2691. return self;},
  2692. args: ["aNumber"],
  2693. source: unescape('%5C%5C%20aNumber%0A%09%3Creturn%20self%20%25%20aNumber%3E'),
  2694. messageSends: [],
  2695. referencedClasses: []
  2696. }),
  2697. smalltalk.Number);
  2698. smalltalk.addMethod(
  2699. unescape('_sqrt'),
  2700. smalltalk.method({
  2701. selector: unescape('sqrt'),
  2702. category: 'arithmetic',
  2703. fn: function (){
  2704. var self=this;
  2705. return Math.sqrt(self);
  2706. return self;},
  2707. args: [],
  2708. source: unescape('sqrt%0A%09%3Creturn%20Math.sqrt%28self%29%3E'),
  2709. messageSends: [],
  2710. referencedClasses: []
  2711. }),
  2712. smalltalk.Number);
  2713. smalltalk.addMethod(
  2714. unescape('_squared'),
  2715. smalltalk.method({
  2716. selector: unescape('squared'),
  2717. category: 'arithmetic',
  2718. fn: function (){
  2719. var self=this;
  2720. return self * self;
  2721. return self;},
  2722. args: [],
  2723. source: unescape('squared%0A%09%5Eself%20*%20self'),
  2724. messageSends: [unescape("*")],
  2725. referencedClasses: []
  2726. }),
  2727. smalltalk.Number);
  2728. smalltalk.addMethod(
  2729. unescape('_pi'),
  2730. smalltalk.method({
  2731. selector: unescape('pi'),
  2732. category: 'instance creation',
  2733. fn: function (){
  2734. var self=this;
  2735. return Math.PI;
  2736. return self;},
  2737. args: [],
  2738. source: unescape('pi%0A%09%3Creturn%20Math.PI%3E'),
  2739. messageSends: [],
  2740. referencedClasses: []
  2741. }),
  2742. smalltalk.Number.klass);
  2743. smalltalk.addClass('BlockClosure', smalltalk.Object, [], 'Kernel');
  2744. smalltalk.addMethod(
  2745. unescape('_compiledSource'),
  2746. smalltalk.method({
  2747. selector: unescape('compiledSource'),
  2748. category: 'accessing',
  2749. fn: function (){
  2750. var self=this;
  2751. return self.toString();
  2752. return self;},
  2753. args: [],
  2754. source: unescape('compiledSource%0A%09%3Creturn%20self.toString%28%29%3E'),
  2755. messageSends: [],
  2756. referencedClasses: []
  2757. }),
  2758. smalltalk.BlockClosure);
  2759. smalltalk.addMethod(
  2760. unescape('_whileTrue_'),
  2761. smalltalk.method({
  2762. selector: unescape('whileTrue%3A'),
  2763. category: 'controlling',
  2764. fn: function (aBlock){
  2765. var self=this;
  2766. while(self()) {aBlock()};
  2767. return self;},
  2768. args: ["aBlock"],
  2769. source: unescape('whileTrue%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Cwhile%28self%28%29%29%20%7BaBlock%28%29%7D%3E'),
  2770. messageSends: [],
  2771. referencedClasses: []
  2772. }),
  2773. smalltalk.BlockClosure);
  2774. smalltalk.addMethod(
  2775. unescape('_whileFalse_'),
  2776. smalltalk.method({
  2777. selector: unescape('whileFalse%3A'),
  2778. category: 'controlling',
  2779. fn: function (aBlock){
  2780. var self=this;
  2781. while(!self()) {aBlock()};
  2782. return self;},
  2783. args: ["aBlock"],
  2784. source: unescape('whileFalse%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Cwhile%28%21self%28%29%29%20%7BaBlock%28%29%7D%3E'),
  2785. messageSends: [],
  2786. referencedClasses: []
  2787. }),
  2788. smalltalk.BlockClosure);
  2789. smalltalk.addMethod(
  2790. unescape('_value'),
  2791. smalltalk.method({
  2792. selector: unescape('value'),
  2793. category: 'evaluating',
  2794. fn: function (){
  2795. var self=this;
  2796. return self();;
  2797. return self;},
  2798. args: [],
  2799. source: unescape('value%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28%29%3B%3E'),
  2800. messageSends: [],
  2801. referencedClasses: []
  2802. }),
  2803. smalltalk.BlockClosure);
  2804. smalltalk.addMethod(
  2805. unescape('_value_'),
  2806. smalltalk.method({
  2807. selector: unescape('value%3A'),
  2808. category: 'evaluating',
  2809. fn: function (anArg){
  2810. var self=this;
  2811. return self(anArg);;
  2812. return self;},
  2813. args: ["anArg"],
  2814. source: unescape('value%3A%20anArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28anArg%29%3B%3E'),
  2815. messageSends: [],
  2816. referencedClasses: []
  2817. }),
  2818. smalltalk.BlockClosure);
  2819. smalltalk.addMethod(
  2820. unescape('_value_value_'),
  2821. smalltalk.method({
  2822. selector: unescape('value%3Avalue%3A'),
  2823. category: 'evaluating',
  2824. fn: function (firstArg, secondArg){
  2825. var self=this;
  2826. return self(firstArg, secondArg);;
  2827. return self;},
  2828. args: ["firstArg", "secondArg"],
  2829. source: unescape('value%3A%20firstArg%20value%3A%20secondArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28firstArg%2C%20secondArg%29%3B%3E'),
  2830. messageSends: [],
  2831. referencedClasses: []
  2832. }),
  2833. smalltalk.BlockClosure);
  2834. smalltalk.addMethod(
  2835. unescape('_value_value_value_'),
  2836. smalltalk.method({
  2837. selector: unescape('value%3Avalue%3Avalue%3A'),
  2838. category: 'evaluating',
  2839. fn: function (firstArg, secondArg, thirdArg){
  2840. var self=this;
  2841. return self(firstArg, secondArg, thirdArg);;
  2842. return self;},
  2843. args: ["firstArg", "secondArg", "thirdArg"],
  2844. source: unescape('value%3A%20firstArg%20value%3A%20secondArg%20value%3A%20thirdArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28firstArg%2C%20secondArg%2C%20thirdArg%29%3B%3E'),
  2845. messageSends: [],
  2846. referencedClasses: []
  2847. }),
  2848. smalltalk.BlockClosure);
  2849. smalltalk.addMethod(
  2850. unescape('_valueWithPossibleArguments_'),
  2851. smalltalk.method({
  2852. selector: unescape('valueWithPossibleArguments%3A'),
  2853. category: 'evaluating',
  2854. fn: function (aCollection){
  2855. var self=this;
  2856. return self.apply(null, aCollection);;
  2857. return self;},
  2858. args: ["aCollection"],
  2859. source: unescape('valueWithPossibleArguments%3A%20aCollection%0A%09%3Creturn%20self.apply%28null%2C%20aCollection%29%3B%3E'),
  2860. messageSends: [],
  2861. referencedClasses: []
  2862. }),
  2863. smalltalk.BlockClosure);
  2864. smalltalk.addMethod(
  2865. unescape('_on_do_'),
  2866. smalltalk.method({
  2867. selector: unescape('on%3Ado%3A'),
  2868. category: 'error handling',
  2869. fn: function (anErrorClass, aBlock){
  2870. var self=this;
  2871. smalltalk.send(self, "_try_catch_", [self, (function(error){return ((($receiver = smalltalk.send(error, "_isKindOf_", [anErrorClass])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(aBlock, "_value_", [error]);})() : (function(){return smalltalk.send(error, "_signal", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(aBlock, "_value_", [error]);}), (function(){return smalltalk.send(error, "_signal", []);})]));})]);
  2872. return self;},
  2873. args: ["anErrorClass", "aBlock"],
  2874. source: unescape('on%3A%20anErrorClass%20do%3A%20aBlock%0A%09self%20try%3A%20self%20catch%3A%20%5B%3Aerror%20%7C%0A%09%20%20%20%20%28error%20isKindOf%3A%20anErrorClass%29%20%0A%09%20%20%20%20%20ifTrue%3A%20%5BaBlock%20value%3A%20error%5D%0A%09%20%20%20%20%20ifFalse%3A%20%5Berror%20signal%5D%5D'),
  2875. messageSends: ["try:catch:", "ifTrue:ifFalse:", "isKindOf:", "value:", "signal"],
  2876. referencedClasses: []
  2877. }),
  2878. smalltalk.BlockClosure);
  2879. smalltalk.addMethod(
  2880. unescape('_valueWithTimeout_'),
  2881. smalltalk.method({
  2882. selector: unescape('valueWithTimeout%3A'),
  2883. category: 'timeout/interval',
  2884. fn: function (aNumber){
  2885. var self=this;
  2886. return setTimeout(self, aNumber);
  2887. return self;},
  2888. args: ["aNumber"],
  2889. source: unescape('valueWithTimeout%3A%20aNumber%0A%09%3Creturn%20setTimeout%28self%2C%20aNumber%29%3E'),
  2890. messageSends: [],
  2891. referencedClasses: []
  2892. }),
  2893. smalltalk.BlockClosure);
  2894. smalltalk.addMethod(
  2895. unescape('_valueWithInterval_'),
  2896. smalltalk.method({
  2897. selector: unescape('valueWithInterval%3A'),
  2898. category: 'timeout/interval',
  2899. fn: function (aNumber){
  2900. var self=this;
  2901. return setInterval(self, aNumber);
  2902. return self;},
  2903. args: ["aNumber"],
  2904. source: unescape('valueWithInterval%3A%20aNumber%0A%09%3Creturn%20setInterval%28self%2C%20aNumber%29%3E'),
  2905. messageSends: [],
  2906. referencedClasses: []
  2907. }),
  2908. smalltalk.BlockClosure);
  2909. smalltalk.addMethod(
  2910. unescape('_whileFalse'),
  2911. smalltalk.method({
  2912. selector: unescape('whileFalse'),
  2913. category: 'controlling',
  2914. fn: function (){
  2915. var self=this;
  2916. smalltalk.send(self, "_whileFalse_", [(function(){return nil;})]);
  2917. return self;},
  2918. args: [],
  2919. source: unescape('whileFalse%0A%09%22inlined%20in%20the%20Compiler%22%0A%09self%20whileFalse%3A%20%5B%5D'),
  2920. messageSends: ["whileFalse:"],
  2921. referencedClasses: []
  2922. }),
  2923. smalltalk.BlockClosure);
  2924. smalltalk.addMethod(
  2925. unescape('_whileTrue'),
  2926. smalltalk.method({
  2927. selector: unescape('whileTrue'),
  2928. category: 'controlling',
  2929. fn: function (){
  2930. var self=this;
  2931. smalltalk.send(self, "_whileTrue_", [(function(){return nil;})]);
  2932. return self;},
  2933. args: [],
  2934. source: unescape('whileTrue%0A%09%22inlined%20in%20the%20Compiler%22%0A%09self%20whileTrue%3A%20%5B%5D'),
  2935. messageSends: ["whileTrue:"],
  2936. referencedClasses: []
  2937. }),
  2938. smalltalk.BlockClosure);
  2939. smalltalk.addMethod(
  2940. unescape('_new'),
  2941. smalltalk.method({
  2942. selector: unescape('new'),
  2943. category: 'evaluating',
  2944. fn: function (){
  2945. var self=this;
  2946. return new self();
  2947. return self;},
  2948. args: [],
  2949. source: unescape('new%0A%09%22Use%20the%20receiver%20as%20a%20JS%20constructor.%20%0A%09*Do%20not*%20use%20this%20method%20to%20instanciate%20Smalltalk%20objects%21%22%0A%09%3Creturn%20new%20self%28%29%3E'),
  2950. messageSends: [],
  2951. referencedClasses: []
  2952. }),
  2953. smalltalk.BlockClosure);
  2954. smalltalk.addMethod(
  2955. unescape('_applyTo_arguments_'),
  2956. smalltalk.method({
  2957. selector: unescape('applyTo%3Aarguments%3A'),
  2958. category: 'evaluating',
  2959. fn: function (anObject, aCollection){
  2960. var self=this;
  2961. return self.apply(anObject, aCollection);
  2962. return self;},
  2963. args: ["anObject", "aCollection"],
  2964. source: unescape('applyTo%3A%20anObject%20arguments%3A%20aCollection%0A%09%3Creturn%20self.apply%28anObject%2C%20aCollection%29%3E'),
  2965. messageSends: [],
  2966. referencedClasses: []
  2967. }),
  2968. smalltalk.BlockClosure);
  2969. smalltalk.addMethod(
  2970. unescape('_timeToRun'),
  2971. smalltalk.method({
  2972. selector: unescape('timeToRun'),
  2973. category: 'evaluating',
  2974. fn: function (){
  2975. var self=this;
  2976. return smalltalk.send((smalltalk.Date || Date), "_millisecondsToRun_", [self]);
  2977. return self;},
  2978. args: [],
  2979. source: unescape('timeToRun%0A%09%22Answer%20the%20number%20of%20milliseconds%20taken%20to%20execute%20this%20block.%22%0A%0A%09%5E%20Date%20millisecondsToRun%3A%20self'),
  2980. messageSends: ["millisecondsToRun:"],
  2981. referencedClasses: ["Date"]
  2982. }),
  2983. smalltalk.BlockClosure);
  2984. smalltalk.addMethod(
  2985. unescape('_numArgs'),
  2986. smalltalk.method({
  2987. selector: unescape('numArgs'),
  2988. category: 'accessing',
  2989. fn: function (){
  2990. var self=this;
  2991. return self.length;
  2992. return self;},
  2993. args: [],
  2994. source: unescape('numArgs%0A%09%3Creturn%20self.length%3E'),
  2995. messageSends: [],
  2996. referencedClasses: []
  2997. }),
  2998. smalltalk.BlockClosure);
  2999. smalltalk.addMethod(
  3000. unescape('_ensure_'),
  3001. smalltalk.method({
  3002. selector: unescape('ensure%3A'),
  3003. category: 'evaluating',
  3004. fn: function (aBlock){
  3005. var self=this;
  3006. var success=nil;
  3007. success=false;
  3008. smalltalk.send((function(){smalltalk.send(self, "_value", []);success=true;return smalltalk.send(aBlock, "_value", []);}), "_on_do_", [(smalltalk.Error || Error), (function(ex){((($receiver = success).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(aBlock, "_value", []);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(aBlock, "_value", []);})]));return smalltalk.send(ex, "_signal", []);})]);
  3009. return self;},
  3010. args: ["aBlock"],
  3011. source: unescape('ensure%3A%20aBlock%0A%09%7C%20success%20%7C%0A%09success%20%3A%3D%20false.%0A%09%5Bself%20value.%20success%20%3A%3D%20true.%20aBlock%20value%5D%0A%09%09on%3A%20Error%0A%09%09do%3A%20%5B%3Aex%20%7C%0A%09%09%09success%20ifFalse%3A%20%5BaBlock%20value%5D.%0A%09%09%09ex%20signal%5D'),
  3012. messageSends: ["on:do:", "value", "ifFalse:", "signal"],
  3013. referencedClasses: ["Error"]
  3014. }),
  3015. smalltalk.BlockClosure);
  3016. smalltalk.addClass('Boolean', smalltalk.Object, [], 'Kernel');
  3017. smalltalk.addMethod(
  3018. unescape('__eq'),
  3019. smalltalk.method({
  3020. selector: unescape('%3D'),
  3021. category: 'comparing',
  3022. fn: function (aBoolean){
  3023. var self=this;
  3024. try{((($receiver = smalltalk.send(smalltalk.send(aBoolean, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  3025. return Boolean(self == true) == aBoolean;
  3026. return self;
  3027. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  3028. args: ["aBoolean"],
  3029. source: unescape('%3D%20aBoolean%0A%09aBoolean%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20Boolean%28self%20%3D%3D%20true%29%20%3D%3D%20aBoolean%3E'),
  3030. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  3031. referencedClasses: []
  3032. }),
  3033. smalltalk.Boolean);
  3034. smalltalk.addMethod(
  3035. unescape('_shallowCopy'),
  3036. smalltalk.method({
  3037. selector: unescape('shallowCopy'),
  3038. category: 'copying',
  3039. fn: function (){
  3040. var self=this;
  3041. return self;
  3042. return self;},
  3043. args: [],
  3044. source: unescape('shallowCopy%0A%09%5Eself'),
  3045. messageSends: [],
  3046. referencedClasses: []
  3047. }),
  3048. smalltalk.Boolean);
  3049. smalltalk.addMethod(
  3050. unescape('_deepCopy'),
  3051. smalltalk.method({
  3052. selector: unescape('deepCopy'),
  3053. category: 'copying',
  3054. fn: function (){
  3055. var self=this;
  3056. return self;
  3057. return self;},
  3058. args: [],
  3059. source: unescape('deepCopy%0A%09%5Eself'),
  3060. messageSends: [],
  3061. referencedClasses: []
  3062. }),
  3063. smalltalk.Boolean);
  3064. smalltalk.addMethod(
  3065. unescape('_ifTrue_'),
  3066. smalltalk.method({
  3067. selector: unescape('ifTrue%3A'),
  3068. category: 'controlling',
  3069. fn: function (aBlock){
  3070. var self=this;
  3071. return smalltalk.send(self, "_ifTrue_ifFalse_", [aBlock, (function(){return nil;})]);
  3072. return self;},
  3073. args: ["aBlock"],
  3074. source: unescape('ifTrue%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20aBlock%20ifFalse%3A%20%5B%5D'),
  3075. messageSends: ["ifTrue:ifFalse:"],
  3076. referencedClasses: []
  3077. }),
  3078. smalltalk.Boolean);
  3079. smalltalk.addMethod(
  3080. unescape('_ifFalse_'),
  3081. smalltalk.method({
  3082. selector: unescape('ifFalse%3A'),
  3083. category: 'controlling',
  3084. fn: function (aBlock){
  3085. var self=this;
  3086. return smalltalk.send(self, "_ifTrue_ifFalse_", [(function(){return nil;}), aBlock]);
  3087. return self;},
  3088. args: ["aBlock"],
  3089. source: unescape('ifFalse%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20%5B%5D%20ifFalse%3A%20aBlock'),
  3090. messageSends: ["ifTrue:ifFalse:"],
  3091. referencedClasses: []
  3092. }),
  3093. smalltalk.Boolean);
  3094. smalltalk.addMethod(
  3095. unescape('_ifFalse_ifTrue_'),
  3096. smalltalk.method({
  3097. selector: unescape('ifFalse%3AifTrue%3A'),
  3098. category: 'controlling',
  3099. fn: function (aBlock, anotherBlock){
  3100. var self=this;
  3101. return smalltalk.send(self, "_ifTrue_ifFalse_", [anotherBlock, aBlock]);
  3102. return self;},
  3103. args: ["aBlock", "anotherBlock"],
  3104. source: unescape('ifFalse%3A%20aBlock%20ifTrue%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20anotherBlock%20ifFalse%3A%20aBlock'),
  3105. messageSends: ["ifTrue:ifFalse:"],
  3106. referencedClasses: []
  3107. }),
  3108. smalltalk.Boolean);
  3109. smalltalk.addMethod(
  3110. unescape('_ifTrue_ifFalse_'),
  3111. smalltalk.method({
  3112. selector: unescape('ifTrue%3AifFalse%3A'),
  3113. category: 'controlling',
  3114. fn: function (aBlock, anotherBlock){
  3115. var self=this;
  3116. if(self == true) {
  3117. return aBlock();
  3118. } else {
  3119. return anotherBlock();
  3120. }
  3121. ;
  3122. return self;},
  3123. args: ["aBlock", "anotherBlock"],
  3124. source: unescape('ifTrue%3A%20aBlock%20ifFalse%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20aBlock%28%29%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20anotherBlock%28%29%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3125. messageSends: [],
  3126. referencedClasses: []
  3127. }),
  3128. smalltalk.Boolean);
  3129. smalltalk.addMethod(
  3130. unescape('_and_'),
  3131. smalltalk.method({
  3132. selector: unescape('and%3A'),
  3133. category: 'controlling',
  3134. fn: function (aBlock){
  3135. var self=this;
  3136. return smalltalk.send(smalltalk.send(self, "__eq", [true]), "_ifTrue_ifFalse_", [aBlock, (function(){return false;})]);
  3137. return self;},
  3138. args: ["aBlock"],
  3139. source: unescape('and%3A%20aBlock%0A%09%5Eself%20%3D%20true%0A%09%20%20%20%20ifTrue%3A%20aBlock%0A%09%20%20%20%20ifFalse%3A%20%5Bfalse%5D'),
  3140. messageSends: ["ifTrue:ifFalse:", unescape("%3D")],
  3141. referencedClasses: []
  3142. }),
  3143. smalltalk.Boolean);
  3144. smalltalk.addMethod(
  3145. unescape('_or_'),
  3146. smalltalk.method({
  3147. selector: unescape('or%3A'),
  3148. category: 'controlling',
  3149. fn: function (aBlock){
  3150. var self=this;
  3151. return smalltalk.send(smalltalk.send(self, "__eq", [true]), "_ifTrue_ifFalse_", [(function(){return true;}), aBlock]);
  3152. return self;},
  3153. args: ["aBlock"],
  3154. source: unescape('or%3A%20aBlock%0A%09%5Eself%20%3D%20true%0A%09%20%20%20%20ifTrue%3A%20%5Btrue%5D%0A%09%20%20%20%20ifFalse%3A%20aBlock'),
  3155. messageSends: ["ifTrue:ifFalse:", unescape("%3D")],
  3156. referencedClasses: []
  3157. }),
  3158. smalltalk.Boolean);
  3159. smalltalk.addMethod(
  3160. unescape('_not'),
  3161. smalltalk.method({
  3162. selector: unescape('not'),
  3163. category: 'controlling',
  3164. fn: function (){
  3165. var self=this;
  3166. return smalltalk.send(self, "__eq", [false]);
  3167. return self;},
  3168. args: [],
  3169. source: unescape('not%0A%09%5Eself%20%3D%20false'),
  3170. messageSends: [unescape("%3D")],
  3171. referencedClasses: []
  3172. }),
  3173. smalltalk.Boolean);
  3174. smalltalk.addMethod(
  3175. unescape('_printString'),
  3176. smalltalk.method({
  3177. selector: unescape('printString'),
  3178. category: 'printing',
  3179. fn: function (){
  3180. var self=this;
  3181. return self.toString();
  3182. return self;},
  3183. args: [],
  3184. source: unescape('printString%0A%09%3Creturn%20self.toString%28%29%3E'),
  3185. messageSends: [],
  3186. referencedClasses: []
  3187. }),
  3188. smalltalk.Boolean);
  3189. smalltalk.addMethod(
  3190. unescape('_%26'),
  3191. smalltalk.method({
  3192. selector: unescape('%26'),
  3193. category: 'controlling',
  3194. fn: function (aBoolean){
  3195. var self=this;
  3196. if(self == true) {
  3197. return aBoolean;
  3198. } else {
  3199. return false;
  3200. }
  3201. ;
  3202. return self;},
  3203. args: ["aBoolean"],
  3204. source: unescape('%26%20aBoolean%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20aBoolean%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20false%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3205. messageSends: [],
  3206. referencedClasses: []
  3207. }),
  3208. smalltalk.Boolean);
  3209. smalltalk.addMethod(
  3210. unescape('_%7C'),
  3211. smalltalk.method({
  3212. selector: unescape('%7C'),
  3213. category: 'controlling',
  3214. fn: function (aBoolean){
  3215. var self=this;
  3216. if(self == true) {
  3217. return true;
  3218. } else {
  3219. return aBoolean;
  3220. }
  3221. ;
  3222. return self;},
  3223. args: ["aBoolean"],
  3224. source: unescape('%7C%20aBoolean%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20true%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20aBoolean%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3225. messageSends: [],
  3226. referencedClasses: []
  3227. }),
  3228. smalltalk.Boolean);
  3229. smalltalk.addMethod(
  3230. unescape('__eq_eq'),
  3231. smalltalk.method({
  3232. selector: unescape('%3D%3D'),
  3233. category: 'comparing',
  3234. fn: function (aBoolean){
  3235. var self=this;
  3236. try{((($receiver = smalltalk.send(smalltalk.send(aBoolean, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  3237. return Boolean(self == true) === Boolean(aBoolean == true);
  3238. return self;
  3239. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  3240. args: ["aBoolean"],
  3241. source: unescape('%3D%3D%20aBoolean%0A%09aBoolean%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20Boolean%28self%20%3D%3D%20true%29%20%3D%3D%3D%20Boolean%28aBoolean%20%3D%3D%20true%29%3E'),
  3242. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  3243. referencedClasses: []
  3244. }),
  3245. smalltalk.Boolean);
  3246. smalltalk.addClass('Date', smalltalk.Object, [], 'Kernel');
  3247. smalltalk.Date.comment=unescape('The%20Date%20class%20is%20used%20to%20work%20with%20dates%20and%20times.')
  3248. smalltalk.addMethod(
  3249. unescape('_year'),
  3250. smalltalk.method({
  3251. selector: unescape('year'),
  3252. category: 'accessing',
  3253. fn: function (){
  3254. var self=this;
  3255. return self.getFullYear();
  3256. return self;},
  3257. args: [],
  3258. source: unescape('year%0A%09%3Creturn%20self.getFullYear%28%29%3E'),
  3259. messageSends: [],
  3260. referencedClasses: []
  3261. }),
  3262. smalltalk.Date);
  3263. smalltalk.addMethod(
  3264. unescape('_month'),
  3265. smalltalk.method({
  3266. selector: unescape('month'),
  3267. category: 'accessing',
  3268. fn: function (){
  3269. var self=this;
  3270. return self.getMonth() + 1;
  3271. return self;},
  3272. args: [],
  3273. source: unescape('month%0A%09%3Creturn%20self.getMonth%28%29%20+%201%3E'),
  3274. messageSends: [],
  3275. referencedClasses: []
  3276. }),
  3277. smalltalk.Date);
  3278. smalltalk.addMethod(
  3279. unescape('_month_'),
  3280. smalltalk.method({
  3281. selector: unescape('month%3A'),
  3282. category: 'accessing',
  3283. fn: function (aNumber){
  3284. var self=this;
  3285. self.setMonth(aNumber - 1);
  3286. return self;},
  3287. args: ["aNumber"],
  3288. source: unescape('month%3A%20aNumber%0A%09%3Cself.setMonth%28aNumber%20-%201%29%3E'),
  3289. messageSends: [],
  3290. referencedClasses: []
  3291. }),
  3292. smalltalk.Date);
  3293. smalltalk.addMethod(
  3294. unescape('_day'),
  3295. smalltalk.method({
  3296. selector: unescape('day'),
  3297. category: 'accessing',
  3298. fn: function (){
  3299. var self=this;
  3300. return smalltalk.send(self, "_dayOfWeek", []);
  3301. return self;},
  3302. args: [],
  3303. source: unescape('day%0A%09%5Eself%20dayOfWeek'),
  3304. messageSends: ["dayOfWeek"],
  3305. referencedClasses: []
  3306. }),
  3307. smalltalk.Date);
  3308. smalltalk.addMethod(
  3309. unescape('_dayOfWeek'),
  3310. smalltalk.method({
  3311. selector: unescape('dayOfWeek'),
  3312. category: 'accessing',
  3313. fn: function (){
  3314. var self=this;
  3315. return self.getDay() + 1;
  3316. return self;},
  3317. args: [],
  3318. source: unescape('dayOfWeek%0A%09%3Creturn%20self.getDay%28%29%20+%201%3E'),
  3319. messageSends: [],
  3320. referencedClasses: []
  3321. }),
  3322. smalltalk.Date);
  3323. smalltalk.addMethod(
  3324. unescape('_dayOfWeek_'),
  3325. smalltalk.method({
  3326. selector: unescape('dayOfWeek%3A'),
  3327. category: 'accessing',
  3328. fn: function (aNumber){
  3329. var self=this;
  3330. return self.setDay(aNumber - 1);
  3331. return self;},
  3332. args: ["aNumber"],
  3333. source: unescape('dayOfWeek%3A%20aNumber%0A%09%3Creturn%20self.setDay%28aNumber%20-%201%29%3E'),
  3334. messageSends: [],
  3335. referencedClasses: []
  3336. }),
  3337. smalltalk.Date);
  3338. smalltalk.addMethod(
  3339. unescape('_day_'),
  3340. smalltalk.method({
  3341. selector: unescape('day%3A'),
  3342. category: 'accessing',
  3343. fn: function (aNumber){
  3344. var self=this;
  3345. smalltalk.send(self, "_day_", [aNumber]);
  3346. return self;},
  3347. args: ["aNumber"],
  3348. source: unescape('day%3A%20aNumber%0A%09self%20day%3A%20aNumber'),
  3349. messageSends: ["day:"],
  3350. referencedClasses: []
  3351. }),
  3352. smalltalk.Date);
  3353. smalltalk.addMethod(
  3354. unescape('_year_'),
  3355. smalltalk.method({
  3356. selector: unescape('year%3A'),
  3357. category: 'accessing',
  3358. fn: function (aNumber){
  3359. var self=this;
  3360. self.setFullYear(aNumber);
  3361. return self;},
  3362. args: ["aNumber"],
  3363. source: unescape('year%3A%20aNumber%0A%09%3Cself.setFullYear%28aNumber%29%3E'),
  3364. messageSends: [],
  3365. referencedClasses: []
  3366. }),
  3367. smalltalk.Date);
  3368. smalltalk.addMethod(
  3369. unescape('_dayOfMonth'),
  3370. smalltalk.method({
  3371. selector: unescape('dayOfMonth'),
  3372. category: 'accessing',
  3373. fn: function (){
  3374. var self=this;
  3375. return self.getDate();
  3376. return self;},
  3377. args: [],
  3378. source: unescape('dayOfMonth%0A%09%3Creturn%20self.getDate%28%29%3E'),
  3379. messageSends: [],
  3380. referencedClasses: []
  3381. }),
  3382. smalltalk.Date);
  3383. smalltalk.addMethod(
  3384. unescape('_dayOfMonth_'),
  3385. smalltalk.method({
  3386. selector: unescape('dayOfMonth%3A'),
  3387. category: 'accessing',
  3388. fn: function (aNumber){
  3389. var self=this;
  3390. self.setDate(aNumber);
  3391. return self;},
  3392. args: ["aNumber"],
  3393. source: unescape('dayOfMonth%3A%20aNumber%0A%09%3Cself.setDate%28aNumber%29%3E'),
  3394. messageSends: [],
  3395. referencedClasses: []
  3396. }),
  3397. smalltalk.Date);
  3398. smalltalk.addMethod(
  3399. unescape('_asString'),
  3400. smalltalk.method({
  3401. selector: unescape('asString'),
  3402. category: 'converting',
  3403. fn: function (){
  3404. var self=this;
  3405. return self.toString();
  3406. return self;},
  3407. args: [],
  3408. source: unescape('asString%0A%09%3Creturn%20self.toString%28%29%3E'),
  3409. messageSends: [],
  3410. referencedClasses: []
  3411. }),
  3412. smalltalk.Date);
  3413. smalltalk.addMethod(
  3414. unescape('_printString'),
  3415. smalltalk.method({
  3416. selector: unescape('printString'),
  3417. category: 'printing',
  3418. fn: function (){
  3419. var self=this;
  3420. return smalltalk.send(self, "_asString", []);
  3421. return self;},
  3422. args: [],
  3423. source: unescape('printString%0A%09%5Eself%20asString'),
  3424. messageSends: ["asString"],
  3425. referencedClasses: []
  3426. }),
  3427. smalltalk.Date);
  3428. smalltalk.addMethod(
  3429. unescape('_asMilliseconds'),
  3430. smalltalk.method({
  3431. selector: unescape('asMilliseconds'),
  3432. category: 'converting',
  3433. fn: function (){
  3434. var self=this;
  3435. return smalltalk.send(self, "_time", []);
  3436. return self;},
  3437. args: [],
  3438. source: unescape('asMilliseconds%0A%09%5Eself%20time'),
  3439. messageSends: ["time"],
  3440. referencedClasses: []
  3441. }),
  3442. smalltalk.Date);
  3443. smalltalk.addMethod(
  3444. unescape('_time'),
  3445. smalltalk.method({
  3446. selector: unescape('time'),
  3447. category: 'accessing',
  3448. fn: function (){
  3449. var self=this;
  3450. return self.getTime();
  3451. return self;},
  3452. args: [],
  3453. source: unescape('time%0A%09%3Creturn%20self.getTime%28%29%3E'),
  3454. messageSends: [],
  3455. referencedClasses: []
  3456. }),
  3457. smalltalk.Date);
  3458. smalltalk.addMethod(
  3459. unescape('_time_'),
  3460. smalltalk.method({
  3461. selector: unescape('time%3A'),
  3462. category: 'accessing',
  3463. fn: function (aNumber){
  3464. var self=this;
  3465. self.setTime(aNumber);
  3466. return self;},
  3467. args: ["aNumber"],
  3468. source: unescape('time%3A%20aNumber%0A%09%3Cself.setTime%28aNumber%29%3E'),
  3469. messageSends: [],
  3470. referencedClasses: []
  3471. }),
  3472. smalltalk.Date);
  3473. smalltalk.addMethod(
  3474. unescape('_asDateString'),
  3475. smalltalk.method({
  3476. selector: unescape('asDateString'),
  3477. category: 'converting',
  3478. fn: function (){
  3479. var self=this;
  3480. return self.toDateString();
  3481. return self;},
  3482. args: [],
  3483. source: unescape('asDateString%0A%09%3Creturn%20self.toDateString%28%29%3E'),
  3484. messageSends: [],
  3485. referencedClasses: []
  3486. }),
  3487. smalltalk.Date);
  3488. smalltalk.addMethod(
  3489. unescape('_asTimeString'),
  3490. smalltalk.method({
  3491. selector: unescape('asTimeString'),
  3492. category: 'converting',
  3493. fn: function (){
  3494. var self=this;
  3495. return self.toTimeString();
  3496. return self;},
  3497. args: [],
  3498. source: unescape('asTimeString%0A%09%3Creturn%20self.toTimeString%28%29%3E'),
  3499. messageSends: [],
  3500. referencedClasses: []
  3501. }),
  3502. smalltalk.Date);
  3503. smalltalk.addMethod(
  3504. unescape('_asLocaleString'),
  3505. smalltalk.method({
  3506. selector: unescape('asLocaleString'),
  3507. category: 'converting',
  3508. fn: function (){
  3509. var self=this;
  3510. return self.toLocaleString();
  3511. return self;},
  3512. args: [],
  3513. source: unescape('asLocaleString%0A%09%3Creturn%20self.toLocaleString%28%29%3E'),
  3514. messageSends: [],
  3515. referencedClasses: []
  3516. }),
  3517. smalltalk.Date);
  3518. smalltalk.addMethod(
  3519. unescape('_asNumber'),
  3520. smalltalk.method({
  3521. selector: unescape('asNumber'),
  3522. category: 'converting',
  3523. fn: function (){
  3524. var self=this;
  3525. return smalltalk.send(self, "_asMilliseconds", []);
  3526. return self;},
  3527. args: [],
  3528. source: unescape('asNumber%0A%09%5Eself%20asMilliseconds'),
  3529. messageSends: ["asMilliseconds"],
  3530. referencedClasses: []
  3531. }),
  3532. smalltalk.Date);
  3533. smalltalk.addMethod(
  3534. unescape('_hours_'),
  3535. smalltalk.method({
  3536. selector: unescape('hours%3A'),
  3537. category: 'accessing',
  3538. fn: function (aNumber){
  3539. var self=this;
  3540. self.setHours(aNumber);
  3541. return self;},
  3542. args: ["aNumber"],
  3543. source: unescape('hours%3A%20aNumber%0A%09%3Cself.setHours%28aNumber%29%3E'),
  3544. messageSends: [],
  3545. referencedClasses: []
  3546. }),
  3547. smalltalk.Date);
  3548. smalltalk.addMethod(
  3549. unescape('_minutes_'),
  3550. smalltalk.method({
  3551. selector: unescape('minutes%3A'),
  3552. category: 'accessing',
  3553. fn: function (aNumber){
  3554. var self=this;
  3555. self.setMinutes(aNumber);
  3556. return self;},
  3557. args: ["aNumber"],
  3558. source: unescape('minutes%3A%20aNumber%0A%09%3Cself.setMinutes%28aNumber%29%3E'),
  3559. messageSends: [],
  3560. referencedClasses: []
  3561. }),
  3562. smalltalk.Date);
  3563. smalltalk.addMethod(
  3564. unescape('_seconds_'),
  3565. smalltalk.method({
  3566. selector: unescape('seconds%3A'),
  3567. category: 'accessing',
  3568. fn: function (aNumber){
  3569. var self=this;
  3570. self.setSeconds(aNumber);
  3571. return self;},
  3572. args: ["aNumber"],
  3573. source: unescape('seconds%3A%20aNumber%0A%09%3Cself.setSeconds%28aNumber%29%3E'),
  3574. messageSends: [],
  3575. referencedClasses: []
  3576. }),
  3577. smalltalk.Date);
  3578. smalltalk.addMethod(
  3579. unescape('_milliseconds_'),
  3580. smalltalk.method({
  3581. selector: unescape('milliseconds%3A'),
  3582. category: 'accessing',
  3583. fn: function (aNumber){
  3584. var self=this;
  3585. self.setMilliseconds(aNumber);
  3586. return self;},
  3587. args: ["aNumber"],
  3588. source: unescape('milliseconds%3A%20aNumber%0A%09%3Cself.setMilliseconds%28aNumber%29%3E'),
  3589. messageSends: [],
  3590. referencedClasses: []
  3591. }),
  3592. smalltalk.Date);
  3593. smalltalk.addMethod(
  3594. unescape('_hours'),
  3595. smalltalk.method({
  3596. selector: unescape('hours'),
  3597. category: 'accessing',
  3598. fn: function (){
  3599. var self=this;
  3600. return self.getHours();
  3601. return self;},
  3602. args: [],
  3603. source: unescape('hours%0A%09%3Creturn%20self.getHours%28%29%3E'),
  3604. messageSends: [],
  3605. referencedClasses: []
  3606. }),
  3607. smalltalk.Date);
  3608. smalltalk.addMethod(
  3609. unescape('_minutes'),
  3610. smalltalk.method({
  3611. selector: unescape('minutes'),
  3612. category: 'accessing',
  3613. fn: function (){
  3614. var self=this;
  3615. return self.getMinutes();
  3616. return self;},
  3617. args: [],
  3618. source: unescape('minutes%0A%09%3Creturn%20self.getMinutes%28%29%3E'),
  3619. messageSends: [],
  3620. referencedClasses: []
  3621. }),
  3622. smalltalk.Date);
  3623. smalltalk.addMethod(
  3624. unescape('_seconds'),
  3625. smalltalk.method({
  3626. selector: unescape('seconds'),
  3627. category: 'accessing',
  3628. fn: function (){
  3629. var self=this;
  3630. return self.getSeconds();
  3631. return self;},
  3632. args: [],
  3633. source: unescape('seconds%0A%09%3Creturn%20self.getSeconds%28%29%3E'),
  3634. messageSends: [],
  3635. referencedClasses: []
  3636. }),
  3637. smalltalk.Date);
  3638. smalltalk.addMethod(
  3639. unescape('_milliseconds'),
  3640. smalltalk.method({
  3641. selector: unescape('milliseconds'),
  3642. category: 'accessing',
  3643. fn: function (){
  3644. var self=this;
  3645. return self.getMilliseconds();
  3646. return self;},
  3647. args: [],
  3648. source: unescape('milliseconds%0A%09%3Creturn%20self.getMilliseconds%28%29%3E'),
  3649. messageSends: [],
  3650. referencedClasses: []
  3651. }),
  3652. smalltalk.Date);
  3653. smalltalk.addMethod(
  3654. unescape('__lt'),
  3655. smalltalk.method({
  3656. selector: unescape('%3C'),
  3657. category: 'comparing',
  3658. fn: function (aDate){
  3659. var self=this;
  3660. return self < aDate;
  3661. return self;},
  3662. args: ["aDate"],
  3663. source: unescape('%3C%20aDate%0A%09%3Creturn%20self%20%3C%20aDate%3E'),
  3664. messageSends: [],
  3665. referencedClasses: []
  3666. }),
  3667. smalltalk.Date);
  3668. smalltalk.addMethod(
  3669. unescape('__gt'),
  3670. smalltalk.method({
  3671. selector: unescape('%3E'),
  3672. category: 'comparing',
  3673. fn: function (aDate){
  3674. var self=this;
  3675. return self > aDate;
  3676. return self;},
  3677. args: ["aDate"],
  3678. source: unescape('%3E%20aDate%0A%09%3Creturn%20self%20%3E%3E%20aDate%3E'),
  3679. messageSends: [],
  3680. referencedClasses: []
  3681. }),
  3682. smalltalk.Date);
  3683. smalltalk.addMethod(
  3684. unescape('__lt_eq'),
  3685. smalltalk.method({
  3686. selector: unescape('%3C%3D'),
  3687. category: 'comparing',
  3688. fn: function (aDate){
  3689. var self=this;
  3690. return self <= aDate;
  3691. return self;},
  3692. args: ["aDate"],
  3693. source: unescape('%3C%3D%20aDate%0A%09%3Creturn%20self%20%3C%3D%20aDate%3E'),
  3694. messageSends: [],
  3695. referencedClasses: []
  3696. }),
  3697. smalltalk.Date);
  3698. smalltalk.addMethod(
  3699. unescape('__gt_eq'),
  3700. smalltalk.method({
  3701. selector: unescape('%3E%3D'),
  3702. category: 'comparing',
  3703. fn: function (aDate){
  3704. var self=this;
  3705. return self >= aDate;
  3706. return self;},
  3707. args: ["aDate"],
  3708. source: unescape('%3E%3D%20aDate%0A%09%3Creturn%20self%20%3E%3E%3D%20aDate%3E'),
  3709. messageSends: [],
  3710. referencedClasses: []
  3711. }),
  3712. smalltalk.Date);
  3713. smalltalk.addMethod(
  3714. unescape('__minus'),
  3715. smalltalk.method({
  3716. selector: unescape('-'),
  3717. category: 'arithmetic',
  3718. fn: function (aDate){
  3719. var self=this;
  3720. return self - aDate;
  3721. return self;},
  3722. args: ["aDate"],
  3723. source: unescape('-%20aDate%0A%09%3Creturn%20self%20-%20aDate%3E'),
  3724. messageSends: [],
  3725. referencedClasses: []
  3726. }),
  3727. smalltalk.Date);
  3728. smalltalk.addMethod(
  3729. unescape('__plus'),
  3730. smalltalk.method({
  3731. selector: unescape('+'),
  3732. category: 'arithmetic',
  3733. fn: function (aDate){
  3734. var self=this;
  3735. return self + aDate;
  3736. return self;},
  3737. args: ["aDate"],
  3738. source: unescape('+%20aDate%0A%09%3Creturn%20self%20+%20aDate%3E'),
  3739. messageSends: [],
  3740. referencedClasses: []
  3741. }),
  3742. smalltalk.Date);
  3743. smalltalk.addMethod(
  3744. unescape('_new_'),
  3745. smalltalk.method({
  3746. selector: unescape('new%3A'),
  3747. category: 'instance creation',
  3748. fn: function (anObject){
  3749. var self=this;
  3750. return new Date(anObject);
  3751. return self;},
  3752. args: ["anObject"],
  3753. source: unescape('new%3A%20anObject%0A%09%3Creturn%20new%20Date%28anObject%29%3E'),
  3754. messageSends: [],
  3755. referencedClasses: []
  3756. }),
  3757. smalltalk.Date.klass);
  3758. smalltalk.addMethod(
  3759. unescape('_fromString_'),
  3760. smalltalk.method({
  3761. selector: unescape('fromString%3A'),
  3762. category: 'instance creation',
  3763. fn: function (aString){
  3764. var self=this;
  3765. return smalltalk.send(self, "_new_", [aString]);
  3766. return self;},
  3767. args: ["aString"],
  3768. source: unescape('fromString%3A%20aString%0A%09%22Example%3A%20Date%20fromString%28%272011/04/15%2000%3A00%3A00%27%29%22%0A%09%5Eself%20new%3A%20aString'),
  3769. messageSends: ["new:"],
  3770. referencedClasses: []
  3771. }),
  3772. smalltalk.Date.klass);
  3773. smalltalk.addMethod(
  3774. unescape('_fromSeconds_'),
  3775. smalltalk.method({
  3776. selector: unescape('fromSeconds%3A'),
  3777. category: 'instance creation',
  3778. fn: function (aNumber){
  3779. var self=this;
  3780. return smalltalk.send(self, "_fromMilliseconds_", [((($receiver = aNumber).klass === smalltalk.Number) ? $receiver *(1000) : smalltalk.send($receiver, "__star", [(1000)]))]);
  3781. return self;},
  3782. args: ["aNumber"],
  3783. source: unescape('fromSeconds%3A%20aNumber%0A%09%5Eself%20fromMilliseconds%3A%20aNumber%20*%201000'),
  3784. messageSends: ["fromMilliseconds:", unescape("*")],
  3785. referencedClasses: []
  3786. }),
  3787. smalltalk.Date.klass);
  3788. smalltalk.addMethod(
  3789. unescape('_fromMilliseconds_'),
  3790. smalltalk.method({
  3791. selector: unescape('fromMilliseconds%3A'),
  3792. category: 'instance creation',
  3793. fn: function (aNumber){
  3794. var self=this;
  3795. return smalltalk.send(self, "_new_", [aNumber]);
  3796. return self;},
  3797. args: ["aNumber"],
  3798. source: unescape('fromMilliseconds%3A%20aNumber%0A%09%5Eself%20new%3A%20aNumber'),
  3799. messageSends: ["new:"],
  3800. referencedClasses: []
  3801. }),
  3802. smalltalk.Date.klass);
  3803. smalltalk.addMethod(
  3804. unescape('_today'),
  3805. smalltalk.method({
  3806. selector: unescape('today'),
  3807. category: 'instance creation',
  3808. fn: function (){
  3809. var self=this;
  3810. return smalltalk.send(self, "_new", []);
  3811. return self;},
  3812. args: [],
  3813. source: unescape('today%0A%09%5Eself%20new'),
  3814. messageSends: ["new"],
  3815. referencedClasses: []
  3816. }),
  3817. smalltalk.Date.klass);
  3818. smalltalk.addMethod(
  3819. unescape('_now'),
  3820. smalltalk.method({
  3821. selector: unescape('now'),
  3822. category: 'instance creation',
  3823. fn: function (){
  3824. var self=this;
  3825. return smalltalk.send(self, "_today", []);
  3826. return self;},
  3827. args: [],
  3828. source: unescape('now%0A%09%5Eself%20today'),
  3829. messageSends: ["today"],
  3830. referencedClasses: []
  3831. }),
  3832. smalltalk.Date.klass);
  3833. smalltalk.addMethod(
  3834. unescape('_millisecondsToRun_'),
  3835. smalltalk.method({
  3836. selector: unescape('millisecondsToRun%3A'),
  3837. category: 'instance creation',
  3838. fn: function (aBlock){
  3839. var self=this;
  3840. var t=nil;
  3841. t=smalltalk.send((smalltalk.Date || Date), "_now", []);
  3842. smalltalk.send(aBlock, "_value", []);
  3843. return ((($receiver = smalltalk.send((smalltalk.Date || Date), "_now", [])).klass === smalltalk.Number) ? $receiver -t : smalltalk.send($receiver, "__minus", [t]));
  3844. return self;},
  3845. args: ["aBlock"],
  3846. source: unescape('millisecondsToRun%3A%20aBlock%0A%09%7C%20t%20%7C%0A%09t%20%3A%3D%20Date%20now.%0A%09aBlock%20value.%0A%09%5EDate%20now%20-%20t'),
  3847. messageSends: ["now", "value", unescape("-")],
  3848. referencedClasses: ["Date"]
  3849. }),
  3850. smalltalk.Date.klass);
  3851. smalltalk.addClass('UndefinedObject', smalltalk.Object, [], 'Kernel');
  3852. smalltalk.addMethod(
  3853. unescape('_subclass_instanceVariableNames_'),
  3854. smalltalk.method({
  3855. selector: unescape('subclass%3AinstanceVariableNames%3A'),
  3856. category: 'class creation',
  3857. fn: function (aString, anotherString){
  3858. var self=this;
  3859. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, anotherString, nil]);
  3860. return self;},
  3861. args: ["aString", "anotherString"],
  3862. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%20package%3A%20nil'),
  3863. messageSends: ["subclass:instanceVariableNames:package:"],
  3864. referencedClasses: []
  3865. }),
  3866. smalltalk.UndefinedObject);
  3867. smalltalk.addMethod(
  3868. unescape('_subclass_instanceVariableNames_category_'),
  3869. smalltalk.method({
  3870. selector: unescape('subclass%3AinstanceVariableNames%3Acategory%3A'),
  3871. category: 'class creation',
  3872. fn: function (aString, aString2, aString3){
  3873. var self=this;
  3874. smalltalk.send(self, "_deprecatedAPI", []);
  3875. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  3876. return self;},
  3877. args: ["aString", "aString2", "aString3"],
  3878. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20category%3A%20aString3%0A%09%22Kept%20for%20compatibility.%22%0A%09self%20deprecatedAPI.%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  3879. messageSends: ["deprecatedAPI", "subclass:instanceVariableNames:package:"],
  3880. referencedClasses: []
  3881. }),
  3882. smalltalk.UndefinedObject);
  3883. smalltalk.addMethod(
  3884. unescape('_shallowCopy'),
  3885. smalltalk.method({
  3886. selector: unescape('shallowCopy'),
  3887. category: 'copying',
  3888. fn: function (){
  3889. var self=this;
  3890. return self;
  3891. return self;},
  3892. args: [],
  3893. source: unescape('shallowCopy%0A%09%5Eself'),
  3894. messageSends: [],
  3895. referencedClasses: []
  3896. }),
  3897. smalltalk.UndefinedObject);
  3898. smalltalk.addMethod(
  3899. unescape('_deepCopy'),
  3900. smalltalk.method({
  3901. selector: unescape('deepCopy'),
  3902. category: 'copying',
  3903. fn: function (){
  3904. var self=this;
  3905. return self;
  3906. return self;},
  3907. args: [],
  3908. source: unescape('deepCopy%0A%09%5Eself'),
  3909. messageSends: [],
  3910. referencedClasses: []
  3911. }),
  3912. smalltalk.UndefinedObject);
  3913. smalltalk.addMethod(
  3914. unescape('_ifNil_'),
  3915. smalltalk.method({
  3916. selector: unescape('ifNil%3A'),
  3917. category: 'testing',
  3918. fn: function (aBlock){
  3919. var self=this;
  3920. return smalltalk.send(self, "_ifNil_ifNotNil_", [aBlock, (function(){return nil;})]);
  3921. return self;},
  3922. args: ["aBlock"],
  3923. source: unescape('ifNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifNil%3A%20aBlock%20ifNotNil%3A%20%5B%5D'),
  3924. messageSends: ["ifNil:ifNotNil:"],
  3925. referencedClasses: []
  3926. }),
  3927. smalltalk.UndefinedObject);
  3928. smalltalk.addMethod(
  3929. unescape('_ifNotNil_'),
  3930. smalltalk.method({
  3931. selector: unescape('ifNotNil%3A'),
  3932. category: 'testing',
  3933. fn: function (aBlock){
  3934. var self=this;
  3935. return self;
  3936. return self;},
  3937. args: ["aBlock"],
  3938. source: unescape('ifNotNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself'),
  3939. messageSends: [],
  3940. referencedClasses: []
  3941. }),
  3942. smalltalk.UndefinedObject);
  3943. smalltalk.addMethod(
  3944. unescape('_ifNil_ifNotNil_'),
  3945. smalltalk.method({
  3946. selector: unescape('ifNil%3AifNotNil%3A'),
  3947. category: 'testing',
  3948. fn: function (aBlock, anotherBlock){
  3949. var self=this;
  3950. return smalltalk.send(aBlock, "_value", []);
  3951. return self;},
  3952. args: ["aBlock", "anotherBlock"],
  3953. source: unescape('ifNil%3A%20aBlock%20ifNotNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  3954. messageSends: ["value"],
  3955. referencedClasses: []
  3956. }),
  3957. smalltalk.UndefinedObject);
  3958. smalltalk.addMethod(
  3959. unescape('_ifNotNil_ifNil_'),
  3960. smalltalk.method({
  3961. selector: unescape('ifNotNil%3AifNil%3A'),
  3962. category: 'testing',
  3963. fn: function (aBlock, anotherBlock){
  3964. var self=this;
  3965. return smalltalk.send(anotherBlock, "_value", []);
  3966. return self;},
  3967. args: ["aBlock", "anotherBlock"],
  3968. source: unescape('ifNotNil%3A%20aBlock%20ifNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EanotherBlock%20value'),
  3969. messageSends: ["value"],
  3970. referencedClasses: []
  3971. }),
  3972. smalltalk.UndefinedObject);
  3973. smalltalk.addMethod(
  3974. unescape('_isNil'),
  3975. smalltalk.method({
  3976. selector: unescape('isNil'),
  3977. category: 'testing',
  3978. fn: function (){
  3979. var self=this;
  3980. return true;
  3981. return self;},
  3982. args: [],
  3983. source: unescape('isNil%0A%09%5Etrue'),
  3984. messageSends: [],
  3985. referencedClasses: []
  3986. }),
  3987. smalltalk.UndefinedObject);
  3988. smalltalk.addMethod(
  3989. unescape('_notNil'),
  3990. smalltalk.method({
  3991. selector: unescape('notNil'),
  3992. category: 'testing',
  3993. fn: function (){
  3994. var self=this;
  3995. return false;
  3996. return self;},
  3997. args: [],
  3998. source: unescape('notNil%0A%09%5Efalse'),
  3999. messageSends: [],
  4000. referencedClasses: []
  4001. }),
  4002. smalltalk.UndefinedObject);
  4003. smalltalk.addMethod(
  4004. unescape('_printString'),
  4005. smalltalk.method({
  4006. selector: unescape('printString'),
  4007. category: 'printing',
  4008. fn: function (){
  4009. var self=this;
  4010. return "nil";
  4011. return self;},
  4012. args: [],
  4013. source: unescape('printString%0A%20%20%20%20%5E%27nil%27'),
  4014. messageSends: [],
  4015. referencedClasses: []
  4016. }),
  4017. smalltalk.UndefinedObject);
  4018. smalltalk.addMethod(
  4019. unescape('_subclass_instanceVariableNames_package_'),
  4020. smalltalk.method({
  4021. selector: unescape('subclass%3AinstanceVariableNames%3Apackage%3A'),
  4022. category: 'class creation',
  4023. fn: function (aString, aString2, aString3){
  4024. var self=this;
  4025. return smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_superclass_subclass_instanceVariableNames_package_", [self, aString, aString2, aString3]);
  4026. return self;},
  4027. args: ["aString", "aString2", "aString3"],
  4028. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%5EClassBuilder%20new%0A%09%20%20%20%20superclass%3A%20self%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  4029. messageSends: ["superclass:subclass:instanceVariableNames:package:", "new"],
  4030. referencedClasses: ["ClassBuilder"]
  4031. }),
  4032. smalltalk.UndefinedObject);
  4033. smalltalk.addMethod(
  4034. unescape('_new'),
  4035. smalltalk.method({
  4036. selector: unescape('new'),
  4037. category: 'instance creation',
  4038. fn: function (){
  4039. var self=this;
  4040. smalltalk.send(self, "_error_", ["You cannot create new instances of UndefinedObject. Use nil"]);
  4041. return self;},
  4042. args: [],
  4043. source: unescape('new%0A%09%20%20%20%20self%20error%3A%20%27You%20cannot%20create%20new%20instances%20of%20UndefinedObject.%20Use%20nil%27'),
  4044. messageSends: ["error:"],
  4045. referencedClasses: []
  4046. }),
  4047. smalltalk.UndefinedObject.klass);
  4048. smalltalk.addClass('Collection', smalltalk.Object, [], 'Kernel');
  4049. smalltalk.addMethod(
  4050. unescape('_size'),
  4051. smalltalk.method({
  4052. selector: unescape('size'),
  4053. category: 'accessing',
  4054. fn: function (){
  4055. var self=this;
  4056. smalltalk.send(self, "_subclassResponsibility", []);
  4057. return self;},
  4058. args: [],
  4059. source: unescape('size%0A%09self%20subclassResponsibility'),
  4060. messageSends: ["subclassResponsibility"],
  4061. referencedClasses: []
  4062. }),
  4063. smalltalk.Collection);
  4064. smalltalk.addMethod(
  4065. unescape('_readStream'),
  4066. smalltalk.method({
  4067. selector: unescape('readStream'),
  4068. category: 'accessing',
  4069. fn: function (){
  4070. var self=this;
  4071. return smalltalk.send(self, "_stream", []);
  4072. return self;},
  4073. args: [],
  4074. source: unescape('readStream%0A%09%5Eself%20stream'),
  4075. messageSends: ["stream"],
  4076. referencedClasses: []
  4077. }),
  4078. smalltalk.Collection);
  4079. smalltalk.addMethod(
  4080. unescape('_writeStream'),
  4081. smalltalk.method({
  4082. selector: unescape('writeStream'),
  4083. category: 'accessing',
  4084. fn: function (){
  4085. var self=this;
  4086. return smalltalk.send(self, "_stream", []);
  4087. return self;},
  4088. args: [],
  4089. source: unescape('writeStream%0A%09%5Eself%20stream'),
  4090. messageSends: ["stream"],
  4091. referencedClasses: []
  4092. }),
  4093. smalltalk.Collection);
  4094. smalltalk.addMethod(
  4095. unescape('_stream'),
  4096. smalltalk.method({
  4097. selector: unescape('stream'),
  4098. category: 'accessing',
  4099. fn: function (){
  4100. var self=this;
  4101. return smalltalk.send(smalltalk.send(self, "_streamClass", []), "_on_", [self]);
  4102. return self;},
  4103. args: [],
  4104. source: unescape('stream%0A%09%5Eself%20streamClass%20on%3A%20self'),
  4105. messageSends: ["on:", "streamClass"],
  4106. referencedClasses: []
  4107. }),
  4108. smalltalk.Collection);
  4109. smalltalk.addMethod(
  4110. unescape('_streamClass'),
  4111. smalltalk.method({
  4112. selector: unescape('streamClass'),
  4113. category: 'accessing',
  4114. fn: function (){
  4115. var self=this;
  4116. return smalltalk.send(smalltalk.send(self, "_class", []), "_streamClass", []);
  4117. return self;},
  4118. args: [],
  4119. source: unescape('streamClass%0A%09%5Eself%20class%20streamClass'),
  4120. messageSends: ["streamClass", "class"],
  4121. referencedClasses: []
  4122. }),
  4123. smalltalk.Collection);
  4124. smalltalk.addMethod(
  4125. unescape('_add_'),
  4126. smalltalk.method({
  4127. selector: unescape('add%3A'),
  4128. category: 'adding/removing',
  4129. fn: function (anObject){
  4130. var self=this;
  4131. smalltalk.send(self, "_subclassResponsibility", []);
  4132. return self;},
  4133. args: ["anObject"],
  4134. source: unescape('add%3A%20anObject%0A%09self%20subclassResponsibility'),
  4135. messageSends: ["subclassResponsibility"],
  4136. referencedClasses: []
  4137. }),
  4138. smalltalk.Collection);
  4139. smalltalk.addMethod(
  4140. unescape('_addAll_'),
  4141. smalltalk.method({
  4142. selector: unescape('addAll%3A'),
  4143. category: 'adding/removing',
  4144. fn: function (aCollection){
  4145. var self=this;
  4146. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(self, "_add_", [each]);})]);
  4147. return aCollection;
  4148. return self;},
  4149. args: ["aCollection"],
  4150. source: unescape('addAll%3A%20aCollection%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20add%3A%20each%5D.%0A%09%5EaCollection'),
  4151. messageSends: ["do:", "add:"],
  4152. referencedClasses: []
  4153. }),
  4154. smalltalk.Collection);
  4155. smalltalk.addMethod(
  4156. unescape('__comma'),
  4157. smalltalk.method({
  4158. selector: unescape('%2C'),
  4159. category: 'copying',
  4160. fn: function (aCollection){
  4161. var self=this;
  4162. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4163. return self;},
  4164. args: ["aCollection"],
  4165. source: unescape('%2C%20aCollection%0A%09%5Eself%20copy%20%0A%09%20%20%20%20addAll%3A%20aCollection%3B%20%0A%09%20%20%20%20yourself'),
  4166. messageSends: ["addAll:", "yourself", "copy"],
  4167. referencedClasses: []
  4168. }),
  4169. smalltalk.Collection);
  4170. smalltalk.addMethod(
  4171. unescape('_copyWith_'),
  4172. smalltalk.method({
  4173. selector: unescape('copyWith%3A'),
  4174. category: 'copying',
  4175. fn: function (anObject){
  4176. var self=this;
  4177. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4178. return self;},
  4179. args: ["anObject"],
  4180. source: unescape('copyWith%3A%20anObject%0A%09%5Eself%20copy%20add%3A%20anObject%3B%20yourself'),
  4181. messageSends: ["add:", "yourself", "copy"],
  4182. referencedClasses: []
  4183. }),
  4184. smalltalk.Collection);
  4185. smalltalk.addMethod(
  4186. unescape('_copyWithAll_'),
  4187. smalltalk.method({
  4188. selector: unescape('copyWithAll%3A'),
  4189. category: 'copying',
  4190. fn: function (aCollection){
  4191. var self=this;
  4192. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4193. return self;},
  4194. args: ["aCollection"],
  4195. source: unescape('copyWithAll%3A%20aCollection%0A%09%5Eself%20copy%20addAll%3A%20aCollection%3B%20yourself'),
  4196. messageSends: ["addAll:", "yourself", "copy"],
  4197. referencedClasses: []
  4198. }),
  4199. smalltalk.Collection);
  4200. smalltalk.addMethod(
  4201. unescape('_asArray'),
  4202. smalltalk.method({
  4203. selector: unescape('asArray'),
  4204. category: 'converting',
  4205. fn: function (){
  4206. var self=this;
  4207. var array=nil;
  4208. var index=nil;
  4209. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  4210. index=(0);
  4211. smalltalk.send(self, "_do_", [(function(each){index=((($receiver = index).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return smalltalk.send(array, "_at_put_", [index, each]);})]);
  4212. return array;
  4213. return self;},
  4214. args: [],
  4215. source: unescape('asArray%0A%09%7C%20array%20index%20%7C%0A%09array%20%3A%3D%20Array%20new.%0A%09index%20%3A%3D%200.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20index%20%3A%3D%20index%20+%201.%0A%09%20%20%20%20array%20at%3A%20index%20put%3A%20each%5D.%0A%09%5Earray'),
  4216. messageSends: ["new", "do:", unescape("+"), "at:put:"],
  4217. referencedClasses: ["Array"]
  4218. }),
  4219. smalltalk.Collection);
  4220. smalltalk.addMethod(
  4221. unescape('_do_'),
  4222. smalltalk.method({
  4223. selector: unescape('do%3A'),
  4224. category: 'enumerating',
  4225. fn: function (aBlock){
  4226. var self=this;
  4227. for(var i=0;i<self.length;i++){aBlock(self[i]);};
  4228. return self;},
  4229. args: ["aBlock"],
  4230. source: unescape('do%3A%20aBlock%0A%09%3Cfor%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7BaBlock%28self%5Bi%5D%29%3B%7D%3E'),
  4231. messageSends: [],
  4232. referencedClasses: []
  4233. }),
  4234. smalltalk.Collection);
  4235. smalltalk.addMethod(
  4236. unescape('_collect_'),
  4237. smalltalk.method({
  4238. selector: unescape('collect%3A'),
  4239. category: 'enumerating',
  4240. fn: function (aBlock){
  4241. var self=this;
  4242. var newCollection=nil;
  4243. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  4244. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [smalltalk.send(aBlock, "_value_", [each])]);})]);
  4245. return newCollection;
  4246. return self;},
  4247. args: ["aBlock"],
  4248. source: unescape('collect%3A%20aBlock%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20newCollection%20add%3A%20%28aBlock%20value%3A%20each%29%5D.%0A%09%5EnewCollection'),
  4249. messageSends: ["new", "class", "do:", "add:", "value:"],
  4250. referencedClasses: []
  4251. }),
  4252. smalltalk.Collection);
  4253. smalltalk.addMethod(
  4254. unescape('_detect_'),
  4255. smalltalk.method({
  4256. selector: unescape('detect%3A'),
  4257. category: 'enumerating',
  4258. fn: function (aBlock){
  4259. var self=this;
  4260. return smalltalk.send(self, "_detect_ifNone_", [aBlock, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  4261. return self;},
  4262. args: ["aBlock"],
  4263. source: unescape('detect%3A%20aBlock%0A%09%5Eself%20detect%3A%20aBlock%20ifNone%3A%20%5Bself%20errorNotFound%5D'),
  4264. messageSends: ["detect:ifNone:", "errorNotFound"],
  4265. referencedClasses: []
  4266. }),
  4267. smalltalk.Collection);
  4268. smalltalk.addMethod(
  4269. unescape('_detect_ifNone_'),
  4270. smalltalk.method({
  4271. selector: unescape('detect%3AifNone%3A'),
  4272. category: 'enumerating',
  4273. fn: function (aBlock, anotherBlock){
  4274. var self=this;
  4275. for(var i = 0; i < self.length; i++)
  4276. if(aBlock(self[i]))
  4277. return self[i];
  4278. return anotherBlock();
  4279. ;
  4280. return self;},
  4281. args: ["aBlock", "anotherBlock"],
  4282. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%3C%0A%09%09for%28var%20i%20%3D%200%3B%20i%20%3C%20self.length%3B%20i++%29%0A%09%09%09if%28aBlock%28self%5Bi%5D%29%29%0A%09%09%09%09return%20self%5Bi%5D%3B%0A%09%09return%20anotherBlock%28%29%3B%0A%09%3E'),
  4283. messageSends: [],
  4284. referencedClasses: []
  4285. }),
  4286. smalltalk.Collection);
  4287. smalltalk.addMethod(
  4288. unescape('_do_separatedBy_'),
  4289. smalltalk.method({
  4290. selector: unescape('do%3AseparatedBy%3A'),
  4291. category: 'enumerating',
  4292. fn: function (aBlock, anotherBlock){
  4293. var self=this;
  4294. var first=nil;
  4295. first=true;
  4296. smalltalk.send(self, "_do_", [(function(each){((($receiver = first).klass === smalltalk.Boolean) ? ($receiver ? (function(){return first=false;})() : (function(){return smalltalk.send(anotherBlock, "_value", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return first=false;}), (function(){return smalltalk.send(anotherBlock, "_value", []);})]));return smalltalk.send(aBlock, "_value_", [each]);})]);
  4297. return self;},
  4298. args: ["aBlock", "anotherBlock"],
  4299. source: unescape('do%3A%20aBlock%20separatedBy%3A%20anotherBlock%0A%20%20%20%20%09%7C%20first%20%7C%0A%20%20%20%20%09first%20%3A%3D%20true.%0A%20%20%20%20%09self%20do%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%09%20%20%20%20first%0A%20%20%20%20%09%09ifTrue%3A%20%5Bfirst%20%3A%3D%20false%5D%0A%20%20%20%20%09%09ifFalse%3A%20%5BanotherBlock%20value%5D.%0A%20%20%20%20%09%20%20%20%20aBlock%20value%3A%20each%5D'),
  4300. messageSends: ["do:", "ifTrue:ifFalse:", "value", "value:"],
  4301. referencedClasses: []
  4302. }),
  4303. smalltalk.Collection);
  4304. smalltalk.addMethod(
  4305. unescape('_inject_into_'),
  4306. smalltalk.method({
  4307. selector: unescape('inject%3Ainto%3A'),
  4308. category: 'enumerating',
  4309. fn: function (anObject, aBlock){
  4310. var self=this;
  4311. var result=nil;
  4312. result=anObject;
  4313. smalltalk.send(self, "_do_", [(function(each){return result=smalltalk.send(aBlock, "_value_value_", [result, each]);})]);
  4314. return result;
  4315. return self;},
  4316. args: ["anObject", "aBlock"],
  4317. source: unescape('inject%3A%20anObject%20into%3A%20aBlock%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20anObject.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20%0A%09%20%20%20%20result%20%3A%3D%20aBlock%20value%3A%20result%20value%3A%20each%5D.%0A%09%5Eresult'),
  4318. messageSends: ["do:", "value:value:"],
  4319. referencedClasses: []
  4320. }),
  4321. smalltalk.Collection);
  4322. smalltalk.addMethod(
  4323. unescape('_reject_'),
  4324. smalltalk.method({
  4325. selector: unescape('reject%3A'),
  4326. category: 'enumerating',
  4327. fn: function (aBlock){
  4328. var self=this;
  4329. return smalltalk.send(self, "_select_", [(function(each){return smalltalk.send(smalltalk.send(aBlock, "_value_", [each]), "__eq", [false]);})]);
  4330. return self;},
  4331. args: ["aBlock"],
  4332. source: unescape('reject%3A%20aBlock%0A%09%5Eself%20select%3A%20%5B%3Aeach%20%7C%20%28aBlock%20value%3A%20each%29%20%3D%20false%5D'),
  4333. messageSends: ["select:", unescape("%3D"), "value:"],
  4334. referencedClasses: []
  4335. }),
  4336. smalltalk.Collection);
  4337. smalltalk.addMethod(
  4338. unescape('_select_'),
  4339. smalltalk.method({
  4340. selector: unescape('select%3A'),
  4341. category: 'enumerating',
  4342. fn: function (aBlock){
  4343. var self=this;
  4344. var stream=nil;
  4345. stream=smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_new", []), "_writeStream", []);
  4346. smalltalk.send(self, "_do_", [(function(each){return ((($receiver = smalltalk.send(aBlock, "_value_", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(stream, "_nextPut_", [each]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(stream, "_nextPut_", [each]);})]));})]);
  4347. return smalltalk.send(stream, "_contents", []);
  4348. return self;},
  4349. args: ["aBlock"],
  4350. source: unescape('select%3A%20aBlock%0A%09%7C%20stream%20%7C%0A%09stream%20%3A%3D%20self%20class%20new%20writeStream.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20%28aBlock%20value%3A%20each%29%20ifTrue%3A%20%5B%0A%09%09stream%20nextPut%3A%20each%5D%5D.%0A%09%5Estream%20contents'),
  4351. messageSends: ["writeStream", "new", "class", "do:", "ifTrue:", "value:", "nextPut:", "contents"],
  4352. referencedClasses: []
  4353. }),
  4354. smalltalk.Collection);
  4355. smalltalk.addMethod(
  4356. unescape('_errorNotFound'),
  4357. smalltalk.method({
  4358. selector: unescape('errorNotFound'),
  4359. category: 'error handling',
  4360. fn: function (){
  4361. var self=this;
  4362. smalltalk.send(self, "_error_", ["Object is not in the collection"]);
  4363. return self;},
  4364. args: [],
  4365. source: unescape('errorNotFound%0A%09self%20error%3A%20%27Object%20is%20not%20in%20the%20collection%27'),
  4366. messageSends: ["error:"],
  4367. referencedClasses: []
  4368. }),
  4369. smalltalk.Collection);
  4370. smalltalk.addMethod(
  4371. unescape('_includes_'),
  4372. smalltalk.method({
  4373. selector: unescape('includes%3A'),
  4374. category: 'testing',
  4375. fn: function (anObject){
  4376. var self=this;
  4377. var i = self.length;
  4378. while (i--) {
  4379. if (smalltalk.send(self[i], "__eq", [anObject])) {return true;}
  4380. }
  4381. return false
  4382. ;
  4383. return self;},
  4384. args: ["anObject"],
  4385. source: unescape('includes%3A%20anObject%0A%09%3C%0A%09%09var%20i%20%3D%20self.length%3B%0A%09%09while%20%28i--%29%20%7B%0A%09%09%09if%20%28smalltalk.send%28self%5Bi%5D%2C%20%22__eq%22%2C%20%5BanObject%5D%29%29%20%7Breturn%20true%3B%7D%09%0A%09%09%7D%0A%09%09return%20false%0A%09%3E'),
  4386. messageSends: [],
  4387. referencedClasses: []
  4388. }),
  4389. smalltalk.Collection);
  4390. smalltalk.addMethod(
  4391. unescape('_notEmpty'),
  4392. smalltalk.method({
  4393. selector: unescape('notEmpty'),
  4394. category: 'testing',
  4395. fn: function (){
  4396. var self=this;
  4397. return smalltalk.send(smalltalk.send(self, "_isEmpty", []), "_not", []);
  4398. return self;},
  4399. args: [],
  4400. source: unescape('notEmpty%0A%09%5Eself%20isEmpty%20not'),
  4401. messageSends: ["not", "isEmpty"],
  4402. referencedClasses: []
  4403. }),
  4404. smalltalk.Collection);
  4405. smalltalk.addMethod(
  4406. unescape('_isEmpty'),
  4407. smalltalk.method({
  4408. selector: unescape('isEmpty'),
  4409. category: 'testing',
  4410. fn: function (){
  4411. var self=this;
  4412. return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [(0)]);
  4413. return self;},
  4414. args: [],
  4415. source: unescape('isEmpty%0A%09%5Eself%20size%20%3D%200'),
  4416. messageSends: [unescape("%3D"), "size"],
  4417. referencedClasses: []
  4418. }),
  4419. smalltalk.Collection);
  4420. smalltalk.addMethod(
  4421. unescape('_remove_'),
  4422. smalltalk.method({
  4423. selector: unescape('remove%3A'),
  4424. category: 'adding/removing',
  4425. fn: function (anObject){
  4426. var self=this;
  4427. return smalltalk.send(self, "_remove_ifAbsent_", [anObject, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  4428. return self;},
  4429. args: ["anObject"],
  4430. source: unescape('remove%3A%20anObject%0A%20%20%20%20%5Eself%20remove%3A%20anObject%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  4431. messageSends: ["remove:ifAbsent:", "errorNotFound"],
  4432. referencedClasses: []
  4433. }),
  4434. smalltalk.Collection);
  4435. smalltalk.addMethod(
  4436. unescape('_asSet'),
  4437. smalltalk.method({
  4438. selector: unescape('asSet'),
  4439. category: 'converting',
  4440. fn: function (){
  4441. var self=this;
  4442. return smalltalk.send((smalltalk.Set || Set), "_withAll_", [self]);
  4443. return self;},
  4444. args: [],
  4445. source: unescape('asSet%0A%09%5ESet%20withAll%3A%20self'),
  4446. messageSends: ["withAll:"],
  4447. referencedClasses: ["Set"]
  4448. }),
  4449. smalltalk.Collection);
  4450. smalltalk.addMethod(
  4451. unescape('_ifNotEmpty_'),
  4452. smalltalk.method({
  4453. selector: unescape('ifNotEmpty%3A'),
  4454. category: 'testing',
  4455. fn: function (aBlock){
  4456. var self=this;
  4457. smalltalk.send(smalltalk.send(self, "_notEmpty", []), "_ifTrue_", [aBlock]);
  4458. return self;},
  4459. args: ["aBlock"],
  4460. source: unescape('ifNotEmpty%3A%20aBlock%0A%09self%20notEmpty%20ifTrue%3A%20aBlock.'),
  4461. messageSends: ["ifTrue:", "notEmpty"],
  4462. referencedClasses: []
  4463. }),
  4464. smalltalk.Collection);
  4465. smalltalk.addMethod(
  4466. unescape('_ifEmpty_'),
  4467. smalltalk.method({
  4468. selector: unescape('ifEmpty%3A'),
  4469. category: 'testing',
  4470. fn: function (aBlock){
  4471. var self=this;
  4472. smalltalk.send(smalltalk.send(self, "_isEmpty", []), "_ifTrue_", [aBlock]);
  4473. return self;},
  4474. args: ["aBlock"],
  4475. source: unescape('ifEmpty%3A%20aBlock%0A%09self%20isEmpty%20ifTrue%3A%20aBlock.'),
  4476. messageSends: ["ifTrue:", "isEmpty"],
  4477. referencedClasses: []
  4478. }),
  4479. smalltalk.Collection);
  4480. smalltalk.addMethod(
  4481. unescape('_copyWithoutAll_'),
  4482. smalltalk.method({
  4483. selector: unescape('copyWithoutAll%3A'),
  4484. category: 'copying',
  4485. fn: function (aCollection){
  4486. var self=this;
  4487. return smalltalk.send(self, "_reject_", [(function(each){return smalltalk.send(aCollection, "_includes_", [each]);})]);
  4488. return self;},
  4489. args: ["aCollection"],
  4490. source: unescape('copyWithoutAll%3A%20aCollection%0A%09%22Answer%20a%20copy%20of%20the%20receiver%20that%20does%20not%20contain%20any%20elements%20%0A%09equal%20to%20those%20in%20aCollection.%22%0A%0A%09%5E%20self%20reject%3A%20%5B%3Aeach%20%7C%20aCollection%20includes%3A%20each%5D'),
  4491. messageSends: ["reject:", "includes:"],
  4492. referencedClasses: []
  4493. }),
  4494. smalltalk.Collection);
  4495. smalltalk.addMethod(
  4496. unescape('_remove_ifAbsent_'),
  4497. smalltalk.method({
  4498. selector: unescape('remove%3AifAbsent%3A'),
  4499. category: 'adding/removing',
  4500. fn: function (anObject, aBlock){
  4501. var self=this;
  4502. smalltalk.send(self, "_subclassResponsibility", []);
  4503. return self;},
  4504. args: ["anObject", "aBlock"],
  4505. source: unescape('remove%3A%20anObject%20ifAbsent%3A%20aBlock%0A%20%20%20%20self%20subclassResponsibility'),
  4506. messageSends: ["subclassResponsibility"],
  4507. referencedClasses: []
  4508. }),
  4509. smalltalk.Collection);
  4510. smalltalk.addMethod(
  4511. unescape('_streamClass'),
  4512. smalltalk.method({
  4513. selector: unescape('streamClass'),
  4514. category: 'accessing',
  4515. fn: function (){
  4516. var self=this;
  4517. return (smalltalk.Stream || Stream);
  4518. return self;},
  4519. args: [],
  4520. source: unescape('streamClass%0A%09%20%20%20%20%5EStream'),
  4521. messageSends: [],
  4522. referencedClasses: ["Stream"]
  4523. }),
  4524. smalltalk.Collection.klass);
  4525. smalltalk.addMethod(
  4526. unescape('_with_'),
  4527. smalltalk.method({
  4528. selector: unescape('with%3A'),
  4529. category: 'instance creation',
  4530. fn: function (anObject){
  4531. var self=this;
  4532. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  4533. return self;},
  4534. args: ["anObject"],
  4535. source: unescape('with%3A%20anObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20anObject%3B%0A%09%09yourself'),
  4536. messageSends: ["add:", "yourself", "new"],
  4537. referencedClasses: []
  4538. }),
  4539. smalltalk.Collection.klass);
  4540. smalltalk.addMethod(
  4541. unescape('_with_with_'),
  4542. smalltalk.method({
  4543. selector: unescape('with%3Awith%3A'),
  4544. category: 'instance creation',
  4545. fn: function (anObject, anotherObject){
  4546. var self=this;
  4547. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);smalltalk.send($rec, "_add_", [anotherObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  4548. return self;},
  4549. args: ["anObject", "anotherObject"],
  4550. source: unescape('with%3A%20anObject%20with%3A%20anotherObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20anObject%3B%0A%09%09add%3A%20anotherObject%3B%0A%09%09yourself'),
  4551. messageSends: ["add:", "yourself", "new"],
  4552. referencedClasses: []
  4553. }),
  4554. smalltalk.Collection.klass);
  4555. smalltalk.addMethod(
  4556. unescape('_with_with_with_'),
  4557. smalltalk.method({
  4558. selector: unescape('with%3Awith%3Awith%3A'),
  4559. category: 'instance creation',
  4560. fn: function (firstObject, secondObject, thirdObject){
  4561. var self=this;
  4562. return (function($rec){smalltalk.send($rec, "_add_", [firstObject]);smalltalk.send($rec, "_add_", [secondObject]);smalltalk.send($rec, "_add_", [thirdObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  4563. return self;},
  4564. args: ["firstObject", "secondObject", "thirdObject"],
  4565. source: unescape('with%3A%20firstObject%20with%3A%20secondObject%20with%3A%20thirdObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20firstObject%3B%0A%09%09add%3A%20secondObject%3B%0A%09%09add%3A%20thirdObject%3B%0A%09%09yourself'),
  4566. messageSends: ["add:", "yourself", "new"],
  4567. referencedClasses: []
  4568. }),
  4569. smalltalk.Collection.klass);
  4570. smalltalk.addMethod(
  4571. unescape('_withAll_'),
  4572. smalltalk.method({
  4573. selector: unescape('withAll%3A'),
  4574. category: 'instance creation',
  4575. fn: function (aCollection){
  4576. var self=this;
  4577. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  4578. return self;},
  4579. args: ["aCollection"],
  4580. source: unescape('withAll%3A%20aCollection%0A%09%20%20%20%20%5Eself%20new%0A%09%09addAll%3A%20aCollection%3B%0A%09%09yourself'),
  4581. messageSends: ["addAll:", "yourself", "new"],
  4582. referencedClasses: []
  4583. }),
  4584. smalltalk.Collection.klass);
  4585. smalltalk.addClass('SequenceableCollection', smalltalk.Collection, [], 'Kernel');
  4586. smalltalk.addMethod(
  4587. unescape('_at_'),
  4588. smalltalk.method({
  4589. selector: unescape('at%3A'),
  4590. category: 'accessing',
  4591. fn: function (anIndex){
  4592. var self=this;
  4593. return smalltalk.send(self, "_at_ifAbsent_", [anIndex, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  4594. return self;},
  4595. args: ["anIndex"],
  4596. source: unescape('at%3A%20anIndex%0A%09%5Eself%20at%3A%20anIndex%20ifAbsent%3A%20%5B%0A%09%20%20%20%20self%20errorNotFound%5D'),
  4597. messageSends: ["at:ifAbsent:", "errorNotFound"],
  4598. referencedClasses: []
  4599. }),
  4600. smalltalk.SequenceableCollection);
  4601. smalltalk.addMethod(
  4602. unescape('_at_ifAbsent_'),
  4603. smalltalk.method({
  4604. selector: unescape('at%3AifAbsent%3A'),
  4605. category: 'accessing',
  4606. fn: function (anIndex, aBlock){
  4607. var self=this;
  4608. smalltalk.send(self, "_subclassResponsibility", []);
  4609. return self;},
  4610. args: ["anIndex", "aBlock"],
  4611. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%09self%20subclassResponsibility'),
  4612. messageSends: ["subclassResponsibility"],
  4613. referencedClasses: []
  4614. }),
  4615. smalltalk.SequenceableCollection);
  4616. smalltalk.addMethod(
  4617. unescape('_at_put_'),
  4618. smalltalk.method({
  4619. selector: unescape('at%3Aput%3A'),
  4620. category: 'accessing',
  4621. fn: function (anIndex, anObject){
  4622. var self=this;
  4623. smalltalk.send(self, "_subclassResponsibility", []);
  4624. return self;},
  4625. args: ["anIndex", "anObject"],
  4626. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%09self%20subclassResponsibility'),
  4627. messageSends: ["subclassResponsibility"],
  4628. referencedClasses: []
  4629. }),
  4630. smalltalk.SequenceableCollection);
  4631. smalltalk.addMethod(
  4632. unescape('_copyFrom_to_'),
  4633. smalltalk.method({
  4634. selector: unescape('copyFrom%3Ato%3A'),
  4635. category: 'copying',
  4636. fn: function (anIndex, anotherIndex){
  4637. var self=this;
  4638. smalltalk.send(self, "_subclassResponsibility", []);
  4639. return self;},
  4640. args: ["anIndex", "anotherIndex"],
  4641. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09self%20subclassResponsibility'),
  4642. messageSends: ["subclassResponsibility"],
  4643. referencedClasses: []
  4644. }),
  4645. smalltalk.SequenceableCollection);
  4646. smalltalk.addMethod(
  4647. unescape('_first'),
  4648. smalltalk.method({
  4649. selector: unescape('first'),
  4650. category: 'accessing',
  4651. fn: function (){
  4652. var self=this;
  4653. return smalltalk.send(self, "_at_", [(1)]);
  4654. return self;},
  4655. args: [],
  4656. source: unescape('first%0A%09%5Eself%20at%3A%201'),
  4657. messageSends: ["at:"],
  4658. referencedClasses: []
  4659. }),
  4660. smalltalk.SequenceableCollection);
  4661. smalltalk.addMethod(
  4662. unescape('_fourth'),
  4663. smalltalk.method({
  4664. selector: unescape('fourth'),
  4665. category: 'accessing',
  4666. fn: function (){
  4667. var self=this;
  4668. return smalltalk.send(self, "_at_", [(4)]);
  4669. return self;},
  4670. args: [],
  4671. source: unescape('fourth%0A%09%5Eself%20at%3A%204'),
  4672. messageSends: ["at:"],
  4673. referencedClasses: []
  4674. }),
  4675. smalltalk.SequenceableCollection);
  4676. smalltalk.addMethod(
  4677. unescape('_last'),
  4678. smalltalk.method({
  4679. selector: unescape('last'),
  4680. category: 'accessing',
  4681. fn: function (){
  4682. var self=this;
  4683. return smalltalk.send(self, "_at_", [smalltalk.send(self, "_size", [])]);
  4684. return self;},
  4685. args: [],
  4686. source: unescape('last%0A%09%5Eself%20at%3A%20self%20size'),
  4687. messageSends: ["at:", "size"],
  4688. referencedClasses: []
  4689. }),
  4690. smalltalk.SequenceableCollection);
  4691. smalltalk.addMethod(
  4692. unescape('_second'),
  4693. smalltalk.method({
  4694. selector: unescape('second'),
  4695. category: 'accessing',
  4696. fn: function (){
  4697. var self=this;
  4698. return smalltalk.send(self, "_at_", [(2)]);
  4699. return self;},
  4700. args: [],
  4701. source: unescape('second%0A%09%5Eself%20at%3A%202'),
  4702. messageSends: ["at:"],
  4703. referencedClasses: []
  4704. }),
  4705. smalltalk.SequenceableCollection);
  4706. smalltalk.addMethod(
  4707. unescape('_third'),
  4708. smalltalk.method({
  4709. selector: unescape('third'),
  4710. category: 'accessing',
  4711. fn: function (){
  4712. var self=this;
  4713. return smalltalk.send(self, "_at_", [(3)]);
  4714. return self;},
  4715. args: [],
  4716. source: unescape('third%0A%09%5Eself%20at%3A%203'),
  4717. messageSends: ["at:"],
  4718. referencedClasses: []
  4719. }),
  4720. smalltalk.SequenceableCollection);
  4721. smalltalk.addMethod(
  4722. unescape('_removeLast'),
  4723. smalltalk.method({
  4724. selector: unescape('removeLast'),
  4725. category: 'adding',
  4726. fn: function (){
  4727. var self=this;
  4728. smalltalk.send(self, "_remove_", [smalltalk.send(self, "_last", [])]);
  4729. return self;},
  4730. args: [],
  4731. source: unescape('removeLast%0A%09self%20remove%3A%20self%20last'),
  4732. messageSends: ["remove:", "last"],
  4733. referencedClasses: []
  4734. }),
  4735. smalltalk.SequenceableCollection);
  4736. smalltalk.addMethod(
  4737. unescape('_addLast_'),
  4738. smalltalk.method({
  4739. selector: unescape('addLast%3A'),
  4740. category: 'adding',
  4741. fn: function (anObject){
  4742. var self=this;
  4743. smalltalk.send(self, "_add_", [anObject]);
  4744. return self;},
  4745. args: ["anObject"],
  4746. source: unescape('addLast%3A%20anObject%0A%09self%20add%3A%20anObject'),
  4747. messageSends: ["add:"],
  4748. referencedClasses: []
  4749. }),
  4750. smalltalk.SequenceableCollection);
  4751. smalltalk.addMethod(
  4752. unescape('_withIndexDo_'),
  4753. smalltalk.method({
  4754. selector: unescape('withIndexDo%3A'),
  4755. category: 'enumerating',
  4756. fn: function (aBlock){
  4757. var self=this;
  4758. for(var i=0;i<self.length;i++){aBlock(self[i], i+1);};
  4759. return self;},
  4760. args: ["aBlock"],
  4761. source: unescape('withIndexDo%3A%20aBlock%0A%09%3Cfor%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7BaBlock%28self%5Bi%5D%2C%20i+1%29%3B%7D%3E'),
  4762. messageSends: [],
  4763. referencedClasses: []
  4764. }),
  4765. smalltalk.SequenceableCollection);
  4766. smalltalk.addMethod(
  4767. unescape('_allButFirst'),
  4768. smalltalk.method({
  4769. selector: unescape('allButFirst'),
  4770. category: 'accessing',
  4771. fn: function (){
  4772. var self=this;
  4773. return smalltalk.send(self, "_copyFrom_to_", [(2), smalltalk.send(self, "_size", [])]);
  4774. return self;},
  4775. args: [],
  4776. source: unescape('allButFirst%0A%09%5Eself%20copyFrom%3A%202%20to%3A%20self%20size'),
  4777. messageSends: ["copyFrom:to:", "size"],
  4778. referencedClasses: []
  4779. }),
  4780. smalltalk.SequenceableCollection);
  4781. smalltalk.addMethod(
  4782. unescape('_allButLast'),
  4783. smalltalk.method({
  4784. selector: unescape('allButLast'),
  4785. category: 'accessing',
  4786. fn: function (){
  4787. var self=this;
  4788. return smalltalk.send(self, "_copyFrom_to_", [(1), ((($receiver = smalltalk.send(self, "_size", [])).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]))]);
  4789. return self;},
  4790. args: [],
  4791. source: unescape('allButLast%0A%09%5Eself%20copyFrom%3A%201%20to%3A%20self%20size%20-%201'),
  4792. messageSends: ["copyFrom:to:", unescape("-"), "size"],
  4793. referencedClasses: []
  4794. }),
  4795. smalltalk.SequenceableCollection);
  4796. smalltalk.addMethod(
  4797. unescape('_indexOf_'),
  4798. smalltalk.method({
  4799. selector: unescape('indexOf%3A'),
  4800. category: 'accessing',
  4801. fn: function (anObject){
  4802. var self=this;
  4803. return smalltalk.send(self, "_indexOf_ifAbsent_", [anObject, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  4804. return self;},
  4805. args: ["anObject"],
  4806. source: unescape('indexOf%3A%20anObject%0A%09%5Eself%20indexOf%3A%20anObject%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  4807. messageSends: ["indexOf:ifAbsent:", "errorNotFound"],
  4808. referencedClasses: []
  4809. }),
  4810. smalltalk.SequenceableCollection);
  4811. smalltalk.addMethod(
  4812. unescape('_indexOf_ifAbsent_'),
  4813. smalltalk.method({
  4814. selector: unescape('indexOf%3AifAbsent%3A'),
  4815. category: 'accessing',
  4816. fn: function (anObject, aBlock){
  4817. var self=this;
  4818. for(var i=0;i<self.length;i++){
  4819. if(self[i].__eq(anObject)) {return i+1}
  4820. }
  4821. return aBlock();
  4822. ;
  4823. return self;},
  4824. args: ["anObject", "aBlock"],
  4825. source: unescape('indexOf%3A%20anObject%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%09for%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7B%0A%09%09%09if%28self%5Bi%5D.__eq%28anObject%29%29%20%7Breturn%20i+1%7D%0A%09%09%7D%0A%09%09return%20aBlock%28%29%3B%0A%09%3E'),
  4826. messageSends: [],
  4827. referencedClasses: []
  4828. }),
  4829. smalltalk.SequenceableCollection);
  4830. smalltalk.addMethod(
  4831. unescape('_indexOf_startingAt_ifAbsent_'),
  4832. smalltalk.method({
  4833. selector: unescape('indexOf%3AstartingAt%3AifAbsent%3A'),
  4834. category: 'accessing',
  4835. fn: function (anObject, start, aBlock){
  4836. var self=this;
  4837. for(var i=start-1;i<self.length;i++){
  4838. if(self[i].__eq(anObject)) {return i+1}
  4839. }
  4840. return aBlock();
  4841. ;
  4842. return self;},
  4843. args: ["anObject", "start", "aBlock"],
  4844. source: unescape('indexOf%3A%20anObject%20startingAt%3A%20start%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%09for%28var%20i%3Dstart-1%3Bi%3Cself.length%3Bi++%29%7B%0A%09%09%09if%28self%5Bi%5D.__eq%28anObject%29%29%20%7Breturn%20i+1%7D%0A%09%09%7D%0A%09%09return%20aBlock%28%29%3B%0A%09%3E'),
  4845. messageSends: [],
  4846. referencedClasses: []
  4847. }),
  4848. smalltalk.SequenceableCollection);
  4849. smalltalk.addMethod(
  4850. unescape('_indexOf_startingAt_'),
  4851. smalltalk.method({
  4852. selector: unescape('indexOf%3AstartingAt%3A'),
  4853. category: 'accessing',
  4854. fn: function (anObject, start){
  4855. var self=this;
  4856. return smalltalk.send(self, "_indexOf_startingAt_ifAbsent_", [anObject, start, (function(){return (0);})]);
  4857. return self;},
  4858. args: ["anObject", "start"],
  4859. source: unescape('indexOf%3A%20anObject%20startingAt%3A%20start%0A%09%22Answer%20the%20index%20of%20the%20first%20occurence%20of%20anElement%20after%20start%0A%09within%20the%20receiver.%20If%20the%20receiver%20does%20not%20contain%20anElement%2C%20%0A%09answer%200.%22%0A%09%5Eself%20indexOf%3A%20anObject%20startingAt%3A%20start%20ifAbsent%3A%20%5B0%5D'),
  4860. messageSends: ["indexOf:startingAt:ifAbsent:"],
  4861. referencedClasses: []
  4862. }),
  4863. smalltalk.SequenceableCollection);
  4864. smalltalk.addMethod(
  4865. unescape('_reversed'),
  4866. smalltalk.method({
  4867. selector: unescape('reversed'),
  4868. category: 'converting',
  4869. fn: function (){
  4870. var self=this;
  4871. smalltalk.send(self, "_subclassResponsibility", []);
  4872. return self;},
  4873. args: [],
  4874. source: unescape('reversed%0A%09self%20subclassResponsibility'),
  4875. messageSends: ["subclassResponsibility"],
  4876. referencedClasses: []
  4877. }),
  4878. smalltalk.SequenceableCollection);
  4879. smalltalk.addMethod(
  4880. unescape('_atRandom'),
  4881. smalltalk.method({
  4882. selector: unescape('atRandom'),
  4883. category: 'accessing',
  4884. fn: function (){
  4885. var self=this;
  4886. return smalltalk.send(self, "_at_", [smalltalk.send(smalltalk.send(self, "_size", []), "_atRandom", [])]);
  4887. return self;},
  4888. args: [],
  4889. source: unescape('atRandom%0A%09%5E%20self%20at%3A%20self%20size%20atRandom'),
  4890. messageSends: ["at:", "atRandom", "size"],
  4891. referencedClasses: []
  4892. }),
  4893. smalltalk.SequenceableCollection);
  4894. smalltalk.addClass('String', smalltalk.SequenceableCollection, [], 'Kernel');
  4895. smalltalk.addMethod(
  4896. unescape('__eq'),
  4897. smalltalk.method({
  4898. selector: unescape('%3D'),
  4899. category: 'comparing',
  4900. fn: function (aString){
  4901. var self=this;
  4902. try{((($receiver = smalltalk.send(smalltalk.send(aString, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  4903. return String(self) == aString;
  4904. return self;
  4905. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  4906. args: ["aString"],
  4907. source: unescape('%3D%20aString%0A%09aString%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20String%28self%29%20%3D%3D%20aString%3E'),
  4908. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  4909. referencedClasses: []
  4910. }),
  4911. smalltalk.String);
  4912. smalltalk.addMethod(
  4913. unescape('_size'),
  4914. smalltalk.method({
  4915. selector: unescape('size'),
  4916. category: 'accessing',
  4917. fn: function (){
  4918. var self=this;
  4919. return self.length;
  4920. return self;},
  4921. args: [],
  4922. source: unescape('size%0A%09%3Creturn%20self.length%3E'),
  4923. messageSends: [],
  4924. referencedClasses: []
  4925. }),
  4926. smalltalk.String);
  4927. smalltalk.addMethod(
  4928. unescape('_at_'),
  4929. smalltalk.method({
  4930. selector: unescape('at%3A'),
  4931. category: 'accessing',
  4932. fn: function (anIndex){
  4933. var self=this;
  4934. return self[anIndex - 1];
  4935. return self;},
  4936. args: ["anIndex"],
  4937. source: unescape('at%3A%20anIndex%0A%09%3Creturn%20self%5BanIndex%20-%201%5D%3E'),
  4938. messageSends: [],
  4939. referencedClasses: []
  4940. }),
  4941. smalltalk.String);
  4942. smalltalk.addMethod(
  4943. unescape('_at_put_'),
  4944. smalltalk.method({
  4945. selector: unescape('at%3Aput%3A'),
  4946. category: 'accessing',
  4947. fn: function (anIndex, anObject){
  4948. var self=this;
  4949. smalltalk.send(self, "_errorReadOnly", []);
  4950. return self;},
  4951. args: ["anIndex", "anObject"],
  4952. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%20%20%20%20%09self%20errorReadOnly'),
  4953. messageSends: ["errorReadOnly"],
  4954. referencedClasses: []
  4955. }),
  4956. smalltalk.String);
  4957. smalltalk.addMethod(
  4958. unescape('_at_ifAbsent_'),
  4959. smalltalk.method({
  4960. selector: unescape('at%3AifAbsent%3A'),
  4961. category: 'accessing',
  4962. fn: function (anIndex, aBlock){
  4963. var self=this;
  4964. (($receiver = smalltalk.send(self, "_at_", [anIndex])) == nil || $receiver == undefined) ? (function(){return aBlock;})() : $receiver;
  4965. return self;},
  4966. args: ["anIndex", "aBlock"],
  4967. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%20%20%20%20%09%28self%20at%3A%20anIndex%29%20ifNil%3A%20%5BaBlock%5D'),
  4968. messageSends: ["ifNil:", "at:"],
  4969. referencedClasses: []
  4970. }),
  4971. smalltalk.String);
  4972. smalltalk.addMethod(
  4973. unescape('_escaped'),
  4974. smalltalk.method({
  4975. selector: unescape('escaped'),
  4976. category: 'accessing',
  4977. fn: function (){
  4978. var self=this;
  4979. return escape(self);
  4980. return self;},
  4981. args: [],
  4982. source: unescape('escaped%0A%09%3Creturn%20escape%28self%29%3E'),
  4983. messageSends: [],
  4984. referencedClasses: []
  4985. }),
  4986. smalltalk.String);
  4987. smalltalk.addMethod(
  4988. unescape('_unescaped'),
  4989. smalltalk.method({
  4990. selector: unescape('unescaped'),
  4991. category: 'accessing',
  4992. fn: function (){
  4993. var self=this;
  4994. return unescape(self);
  4995. return self;},
  4996. args: [],
  4997. source: unescape('unescaped%0A%09%3Creturn%20unescape%28self%29%3E'),
  4998. messageSends: [],
  4999. referencedClasses: []
  5000. }),
  5001. smalltalk.String);
  5002. smalltalk.addMethod(
  5003. unescape('_add_'),
  5004. smalltalk.method({
  5005. selector: unescape('add%3A'),
  5006. category: 'adding',
  5007. fn: function (anObject){
  5008. var self=this;
  5009. smalltalk.send(self, "_errorReadOnly", []);
  5010. return self;},
  5011. args: ["anObject"],
  5012. source: unescape('add%3A%20anObject%0A%20%20%20%20%09self%20errorReadOnly'),
  5013. messageSends: ["errorReadOnly"],
  5014. referencedClasses: []
  5015. }),
  5016. smalltalk.String);
  5017. smalltalk.addMethod(
  5018. unescape('__comma'),
  5019. smalltalk.method({
  5020. selector: unescape('%2C'),
  5021. category: 'copying',
  5022. fn: function (aString){
  5023. var self=this;
  5024. return self + aString;
  5025. return self;},
  5026. args: ["aString"],
  5027. source: unescape('%2C%20aString%0A%09%3Creturn%20self%20+%20aString%3E'),
  5028. messageSends: [],
  5029. referencedClasses: []
  5030. }),
  5031. smalltalk.String);
  5032. smalltalk.addMethod(
  5033. unescape('_copyFrom_to_'),
  5034. smalltalk.method({
  5035. selector: unescape('copyFrom%3Ato%3A'),
  5036. category: 'copying',
  5037. fn: function (anIndex, anotherIndex){
  5038. var self=this;
  5039. return self.substring(anIndex - 1, anotherIndex);
  5040. return self;},
  5041. args: ["anIndex", "anotherIndex"],
  5042. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09%3Creturn%20self.substring%28anIndex%20-%201%2C%20anotherIndex%29%3E'),
  5043. messageSends: [],
  5044. referencedClasses: []
  5045. }),
  5046. smalltalk.String);
  5047. smalltalk.addMethod(
  5048. unescape('_shallowCopy'),
  5049. smalltalk.method({
  5050. selector: unescape('shallowCopy'),
  5051. category: 'copying',
  5052. fn: function (){
  5053. var self=this;
  5054. return smalltalk.send(smalltalk.send(self, "_class", []), "_fromString_", [self]);
  5055. return self;},
  5056. args: [],
  5057. source: unescape('shallowCopy%0A%20%20%20%20%09%5Eself%20class%20fromString%3A%20self'),
  5058. messageSends: ["fromString:", "class"],
  5059. referencedClasses: []
  5060. }),
  5061. smalltalk.String);
  5062. smalltalk.addMethod(
  5063. unescape('_deepCopy'),
  5064. smalltalk.method({
  5065. selector: unescape('deepCopy'),
  5066. category: 'copying',
  5067. fn: function (){
  5068. var self=this;
  5069. return smalltalk.send(self, "_shallowCopy", []);
  5070. return self;},
  5071. args: [],
  5072. source: unescape('deepCopy%0A%20%20%20%20%09%5Eself%20shallowCopy'),
  5073. messageSends: ["shallowCopy"],
  5074. referencedClasses: []
  5075. }),
  5076. smalltalk.String);
  5077. smalltalk.addMethod(
  5078. unescape('_asSelector'),
  5079. smalltalk.method({
  5080. selector: unescape('asSelector'),
  5081. category: 'converting',
  5082. fn: function (){
  5083. var self=this;
  5084. var selector=nil;
  5085. selector=smalltalk.send("_", "__comma", [self]);
  5086. selector=smalltalk.send(selector, "_replace_with_", [":", "_"]);
  5087. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B+%5D"), "_plus"]);
  5088. selector=smalltalk.send(selector, "_replace_with_", [unescape("-"), "_minus"]);
  5089. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B*%5D"), "_star"]);
  5090. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B/%5D"), "_slash"]);
  5091. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3E"), "_gt"]);
  5092. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3C"), "_lt"]);
  5093. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3D"), "_eq"]);
  5094. selector=smalltalk.send(selector, "_replace_with_", [unescape("%2C"), "_comma"]);
  5095. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B@%5D"), "_at"]);
  5096. return selector;
  5097. return self;},
  5098. args: [],
  5099. source: unescape('asSelector%0A%09%22If%20you%20change%20this%20method%2C%20change%20smalltalk.convertSelector%20too%20%28see%20js/boot.js%20file%29%22%0A%0A%09%7C%20selector%20%7C%0A%09selector%20%3A%3D%20%27_%27%2C%20self.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3A%27%20with%3A%20%27_%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B+%5D%27%20with%3A%20%27_plus%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27-%27%20with%3A%20%27_minus%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B*%5D%27%20with%3A%20%27_star%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B/%5D%27%20with%3A%20%27_slash%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3E%27%20with%3A%20%27_gt%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3C%27%20with%3A%20%27_lt%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3D%27%20with%3A%20%27_eq%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%2C%27%20with%3A%20%27_comma%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B@%5D%27%20with%3A%20%27_at%27.%0A%09%5Eselector'),
  5100. messageSends: [unescape("%2C"), "replace:with:"],
  5101. referencedClasses: []
  5102. }),
  5103. smalltalk.String);
  5104. smalltalk.addMethod(
  5105. unescape('_asJavascript'),
  5106. smalltalk.method({
  5107. selector: unescape('asJavascript'),
  5108. category: 'converting',
  5109. fn: function (){
  5110. var self=this;
  5111. if(self.search(/^[a-zA-Z0-9_:.$ ]*$/) == -1)
  5112. return "unescape(\"" + escape(self) + "\")";
  5113. else
  5114. return "\"" + self + "\"";
  5115. ;
  5116. return self;},
  5117. args: [],
  5118. source: unescape('asJavascript%0A%09%3C%0A%09%09if%28self.search%28/%5E%5Ba-zA-Z0-9_%3A.%24%20%5D*%24/%29%20%3D%3D%20-1%29%0A%09%09%09return%20%22unescape%28%5C%22%22%20+%20escape%28self%29%20+%20%22%5C%22%29%22%3B%0A%09%09else%0A%09%09%09return%20%22%5C%22%22%20+%20self%20+%20%22%5C%22%22%3B%0A%09%3E'),
  5119. messageSends: [],
  5120. referencedClasses: []
  5121. }),
  5122. smalltalk.String);
  5123. smalltalk.addMethod(
  5124. unescape('_replace_with_'),
  5125. smalltalk.method({
  5126. selector: unescape('replace%3Awith%3A'),
  5127. category: 'regular expressions',
  5128. fn: function (aString, anotherString){
  5129. var self=this;
  5130. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [aString, "g"]), anotherString]);
  5131. return self;},
  5132. args: ["aString", "anotherString"],
  5133. source: unescape('replace%3A%20aString%20with%3A%20anotherString%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20aString%20flag%3A%20%27g%27%29%20with%3A%20anotherString'),
  5134. messageSends: ["replaceRegexp:with:", "fromString:flag:"],
  5135. referencedClasses: ["RegularExpression"]
  5136. }),
  5137. smalltalk.String);
  5138. smalltalk.addMethod(
  5139. unescape('_replaceRegexp_with_'),
  5140. smalltalk.method({
  5141. selector: unescape('replaceRegexp%3Awith%3A'),
  5142. category: 'regular expressions',
  5143. fn: function (aRegexp, aString){
  5144. var self=this;
  5145. return self.replace(aRegexp, aString);
  5146. return self;},
  5147. args: ["aRegexp", "aString"],
  5148. source: unescape('replaceRegexp%3A%20aRegexp%20with%3A%20aString%0A%09%3Creturn%20self.replace%28aRegexp%2C%20aString%29%3E'),
  5149. messageSends: [],
  5150. referencedClasses: []
  5151. }),
  5152. smalltalk.String);
  5153. smalltalk.addMethod(
  5154. unescape('_tokenize_'),
  5155. smalltalk.method({
  5156. selector: unescape('tokenize%3A'),
  5157. category: 'converting',
  5158. fn: function (aString){
  5159. var self=this;
  5160. return self.split(aString);
  5161. return self;},
  5162. args: ["aString"],
  5163. source: unescape('tokenize%3A%20aString%0A%09%3Creturn%20self.split%28aString%29%3E'),
  5164. messageSends: [],
  5165. referencedClasses: []
  5166. }),
  5167. smalltalk.String);
  5168. smalltalk.addMethod(
  5169. unescape('_match_'),
  5170. smalltalk.method({
  5171. selector: unescape('match%3A'),
  5172. category: 'regular expressions',
  5173. fn: function (aRegexp){
  5174. var self=this;
  5175. return self.search(aRegexp) != -1;
  5176. return self;},
  5177. args: ["aRegexp"],
  5178. source: unescape('match%3A%20aRegexp%0A%09%3Creturn%20self.search%28aRegexp%29%20%21%3D%20-1%3E'),
  5179. messageSends: [],
  5180. referencedClasses: []
  5181. }),
  5182. smalltalk.String);
  5183. smalltalk.addMethod(
  5184. unescape('_asString'),
  5185. smalltalk.method({
  5186. selector: unescape('asString'),
  5187. category: 'converting',
  5188. fn: function (){
  5189. var self=this;
  5190. return self;
  5191. return self;},
  5192. args: [],
  5193. source: unescape('asString%0A%20%20%20%20%09%5Eself'),
  5194. messageSends: [],
  5195. referencedClasses: []
  5196. }),
  5197. smalltalk.String);
  5198. smalltalk.addMethod(
  5199. unescape('_asNumber'),
  5200. smalltalk.method({
  5201. selector: unescape('asNumber'),
  5202. category: 'converting',
  5203. fn: function (){
  5204. var self=this;
  5205. return Number(self);
  5206. return self;},
  5207. args: [],
  5208. source: unescape('asNumber%0A%09%3Creturn%20Number%28self%29%3E'),
  5209. messageSends: [],
  5210. referencedClasses: []
  5211. }),
  5212. smalltalk.String);
  5213. smalltalk.addMethod(
  5214. unescape('_errorReadOnly'),
  5215. smalltalk.method({
  5216. selector: unescape('errorReadOnly'),
  5217. category: 'error handling',
  5218. fn: function (){
  5219. var self=this;
  5220. smalltalk.send(self, "_error_", [unescape("Object%20is%20read-only")]);
  5221. return self;},
  5222. args: [],
  5223. source: unescape('errorReadOnly%0A%20%20%20%20%09self%20error%3A%20%27Object%20is%20read-only%27'),
  5224. messageSends: ["error:"],
  5225. referencedClasses: []
  5226. }),
  5227. smalltalk.String);
  5228. smalltalk.addMethod(
  5229. unescape('_printString'),
  5230. smalltalk.method({
  5231. selector: unescape('printString'),
  5232. category: 'printing',
  5233. fn: function (){
  5234. var self=this;
  5235. return smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [self]), "__comma", [unescape("%27")]);
  5236. return self;},
  5237. args: [],
  5238. source: unescape('printString%0A%20%20%20%20%09%5E%27%27%27%27%2C%20self%2C%20%27%27%27%27'),
  5239. messageSends: [unescape("%2C")],
  5240. referencedClasses: []
  5241. }),
  5242. smalltalk.String);
  5243. smalltalk.addMethod(
  5244. unescape('_printNl'),
  5245. smalltalk.method({
  5246. selector: unescape('printNl'),
  5247. category: 'printing',
  5248. fn: function (){
  5249. var self=this;
  5250. console.log(self);
  5251. return self;},
  5252. args: [],
  5253. source: unescape('printNl%0A%09%3Cconsole.log%28self%29%3E'),
  5254. messageSends: [],
  5255. referencedClasses: []
  5256. }),
  5257. smalltalk.String);
  5258. smalltalk.addMethod(
  5259. unescape('_isString'),
  5260. smalltalk.method({
  5261. selector: unescape('isString'),
  5262. category: 'testing',
  5263. fn: function (){
  5264. var self=this;
  5265. return true;
  5266. return self;},
  5267. args: [],
  5268. source: unescape('isString%0A%20%20%20%20%09%5Etrue'),
  5269. messageSends: [],
  5270. referencedClasses: []
  5271. }),
  5272. smalltalk.String);
  5273. smalltalk.addMethod(
  5274. unescape('__gt'),
  5275. smalltalk.method({
  5276. selector: unescape('%3E'),
  5277. category: 'comparing',
  5278. fn: function (aString){
  5279. var self=this;
  5280. return String(self) > aString;
  5281. return self;},
  5282. args: ["aString"],
  5283. source: unescape('%3E%20aString%0A%09%3Creturn%20String%28self%29%20%3E%3E%20aString%3E'),
  5284. messageSends: [],
  5285. referencedClasses: []
  5286. }),
  5287. smalltalk.String);
  5288. smalltalk.addMethod(
  5289. unescape('__lt'),
  5290. smalltalk.method({
  5291. selector: unescape('%3C'),
  5292. category: 'comparing',
  5293. fn: function (aString){
  5294. var self=this;
  5295. return String(self) < aString;
  5296. return self;},
  5297. args: ["aString"],
  5298. source: unescape('%3C%20aString%0A%09%3Creturn%20String%28self%29%20%3C%20aString%3E'),
  5299. messageSends: [],
  5300. referencedClasses: []
  5301. }),
  5302. smalltalk.String);
  5303. smalltalk.addMethod(
  5304. unescape('__gt_eq'),
  5305. smalltalk.method({
  5306. selector: unescape('%3E%3D'),
  5307. category: 'comparing',
  5308. fn: function (aString){
  5309. var self=this;
  5310. return String(self) >= aString;
  5311. return self;},
  5312. args: ["aString"],
  5313. source: unescape('%3E%3D%20aString%0A%09%3Creturn%20String%28self%29%20%3E%3E%3D%20aString%3E'),
  5314. messageSends: [],
  5315. referencedClasses: []
  5316. }),
  5317. smalltalk.String);
  5318. smalltalk.addMethod(
  5319. unescape('__lt_eq'),
  5320. smalltalk.method({
  5321. selector: unescape('%3C%3D'),
  5322. category: 'comparing',
  5323. fn: function (aString){
  5324. var self=this;
  5325. return String(self) <= aString;
  5326. return self;},
  5327. args: ["aString"],
  5328. source: unescape('%3C%3D%20aString%0A%09%3Creturn%20String%28self%29%20%3C%3D%20aString%3E'),
  5329. messageSends: [],
  5330. referencedClasses: []
  5331. }),
  5332. smalltalk.String);
  5333. smalltalk.addMethod(
  5334. unescape('_remove_'),
  5335. smalltalk.method({
  5336. selector: unescape('remove%3A'),
  5337. category: 'adding',
  5338. fn: function (anObject){
  5339. var self=this;
  5340. smalltalk.send(self, "_errorReadOnly", []);
  5341. return self;},
  5342. args: ["anObject"],
  5343. source: unescape('remove%3A%20anObject%0A%09self%20errorReadOnly'),
  5344. messageSends: ["errorReadOnly"],
  5345. referencedClasses: []
  5346. }),
  5347. smalltalk.String);
  5348. smalltalk.addMethod(
  5349. unescape('_trimLeft_'),
  5350. smalltalk.method({
  5351. selector: unescape('trimLeft%3A'),
  5352. category: 'regular expressions',
  5353. fn: function (separators){
  5354. var self=this;
  5355. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [smalltalk.send(smalltalk.send(unescape("%5E%5B"), "__comma", [separators]), "__comma", [unescape("%5D+")]), "g"]), ""]);
  5356. return self;},
  5357. args: ["separators"],
  5358. source: unescape('trimLeft%3A%20separators%0A%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20%27%5E%5B%27%2C%20separators%2C%20%27%5D+%27%20flag%3A%20%27g%27%29%20with%3A%20%27%27'),
  5359. messageSends: ["replaceRegexp:with:", "fromString:flag:", unescape("%2C")],
  5360. referencedClasses: ["RegularExpression"]
  5361. }),
  5362. smalltalk.String);
  5363. smalltalk.addMethod(
  5364. unescape('_trimRight_'),
  5365. smalltalk.method({
  5366. selector: unescape('trimRight%3A'),
  5367. category: 'regular expressions',
  5368. fn: function (separators){
  5369. var self=this;
  5370. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [smalltalk.send(smalltalk.send(unescape("%5B"), "__comma", [separators]), "__comma", [unescape("%5D+%24")]), "g"]), ""]);
  5371. return self;},
  5372. args: ["separators"],
  5373. source: unescape('trimRight%3A%20separators%0A%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20%27%5B%27%2C%20separators%2C%20%27%5D+%24%27%20flag%3A%20%27g%27%29%20with%3A%20%27%27'),
  5374. messageSends: ["replaceRegexp:with:", "fromString:flag:", unescape("%2C")],
  5375. referencedClasses: ["RegularExpression"]
  5376. }),
  5377. smalltalk.String);
  5378. smalltalk.addMethod(
  5379. unescape('_trimLeft'),
  5380. smalltalk.method({
  5381. selector: unescape('trimLeft'),
  5382. category: 'regular expressions',
  5383. fn: function (){
  5384. var self=this;
  5385. return smalltalk.send(self, "_trimLeft_", [unescape("%5Cs")]);
  5386. return self;},
  5387. args: [],
  5388. source: unescape('trimLeft%0A%09%5Eself%20trimLeft%3A%20%27%5Cs%27'),
  5389. messageSends: ["trimLeft:"],
  5390. referencedClasses: []
  5391. }),
  5392. smalltalk.String);
  5393. smalltalk.addMethod(
  5394. unescape('_trimRight'),
  5395. smalltalk.method({
  5396. selector: unescape('trimRight'),
  5397. category: 'regular expressions',
  5398. fn: function (){
  5399. var self=this;
  5400. return smalltalk.send(self, "_trimRight_", [unescape("%5Cs")]);
  5401. return self;},
  5402. args: [],
  5403. source: unescape('trimRight%0A%09%5Eself%20trimRight%3A%20%27%5Cs%27'),
  5404. messageSends: ["trimRight:"],
  5405. referencedClasses: []
  5406. }),
  5407. smalltalk.String);
  5408. smalltalk.addMethod(
  5409. unescape('_trimBoth'),
  5410. smalltalk.method({
  5411. selector: unescape('trimBoth'),
  5412. category: 'regular expressions',
  5413. fn: function (){
  5414. var self=this;
  5415. return smalltalk.send(self, "_trimBoth_", [unescape("%5Cs")]);
  5416. return self;},
  5417. args: [],
  5418. source: unescape('trimBoth%0A%09%5Eself%20trimBoth%3A%20%27%5Cs%27'),
  5419. messageSends: ["trimBoth:"],
  5420. referencedClasses: []
  5421. }),
  5422. smalltalk.String);
  5423. smalltalk.addMethod(
  5424. unescape('_trimBoth_'),
  5425. smalltalk.method({
  5426. selector: unescape('trimBoth%3A'),
  5427. category: 'regular expressions',
  5428. fn: function (separators){
  5429. var self=this;
  5430. return smalltalk.send(smalltalk.send(self, "_trimLeft_", [separators]), "_trimRight_", [separators]);
  5431. return self;},
  5432. args: ["separators"],
  5433. source: unescape('trimBoth%3A%20separators%0A%0A%20%20%20%20%09%5E%28self%20trimLeft%3A%20separators%29%20trimRight%3A%20separators'),
  5434. messageSends: ["trimRight:", "trimLeft:"],
  5435. referencedClasses: []
  5436. }),
  5437. smalltalk.String);
  5438. smalltalk.addMethod(
  5439. unescape('_asLowercase'),
  5440. smalltalk.method({
  5441. selector: unescape('asLowercase'),
  5442. category: 'converting',
  5443. fn: function (){
  5444. var self=this;
  5445. return self.toLowerCase();
  5446. return self;},
  5447. args: [],
  5448. source: unescape('asLowercase%0A%09%3Creturn%20self.toLowerCase%28%29%3E'),
  5449. messageSends: [],
  5450. referencedClasses: []
  5451. }),
  5452. smalltalk.String);
  5453. smalltalk.addMethod(
  5454. unescape('_asUppercase'),
  5455. smalltalk.method({
  5456. selector: unescape('asUppercase'),
  5457. category: 'converting',
  5458. fn: function (){
  5459. var self=this;
  5460. return self.toUpperCase();
  5461. return self;},
  5462. args: [],
  5463. source: unescape('asUppercase%0A%09%3Creturn%20self.toUpperCase%28%29%3E'),
  5464. messageSends: [],
  5465. referencedClasses: []
  5466. }),
  5467. smalltalk.String);
  5468. smalltalk.addMethod(
  5469. unescape('_join_'),
  5470. smalltalk.method({
  5471. selector: unescape('join%3A'),
  5472. category: 'split join',
  5473. fn: function (aCollection){
  5474. var self=this;
  5475. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(stream){return smalltalk.send(aCollection, "_do_separatedBy_", [(function(each){return smalltalk.send(stream, "_nextPutAll_", [smalltalk.send(each, "_asString", [])]);}), (function(){return smalltalk.send(stream, "_nextPutAll_", [self]);})]);})]);
  5476. return self;},
  5477. args: ["aCollection"],
  5478. source: unescape('join%3A%20aCollection%20%0A%09%5E%20String%0A%09%09streamContents%3A%20%5B%3Astream%20%7C%20aCollection%0A%09%09%09%09do%3A%20%5B%3Aeach%20%7C%20stream%20nextPutAll%3A%20each%20asString%5D%20%0A%09%09%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20self%5D%5D'),
  5479. messageSends: ["streamContents:", "do:separatedBy:", "nextPutAll:", "asString"],
  5480. referencedClasses: ["String"]
  5481. }),
  5482. smalltalk.String);
  5483. smalltalk.addMethod(
  5484. unescape('_includesSubString_'),
  5485. smalltalk.method({
  5486. selector: unescape('includesSubString%3A'),
  5487. category: 'testing',
  5488. fn: function (subString){
  5489. var self=this;
  5490. return self.indexOf(subString) != -1 ;
  5491. return self;},
  5492. args: ["subString"],
  5493. source: unescape('includesSubString%3A%20subString%0A%09%3C%20return%20self.indexOf%28subString%29%20%21%3D%20-1%20%3E'),
  5494. messageSends: [],
  5495. referencedClasses: []
  5496. }),
  5497. smalltalk.String);
  5498. smalltalk.addMethod(
  5499. unescape('_asciiValue'),
  5500. smalltalk.method({
  5501. selector: unescape('asciiValue'),
  5502. category: 'accessing',
  5503. fn: function (){
  5504. var self=this;
  5505. return self.charCodeAt(0);;
  5506. return self;},
  5507. args: [],
  5508. source: unescape('asciiValue%0A%09%3Creturn%20self.charCodeAt%280%29%3B%3E'),
  5509. messageSends: [],
  5510. referencedClasses: []
  5511. }),
  5512. smalltalk.String);
  5513. smalltalk.addMethod(
  5514. unescape('_lineIndicesDo_'),
  5515. smalltalk.method({
  5516. selector: unescape('lineIndicesDo%3A'),
  5517. category: 'split join',
  5518. fn: function (aBlock){
  5519. var self=this;
  5520. try{var cr=nil;
  5521. var lf=nil;
  5522. var start=nil;
  5523. var sz=nil;
  5524. var nextLF=nil;
  5525. var nextCR=nil;
  5526. start=(1);
  5527. sz=smalltalk.send(self, "_size", []);
  5528. cr=smalltalk.send((smalltalk.String || String), "_cr", []);
  5529. nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, (1)]);
  5530. lf=smalltalk.send((smalltalk.String || String), "_lf", []);
  5531. nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, (1)]);
  5532. (function(){while((function(){return ((($receiver = start).klass === smalltalk.Number) ? $receiver <=sz : smalltalk.send($receiver, "__lt_eq", [sz]));})()) {(function(){((($receiver = smalltalk.send(smalltalk.send(nextLF, "__eq", [(0)]), "_and_", [(function(){return smalltalk.send(nextCR, "__eq", [(0)]);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, sz, sz]);return (function(){throw({name: 'stReturn', selector: '_lineIndicesDo_', fn: function(){return self}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, sz, sz]);return (function(){throw({name: 'stReturn', selector: '_lineIndicesDo_', fn: function(){return self}})})();})]));return ((($receiver = smalltalk.send(smalltalk.send(nextCR, "__eq", [(0)]), "_or_", [(function(){return smalltalk.send((0) < nextLF, "_and_", [(function(){return ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver <nextCR : smalltalk.send($receiver, "__lt", [nextCR]));})]);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){return ((($receiver = smalltalk.send((1) + nextCR, "__eq", [nextLF])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){return ((($receiver = smalltalk.send((1) + nextCR, "__eq", [nextLF])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})]));})]));})()}})();
  5533. return self;
  5534. } catch(e) {if(e.name === 'stReturn' && e.selector === '_lineIndicesDo_'){return e.fn()} throw(e)}},
  5535. args: ["aBlock"],
  5536. source: unescape('lineIndicesDo%3A%20aBlock%0A%09%22execute%20aBlock%20with%203%20arguments%20for%20each%20line%3A%0A%09-%20start%20index%20of%20line%0A%09-%20end%20index%20of%20line%20without%20line%20delimiter%0A%09-%20end%20index%20of%20line%20including%20line%20delimiter%28s%29%20CR%2C%20LF%20or%20CRLF%22%0A%09%0A%09%7C%20cr%20lf%20start%20sz%20nextLF%20nextCR%20%7C%0A%09start%20%3A%3D%201.%0A%09sz%20%3A%3D%20self%20size.%0A%09cr%20%3A%3D%20String%20cr.%0A%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%201.%0A%09lf%20%3A%3D%20String%20lf.%0A%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%201.%0A%09%5B%20start%20%3C%3D%20sz%20%5D%20whileTrue%3A%20%5B%0A%09%09%28nextLF%20%3D%200%20and%3A%20%5B%20nextCR%20%3D%200%20%5D%29%0A%09%09%09ifTrue%3A%20%5B%20%22No%20more%20CR%2C%20nor%20LF%2C%20the%20string%20is%20over%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20sz%20value%3A%20sz.%0A%09%09%09%09%09%5Eself%20%5D.%0A%09%09%28nextCR%20%3D%200%20or%3A%20%5B%200%20%3C%20nextLF%20and%3A%20%5B%20nextLF%20%3C%20nextCR%20%5D%20%5D%29%0A%09%09%09ifTrue%3A%20%5B%20%22Found%20a%20LF%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextLF%20-%201%20value%3A%20nextLF.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextLF.%0A%09%09%09%09%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%20start%20%5D%0A%09%09%09ifFalse%3A%20%5B%201%20+%20nextCR%20%3D%20nextLF%0A%09%09%09%09ifTrue%3A%20%5B%20%22Found%20a%20CR-LF%20pair%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextCR%20-%201%20value%3A%20nextLF.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextLF.%0A%09%09%09%09%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%20start.%0A%09%09%09%09%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%20start%20%5D%0A%09%09%09%09ifFalse%3A%20%5B%20%22Found%20a%20CR%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextCR%20-%201%20value%3A%20nextCR.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextCR.%0A%09%09%09%09%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%20start%20%5D%5D%5D'),
  5537. messageSends: ["size", "cr", "indexOf:startingAt:", "lf", "whileTrue:", unescape("%3C%3D"), "ifTrue:", "and:", unescape("%3D"), "value:value:value:", "ifTrue:ifFalse:", "or:", unescape("%3C"), unescape("-"), unescape("+")],
  5538. referencedClasses: ["String"]
  5539. }),
  5540. smalltalk.String);
  5541. smalltalk.addMethod(
  5542. unescape('_linesDo_'),
  5543. smalltalk.method({
  5544. selector: unescape('linesDo%3A'),
  5545. category: 'split join',
  5546. fn: function (aBlock){
  5547. var self=this;
  5548. smalltalk.send(self, "_lineIndicesDo_", [(function(start, endWithoutDelimiters, end){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])]);})]);
  5549. return self;},
  5550. args: ["aBlock"],
  5551. source: unescape('linesDo%3A%20aBlock%0A%09%22Execute%20aBlock%20with%20each%20line%20in%20this%20string.%20The%20terminating%20line%0A%09delimiters%20CR%2C%20LF%20or%20CRLF%20pairs%20are%20not%20included%20in%20what%20is%20passed%20to%20aBlock%22%0A%0A%09self%20lineIndicesDo%3A%20%5B%3Astart%20%3AendWithoutDelimiters%20%3Aend%20%7C%0A%09%09aBlock%20value%3A%20%28self%20copyFrom%3A%20start%20to%3A%20endWithoutDelimiters%29%5D'),
  5552. messageSends: ["lineIndicesDo:", "value:", "copyFrom:to:"],
  5553. referencedClasses: []
  5554. }),
  5555. smalltalk.String);
  5556. smalltalk.addMethod(
  5557. unescape('_lines'),
  5558. smalltalk.method({
  5559. selector: unescape('lines'),
  5560. category: 'split join',
  5561. fn: function (){
  5562. var self=this;
  5563. var lines=nil;
  5564. lines=smalltalk.send((smalltalk.Array || Array), "_new", []);
  5565. smalltalk.send(self, "_linesDo_", [(function(aLine){return smalltalk.send(lines, "_add_", [aLine]);})]);
  5566. return lines;
  5567. return self;},
  5568. args: [],
  5569. source: unescape('lines%0A%09%22Answer%20an%20array%20of%20lines%20composing%20this%20receiver%20without%20the%20line%20ending%20delimiters.%22%0A%0A%09%7C%20lines%20%7C%0A%09lines%20%3A%3D%20Array%20new.%0A%09self%20linesDo%3A%20%5B%3AaLine%20%7C%20lines%20add%3A%20aLine%5D.%0A%09%5Elines'),
  5570. messageSends: ["new", "linesDo:", "add:"],
  5571. referencedClasses: ["Array"]
  5572. }),
  5573. smalltalk.String);
  5574. smalltalk.addMethod(
  5575. unescape('_lineNumber_'),
  5576. smalltalk.method({
  5577. selector: unescape('lineNumber%3A'),
  5578. category: 'split join',
  5579. fn: function (anIndex){
  5580. var self=this;
  5581. try{var lineCount=nil;
  5582. lineCount=(0);
  5583. smalltalk.send(self, "_lineIndicesDo_", [(function(start, endWithoutDelimiters, end){return ((($receiver = smalltalk.send(lineCount=((($receiver = lineCount).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])), "__eq", [anIndex])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])}})})();})]));})]);
  5584. (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return nil}})})();
  5585. return self;
  5586. } catch(e) {if(e.name === 'stReturn' && e.selector === '_lineNumber_'){return e.fn()} throw(e)}},
  5587. args: ["anIndex"],
  5588. source: unescape('lineNumber%3A%20anIndex%0A%09%22Answer%20a%20string%20containing%20the%20characters%20in%20the%20given%20line%20number.%22%0A%0A%09%7C%20lineCount%20%7C%0A%09lineCount%20%3A%3D%200.%0A%09self%20lineIndicesDo%3A%20%5B%3Astart%20%3AendWithoutDelimiters%20%3Aend%20%7C%0A%09%09%28lineCount%20%3A%3D%20lineCount%20+%201%29%20%3D%20anIndex%20ifTrue%3A%20%5B%5Eself%20copyFrom%3A%20start%20to%3A%20endWithoutDelimiters%5D%5D.%0A%09%5Enil'),
  5589. messageSends: ["lineIndicesDo:", "ifTrue:", unescape("%3D"), unescape("+"), "copyFrom:to:"],
  5590. referencedClasses: []
  5591. }),
  5592. smalltalk.String);
  5593. smalltalk.addMethod(
  5594. unescape('_reversed'),
  5595. smalltalk.method({
  5596. selector: unescape('reversed'),
  5597. category: 'converting',
  5598. fn: function (){
  5599. var self=this;
  5600. return self.split("").reverse().join("");
  5601. return self;},
  5602. args: [],
  5603. source: unescape('reversed%0A%09%3Creturn%20self.split%28%22%22%29.reverse%28%29.join%28%22%22%29%3E'),
  5604. messageSends: [],
  5605. referencedClasses: []
  5606. }),
  5607. smalltalk.String);
  5608. smalltalk.addMethod(
  5609. unescape('__eq_eq'),
  5610. smalltalk.method({
  5611. selector: unescape('%3D%3D'),
  5612. category: 'comparing',
  5613. fn: function (aString){
  5614. var self=this;
  5615. try{((($receiver = smalltalk.send(smalltalk.send(aString, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  5616. return String(self) === String(aString);
  5617. return self;
  5618. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  5619. args: ["aString"],
  5620. source: unescape('%3D%3D%20aString%0A%09aString%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20String%28self%29%20%3D%3D%3D%20String%28aString%29%3E'),
  5621. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  5622. referencedClasses: []
  5623. }),
  5624. smalltalk.String);
  5625. smalltalk.addMethod(
  5626. unescape('_asJavaScriptSelector'),
  5627. smalltalk.method({
  5628. selector: unescape('asJavaScriptSelector'),
  5629. category: 'converting',
  5630. fn: function (){
  5631. var self=this;
  5632. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_asSelector", []), "_replace_with_", [unescape("%5E_"), ""]), "_replace_with_", [unescape("_.*"), ""]);
  5633. return self;},
  5634. args: [],
  5635. source: unescape('asJavaScriptSelector%0A%09%5E%28self%20asSelector%20replace%3A%20%27%5E_%27%20with%3A%20%27%27%29%20replace%3A%20%27_.*%27%20with%3A%20%27%27.'),
  5636. messageSends: ["replace:with:", "asSelector"],
  5637. referencedClasses: []
  5638. }),
  5639. smalltalk.String);
  5640. smalltalk.addMethod(
  5641. unescape('_streamClass'),
  5642. smalltalk.method({
  5643. selector: unescape('streamClass'),
  5644. category: 'accessing',
  5645. fn: function (){
  5646. var self=this;
  5647. return (smalltalk.StringStream || StringStream);
  5648. return self;},
  5649. args: [],
  5650. source: unescape('streamClass%0A%09%20%20%20%20%5EStringStream'),
  5651. messageSends: [],
  5652. referencedClasses: ["StringStream"]
  5653. }),
  5654. smalltalk.String.klass);
  5655. smalltalk.addMethod(
  5656. unescape('_fromString_'),
  5657. smalltalk.method({
  5658. selector: unescape('fromString%3A'),
  5659. category: 'instance creation',
  5660. fn: function (aString){
  5661. var self=this;
  5662. return new self.fn(aString);
  5663. return self;},
  5664. args: ["aString"],
  5665. source: unescape('fromString%3A%20aString%0A%09%20%20%20%20%3Creturn%20new%20self.fn%28aString%29%3E'),
  5666. messageSends: [],
  5667. referencedClasses: []
  5668. }),
  5669. smalltalk.String.klass);
  5670. smalltalk.addMethod(
  5671. unescape('_cr'),
  5672. smalltalk.method({
  5673. selector: unescape('cr'),
  5674. category: 'accessing',
  5675. fn: function (){
  5676. var self=this;
  5677. return '\r';
  5678. return self;},
  5679. args: [],
  5680. source: unescape('cr%0A%09%3Creturn%20%27%5Cr%27%3E'),
  5681. messageSends: [],
  5682. referencedClasses: []
  5683. }),
  5684. smalltalk.String.klass);
  5685. smalltalk.addMethod(
  5686. unescape('_lf'),
  5687. smalltalk.method({
  5688. selector: unescape('lf'),
  5689. category: 'accessing',
  5690. fn: function (){
  5691. var self=this;
  5692. return '\n';
  5693. return self;},
  5694. args: [],
  5695. source: unescape('lf%0A%09%3Creturn%20%27%5Cn%27%3E'),
  5696. messageSends: [],
  5697. referencedClasses: []
  5698. }),
  5699. smalltalk.String.klass);
  5700. smalltalk.addMethod(
  5701. unescape('_space'),
  5702. smalltalk.method({
  5703. selector: unescape('space'),
  5704. category: 'accessing',
  5705. fn: function (){
  5706. var self=this;
  5707. return ' ';
  5708. return self;},
  5709. args: [],
  5710. source: unescape('space%0A%09%3Creturn%20%27%20%27%3E'),
  5711. messageSends: [],
  5712. referencedClasses: []
  5713. }),
  5714. smalltalk.String.klass);
  5715. smalltalk.addMethod(
  5716. unescape('_tab'),
  5717. smalltalk.method({
  5718. selector: unescape('tab'),
  5719. category: 'accessing',
  5720. fn: function (){
  5721. var self=this;
  5722. return '\t';
  5723. return self;},
  5724. args: [],
  5725. source: unescape('tab%0A%09%3Creturn%20%27%5Ct%27%3E'),
  5726. messageSends: [],
  5727. referencedClasses: []
  5728. }),
  5729. smalltalk.String.klass);
  5730. smalltalk.addMethod(
  5731. unescape('_crlf'),
  5732. smalltalk.method({
  5733. selector: unescape('crlf'),
  5734. category: 'accessing',
  5735. fn: function (){
  5736. var self=this;
  5737. return '\r\n';
  5738. return self;},
  5739. args: [],
  5740. source: unescape('crlf%0A%09%3Creturn%20%27%5Cr%5Cn%27%3E'),
  5741. messageSends: [],
  5742. referencedClasses: []
  5743. }),
  5744. smalltalk.String.klass);
  5745. smalltalk.addMethod(
  5746. unescape('_streamContents_'),
  5747. smalltalk.method({
  5748. selector: unescape('streamContents%3A'),
  5749. category: 'instance creation',
  5750. fn: function (blockWithArg){
  5751. var self=this;
  5752. var stream=nil;
  5753. stream=smalltalk.send(smalltalk.send(self, "_streamClass", []), "_on_", [smalltalk.send((smalltalk.String || String), "_new", [])]);
  5754. smalltalk.send(blockWithArg, "_value_", [stream]);
  5755. return smalltalk.send(stream, "_contents", []);
  5756. return self;},
  5757. args: ["blockWithArg"],
  5758. source: unescape('streamContents%3A%20blockWithArg%0A%09%7Cstream%7C%0A%09stream%20%3A%3D%20%28self%20streamClass%20on%3A%20String%20new%29.%0A%09blockWithArg%20value%3A%20stream.%0A%09%5E%20stream%20contents'),
  5759. messageSends: ["on:", "streamClass", "new", "value:", "contents"],
  5760. referencedClasses: ["String"]
  5761. }),
  5762. smalltalk.String.klass);
  5763. smalltalk.addMethod(
  5764. unescape('_value_'),
  5765. smalltalk.method({
  5766. selector: unescape('value%3A'),
  5767. category: 'instance creation',
  5768. fn: function (aUTFCharCode){
  5769. var self=this;
  5770. return String.fromCharCode(aUTFCharCode);;
  5771. return self;},
  5772. args: ["aUTFCharCode"],
  5773. source: unescape('value%3A%20aUTFCharCode%0A%0A%09%3Creturn%20String.fromCharCode%28aUTFCharCode%29%3B%3E'),
  5774. messageSends: [],
  5775. referencedClasses: []
  5776. }),
  5777. smalltalk.String.klass);
  5778. smalltalk.addClass('Array', smalltalk.SequenceableCollection, [], 'Kernel');
  5779. smalltalk.addMethod(
  5780. unescape('_size'),
  5781. smalltalk.method({
  5782. selector: unescape('size'),
  5783. category: 'accessing',
  5784. fn: function (){
  5785. var self=this;
  5786. return self.length;
  5787. return self;},
  5788. args: [],
  5789. source: unescape('size%0A%09%3Creturn%20self.length%3E'),
  5790. messageSends: [],
  5791. referencedClasses: []
  5792. }),
  5793. smalltalk.Array);
  5794. smalltalk.addMethod(
  5795. unescape('_at_put_'),
  5796. smalltalk.method({
  5797. selector: unescape('at%3Aput%3A'),
  5798. category: 'accessing',
  5799. fn: function (anIndex, anObject){
  5800. var self=this;
  5801. return self[anIndex - 1] = anObject;
  5802. return self;},
  5803. args: ["anIndex", "anObject"],
  5804. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%09%3Creturn%20self%5BanIndex%20-%201%5D%20%3D%20anObject%3E'),
  5805. messageSends: [],
  5806. referencedClasses: []
  5807. }),
  5808. smalltalk.Array);
  5809. smalltalk.addMethod(
  5810. unescape('_at_ifAbsent_'),
  5811. smalltalk.method({
  5812. selector: unescape('at%3AifAbsent%3A'),
  5813. category: 'accessing',
  5814. fn: function (anIndex, aBlock){
  5815. var self=this;
  5816. var value = self[anIndex - 1];
  5817. if(value === undefined) {
  5818. return aBlock();
  5819. } else {
  5820. return value;
  5821. }
  5822. ;
  5823. return self;},
  5824. args: ["anIndex", "aBlock"],
  5825. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%20%20%20%20var%20value%20%3D%20self%5BanIndex%20-%201%5D%3B%0A%09%20%20%20%20if%28value%20%3D%3D%3D%20undefined%29%20%7B%0A%09%09return%20aBlock%28%29%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20value%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  5826. messageSends: [],
  5827. referencedClasses: []
  5828. }),
  5829. smalltalk.Array);
  5830. smalltalk.addMethod(
  5831. unescape('_add_'),
  5832. smalltalk.method({
  5833. selector: unescape('add%3A'),
  5834. category: 'adding/removing',
  5835. fn: function (anObject){
  5836. var self=this;
  5837. self.push(anObject); return anObject;;
  5838. return self;},
  5839. args: ["anObject"],
  5840. source: unescape('add%3A%20anObject%0A%09%3Cself.push%28anObject%29%3B%20return%20anObject%3B%3E'),
  5841. messageSends: [],
  5842. referencedClasses: []
  5843. }),
  5844. smalltalk.Array);
  5845. smalltalk.addMethod(
  5846. unescape('_shallowCopy'),
  5847. smalltalk.method({
  5848. selector: unescape('shallowCopy'),
  5849. category: 'copying',
  5850. fn: function (){
  5851. var self=this;
  5852. var newCollection=nil;
  5853. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  5854. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [each]);})]);
  5855. return newCollection;
  5856. return self;},
  5857. args: [],
  5858. source: unescape('shallowCopy%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20newCollection%20add%3A%20each%5D.%0A%09%5EnewCollection'),
  5859. messageSends: ["new", "class", "do:", "add:"],
  5860. referencedClasses: []
  5861. }),
  5862. smalltalk.Array);
  5863. smalltalk.addMethod(
  5864. unescape('_deepCopy'),
  5865. smalltalk.method({
  5866. selector: unescape('deepCopy'),
  5867. category: 'copying',
  5868. fn: function (){
  5869. var self=this;
  5870. var newCollection=nil;
  5871. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  5872. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [smalltalk.send(each, "_deepCopy", [])]);})]);
  5873. return newCollection;
  5874. return self;},
  5875. args: [],
  5876. source: unescape('deepCopy%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20newCollection%20add%3A%20each%20deepCopy%5D.%0A%09%5EnewCollection'),
  5877. messageSends: ["new", "class", "do:", "add:", "deepCopy"],
  5878. referencedClasses: []
  5879. }),
  5880. smalltalk.Array);
  5881. smalltalk.addMethod(
  5882. unescape('_copyFrom_to_'),
  5883. smalltalk.method({
  5884. selector: unescape('copyFrom%3Ato%3A'),
  5885. category: 'copying',
  5886. fn: function (anIndex, anotherIndex){
  5887. var self=this;
  5888. var array=nil;
  5889. array=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  5890. smalltalk.send(anIndex, "_to_do_", [anotherIndex, (function(each){return smalltalk.send(array, "_add_", [smalltalk.send(self, "_at_", [each])]);})]);
  5891. return array;
  5892. return self;},
  5893. args: ["anIndex", "anotherIndex"],
  5894. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09%7C%20array%20%7C%0A%09array%20%3A%3D%20self%20class%20new.%0A%09anIndex%20to%3A%20anotherIndex%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20array%20add%3A%20%28self%20at%3A%20each%29%5D.%0A%09%5Earray'),
  5895. messageSends: ["new", "class", "to:do:", "add:", "at:"],
  5896. referencedClasses: []
  5897. }),
  5898. smalltalk.Array);
  5899. smalltalk.addMethod(
  5900. unescape('_join_'),
  5901. smalltalk.method({
  5902. selector: unescape('join%3A'),
  5903. category: 'enumerating',
  5904. fn: function (aString){
  5905. var self=this;
  5906. return self.join(aString);
  5907. return self;},
  5908. args: ["aString"],
  5909. source: unescape('join%3A%20aString%0A%09%3Creturn%20self.join%28aString%29%3E'),
  5910. messageSends: [],
  5911. referencedClasses: []
  5912. }),
  5913. smalltalk.Array);
  5914. smalltalk.addMethod(
  5915. unescape('_asJavascript'),
  5916. smalltalk.method({
  5917. selector: unescape('asJavascript'),
  5918. category: 'converting',
  5919. fn: function (){
  5920. var self=this;
  5921. return smalltalk.send(smalltalk.send(unescape("%5B"), "__comma", [smalltalk.send(smalltalk.send(self, "_collect_", [(function(each){return smalltalk.send(each, "_asJavascript", []);})]), "_join_", [unescape("%2C%20")])]), "__comma", [unescape("%5D")]);
  5922. return self;},
  5923. args: [],
  5924. source: unescape('asJavascript%0A%09%5E%27%5B%27%2C%20%28%28self%20collect%3A%20%5B%3Aeach%20%7C%20each%20asJavascript%5D%29%20join%3A%20%27%2C%20%27%29%2C%20%20%27%5D%27'),
  5925. messageSends: [unescape("%2C"), "join:", "collect:", "asJavascript"],
  5926. referencedClasses: []
  5927. }),
  5928. smalltalk.Array);
  5929. smalltalk.addMethod(
  5930. unescape('_sort'),
  5931. smalltalk.method({
  5932. selector: unescape('sort'),
  5933. category: 'enumerating',
  5934. fn: function (){
  5935. var self=this;
  5936. return smalltalk.send(self, "_basicPerform_", ["sort"]);
  5937. return self;},
  5938. args: [],
  5939. source: unescape('sort%0A%20%20%20%20%5Eself%20basicPerform%3A%20%27sort%27'),
  5940. messageSends: ["basicPerform:"],
  5941. referencedClasses: []
  5942. }),
  5943. smalltalk.Array);
  5944. smalltalk.addMethod(
  5945. unescape('_sort_'),
  5946. smalltalk.method({
  5947. selector: unescape('sort%3A'),
  5948. category: 'enumerating',
  5949. fn: function (aBlock){
  5950. var self=this;
  5951. return self.sort(function(a, b) {
  5952. if(aBlock(a,b)) {return -1} else {return 1}
  5953. })
  5954. ;
  5955. return self;},
  5956. args: ["aBlock"],
  5957. source: unescape('sort%3A%20aBlock%0A%09%3C%0A%09%09return%20self.sort%28function%28a%2C%20b%29%20%7B%0A%09%09%09if%28aBlock%28a%2Cb%29%29%20%7Breturn%20-1%7D%20else%20%7Breturn%201%7D%0A%09%09%7D%29%0A%09%3E'),
  5958. messageSends: [],
  5959. referencedClasses: []
  5960. }),
  5961. smalltalk.Array);
  5962. smalltalk.addMethod(
  5963. unescape('_remove_'),
  5964. smalltalk.method({
  5965. selector: unescape('remove%3A'),
  5966. category: 'adding/removing',
  5967. fn: function (anObject){
  5968. var self=this;
  5969. for(var i=0;i<self.length;i++) {
  5970. if(self[i] == anObject) {
  5971. self.splice(i,1);
  5972. break;
  5973. }
  5974. }
  5975. ;
  5976. return self;},
  5977. args: ["anObject"],
  5978. source: unescape('remove%3A%20anObject%0A%09%3C%0A%09%09for%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%20%7B%0A%09%09%09if%28self%5Bi%5D%20%3D%3D%20anObject%29%20%7B%0A%09%09%09%09self.splice%28i%2C1%29%3B%0A%09%09%09%09break%3B%0A%09%09%09%7D%0A%09%09%7D%0A%09%3E'),
  5979. messageSends: [],
  5980. referencedClasses: []
  5981. }),
  5982. smalltalk.Array);
  5983. smalltalk.addMethod(
  5984. unescape('_sorted'),
  5985. smalltalk.method({
  5986. selector: unescape('sorted'),
  5987. category: 'enumerating',
  5988. fn: function (){
  5989. var self=this;
  5990. return smalltalk.send(smalltalk.send(self, "_copy", []), "_sort", []);
  5991. return self;},
  5992. args: [],
  5993. source: unescape('sorted%0A%09%5Eself%20copy%20sort'),
  5994. messageSends: ["sort", "copy"],
  5995. referencedClasses: []
  5996. }),
  5997. smalltalk.Array);
  5998. smalltalk.addMethod(
  5999. unescape('_sorted_'),
  6000. smalltalk.method({
  6001. selector: unescape('sorted%3A'),
  6002. category: 'enumerating',
  6003. fn: function (aBlock){
  6004. var self=this;
  6005. return smalltalk.send(smalltalk.send(self, "_copy", []), "_sort_", [aBlock]);
  6006. return self;},
  6007. args: ["aBlock"],
  6008. source: unescape('sorted%3A%20aBlock%0A%09%5Eself%20copy%20sort%3A%20aBlock'),
  6009. messageSends: ["sort:", "copy"],
  6010. referencedClasses: []
  6011. }),
  6012. smalltalk.Array);
  6013. smalltalk.addMethod(
  6014. unescape('_removeFrom_to_'),
  6015. smalltalk.method({
  6016. selector: unescape('removeFrom%3Ato%3A'),
  6017. category: 'adding/removing',
  6018. fn: function (aNumber, anotherNumber){
  6019. var self=this;
  6020. self.splice(aNumber - 1,anotherNumber - 1);
  6021. return self;},
  6022. args: ["aNumber", "anotherNumber"],
  6023. source: unescape('removeFrom%3A%20aNumber%20to%3A%20anotherNumber%0A%09%3Cself.splice%28aNumber%20-%201%2CanotherNumber%20-%201%29%3E'),
  6024. messageSends: [],
  6025. referencedClasses: []
  6026. }),
  6027. smalltalk.Array);
  6028. smalltalk.addMethod(
  6029. unescape('_printString'),
  6030. smalltalk.method({
  6031. selector: unescape('printString'),
  6032. category: 'enumerating',
  6033. fn: function (){
  6034. var self=this;
  6035. var str=nil;
  6036. str=smalltalk.send("", "_writeStream", []);
  6037. smalltalk.send(str, "_nextPutAll_", [smalltalk.send(smalltalk.send(self, "_printString", [], smalltalk.SequenceableCollection), "__comma", [unescape("%20%28")])]);
  6038. smalltalk.send(self, "_do_separatedBy_", [(function(each){return smalltalk.send(str, "_nextPutAll_", [smalltalk.send(each, "_printString", [])]);}), (function(){return smalltalk.send(str, "_nextPutAll_", [" "]);})]);
  6039. smalltalk.send(str, "_nextPutAll_", [unescape("%29")]);
  6040. return smalltalk.send(str, "_contents", []);
  6041. return self;},
  6042. args: [],
  6043. source: unescape('printString%0A%09%7C%20str%20%7C%0A%09str%20%3A%3D%20%27%27%20writeStream.%0A%09str%20nextPutAll%3A%20super%20printString%2C%20%27%20%28%27.%0A%09self%20%0A%09%09do%3A%20%5B%3Aeach%20%7C%20str%20nextPutAll%3A%20each%20printString%5D%0A%09%09separatedBy%3A%20%5Bstr%20nextPutAll%3A%20%27%20%27%5D.%0A%09str%20nextPutAll%3A%20%27%29%27.%0A%09%5Estr%20contents'),
  6044. messageSends: ["writeStream", "nextPutAll:", unescape("%2C"), "printString", "do:separatedBy:", "contents"],
  6045. referencedClasses: []
  6046. }),
  6047. smalltalk.Array);
  6048. smalltalk.addMethod(
  6049. unescape('_reversed'),
  6050. smalltalk.method({
  6051. selector: unescape('reversed'),
  6052. category: 'converting',
  6053. fn: function (){
  6054. var self=this;
  6055. return self._copy().reverse();
  6056. return self;},
  6057. args: [],
  6058. source: unescape('reversed%0A%09%3Creturn%20self._copy%28%29.reverse%28%29%3E'),
  6059. messageSends: [],
  6060. referencedClasses: []
  6061. }),
  6062. smalltalk.Array);
  6063. smalltalk.addMethod(
  6064. unescape('__eq'),
  6065. smalltalk.method({
  6066. selector: unescape('%3D'),
  6067. category: 'comparing',
  6068. fn: function (aCollection){
  6069. var self=this;
  6070. try{((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aCollection, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [smalltalk.send(aCollection, "_size", [])]);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  6071. smalltalk.send(self, "_withIndexDo_", [(function(each, i){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_at_", [i]), "__eq", [each])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));})]);
  6072. (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return true}})})();
  6073. return self;
  6074. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  6075. args: ["aCollection"],
  6076. source: unescape('%3D%20aCollection%0A%09%28self%20class%20%3D%20aCollection%20class%20and%3A%20%5B%0A%20%20%20%20%20%20%20%20%09self%20size%20%3D%20aCollection%20size%5D%29%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09self%20withIndexDo%3A%20%5B%3Aeach%20%3Ai%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%28aCollection%20at%3A%20i%29%20%3D%20each%20ifFalse%3A%20%5B%5Efalse%5D%5D.%0A%09%5Etrue'),
  6077. messageSends: ["ifFalse:", "and:", unescape("%3D"), "class", "size", "withIndexDo:", "at:"],
  6078. referencedClasses: []
  6079. }),
  6080. smalltalk.Array);
  6081. smalltalk.addClass('RegularExpression', smalltalk.Object, [], 'Kernel');
  6082. smalltalk.addMethod(
  6083. unescape('_compile_'),
  6084. smalltalk.method({
  6085. selector: unescape('compile%3A'),
  6086. category: 'evaluating',
  6087. fn: function (aString){
  6088. var self=this;
  6089. return self.compile(aString);
  6090. return self;},
  6091. args: ["aString"],
  6092. source: unescape('compile%3A%20aString%0A%09%3Creturn%20self.compile%28aString%29%3E'),
  6093. messageSends: [],
  6094. referencedClasses: []
  6095. }),
  6096. smalltalk.RegularExpression);
  6097. smalltalk.addMethod(
  6098. unescape('_exec_'),
  6099. smalltalk.method({
  6100. selector: unescape('exec%3A'),
  6101. category: 'evaluating',
  6102. fn: function (aString){
  6103. var self=this;
  6104. return self.exec(aString) || nil;
  6105. return self;},
  6106. args: ["aString"],
  6107. source: unescape('exec%3A%20aString%0A%09%3Creturn%20self.exec%28aString%29%20%7C%7C%20nil%3E'),
  6108. messageSends: [],
  6109. referencedClasses: []
  6110. }),
  6111. smalltalk.RegularExpression);
  6112. smalltalk.addMethod(
  6113. unescape('_test_'),
  6114. smalltalk.method({
  6115. selector: unescape('test%3A'),
  6116. category: 'evaluating',
  6117. fn: function (aString){
  6118. var self=this;
  6119. return self.test(aString);
  6120. return self;},
  6121. args: ["aString"],
  6122. source: unescape('test%3A%20aString%0A%09%3Creturn%20self.test%28aString%29%3E'),
  6123. messageSends: [],
  6124. referencedClasses: []
  6125. }),
  6126. smalltalk.RegularExpression);
  6127. smalltalk.addMethod(
  6128. unescape('_fromString_flag_'),
  6129. smalltalk.method({
  6130. selector: unescape('fromString%3Aflag%3A'),
  6131. category: 'instance creation',
  6132. fn: function (aString, anotherString){
  6133. var self=this;
  6134. return new RegExp(aString, anotherString);
  6135. return self;},
  6136. args: ["aString", "anotherString"],
  6137. source: unescape('fromString%3A%20aString%20flag%3A%20anotherString%0A%09%3Creturn%20new%20RegExp%28aString%2C%20anotherString%29%3E'),
  6138. messageSends: [],
  6139. referencedClasses: []
  6140. }),
  6141. smalltalk.RegularExpression.klass);
  6142. smalltalk.addMethod(
  6143. unescape('_fromString_'),
  6144. smalltalk.method({
  6145. selector: unescape('fromString%3A'),
  6146. category: 'instance creation',
  6147. fn: function (aString){
  6148. var self=this;
  6149. return smalltalk.send(self, "_fromString_flag_", [aString, ""]);
  6150. return self;},
  6151. args: ["aString"],
  6152. source: unescape('fromString%3A%20aString%0A%09%20%20%20%20%5Eself%20fromString%3A%20aString%20flag%3A%20%27%27'),
  6153. messageSends: ["fromString:flag:"],
  6154. referencedClasses: []
  6155. }),
  6156. smalltalk.RegularExpression.klass);
  6157. smalltalk.addClass('Error', smalltalk.Object, ['messageText'], 'Kernel');
  6158. smalltalk.addMethod(
  6159. unescape('_messageText'),
  6160. smalltalk.method({
  6161. selector: unescape('messageText'),
  6162. category: 'accessing',
  6163. fn: function (){
  6164. var self=this;
  6165. return self['@messageText'];
  6166. return self;},
  6167. args: [],
  6168. source: unescape('messageText%0A%09%5EmessageText'),
  6169. messageSends: [],
  6170. referencedClasses: []
  6171. }),
  6172. smalltalk.Error);
  6173. smalltalk.addMethod(
  6174. unescape('_messageText_'),
  6175. smalltalk.method({
  6176. selector: unescape('messageText%3A'),
  6177. category: 'accessing',
  6178. fn: function (aString){
  6179. var self=this;
  6180. self['@messageText']=aString;
  6181. return self;},
  6182. args: ["aString"],
  6183. source: unescape('messageText%3A%20aString%0A%09messageText%20%3A%3D%20aString'),
  6184. messageSends: [],
  6185. referencedClasses: []
  6186. }),
  6187. smalltalk.Error);
  6188. smalltalk.addMethod(
  6189. unescape('_signal'),
  6190. smalltalk.method({
  6191. selector: unescape('signal'),
  6192. category: 'signaling',
  6193. fn: function (){
  6194. var self=this;
  6195. self.context = smalltalk.getThisContext(); self.smalltalkError = true; throw(self);
  6196. return self;},
  6197. args: [],
  6198. source: unescape('signal%0A%09%3Cself.context%20%3D%20smalltalk.getThisContext%28%29%3B%20self.smalltalkError%20%3D%20true%3B%20throw%28self%29%3E'),
  6199. messageSends: [],
  6200. referencedClasses: []
  6201. }),
  6202. smalltalk.Error);
  6203. smalltalk.addMethod(
  6204. unescape('_context'),
  6205. smalltalk.method({
  6206. selector: unescape('context'),
  6207. category: 'accessing',
  6208. fn: function (){
  6209. var self=this;
  6210. return self.context;
  6211. return self;},
  6212. args: [],
  6213. source: unescape('context%0A%09%3Creturn%20self.context%3E'),
  6214. messageSends: [],
  6215. referencedClasses: []
  6216. }),
  6217. smalltalk.Error);
  6218. smalltalk.addMethod(
  6219. unescape('_jsStack'),
  6220. smalltalk.method({
  6221. selector: unescape('jsStack'),
  6222. category: 'accessing',
  6223. fn: function (){
  6224. var self=this;
  6225. return self.stack;
  6226. return self;},
  6227. args: [],
  6228. source: unescape('jsStack%0A%09%3Creturn%20self.stack%3E'),
  6229. messageSends: [],
  6230. referencedClasses: []
  6231. }),
  6232. smalltalk.Error);
  6233. smalltalk.addMethod(
  6234. unescape('_isSmalltalkError'),
  6235. smalltalk.method({
  6236. selector: unescape('isSmalltalkError'),
  6237. category: 'testing',
  6238. fn: function (){
  6239. var self=this;
  6240. return self.smalltalkError === true;
  6241. return self;},
  6242. args: [],
  6243. source: unescape('isSmalltalkError%0A%09%3Creturn%20self.smalltalkError%20%3D%3D%3D%20true%3E'),
  6244. messageSends: [],
  6245. referencedClasses: []
  6246. }),
  6247. smalltalk.Error);
  6248. smalltalk.addMethod(
  6249. unescape('_signal_'),
  6250. smalltalk.method({
  6251. selector: unescape('signal%3A'),
  6252. category: 'instance creation',
  6253. fn: function (aString){
  6254. var self=this;
  6255. return (function($rec){smalltalk.send($rec, "_messageText_", [aString]);return smalltalk.send($rec, "_signal", []);})(smalltalk.send(self, "_new", []));
  6256. return self;},
  6257. args: ["aString"],
  6258. source: unescape('signal%3A%20aString%0A%09%20%20%20%20%5Eself%20new%0A%09%09messageText%3A%20aString%3B%0A%09%09signal'),
  6259. messageSends: ["messageText:", "signal", "new"],
  6260. referencedClasses: []
  6261. }),
  6262. smalltalk.Error.klass);
  6263. smalltalk.addClass('MethodContext', smalltalk.Object, [], 'Kernel');
  6264. smalltalk.addMethod(
  6265. unescape('_receiver'),
  6266. smalltalk.method({
  6267. selector: unescape('receiver'),
  6268. category: 'accessing',
  6269. fn: function (){
  6270. var self=this;
  6271. return self.receiver;
  6272. return self;},
  6273. args: [],
  6274. source: unescape('receiver%0A%09%3Creturn%20self.receiver%3E'),
  6275. messageSends: [],
  6276. referencedClasses: []
  6277. }),
  6278. smalltalk.MethodContext);
  6279. smalltalk.addMethod(
  6280. unescape('_selector'),
  6281. smalltalk.method({
  6282. selector: unescape('selector'),
  6283. category: 'accessing',
  6284. fn: function (){
  6285. var self=this;
  6286. return smalltalk.convertSelector(self.selector);
  6287. return self;},
  6288. args: [],
  6289. source: unescape('selector%0A%09%3Creturn%20smalltalk.convertSelector%28self.selector%29%3E'),
  6290. messageSends: [],
  6291. referencedClasses: []
  6292. }),
  6293. smalltalk.MethodContext);
  6294. smalltalk.addMethod(
  6295. unescape('_home'),
  6296. smalltalk.method({
  6297. selector: unescape('home'),
  6298. category: 'accessing',
  6299. fn: function (){
  6300. var self=this;
  6301. return self.homeContext;
  6302. return self;},
  6303. args: [],
  6304. source: unescape('home%0A%09%3Creturn%20self.homeContext%3E'),
  6305. messageSends: [],
  6306. referencedClasses: []
  6307. }),
  6308. smalltalk.MethodContext);
  6309. smalltalk.addMethod(
  6310. unescape('_temps'),
  6311. smalltalk.method({
  6312. selector: unescape('temps'),
  6313. category: 'accessing',
  6314. fn: function (){
  6315. var self=this;
  6316. return self.temps;
  6317. return self;},
  6318. args: [],
  6319. source: unescape('temps%0A%09%3Creturn%20self.temps%3E'),
  6320. messageSends: [],
  6321. referencedClasses: []
  6322. }),
  6323. smalltalk.MethodContext);
  6324. smalltalk.addMethod(
  6325. unescape('_printString'),
  6326. smalltalk.method({
  6327. selector: unescape('printString'),
  6328. category: 'accessing',
  6329. fn: function (){
  6330. var self=this;
  6331. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_printString", [], smalltalk.Object), "__comma", [unescape("%28")]), "__comma", [smalltalk.send(self, "_asString", [])]), "__comma", [unescape("%29")]);
  6332. return self;},
  6333. args: [],
  6334. source: unescape('printString%0A%09%5Esuper%20printString%2C%20%27%28%27%2C%20self%20asString%2C%20%27%29%27'),
  6335. messageSends: [unescape("%2C"), "printString", "asString"],
  6336. referencedClasses: []
  6337. }),
  6338. smalltalk.MethodContext);
  6339. smalltalk.addMethod(
  6340. unescape('_asString'),
  6341. smalltalk.method({
  6342. selector: unescape('asString'),
  6343. category: 'accessing',
  6344. fn: function (){
  6345. var self=this;
  6346. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_receiver", []), "_class", []), "_printString", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(self, "_selector", [])]);
  6347. return self;},
  6348. args: [],
  6349. source: unescape('asString%0A%09%5Eself%20receiver%20class%20printString%2C%20%27%20%3E%3E%20%27%2C%20self%20selector'),
  6350. messageSends: [unescape("%2C"), "printString", "class", "receiver", "selector"],
  6351. referencedClasses: []
  6352. }),
  6353. smalltalk.MethodContext);
  6354. smalltalk.addClass('Association', smalltalk.Object, ['key', 'value'], 'Kernel');
  6355. smalltalk.addMethod(
  6356. unescape('__eq'),
  6357. smalltalk.method({
  6358. selector: unescape('%3D'),
  6359. category: 'comparing',
  6360. fn: function (anAssociation){
  6361. var self=this;
  6362. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(anAssociation, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_key", []), "__eq", [smalltalk.send(anAssociation, "_key", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(self, "_value", []), "__eq", [smalltalk.send(anAssociation, "_value", [])]);})]);})]);
  6363. return self;},
  6364. args: ["anAssociation"],
  6365. source: unescape('%3D%20anAssociation%0A%09%5Eself%20class%20%3D%20anAssociation%20class%20and%3A%20%5B%0A%09%20%20%20%20self%20key%20%3D%20anAssociation%20key%20and%3A%20%5B%0A%09%09self%20value%20%3D%20anAssociation%20value%5D%5D'),
  6366. messageSends: ["and:", unescape("%3D"), "class", "key", "value"],
  6367. referencedClasses: []
  6368. }),
  6369. smalltalk.Association);
  6370. smalltalk.addMethod(
  6371. unescape('_key_'),
  6372. smalltalk.method({
  6373. selector: unescape('key%3A'),
  6374. category: 'accessing',
  6375. fn: function (aKey){
  6376. var self=this;
  6377. self['@key']=aKey;
  6378. return self;},
  6379. args: ["aKey"],
  6380. source: unescape('key%3A%20aKey%0A%09key%20%3A%3D%20aKey'),
  6381. messageSends: [],
  6382. referencedClasses: []
  6383. }),
  6384. smalltalk.Association);
  6385. smalltalk.addMethod(
  6386. unescape('_key'),
  6387. smalltalk.method({
  6388. selector: unescape('key'),
  6389. category: 'accessing',
  6390. fn: function (){
  6391. var self=this;
  6392. return self['@key'];
  6393. return self;},
  6394. args: [],
  6395. source: unescape('key%0A%09%5Ekey'),
  6396. messageSends: [],
  6397. referencedClasses: []
  6398. }),
  6399. smalltalk.Association);
  6400. smalltalk.addMethod(
  6401. unescape('_value_'),
  6402. smalltalk.method({
  6403. selector: unescape('value%3A'),
  6404. category: 'accessing',
  6405. fn: function (aValue){
  6406. var self=this;
  6407. self['@value']=aValue;
  6408. return self;},
  6409. args: ["aValue"],
  6410. source: unescape('value%3A%20aValue%0A%09value%20%3A%3D%20aValue'),
  6411. messageSends: [],
  6412. referencedClasses: []
  6413. }),
  6414. smalltalk.Association);
  6415. smalltalk.addMethod(
  6416. unescape('_value'),
  6417. smalltalk.method({
  6418. selector: unescape('value'),
  6419. category: 'accessing',
  6420. fn: function (){
  6421. var self=this;
  6422. return self['@value'];
  6423. return self;},
  6424. args: [],
  6425. source: unescape('value%0A%09%5Evalue'),
  6426. messageSends: [],
  6427. referencedClasses: []
  6428. }),
  6429. smalltalk.Association);
  6430. smalltalk.addMethod(
  6431. unescape('_storeOn_'),
  6432. smalltalk.method({
  6433. selector: unescape('storeOn%3A'),
  6434. category: 'comparing',
  6435. fn: function (aStream){
  6436. var self=this;
  6437. smalltalk.send(self['@key'], "_storeOn_", [aStream]);
  6438. smalltalk.send(aStream, "_nextPutAll_", [unescape("-%3E")]);
  6439. smalltalk.send(self['@value'], "_storeOn_", [aStream]);
  6440. return self;},
  6441. args: ["aStream"],
  6442. source: unescape('storeOn%3A%20aStream%0A%09%22Store%20in%20the%20format%20%28key-%3Evalue%29%22%0A%0A%09%22aStream%20nextPutAll%3A%20%27%28%27.%22%0A%09key%20storeOn%3A%20aStream.%0A%09aStream%20nextPutAll%3A%20%27-%3E%27.%0A%09value%20storeOn%3A%20aStream.%0A%09%22aStream%20nextPutAll%3A%20%27%29%27%22'),
  6443. messageSends: ["storeOn:", "nextPutAll:"],
  6444. referencedClasses: []
  6445. }),
  6446. smalltalk.Association);
  6447. smalltalk.addMethod(
  6448. unescape('_key_value_'),
  6449. smalltalk.method({
  6450. selector: unescape('key%3Avalue%3A'),
  6451. category: 'instance creation',
  6452. fn: function (aKey, aValue){
  6453. var self=this;
  6454. return (function($rec){smalltalk.send($rec, "_key_", [aKey]);smalltalk.send($rec, "_value_", [aValue]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  6455. return self;},
  6456. args: ["aKey", "aValue"],
  6457. source: unescape('key%3A%20aKey%20value%3A%20aValue%0A%09%20%20%20%20%5Eself%20new%0A%09%09key%3A%20aKey%3B%0A%09%09value%3A%20aValue%3B%0A%09%09yourself'),
  6458. messageSends: ["key:", "value:", "yourself", "new"],
  6459. referencedClasses: []
  6460. }),
  6461. smalltalk.Association.klass);
  6462. smalltalk.addClass('Dictionary', smalltalk.Collection, [], 'Kernel');
  6463. smalltalk.addMethod(
  6464. unescape('__eq'),
  6465. smalltalk.method({
  6466. selector: unescape('%3D'),
  6467. category: 'comparing',
  6468. fn: function (aDictionary){
  6469. var self=this;
  6470. try{((($receiver = smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aDictionary, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  6471. ((($receiver = smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [smalltalk.send(aDictionary, "_size", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  6472. (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return smalltalk.send(smalltalk.send(self, "_associations", []), "__eq", [smalltalk.send(aDictionary, "_associations", [])])}})})();
  6473. return self;
  6474. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  6475. args: ["aDictionary"],
  6476. source: unescape('%3D%20aDictionary%0A%09self%20class%20%3D%20aDictionary%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09self%20size%20%3D%20aDictionary%20size%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%5Eself%20associations%20%3D%20aDictionary%20associations'),
  6477. messageSends: ["ifFalse:", unescape("%3D"), "class", "size", "associations"],
  6478. referencedClasses: []
  6479. }),
  6480. smalltalk.Dictionary);
  6481. smalltalk.addMethod(
  6482. unescape('_shallowCopy'),
  6483. smalltalk.method({
  6484. selector: unescape('shallowCopy'),
  6485. category: 'copying',
  6486. fn: function (){
  6487. var self=this;
  6488. var copy=nil;
  6489. copy=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6490. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(copy, "_at_put_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  6491. return copy;
  6492. return self;},
  6493. args: [],
  6494. source: unescape('shallowCopy%0A%09%7C%20copy%20%7C%0A%09copy%20%3A%3D%20self%20class%20new.%0A%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20copy%20at%3A%20each%20key%20%20put%3A%20each%20value%5D.%0A%09%5Ecopy'),
  6495. messageSends: ["new", "class", "associationsDo:", "at:put:", "key", "value"],
  6496. referencedClasses: []
  6497. }),
  6498. smalltalk.Dictionary);
  6499. smalltalk.addMethod(
  6500. unescape('_size'),
  6501. smalltalk.method({
  6502. selector: unescape('size'),
  6503. category: 'accessing',
  6504. fn: function (){
  6505. var self=this;
  6506. return smalltalk.send(smalltalk.send(self, "_keys", []), "_size", []);
  6507. return self;},
  6508. args: [],
  6509. source: unescape('size%0A%09%5Eself%20keys%20size'),
  6510. messageSends: ["size", "keys"],
  6511. referencedClasses: []
  6512. }),
  6513. smalltalk.Dictionary);
  6514. smalltalk.addMethod(
  6515. unescape('_associations'),
  6516. smalltalk.method({
  6517. selector: unescape('associations'),
  6518. category: 'accessing',
  6519. fn: function (){
  6520. var self=this;
  6521. var associations=nil;
  6522. associations=[];
  6523. smalltalk.send(smalltalk.send(self, "_keys", []), "_do_", [(function(each){return smalltalk.send(associations, "_add_", [smalltalk.send((smalltalk.Association || Association), "_key_value_", [each, smalltalk.send(self, "_at_", [each])])]);})]);
  6524. return associations;
  6525. return self;},
  6526. args: [],
  6527. source: unescape('associations%0A%09%7C%20associations%20%7C%0A%09associations%20%3A%3D%20%23%28%29.%0A%09self%20keys%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20associations%20add%3A%20%28Association%20key%3A%20each%20value%3A%20%28self%20at%3A%20each%29%29%5D.%0A%09%5Eassociations'),
  6528. messageSends: ["do:", "keys", "add:", "key:value:", "at:"],
  6529. referencedClasses: ["Association"]
  6530. }),
  6531. smalltalk.Dictionary);
  6532. smalltalk.addMethod(
  6533. unescape('_keys'),
  6534. smalltalk.method({
  6535. selector: unescape('keys'),
  6536. category: 'accessing',
  6537. fn: function (){
  6538. var self=this;
  6539. var keys = [];
  6540. for(var i in self) {
  6541. if(self.hasOwnProperty(i)) {
  6542. keys.push(i);
  6543. }
  6544. };
  6545. return keys;
  6546. ;
  6547. return self;},
  6548. args: [],
  6549. source: unescape('keys%0A%09%3C%0A%09%09var%20keys%20%3D%20%5B%5D%3B%0A%09%09for%28var%20i%20in%20self%29%20%7B%0A%09%09%09if%28self.hasOwnProperty%28i%29%29%20%7B%0A%09%09%09%09keys.push%28i%29%3B%0A%09%09%09%7D%0A%09%09%7D%3B%0A%09%09return%20keys%3B%0A%09%3E'),
  6550. messageSends: [],
  6551. referencedClasses: []
  6552. }),
  6553. smalltalk.Dictionary);
  6554. smalltalk.addMethod(
  6555. unescape('_values'),
  6556. smalltalk.method({
  6557. selector: unescape('values'),
  6558. category: 'accessing',
  6559. fn: function (){
  6560. var self=this;
  6561. return smalltalk.send(smalltalk.send(self, "_keys", []), "_collect_", [(function(each){return smalltalk.send(self, "_at_", [each]);})]);
  6562. return self;},
  6563. args: [],
  6564. source: unescape('values%0A%20%20%20%20%09%5Eself%20keys%20collect%3A%20%5B%3Aeach%20%7C%20self%20at%3A%20each%5D'),
  6565. messageSends: ["collect:", "keys", "at:"],
  6566. referencedClasses: []
  6567. }),
  6568. smalltalk.Dictionary);
  6569. smalltalk.addMethod(
  6570. unescape('_at_put_'),
  6571. smalltalk.method({
  6572. selector: unescape('at%3Aput%3A'),
  6573. category: 'accessing',
  6574. fn: function (aKey, aValue){
  6575. var self=this;
  6576. return smalltalk.send(self, "_basicAt_put_", [aKey, aValue]);
  6577. return self;},
  6578. args: ["aKey", "aValue"],
  6579. source: unescape('at%3A%20aKey%20put%3A%20aValue%0A%09%5Eself%20basicAt%3A%20aKey%20put%3A%20aValue'),
  6580. messageSends: ["basicAt:put:"],
  6581. referencedClasses: []
  6582. }),
  6583. smalltalk.Dictionary);
  6584. smalltalk.addMethod(
  6585. unescape('_at_ifAbsent_'),
  6586. smalltalk.method({
  6587. selector: unescape('at%3AifAbsent%3A'),
  6588. category: 'accessing',
  6589. fn: function (aKey, aBlock){
  6590. var self=this;
  6591. return smalltalk.send(smalltalk.send(self, "_includesKey_", [aKey]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_basicAt_", [aKey]);}), aBlock]);
  6592. return self;},
  6593. args: ["aKey", "aBlock"],
  6594. source: unescape('at%3A%20aKey%20ifAbsent%3A%20aBlock%0A%09%5E%28self%20includesKey%3A%20aKey%29%0A%09%09ifTrue%3A%20%5Bself%20basicAt%3A%20aKey%5D%0A%09%09ifFalse%3A%20aBlock'),
  6595. messageSends: ["ifTrue:ifFalse:", "includesKey:", "basicAt:"],
  6596. referencedClasses: []
  6597. }),
  6598. smalltalk.Dictionary);
  6599. smalltalk.addMethod(
  6600. unescape('_at_ifAbsentPut_'),
  6601. smalltalk.method({
  6602. selector: unescape('at%3AifAbsentPut%3A'),
  6603. category: 'accessing',
  6604. fn: function (aKey, aBlock){
  6605. var self=this;
  6606. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_at_put_", [aKey, smalltalk.send(aBlock, "_value", [])]);})]);
  6607. return self;},
  6608. args: ["aKey", "aBlock"],
  6609. source: unescape('at%3A%20aKey%20ifAbsentPut%3A%20aBlock%0A%20%20%20%20%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5B%0A%20%20%20%20%09%20%20%20%20self%20at%3A%20aKey%20put%3A%20aBlock%20value%5D'),
  6610. messageSends: ["at:ifAbsent:", "at:put:", "value"],
  6611. referencedClasses: []
  6612. }),
  6613. smalltalk.Dictionary);
  6614. smalltalk.addMethod(
  6615. unescape('_at_ifPresent_'),
  6616. smalltalk.method({
  6617. selector: unescape('at%3AifPresent%3A'),
  6618. category: 'accessing',
  6619. fn: function (aKey, aBlock){
  6620. var self=this;
  6621. return (($receiver = smalltalk.send(self, "_basicAt_", [aKey])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})() : nil;
  6622. return self;},
  6623. args: ["aKey", "aBlock"],
  6624. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  6625. messageSends: ["ifNotNil:", "basicAt:", "value:", "at:"],
  6626. referencedClasses: []
  6627. }),
  6628. smalltalk.Dictionary);
  6629. smalltalk.addMethod(
  6630. unescape('_at_ifPresent_ifAbsent_'),
  6631. smalltalk.method({
  6632. selector: unescape('at%3AifPresent%3AifAbsent%3A'),
  6633. category: 'accessing',
  6634. fn: function (aKey, aBlock, anotherBlock){
  6635. var self=this;
  6636. return smalltalk.send(smalltalk.send(self, "_basicAt_", [aKey]), "_ifNil_ifNotNil_", [anotherBlock, (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})]);
  6637. return self;},
  6638. args: ["aKey", "aBlock", "anotherBlock"],
  6639. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%20ifAbsent%3A%20anotherBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%0A%09%20%20%20%20ifNil%3A%20anotherBlock%0A%09%20%20%20%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  6640. messageSends: ["ifNil:ifNotNil:", "basicAt:", "value:", "at:"],
  6641. referencedClasses: []
  6642. }),
  6643. smalltalk.Dictionary);
  6644. smalltalk.addMethod(
  6645. unescape('_add_'),
  6646. smalltalk.method({
  6647. selector: unescape('add%3A'),
  6648. category: 'adding/removing',
  6649. fn: function (anAssociation){
  6650. var self=this;
  6651. smalltalk.send(self, "_at_put_", [smalltalk.send(anAssociation, "_key", []), smalltalk.send(anAssociation, "_value", [])]);
  6652. return self;},
  6653. args: ["anAssociation"],
  6654. source: unescape('add%3A%20anAssociation%0A%20%20%20%20%09self%20at%3A%20anAssociation%20key%20put%3A%20anAssociation%20value'),
  6655. messageSends: ["at:put:", "key", "value"],
  6656. referencedClasses: []
  6657. }),
  6658. smalltalk.Dictionary);
  6659. smalltalk.addMethod(
  6660. unescape('_addAll_'),
  6661. smalltalk.method({
  6662. selector: unescape('addAll%3A'),
  6663. category: 'adding/removing',
  6664. fn: function (aDictionary){
  6665. var self=this;
  6666. smalltalk.send(self, "_addAll_", [smalltalk.send(aDictionary, "_associations", [])], smalltalk.Collection);
  6667. return aDictionary;
  6668. return self;},
  6669. args: ["aDictionary"],
  6670. source: unescape('addAll%3A%20aDictionary%0A%20%20%20%20%09super%20addAll%3A%20aDictionary%20associations.%0A%20%20%20%20%09%5EaDictionary'),
  6671. messageSends: ["addAll:", "associations"],
  6672. referencedClasses: []
  6673. }),
  6674. smalltalk.Dictionary);
  6675. smalltalk.addMethod(
  6676. unescape('__comma'),
  6677. smalltalk.method({
  6678. selector: unescape('%2C'),
  6679. category: 'copying',
  6680. fn: function (aCollection){
  6681. var self=this;
  6682. smalltalk.send(self, "_shouldNotImplement", []);
  6683. return self;},
  6684. args: ["aCollection"],
  6685. source: unescape('%2C%20aCollection%0A%09self%20shouldNotImplement'),
  6686. messageSends: ["shouldNotImplement"],
  6687. referencedClasses: []
  6688. }),
  6689. smalltalk.Dictionary);
  6690. smalltalk.addMethod(
  6691. unescape('_copyFrom_to_'),
  6692. smalltalk.method({
  6693. selector: unescape('copyFrom%3Ato%3A'),
  6694. category: 'copying',
  6695. fn: function (anIndex, anotherIndex){
  6696. var self=this;
  6697. smalltalk.send(self, "_shouldNotImplement", []);
  6698. return self;},
  6699. args: ["anIndex", "anotherIndex"],
  6700. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09self%20shouldNotImplement'),
  6701. messageSends: ["shouldNotImplement"],
  6702. referencedClasses: []
  6703. }),
  6704. smalltalk.Dictionary);
  6705. smalltalk.addMethod(
  6706. unescape('_associationsDo_'),
  6707. smalltalk.method({
  6708. selector: unescape('associationsDo%3A'),
  6709. category: 'enumerating',
  6710. fn: function (aBlock){
  6711. var self=this;
  6712. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_", [aBlock]);
  6713. return self;},
  6714. args: ["aBlock"],
  6715. source: unescape('associationsDo%3A%20aBlock%0A%20%20%20%20%09self%20associations%20do%3A%20aBlock'),
  6716. messageSends: ["do:", "associations"],
  6717. referencedClasses: []
  6718. }),
  6719. smalltalk.Dictionary);
  6720. smalltalk.addMethod(
  6721. unescape('_keysAndValuesDo_'),
  6722. smalltalk.method({
  6723. selector: unescape('keysAndValuesDo%3A'),
  6724. category: 'enumerating',
  6725. fn: function (aBlock){
  6726. var self=this;
  6727. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(aBlock, "_value_value_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  6728. return self;},
  6729. args: ["aBlock"],
  6730. source: unescape('keysAndValuesDo%3A%20aBlock%0A%20%20%20%20%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%09%20%20%20%20aBlock%20value%3A%20each%20key%20value%3A%20each%20value%5D'),
  6731. messageSends: ["associationsDo:", "value:value:", "key", "value"],
  6732. referencedClasses: []
  6733. }),
  6734. smalltalk.Dictionary);
  6735. smalltalk.addMethod(
  6736. unescape('_do_'),
  6737. smalltalk.method({
  6738. selector: unescape('do%3A'),
  6739. category: 'enumerating',
  6740. fn: function (aBlock){
  6741. var self=this;
  6742. smalltalk.send(smalltalk.send(self, "_values", []), "_do_", [aBlock]);
  6743. return self;},
  6744. args: ["aBlock"],
  6745. source: unescape('do%3A%20aBlock%0A%20%20%20%20%09self%20values%20do%3A%20aBlock'),
  6746. messageSends: ["do:", "values"],
  6747. referencedClasses: []
  6748. }),
  6749. smalltalk.Dictionary);
  6750. smalltalk.addMethod(
  6751. unescape('_select_'),
  6752. smalltalk.method({
  6753. selector: unescape('select%3A'),
  6754. category: 'enumerating',
  6755. fn: function (aBlock){
  6756. var self=this;
  6757. var newDict=nil;
  6758. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6759. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return ((($receiver = smalltalk.send(aBlock, "_value_", [value])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})]));})]);
  6760. return newDict;
  6761. return self;},
  6762. args: ["aBlock"],
  6763. source: unescape('select%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20%28aBlock%20value%3A%20value%29%20ifTrue%3A%20%5BnewDict%20at%3A%20key%20put%3A%20value%5D%5D.%0A%20%20%20%20%09%5EnewDict'),
  6764. messageSends: ["new", "class", "keysAndValuesDo:", "ifTrue:", "value:", "at:put:"],
  6765. referencedClasses: []
  6766. }),
  6767. smalltalk.Dictionary);
  6768. smalltalk.addMethod(
  6769. unescape('_collect_'),
  6770. smalltalk.method({
  6771. selector: unescape('collect%3A'),
  6772. category: 'enumerating',
  6773. fn: function (aBlock){
  6774. var self=this;
  6775. var newDict=nil;
  6776. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6777. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(newDict, "_at_put_", [key, smalltalk.send(aBlock, "_value_", [value])]);})]);
  6778. return newDict;
  6779. return self;},
  6780. args: ["aBlock"],
  6781. source: unescape('collect%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20newDict%20at%3A%20key%20put%3A%20%28aBlock%20value%3A%20value%29%5D.%0A%20%20%20%20%09%5EnewDict'),
  6782. messageSends: ["new", "class", "keysAndValuesDo:", "at:put:", "value:"],
  6783. referencedClasses: []
  6784. }),
  6785. smalltalk.Dictionary);
  6786. smalltalk.addMethod(
  6787. unescape('_detect_ifNone_'),
  6788. smalltalk.method({
  6789. selector: unescape('detect%3AifNone%3A'),
  6790. category: 'enumerating',
  6791. fn: function (aBlock, anotherBlock){
  6792. var self=this;
  6793. return smalltalk.send(smalltalk.send(self, "_values", []), "_detect_ifNone_", [aBlock, anotherBlock]);
  6794. return self;},
  6795. args: ["aBlock", "anotherBlock"],
  6796. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%5Eself%20values%20detect%3A%20aBlock%20ifNone%3A%20anotherBlock'),
  6797. messageSends: ["detect:ifNone:", "values"],
  6798. referencedClasses: []
  6799. }),
  6800. smalltalk.Dictionary);
  6801. smalltalk.addMethod(
  6802. unescape('_includes_'),
  6803. smalltalk.method({
  6804. selector: unescape('includes%3A'),
  6805. category: 'enumerating',
  6806. fn: function (anObject){
  6807. var self=this;
  6808. return smalltalk.send(smalltalk.send(self, "_values", []), "_includes_", [anObject]);
  6809. return self;},
  6810. args: ["anObject"],
  6811. source: unescape('includes%3A%20anObject%0A%09%5Eself%20values%20includes%3A%20anObject'),
  6812. messageSends: ["includes:", "values"],
  6813. referencedClasses: []
  6814. }),
  6815. smalltalk.Dictionary);
  6816. smalltalk.addMethod(
  6817. unescape('_removeKey_'),
  6818. smalltalk.method({
  6819. selector: unescape('removeKey%3A'),
  6820. category: 'adding/removing',
  6821. fn: function (aKey){
  6822. var self=this;
  6823. smalltalk.send(self, "_remove_", [aKey]);
  6824. return self;},
  6825. args: ["aKey"],
  6826. source: unescape('removeKey%3A%20aKey%0A%20%20%20%20self%20remove%3A%20aKey'),
  6827. messageSends: ["remove:"],
  6828. referencedClasses: []
  6829. }),
  6830. smalltalk.Dictionary);
  6831. smalltalk.addMethod(
  6832. unescape('_at_'),
  6833. smalltalk.method({
  6834. selector: unescape('at%3A'),
  6835. category: 'accessing',
  6836. fn: function (aKey){
  6837. var self=this;
  6838. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  6839. return self;},
  6840. args: ["aKey"],
  6841. source: unescape('at%3A%20aKey%0A%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  6842. messageSends: ["at:ifAbsent:", "errorNotFound"],
  6843. referencedClasses: []
  6844. }),
  6845. smalltalk.Dictionary);
  6846. smalltalk.addMethod(
  6847. unescape('_printString'),
  6848. smalltalk.method({
  6849. selector: unescape('printString'),
  6850. category: 'printing',
  6851. fn: function (){
  6852. var self=this;
  6853. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(aStream){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_printString", [], smalltalk.Collection)]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%28")]);})(aStream);smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(anAssociation){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_key", []), "_printString", [])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%20-%3E%20")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_value", []), "_printString", [])]);})(aStream);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%20%2C%20")]);})]);return smalltalk.send(aStream, "_nextPutAll_", [unescape("%29")]);})]);
  6854. return self;},
  6855. args: [],
  6856. source: unescape('printString%0A%09%5EString%20streamContents%3A%20%5B%3AaStream%7C%20%20%0A%09%09aStream%20%0A%09%09%09nextPutAll%3A%20super%20printString%3B%0A%09%09%09nextPutAll%3A%20%27%28%27.%0A%09%09%09%09self%20associations%20%0A%09%09%09%09%09do%3A%20%5B%3AanAssociation%7C%20%20%0A%09%09%09%09%09%09aStream%20%0A%09%09%09%09%09%09%09nextPutAll%3A%20anAssociation%20key%20printString%3B%0A%09%09%09%09%09%09%09%09nextPutAll%3A%20%27%20-%3E%20%27%3B%0A%09%09%09%09%09%09%09%09nextPutAll%3A%20anAssociation%20value%20printString%5D%0A%09%09%09%09%09%09%09separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%20%2C%20%27%5D.%0A%09%09%09%09%09%09aStream%20nextPutAll%3A%20%27%29%27%5D'),
  6857. messageSends: ["streamContents:", "nextPutAll:", "printString", "do:separatedBy:", "associations", "key", "value"],
  6858. referencedClasses: ["String"]
  6859. }),
  6860. smalltalk.Dictionary);
  6861. smalltalk.addMethod(
  6862. unescape('_storeOn_'),
  6863. smalltalk.method({
  6864. selector: unescape('storeOn%3A'),
  6865. category: 'printing',
  6866. fn: function (aStream){
  6867. var self=this;
  6868. smalltalk.send(aStream, "_nextPutAll_", [unescape("%23%7B")]);
  6869. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(each){return smalltalk.send(each, "_storeOn_", [aStream]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [". "]);})]);
  6870. smalltalk.send(aStream, "_nextPutAll_", [unescape("%7D")]);
  6871. return self;},
  6872. args: ["aStream"],
  6873. source: unescape('storeOn%3A%20aStream%0A%09aStream%20nextPutAll%3A%20%27%23%7B%27.%0A%09self%20associations%0A%09%09do%3A%20%5B%3Aeach%20%7C%20each%20storeOn%3A%20aStream%5D%0A%09%09separatedBy%3A%20%5B%20aStream%20nextPutAll%3A%20%27.%20%27%5D.%0A%09aStream%20nextPutAll%3A%20%27%7D%27'),
  6874. messageSends: ["nextPutAll:", "do:separatedBy:", "associations", "storeOn:"],
  6875. referencedClasses: []
  6876. }),
  6877. smalltalk.Dictionary);
  6878. smalltalk.addMethod(
  6879. unescape('_includesKey_'),
  6880. smalltalk.method({
  6881. selector: unescape('includesKey%3A'),
  6882. category: 'testing',
  6883. fn: function (aKey){
  6884. var self=this;
  6885. return self.hasOwnProperty(aKey);
  6886. return self;},
  6887. args: ["aKey"],
  6888. source: unescape('includesKey%3A%20aKey%0A%09%3Creturn%20self.hasOwnProperty%28aKey%29%3E'),
  6889. messageSends: [],
  6890. referencedClasses: []
  6891. }),
  6892. smalltalk.Dictionary);
  6893. smalltalk.addMethod(
  6894. unescape('_remove_ifAbsent_'),
  6895. smalltalk.method({
  6896. selector: unescape('remove%3AifAbsent%3A'),
  6897. category: 'adding/removing',
  6898. fn: function (aKey, aBlock){
  6899. var self=this;
  6900. return smalltalk.send(self, "_removeKey_ifAbsent_", [aKey, aBlock]);
  6901. return self;},
  6902. args: ["aKey", "aBlock"],
  6903. source: unescape('remove%3A%20aKey%20ifAbsent%3A%20aBlock%0A%20%20%20%20%5Eself%20removeKey%3A%20aKey%20ifAbsent%3A%20aBlock'),
  6904. messageSends: ["removeKey:ifAbsent:"],
  6905. referencedClasses: []
  6906. }),
  6907. smalltalk.Dictionary);
  6908. smalltalk.addMethod(
  6909. unescape('_removeKey_ifAbsent_'),
  6910. smalltalk.method({
  6911. selector: unescape('removeKey%3AifAbsent%3A'),
  6912. category: 'adding/removing',
  6913. fn: function (aKey, aBlock){
  6914. var self=this;
  6915. return ((($receiver = smalltalk.send(self, "_includesKey_", [aKey])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(aBlock, "_value", []);})() : (function(){return smalltalk.send(self, "_basicDelete_", [aKey]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(aBlock, "_value", []);}), (function(){return smalltalk.send(self, "_basicDelete_", [aKey]);})]));
  6916. return self;},
  6917. args: ["aKey", "aBlock"],
  6918. source: unescape('removeKey%3A%20aKey%20ifAbsent%3A%20aBlock%0A%09%5E%28self%20includesKey%3A%20aKey%29%20%0A%09%09ifFalse%3A%20%5BaBlock%20value%5D%0A%09%09ifTrue%3A%20%5Bself%20basicDelete%3A%20aKey%5D'),
  6919. messageSends: ["ifFalse:ifTrue:", "includesKey:", "value", "basicDelete:"],
  6920. referencedClasses: []
  6921. }),
  6922. smalltalk.Dictionary);
  6923. smalltalk.addMethod(
  6924. unescape('_deepCopy'),
  6925. smalltalk.method({
  6926. selector: unescape('deepCopy'),
  6927. category: 'copying',
  6928. fn: function (){
  6929. var self=this;
  6930. var copy=nil;
  6931. copy=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6932. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(copy, "_at_put_", [smalltalk.send(each, "_key", []), smalltalk.send(smalltalk.send(each, "_value", []), "_deepCopy", [])]);})]);
  6933. return copy;
  6934. return self;},
  6935. args: [],
  6936. source: unescape('deepCopy%0A%09%7C%20copy%20%7C%0A%09copy%20%3A%3D%20self%20class%20new.%0A%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20copy%20at%3A%20each%20key%20%20put%3A%20each%20value%20deepCopy%5D.%0A%09%5Ecopy'),
  6937. messageSends: ["new", "class", "associationsDo:", "at:put:", "key", "deepCopy", "value"],
  6938. referencedClasses: []
  6939. }),
  6940. smalltalk.Dictionary);
  6941. smalltalk.addMethod(
  6942. unescape('_fromPairs_'),
  6943. smalltalk.method({
  6944. selector: unescape('fromPairs%3A'),
  6945. category: 'instance creation',
  6946. fn: function (aCollection){
  6947. var self=this;
  6948. var dict=nil;
  6949. dict=smalltalk.send(self, "_new", []);
  6950. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(dict, "_add_", [each]);})]);
  6951. return dict;
  6952. return self;},
  6953. args: ["aCollection"],
  6954. source: unescape('fromPairs%3A%20aCollection%0A%09%7C%20dict%20%7C%0A%09dict%20%3A%3D%20self%20new.%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%20dict%20add%3A%20each%5D.%0A%09%5Edict'),
  6955. messageSends: ["new", "do:", "add:"],
  6956. referencedClasses: []
  6957. }),
  6958. smalltalk.Dictionary.klass);
  6959. smalltalk.addClass('ClassBuilder', smalltalk.Object, [], 'Kernel');
  6960. smalltalk.addMethod(
  6961. unescape('_superclass_subclass_'),
  6962. smalltalk.method({
  6963. selector: unescape('superclass%3Asubclass%3A'),
  6964. category: 'class creation',
  6965. fn: function (aClass, aString){
  6966. var self=this;
  6967. return smalltalk.send(self, "_superclass_subclass_instanceVariableNames_package_", [aClass, aString, "", nil]);
  6968. return self;},
  6969. args: ["aClass", "aString"],
  6970. source: unescape('superclass%3A%20aClass%20subclass%3A%20aString%0A%09%5Eself%20superclass%3A%20aClass%20subclass%3A%20aString%20instanceVariableNames%3A%20%27%27%20package%3A%20nil'),
  6971. messageSends: ["superclass:subclass:instanceVariableNames:package:"],
  6972. referencedClasses: []
  6973. }),
  6974. smalltalk.ClassBuilder);
  6975. smalltalk.addMethod(
  6976. unescape('_class_instanceVariableNames_'),
  6977. smalltalk.method({
  6978. selector: unescape('class%3AinstanceVariableNames%3A'),
  6979. category: 'class creation',
  6980. fn: function (aClass, aString){
  6981. var self=this;
  6982. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_name", []), "__comma", [" is not a metaclass"])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_name", []), "__comma", [" is not a metaclass"])]);})]));
  6983. smalltalk.send(aClass, "_basicAt_put_", ["iVarNames", smalltalk.send(self, "_instanceVariableNamesFor_", [aString])]);
  6984. smalltalk.send(self, "_setupClass_", [aClass]);
  6985. return self;},
  6986. args: ["aClass", "aString"],
  6987. source: unescape('class%3A%20aClass%20instanceVariableNames%3A%20aString%0A%09aClass%20isMetaclass%20ifFalse%3A%20%5Bself%20error%3A%20aClass%20name%2C%20%27%20is%20not%20a%20metaclass%27%5D.%0A%09aClass%20basicAt%3A%20%27iVarNames%27%20put%3A%20%28self%20instanceVariableNamesFor%3A%20aString%29.%0A%09self%20setupClass%3A%20aClass'),
  6988. messageSends: ["ifFalse:", "isMetaclass", "error:", unescape("%2C"), "name", "basicAt:put:", "instanceVariableNamesFor:", "setupClass:"],
  6989. referencedClasses: []
  6990. }),
  6991. smalltalk.ClassBuilder);
  6992. smalltalk.addMethod(
  6993. unescape('_instanceVariableNamesFor_'),
  6994. smalltalk.method({
  6995. selector: unescape('instanceVariableNamesFor%3A'),
  6996. category: 'private',
  6997. fn: function (aString){
  6998. var self=this;
  6999. return smalltalk.send(smalltalk.send(aString, "_tokenize_", [" "]), "_reject_", [(function(each){return smalltalk.send(each, "_isEmpty", []);})]);
  7000. return self;},
  7001. args: ["aString"],
  7002. source: unescape('instanceVariableNamesFor%3A%20aString%0A%09%5E%28aString%20tokenize%3A%20%27%20%27%29%20reject%3A%20%5B%3Aeach%20%7C%20each%20isEmpty%5D'),
  7003. messageSends: ["reject:", "tokenize:", "isEmpty"],
  7004. referencedClasses: []
  7005. }),
  7006. smalltalk.ClassBuilder);
  7007. smalltalk.addMethod(
  7008. unescape('_addSubclassOf_named_instanceVariableNames_'),
  7009. smalltalk.method({
  7010. selector: unescape('addSubclassOf%3Anamed%3AinstanceVariableNames%3A'),
  7011. category: 'private',
  7012. fn: function (aClass, aString, aCollection){
  7013. var self=this;
  7014. smalltalk.addClass(aString, aClass, aCollection);
  7015. return smalltalk[aString];
  7016. return self;},
  7017. args: ["aClass", "aString", "aCollection"],
  7018. source: unescape('addSubclassOf%3A%20aClass%20named%3A%20aString%20instanceVariableNames%3A%20aCollection%0A%09%3Csmalltalk.addClass%28aString%2C%20aClass%2C%20aCollection%29%3B%0A%09%20%20%20%20return%20smalltalk%5BaString%5D%3E'),
  7019. messageSends: [],
  7020. referencedClasses: []
  7021. }),
  7022. smalltalk.ClassBuilder);
  7023. smalltalk.addMethod(
  7024. unescape('_setupClass_'),
  7025. smalltalk.method({
  7026. selector: unescape('setupClass%3A'),
  7027. category: 'private',
  7028. fn: function (aClass){
  7029. var self=this;
  7030. smalltalk.init(aClass);;
  7031. return self;},
  7032. args: ["aClass"],
  7033. source: unescape('setupClass%3A%20aClass%0A%09%3Csmalltalk.init%28aClass%29%3B%3E'),
  7034. messageSends: [],
  7035. referencedClasses: []
  7036. }),
  7037. smalltalk.ClassBuilder);
  7038. smalltalk.addMethod(
  7039. unescape('_superclass_subclass_instanceVariableNames_package_'),
  7040. smalltalk.method({
  7041. selector: unescape('superclass%3Asubclass%3AinstanceVariableNames%3Apackage%3A'),
  7042. category: 'class creation',
  7043. fn: function (aClass, aString, aString2, aString3){
  7044. var self=this;
  7045. var newClass=nil;
  7046. newClass=smalltalk.send(self, "_addSubclassOf_named_instanceVariableNames_package_", [aClass, aString, smalltalk.send(self, "_instanceVariableNamesFor_", [aString2]), (($receiver = aString3) == nil || $receiver == undefined) ? (function(){return "unclassified";})() : $receiver]);
  7047. smalltalk.send(self, "_setupClass_", [newClass]);
  7048. return newClass;
  7049. return self;},
  7050. args: ["aClass", "aString", "aString2", "aString3"],
  7051. source: unescape('superclass%3A%20aClass%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%7C%20newClass%20%7C%0A%09newClass%20%3A%3D%20self%20addSubclassOf%3A%20aClass%0A%09%09%09%09named%3A%20aString%20instanceVariableNames%3A%20%28self%20instanceVariableNamesFor%3A%20aString2%29%0A%09%09%09%09package%3A%20%28aString3%20ifNil%3A%20%5B%27unclassified%27%5D%29.%0A%09self%20setupClass%3A%20newClass.%0A%09%5EnewClass'),
  7052. messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "instanceVariableNamesFor:", "ifNil:", "setupClass:"],
  7053. referencedClasses: []
  7054. }),
  7055. smalltalk.ClassBuilder);
  7056. smalltalk.addMethod(
  7057. unescape('_addSubclassOf_named_instanceVariableNames_package_'),
  7058. smalltalk.method({
  7059. selector: unescape('addSubclassOf%3Anamed%3AinstanceVariableNames%3Apackage%3A'),
  7060. category: 'private',
  7061. fn: function (aClass, aString, aCollection, packageName){
  7062. var self=this;
  7063. smalltalk.addClass(aString, aClass, aCollection, packageName);
  7064. return smalltalk[aString];
  7065. return self;},
  7066. args: ["aClass", "aString", "aCollection", "packageName"],
  7067. source: unescape('addSubclassOf%3A%20aClass%20named%3A%20aString%20instanceVariableNames%3A%20aCollection%20package%3A%20packageName%0A%09%3Csmalltalk.addClass%28aString%2C%20aClass%2C%20aCollection%2C%20packageName%29%3B%0A%09%20%20%20%20return%20smalltalk%5BaString%5D%3E'),
  7068. messageSends: [],
  7069. referencedClasses: []
  7070. }),
  7071. smalltalk.ClassBuilder);
  7072. smalltalk.addMethod(
  7073. unescape('_copyClass_named_'),
  7074. smalltalk.method({
  7075. selector: unescape('copyClass%3Anamed%3A'),
  7076. category: 'private',
  7077. fn: function (aClass, aString){
  7078. var self=this;
  7079. var newClass=nil;
  7080. newClass=smalltalk.send(self, "_addSubclassOf_named_instanceVariableNames_package_", [smalltalk.send(aClass, "_superclass", []), aString, smalltalk.send(aClass, "_instanceVariableNames", []), smalltalk.send(smalltalk.send(aClass, "_package", []), "_name", [])]);
  7081. smalltalk.send(self, "_setupClass_", [newClass]);
  7082. smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_values", []), "_do_", [(function(each){smalltalk.send(newClass, "_addCompiledMethod_", [smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [smalltalk.send(each, "_source", []), newClass])]);return smalltalk.send(smalltalk.send(smalltalk.send(newClass, "_methodDictionary", []), "_at_", [smalltalk.send(each, "_selector", [])]), "_category_", [smalltalk.send(each, "_category", [])]);})]);
  7083. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_methodDictionary", []), "_values", []), "_do_", [(function(each){smalltalk.send(smalltalk.send(newClass, "_class", []), "_addCompiledMethod_", [smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [smalltalk.send(each, "_source", []), smalltalk.send(newClass, "_class", [])])]);return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(newClass, "_class", []), "_methodDictionary", []), "_at_", [smalltalk.send(each, "_selector", [])]), "_category_", [smalltalk.send(each, "_category", [])]);})]);
  7084. smalltalk.send(self, "_setupClass_", [newClass]);
  7085. return newClass;
  7086. return self;},
  7087. args: ["aClass", "aString"],
  7088. source: unescape('copyClass%3A%20aClass%20named%3A%20aString%0A%09%7C%20newClass%20%7C%0A%0A%09newClass%20%3A%3D%20self%20%0A%09%09addSubclassOf%3A%20aClass%20superclass%0A%09%09named%3A%20aString%20%0A%09%09instanceVariableNames%3A%20aClass%20instanceVariableNames%20%0A%09%09package%3A%20aClass%20package%20name.%0A%0A%09self%20setupClass%3A%20newClass.%0A%0A%09aClass%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09newClass%20addCompiledMethod%3A%20%28Compiler%20new%20load%3A%20each%20source%20forClass%3A%20newClass%29.%0A%09%09%28newClass%20methodDictionary%20at%3A%20each%20selector%29%20category%3A%20each%20category%5D.%0A%0A%09aClass%20class%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09newClass%20class%20addCompiledMethod%3A%20%28Compiler%20new%20load%3A%20each%20source%20forClass%3A%20newClass%20class%29.%0A%09%09%28newClass%20class%20methodDictionary%20at%3A%20each%20selector%29%20category%3A%20each%20category%5D.%0A%0A%09self%20setupClass%3A%20newClass.%0A%09%5EnewClass'),
  7089. messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "superclass", "instanceVariableNames", "name", "package", "setupClass:", "do:", "values", "methodDictionary", "addCompiledMethod:", "load:forClass:", "new", "source", "category:", "at:", "selector", "category", "class"],
  7090. referencedClasses: ["Compiler"]
  7091. }),
  7092. smalltalk.ClassBuilder);
  7093. smalltalk.addClass('ClassCategoryReader', smalltalk.Object, ['class', 'category', 'chunkParser'], 'Kernel');
  7094. smalltalk.addMethod(
  7095. unescape('_initialize'),
  7096. smalltalk.method({
  7097. selector: unescape('initialize'),
  7098. category: 'initialization',
  7099. fn: function (){
  7100. var self=this;
  7101. smalltalk.send(self, "_initialize", [], smalltalk.Object);
  7102. self['@chunkParser']=smalltalk.send((smalltalk.ChunkParser || ChunkParser), "_new", []);
  7103. return self;},
  7104. args: [],
  7105. source: unescape('initialize%0A%09super%20initialize.%0A%09chunkParser%20%3A%3D%20ChunkParser%20new.'),
  7106. messageSends: ["initialize", "new"],
  7107. referencedClasses: ["ChunkParser"]
  7108. }),
  7109. smalltalk.ClassCategoryReader);
  7110. smalltalk.addMethod(
  7111. unescape('_class_category_'),
  7112. smalltalk.method({
  7113. selector: unescape('class%3Acategory%3A'),
  7114. category: 'accessing',
  7115. fn: function (aClass, aString){
  7116. var self=this;
  7117. self['@class']=aClass;
  7118. self['@category']=aString;
  7119. return self;},
  7120. args: ["aClass", "aString"],
  7121. source: unescape('class%3A%20aClass%20category%3A%20aString%0A%09class%20%3A%3D%20aClass.%0A%09category%20%3A%3D%20aString'),
  7122. messageSends: [],
  7123. referencedClasses: []
  7124. }),
  7125. smalltalk.ClassCategoryReader);
  7126. smalltalk.addMethod(
  7127. unescape('_scanFrom_'),
  7128. smalltalk.method({
  7129. selector: unescape('scanFrom%3A'),
  7130. category: 'fileIn',
  7131. fn: function (aChunkParser){
  7132. var self=this;
  7133. var chunk=nil;
  7134. (function(){while(!(function(){chunk=smalltalk.send(aChunkParser, "_nextChunk", []);return smalltalk.send(chunk, "_isEmpty", []);})()) {(function(){return smalltalk.send(self, "_compileMethod_", [chunk]);})()}})();
  7135. return self;},
  7136. args: ["aChunkParser"],
  7137. source: unescape('scanFrom%3A%20aChunkParser%0A%09%7C%20chunk%20%7C%0A%09%5Bchunk%20%3A%3D%20aChunkParser%20nextChunk.%0A%09chunk%20isEmpty%5D%20whileFalse%3A%20%5B%0A%09%20%20%20%20self%20compileMethod%3A%20chunk%5D'),
  7138. messageSends: ["whileFalse:", "nextChunk", "isEmpty", "compileMethod:"],
  7139. referencedClasses: []
  7140. }),
  7141. smalltalk.ClassCategoryReader);
  7142. smalltalk.addMethod(
  7143. unescape('_compileMethod_'),
  7144. smalltalk.method({
  7145. selector: unescape('compileMethod%3A'),
  7146. category: 'private',
  7147. fn: function (aString){
  7148. var self=this;
  7149. var method=nil;
  7150. method=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [aString, self['@class']]);
  7151. smalltalk.send(method, "_category_", [self['@category']]);
  7152. smalltalk.send(self['@class'], "_addCompiledMethod_", [method]);
  7153. return self;},
  7154. args: ["aString"],
  7155. source: unescape('compileMethod%3A%20aString%0A%09%7C%20method%20%7C%0A%09method%20%3A%3D%20Compiler%20new%20load%3A%20aString%20forClass%3A%20class.%0A%09method%20category%3A%20category.%0A%09class%20addCompiledMethod%3A%20method'),
  7156. messageSends: ["load:forClass:", "new", "category:", "addCompiledMethod:"],
  7157. referencedClasses: ["Compiler"]
  7158. }),
  7159. smalltalk.ClassCategoryReader);
  7160. smalltalk.addClass('Stream', smalltalk.Object, ['collection', 'position', 'streamSize'], 'Kernel');
  7161. smalltalk.addMethod(
  7162. unescape('_collection'),
  7163. smalltalk.method({
  7164. selector: unescape('collection'),
  7165. category: 'accessing',
  7166. fn: function (){
  7167. var self=this;
  7168. return self['@collection'];
  7169. return self;},
  7170. args: [],
  7171. source: unescape('collection%0A%09%5Ecollection'),
  7172. messageSends: [],
  7173. referencedClasses: []
  7174. }),
  7175. smalltalk.Stream);
  7176. smalltalk.addMethod(
  7177. unescape('_setCollection_'),
  7178. smalltalk.method({
  7179. selector: unescape('setCollection%3A'),
  7180. category: 'accessing',
  7181. fn: function (aCollection){
  7182. var self=this;
  7183. self['@collection']=aCollection;
  7184. return self;},
  7185. args: ["aCollection"],
  7186. source: unescape('setCollection%3A%20aCollection%0A%09collection%20%3A%3D%20aCollection'),
  7187. messageSends: [],
  7188. referencedClasses: []
  7189. }),
  7190. smalltalk.Stream);
  7191. smalltalk.addMethod(
  7192. unescape('_position'),
  7193. smalltalk.method({
  7194. selector: unescape('position'),
  7195. category: 'accessing',
  7196. fn: function (){
  7197. var self=this;
  7198. return (($receiver = self['@position']) == nil || $receiver == undefined) ? (function(){return self['@position']=(0);})() : $receiver;
  7199. return self;},
  7200. args: [],
  7201. source: unescape('position%0A%09%5Eposition%20ifNil%3A%20%5Bposition%20%3A%3D%200%5D'),
  7202. messageSends: ["ifNil:"],
  7203. referencedClasses: []
  7204. }),
  7205. smalltalk.Stream);
  7206. smalltalk.addMethod(
  7207. unescape('_position_'),
  7208. smalltalk.method({
  7209. selector: unescape('position%3A'),
  7210. category: 'accessing',
  7211. fn: function (anInteger){
  7212. var self=this;
  7213. self['@position']=anInteger;
  7214. return self;},
  7215. args: ["anInteger"],
  7216. source: unescape('position%3A%20anInteger%0A%09position%20%3A%3D%20anInteger'),
  7217. messageSends: [],
  7218. referencedClasses: []
  7219. }),
  7220. smalltalk.Stream);
  7221. smalltalk.addMethod(
  7222. unescape('_streamSize'),
  7223. smalltalk.method({
  7224. selector: unescape('streamSize'),
  7225. category: 'accessing',
  7226. fn: function (){
  7227. var self=this;
  7228. return self['@streamSize'];
  7229. return self;},
  7230. args: [],
  7231. source: unescape('streamSize%0A%09%5EstreamSize'),
  7232. messageSends: [],
  7233. referencedClasses: []
  7234. }),
  7235. smalltalk.Stream);
  7236. smalltalk.addMethod(
  7237. unescape('_setStreamSize_'),
  7238. smalltalk.method({
  7239. selector: unescape('setStreamSize%3A'),
  7240. category: 'accessing',
  7241. fn: function (anInteger){
  7242. var self=this;
  7243. self['@streamSize']=anInteger;
  7244. return self;},
  7245. args: ["anInteger"],
  7246. source: unescape('setStreamSize%3A%20anInteger%0A%09streamSize%20%3A%3D%20anInteger'),
  7247. messageSends: [],
  7248. referencedClasses: []
  7249. }),
  7250. smalltalk.Stream);
  7251. smalltalk.addMethod(
  7252. unescape('_contents'),
  7253. smalltalk.method({
  7254. selector: unescape('contents'),
  7255. category: 'accessing',
  7256. fn: function (){
  7257. var self=this;
  7258. return smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [(1), smalltalk.send(self, "_streamSize", [])]);
  7259. return self;},
  7260. args: [],
  7261. source: unescape('contents%0A%09%5Eself%20collection%0A%09%20%20%20%20copyFrom%3A%201%20%0A%09%20%20%20%20to%3A%20self%20streamSize'),
  7262. messageSends: ["copyFrom:to:", "collection", "streamSize"],
  7263. referencedClasses: []
  7264. }),
  7265. smalltalk.Stream);
  7266. smalltalk.addMethod(
  7267. unescape('_size'),
  7268. smalltalk.method({
  7269. selector: unescape('size'),
  7270. category: 'accessing',
  7271. fn: function (){
  7272. var self=this;
  7273. return smalltalk.send(self, "_streamSize", []);
  7274. return self;},
  7275. args: [],
  7276. source: unescape('size%0A%09%5Eself%20streamSize'),
  7277. messageSends: ["streamSize"],
  7278. referencedClasses: []
  7279. }),
  7280. smalltalk.Stream);
  7281. smalltalk.addMethod(
  7282. unescape('_reset'),
  7283. smalltalk.method({
  7284. selector: unescape('reset'),
  7285. category: 'actions',
  7286. fn: function (){
  7287. var self=this;
  7288. smalltalk.send(self, "_position_", [(0)]);
  7289. return self;},
  7290. args: [],
  7291. source: unescape('reset%0A%09self%20position%3A%200'),
  7292. messageSends: ["position:"],
  7293. referencedClasses: []
  7294. }),
  7295. smalltalk.Stream);
  7296. smalltalk.addMethod(
  7297. unescape('_close'),
  7298. smalltalk.method({
  7299. selector: unescape('close'),
  7300. category: 'actions',
  7301. fn: function (){
  7302. var self=this;
  7303. return self;},
  7304. args: [],
  7305. source: unescape('close'),
  7306. messageSends: [],
  7307. referencedClasses: []
  7308. }),
  7309. smalltalk.Stream);
  7310. smalltalk.addMethod(
  7311. unescape('_flush'),
  7312. smalltalk.method({
  7313. selector: unescape('flush'),
  7314. category: 'actions',
  7315. fn: function (){
  7316. var self=this;
  7317. return self;},
  7318. args: [],
  7319. source: unescape('flush'),
  7320. messageSends: [],
  7321. referencedClasses: []
  7322. }),
  7323. smalltalk.Stream);
  7324. smalltalk.addMethod(
  7325. unescape('_resetContents'),
  7326. smalltalk.method({
  7327. selector: unescape('resetContents'),
  7328. category: 'actions',
  7329. fn: function (){
  7330. var self=this;
  7331. smalltalk.send(self, "_reset", []);
  7332. smalltalk.send(self, "_setStreamSize_", [(0)]);
  7333. return self;},
  7334. args: [],
  7335. source: unescape('resetContents%0A%09self%20reset.%0A%09self%20setStreamSize%3A%200'),
  7336. messageSends: ["reset", "setStreamSize:"],
  7337. referencedClasses: []
  7338. }),
  7339. smalltalk.Stream);
  7340. smalltalk.addMethod(
  7341. unescape('_do_'),
  7342. smalltalk.method({
  7343. selector: unescape('do%3A'),
  7344. category: 'enumerating',
  7345. fn: function (aBlock){
  7346. var self=this;
  7347. (function(){while(!(function(){return smalltalk.send(self, "_atEnd", []);})()) {(function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_next", [])]);})()}})();
  7348. return self;},
  7349. args: ["aBlock"],
  7350. source: unescape('do%3A%20aBlock%0A%09%5Bself%20atEnd%5D%20whileFalse%3A%20%5BaBlock%20value%3A%20self%20next%5D'),
  7351. messageSends: ["whileFalse:", "atEnd", "value:", "next"],
  7352. referencedClasses: []
  7353. }),
  7354. smalltalk.Stream);
  7355. smalltalk.addMethod(
  7356. unescape('_setToEnd'),
  7357. smalltalk.method({
  7358. selector: unescape('setToEnd'),
  7359. category: 'positioning',
  7360. fn: function (){
  7361. var self=this;
  7362. smalltalk.send(self, "_position_", [smalltalk.send(self, "_size", [])]);
  7363. return self;},
  7364. args: [],
  7365. source: unescape('setToEnd%0A%09self%20position%3A%20self%20size'),
  7366. messageSends: ["position:", "size"],
  7367. referencedClasses: []
  7368. }),
  7369. smalltalk.Stream);
  7370. smalltalk.addMethod(
  7371. unescape('_skip_'),
  7372. smalltalk.method({
  7373. selector: unescape('skip%3A'),
  7374. category: 'positioning',
  7375. fn: function (anInteger){
  7376. var self=this;
  7377. smalltalk.send(self, "_position_", [smalltalk.send(((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +anInteger : smalltalk.send($receiver, "__plus", [anInteger])), "_min_max_", [smalltalk.send(self, "_size", []), (0)])]);
  7378. return self;},
  7379. args: ["anInteger"],
  7380. source: unescape('skip%3A%20anInteger%0A%09self%20position%3A%20%28%28self%20position%20+%20anInteger%29%20min%3A%20self%20size%20max%3A%200%29'),
  7381. messageSends: ["position:", "min:max:", unescape("+"), "position", "size"],
  7382. referencedClasses: []
  7383. }),
  7384. smalltalk.Stream);
  7385. smalltalk.addMethod(
  7386. unescape('_next'),
  7387. smalltalk.method({
  7388. selector: unescape('next'),
  7389. category: 'reading',
  7390. fn: function (){
  7391. var self=this;
  7392. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);
  7393. return smalltalk.send(self['@collection'], "_at_", [smalltalk.send(self, "_position", [])]);
  7394. return self;},
  7395. args: [],
  7396. source: unescape('next%0A%09self%20position%3A%20self%20position%20+%201.%20%0A%09%5Ecollection%20at%3A%20self%20position'),
  7397. messageSends: ["position:", unescape("+"), "position", "at:"],
  7398. referencedClasses: []
  7399. }),
  7400. smalltalk.Stream);
  7401. smalltalk.addMethod(
  7402. unescape('_next_'),
  7403. smalltalk.method({
  7404. selector: unescape('next%3A'),
  7405. category: 'reading',
  7406. fn: function (anInteger){
  7407. var self=this;
  7408. var tempCollection=nil;
  7409. tempCollection=smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_class", []), "_new", []);
  7410. smalltalk.send(anInteger, "_timesRepeat_", [(function(){return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(tempCollection, "_add_", [smalltalk.send(self, "_next", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(tempCollection, "_add_", [smalltalk.send(self, "_next", [])]);})]));})]);
  7411. return tempCollection;
  7412. return self;},
  7413. args: ["anInteger"],
  7414. source: unescape('next%3A%20anInteger%0A%09%7C%20tempCollection%20%7C%0A%09tempCollection%20%3A%3D%20self%20collection%20class%20new.%0A%09anInteger%20timesRepeat%3A%20%5B%0A%09%20%20%20%20self%20atEnd%20ifFalse%3A%20%5B%0A%09%09tempCollection%20add%3A%20self%20next%5D%5D.%0A%09%5EtempCollection'),
  7415. messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", "add:", "next"],
  7416. referencedClasses: []
  7417. }),
  7418. smalltalk.Stream);
  7419. smalltalk.addMethod(
  7420. unescape('_nextPut_'),
  7421. smalltalk.method({
  7422. selector: unescape('nextPut%3A'),
  7423. category: 'writing',
  7424. fn: function (anObject){
  7425. var self=this;
  7426. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);
  7427. smalltalk.send(smalltalk.send(self, "_collection", []), "_at_put_", [smalltalk.send(self, "_position", []), anObject]);
  7428. smalltalk.send(self, "_setStreamSize_", [smalltalk.send(smalltalk.send(self, "_streamSize", []), "_max_", [smalltalk.send(self, "_position", [])])]);
  7429. return self;},
  7430. args: ["anObject"],
  7431. source: unescape('nextPut%3A%20anObject%0A%09self%20position%3A%20self%20position%20+%201.%0A%09self%20collection%20at%3A%20self%20position%20put%3A%20anObject.%0A%09self%20setStreamSize%3A%20%28self%20streamSize%20max%3A%20self%20position%29'),
  7432. messageSends: ["position:", unescape("+"), "position", "at:put:", "collection", "setStreamSize:", "max:", "streamSize"],
  7433. referencedClasses: []
  7434. }),
  7435. smalltalk.Stream);
  7436. smalltalk.addMethod(
  7437. unescape('_nextPutAll_'),
  7438. smalltalk.method({
  7439. selector: unescape('nextPutAll%3A'),
  7440. category: 'writing',
  7441. fn: function (aCollection){
  7442. var self=this;
  7443. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(self, "_nextPut_", [each]);})]);
  7444. return self;},
  7445. args: ["aCollection"],
  7446. source: unescape('nextPutAll%3A%20aCollection%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20nextPut%3A%20each%5D'),
  7447. messageSends: ["do:", "nextPut:"],
  7448. referencedClasses: []
  7449. }),
  7450. smalltalk.Stream);
  7451. smalltalk.addMethod(
  7452. unescape('_peek'),
  7453. smalltalk.method({
  7454. selector: unescape('peek'),
  7455. category: 'reading',
  7456. fn: function (){
  7457. var self=this;
  7458. return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_collection", []), "_at_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_collection", []), "_at_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);})]));
  7459. return self;},
  7460. args: [],
  7461. source: unescape('peek%0A%09%5Eself%20atEnd%20ifFalse%3A%20%5B%0A%09%20%20%20%20self%20collection%20at%3A%20self%20position%20+%201%5D'),
  7462. messageSends: ["ifFalse:", "atEnd", "at:", "collection", unescape("+"), "position"],
  7463. referencedClasses: []
  7464. }),
  7465. smalltalk.Stream);
  7466. smalltalk.addMethod(
  7467. unescape('_atEnd'),
  7468. smalltalk.method({
  7469. selector: unescape('atEnd'),
  7470. category: 'testing',
  7471. fn: function (){
  7472. var self=this;
  7473. return smalltalk.send(smalltalk.send(self, "_position", []), "__eq", [smalltalk.send(self, "_size", [])]);
  7474. return self;},
  7475. args: [],
  7476. source: unescape('atEnd%0A%09%5Eself%20position%20%3D%20self%20size'),
  7477. messageSends: [unescape("%3D"), "position", "size"],
  7478. referencedClasses: []
  7479. }),
  7480. smalltalk.Stream);
  7481. smalltalk.addMethod(
  7482. unescape('_atStart'),
  7483. smalltalk.method({
  7484. selector: unescape('atStart'),
  7485. category: 'testing',
  7486. fn: function (){
  7487. var self=this;
  7488. return smalltalk.send(smalltalk.send(self, "_position", []), "__eq", [(0)]);
  7489. return self;},
  7490. args: [],
  7491. source: unescape('atStart%0A%09%5Eself%20position%20%3D%200'),
  7492. messageSends: [unescape("%3D"), "position"],
  7493. referencedClasses: []
  7494. }),
  7495. smalltalk.Stream);
  7496. smalltalk.addMethod(
  7497. unescape('_isEmpty'),
  7498. smalltalk.method({
  7499. selector: unescape('isEmpty'),
  7500. category: 'testing',
  7501. fn: function (){
  7502. var self=this;
  7503. return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [(0)]);
  7504. return self;},
  7505. args: [],
  7506. source: unescape('isEmpty%0A%09%5Eself%20size%20%3D%200'),
  7507. messageSends: [unescape("%3D"), "size"],
  7508. referencedClasses: []
  7509. }),
  7510. smalltalk.Stream);
  7511. smalltalk.addMethod(
  7512. unescape('_on_'),
  7513. smalltalk.method({
  7514. selector: unescape('on%3A'),
  7515. category: 'instance creation',
  7516. fn: function (aCollection){
  7517. var self=this;
  7518. return (function($rec){smalltalk.send($rec, "_setCollection_", [aCollection]);smalltalk.send($rec, "_setStreamSize_", [smalltalk.send(aCollection, "_size", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  7519. return self;},
  7520. args: ["aCollection"],
  7521. source: unescape('on%3A%20aCollection%0A%09%20%20%20%20%5Eself%20new%20%0A%09%09setCollection%3A%20aCollection%3B%0A%09%09setStreamSize%3A%20aCollection%20size%3B%0A%09%09yourself'),
  7522. messageSends: ["setCollection:", "setStreamSize:", "size", "yourself", "new"],
  7523. referencedClasses: []
  7524. }),
  7525. smalltalk.Stream.klass);
  7526. smalltalk.addClass('StringStream', smalltalk.Stream, [], 'Kernel');
  7527. smalltalk.addMethod(
  7528. unescape('_next_'),
  7529. smalltalk.method({
  7530. selector: unescape('next%3A'),
  7531. category: 'reading',
  7532. fn: function (anInteger){
  7533. var self=this;
  7534. var tempCollection=nil;
  7535. tempCollection=smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_class", []), "_new", []);
  7536. smalltalk.send(anInteger, "_timesRepeat_", [(function(){return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return tempCollection=smalltalk.send(tempCollection, "__comma", [smalltalk.send(self, "_next", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return tempCollection=smalltalk.send(tempCollection, "__comma", [smalltalk.send(self, "_next", [])]);})]));})]);
  7537. return tempCollection;
  7538. return self;},
  7539. args: ["anInteger"],
  7540. source: unescape('next%3A%20anInteger%0A%09%7C%20tempCollection%20%7C%0A%09tempCollection%20%3A%3D%20self%20collection%20class%20new.%0A%09anInteger%20timesRepeat%3A%20%5B%0A%09%20%20%20%20self%20atEnd%20ifFalse%3A%20%5B%0A%09%09tempCollection%20%3A%3D%20tempCollection%2C%20self%20next%5D%5D.%0A%09%5EtempCollection'),
  7541. messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", unescape("%2C"), "next"],
  7542. referencedClasses: []
  7543. }),
  7544. smalltalk.StringStream);
  7545. smalltalk.addMethod(
  7546. unescape('_nextPut_'),
  7547. smalltalk.method({
  7548. selector: unescape('nextPut%3A'),
  7549. category: 'writing',
  7550. fn: function (aString){
  7551. var self=this;
  7552. smalltalk.send(self, "_nextPutAll_", [aString]);
  7553. return self;},
  7554. args: ["aString"],
  7555. source: unescape('nextPut%3A%20aString%0A%09self%20nextPutAll%3A%20aString'),
  7556. messageSends: ["nextPutAll:"],
  7557. referencedClasses: []
  7558. }),
  7559. smalltalk.StringStream);
  7560. smalltalk.addMethod(
  7561. unescape('_nextPutAll_'),
  7562. smalltalk.method({
  7563. selector: unescape('nextPutAll%3A'),
  7564. category: 'writing',
  7565. fn: function (aString){
  7566. var self=this;
  7567. smalltalk.send(self, "_setCollection_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [(1), smalltalk.send(self, "_position", [])]), "__comma", [aString]), "__comma", [smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [((($receiver = ((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))).klass === smalltalk.Number) ? $receiver +smalltalk.send(aString, "_size", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(aString, "_size", [])])), smalltalk.send(smalltalk.send(self, "_collection", []), "_size", [])])])]);
  7568. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(aString, "_size", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(aString, "_size", [])]))]);
  7569. smalltalk.send(self, "_setStreamSize_", [smalltalk.send(smalltalk.send(self, "_streamSize", []), "_max_", [smalltalk.send(self, "_position", [])])]);
  7570. return self;},
  7571. args: ["aString"],
  7572. source: unescape('nextPutAll%3A%20aString%0A%09self%20setCollection%3A%20%0A%09%20%20%20%20%28self%20collection%20copyFrom%3A%201%20to%3A%20self%20position%29%2C%0A%09%20%20%20%20aString%2C%0A%09%20%20%20%20%28self%20collection%20copyFrom%3A%20%28self%20position%20+%201%20+%20aString%20size%29%20to%3A%20self%20collection%20size%29.%0A%09self%20position%3A%20self%20position%20+%20aString%20size.%0A%09self%20setStreamSize%3A%20%28self%20streamSize%20max%3A%20self%20position%29'),
  7573. messageSends: ["setCollection:", unescape("%2C"), "copyFrom:to:", "collection", "position", unescape("+"), "size", "position:", "setStreamSize:", "max:", "streamSize"],
  7574. referencedClasses: []
  7575. }),
  7576. smalltalk.StringStream);
  7577. smalltalk.addMethod(
  7578. unescape('_cr'),
  7579. smalltalk.method({
  7580. selector: unescape('cr'),
  7581. category: 'writing',
  7582. fn: function (){
  7583. var self=this;
  7584. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_cr", [])]);
  7585. return self;},
  7586. args: [],
  7587. source: unescape('cr%0A%09%5Eself%20nextPutAll%3A%20String%20cr'),
  7588. messageSends: ["nextPutAll:", "cr"],
  7589. referencedClasses: ["String"]
  7590. }),
  7591. smalltalk.StringStream);
  7592. smalltalk.addMethod(
  7593. unescape('_crlf'),
  7594. smalltalk.method({
  7595. selector: unescape('crlf'),
  7596. category: 'writing',
  7597. fn: function (){
  7598. var self=this;
  7599. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_crlf", [])]);
  7600. return self;},
  7601. args: [],
  7602. source: unescape('crlf%0A%09%5Eself%20nextPutAll%3A%20String%20crlf'),
  7603. messageSends: ["nextPutAll:", "crlf"],
  7604. referencedClasses: ["String"]
  7605. }),
  7606. smalltalk.StringStream);
  7607. smalltalk.addMethod(
  7608. unescape('_lf'),
  7609. smalltalk.method({
  7610. selector: unescape('lf'),
  7611. category: 'writing',
  7612. fn: function (){
  7613. var self=this;
  7614. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_lf", [])]);
  7615. return self;},
  7616. args: [],
  7617. source: unescape('lf%0A%09%5Eself%20nextPutAll%3A%20String%20lf'),
  7618. messageSends: ["nextPutAll:", "lf"],
  7619. referencedClasses: ["String"]
  7620. }),
  7621. smalltalk.StringStream);
  7622. smalltalk.addMethod(
  7623. unescape('_space'),
  7624. smalltalk.method({
  7625. selector: unescape('space'),
  7626. category: 'writing',
  7627. fn: function (){
  7628. var self=this;
  7629. smalltalk.send(self, "_nextPut_", [" "]);
  7630. return self;},
  7631. args: [],
  7632. source: unescape('space%0A%09self%20nextPut%3A%20%27%20%27'),
  7633. messageSends: ["nextPut:"],
  7634. referencedClasses: []
  7635. }),
  7636. smalltalk.StringStream);
  7637. smalltalk.addClass('ClassCommentReader', smalltalk.Object, ['class', 'chunkParser'], 'Kernel');
  7638. smalltalk.addMethod(
  7639. unescape('_class_'),
  7640. smalltalk.method({
  7641. selector: unescape('class%3A'),
  7642. category: 'accessing',
  7643. fn: function (aClass){
  7644. var self=this;
  7645. self['@class']=aClass;
  7646. return self;},
  7647. args: ["aClass"],
  7648. source: unescape('class%3A%20aClass%0A%09class%20%3A%3D%20aClass'),
  7649. messageSends: [],
  7650. referencedClasses: []
  7651. }),
  7652. smalltalk.ClassCommentReader);
  7653. smalltalk.addMethod(
  7654. unescape('_scanFrom_'),
  7655. smalltalk.method({
  7656. selector: unescape('scanFrom%3A'),
  7657. category: 'fileIn',
  7658. fn: function (aChunkParser){
  7659. var self=this;
  7660. var chunk=nil;
  7661. chunk=smalltalk.send(aChunkParser, "_nextChunk", []);
  7662. ((($receiver = smalltalk.send(chunk, "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_setComment_", [chunk]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_setComment_", [chunk]);})]));
  7663. return self;},
  7664. args: ["aChunkParser"],
  7665. source: unescape('scanFrom%3A%20aChunkParser%0A%09%7C%20chunk%20%7C%0A%09chunk%20%3A%3D%20aChunkParser%20nextChunk.%0A%09chunk%20isEmpty%20ifFalse%3A%20%5B%0A%09%20%20%20%20self%20setComment%3A%20chunk%5D.'),
  7666. messageSends: ["nextChunk", "ifFalse:", "isEmpty", "setComment:"],
  7667. referencedClasses: []
  7668. }),
  7669. smalltalk.ClassCommentReader);
  7670. smalltalk.addMethod(
  7671. unescape('_initialize'),
  7672. smalltalk.method({
  7673. selector: unescape('initialize'),
  7674. category: 'initialization',
  7675. fn: function (){
  7676. var self=this;
  7677. smalltalk.send(self, "_initialize", [], smalltalk.Object);
  7678. self['@chunkParser']=smalltalk.send((smalltalk.ChunkParser || ChunkParser), "_new", []);
  7679. return self;},
  7680. args: [],
  7681. source: unescape('initialize%0A%09super%20initialize.%0A%09chunkParser%20%3A%3D%20ChunkParser%20new.'),
  7682. messageSends: ["initialize", "new"],
  7683. referencedClasses: ["ChunkParser"]
  7684. }),
  7685. smalltalk.ClassCommentReader);
  7686. smalltalk.addMethod(
  7687. unescape('_setComment_'),
  7688. smalltalk.method({
  7689. selector: unescape('setComment%3A'),
  7690. category: 'private',
  7691. fn: function (aString){
  7692. var self=this;
  7693. smalltalk.send(self['@class'], "_comment_", [aString]);
  7694. return self;},
  7695. args: ["aString"],
  7696. source: unescape('setComment%3A%20aString%0A%20%20%20%20class%20comment%3A%20aString'),
  7697. messageSends: ["comment:"],
  7698. referencedClasses: []
  7699. }),
  7700. smalltalk.ClassCommentReader);
  7701. smalltalk.addClass('Random', smalltalk.Object, [], 'Kernel');
  7702. smalltalk.addMethod(
  7703. unescape('_next'),
  7704. smalltalk.method({
  7705. selector: unescape('next'),
  7706. category: 'accessing',
  7707. fn: function (){
  7708. var self=this;
  7709. return Math.random();
  7710. return self;},
  7711. args: [],
  7712. source: unescape('next%0A%09%3Creturn%20Math.random%28%29%3E'),
  7713. messageSends: [],
  7714. referencedClasses: []
  7715. }),
  7716. smalltalk.Random);
  7717. smalltalk.addMethod(
  7718. unescape('_next_'),
  7719. smalltalk.method({
  7720. selector: unescape('next%3A'),
  7721. category: 'accessing',
  7722. fn: function (anInteger){
  7723. var self=this;
  7724. return smalltalk.send(smalltalk.send((1), "_to_", [anInteger]), "_collect_", [(function(each){return smalltalk.send(self, "_next", []);})]);
  7725. return self;},
  7726. args: ["anInteger"],
  7727. source: unescape('next%3A%20anInteger%0A%20%20%20%20%5E%281%20to%3A%20anInteger%29%20collect%3A%20%5B%3Aeach%20%7C%20self%20next%5D'),
  7728. messageSends: ["collect:", "to:", "next"],
  7729. referencedClasses: []
  7730. }),
  7731. smalltalk.Random);
  7732. smalltalk.addClass('Point', smalltalk.Object, ['x', 'y'], 'Kernel');
  7733. smalltalk.addMethod(
  7734. unescape('_x'),
  7735. smalltalk.method({
  7736. selector: unescape('x'),
  7737. category: 'accessing',
  7738. fn: function (){
  7739. var self=this;
  7740. return self['@x'];
  7741. return self;},
  7742. args: [],
  7743. source: unescape('x%0A%09%5Ex'),
  7744. messageSends: [],
  7745. referencedClasses: []
  7746. }),
  7747. smalltalk.Point);
  7748. smalltalk.addMethod(
  7749. unescape('_y'),
  7750. smalltalk.method({
  7751. selector: unescape('y'),
  7752. category: 'accessing',
  7753. fn: function (){
  7754. var self=this;
  7755. return self['@y'];
  7756. return self;},
  7757. args: [],
  7758. source: unescape('y%0A%09%5Ey'),
  7759. messageSends: [],
  7760. referencedClasses: []
  7761. }),
  7762. smalltalk.Point);
  7763. smalltalk.addMethod(
  7764. unescape('_y_'),
  7765. smalltalk.method({
  7766. selector: unescape('y%3A'),
  7767. category: 'accessing',
  7768. fn: function (aNumber){
  7769. var self=this;
  7770. self['@y']=aNumber;
  7771. return self;},
  7772. args: ["aNumber"],
  7773. source: unescape('y%3A%20aNumber%0A%09y%20%3A%3D%20aNumber'),
  7774. messageSends: [],
  7775. referencedClasses: []
  7776. }),
  7777. smalltalk.Point);
  7778. smalltalk.addMethod(
  7779. unescape('_x_'),
  7780. smalltalk.method({
  7781. selector: unescape('x%3A'),
  7782. category: 'accessing',
  7783. fn: function (aNumber){
  7784. var self=this;
  7785. self['@x']=aNumber;
  7786. return self;},
  7787. args: ["aNumber"],
  7788. source: unescape('x%3A%20aNumber%0A%09x%20%3A%3D%20aNumber'),
  7789. messageSends: [],
  7790. referencedClasses: []
  7791. }),
  7792. smalltalk.Point);
  7793. smalltalk.addMethod(
  7794. unescape('__star'),
  7795. smalltalk.method({
  7796. selector: unescape('*'),
  7797. category: 'arithmetic',
  7798. fn: function (aPoint){
  7799. var self=this;
  7800. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver *smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__star", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver *smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__star", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  7801. return self;},
  7802. args: ["aPoint"],
  7803. source: unescape('*%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20*%20aPoint%20asPoint%20x%20y%3A%20self%20y%20*%20aPoint%20asPoint%20y'),
  7804. messageSends: ["x:y:", unescape("*"), "x", "asPoint", "y"],
  7805. referencedClasses: ["Point"]
  7806. }),
  7807. smalltalk.Point);
  7808. smalltalk.addMethod(
  7809. unescape('__plus'),
  7810. smalltalk.method({
  7811. selector: unescape('+'),
  7812. category: 'arithmetic',
  7813. fn: function (aPoint){
  7814. var self=this;
  7815. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  7816. return self;},
  7817. args: ["aPoint"],
  7818. source: unescape('+%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20+%20aPoint%20asPoint%20x%20y%3A%20self%20y%20+%20aPoint%20asPoint%20y'),
  7819. messageSends: ["x:y:", unescape("+"), "x", "asPoint", "y"],
  7820. referencedClasses: ["Point"]
  7821. }),
  7822. smalltalk.Point);
  7823. smalltalk.addMethod(
  7824. unescape('__minus'),
  7825. smalltalk.method({
  7826. selector: unescape('-'),
  7827. category: 'arithmetic',
  7828. fn: function (aPoint){
  7829. var self=this;
  7830. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  7831. return self;},
  7832. args: ["aPoint"],
  7833. source: unescape('-%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20-%20aPoint%20asPoint%20x%20y%3A%20self%20y%20-%20aPoint%20asPoint%20y'),
  7834. messageSends: ["x:y:", unescape("-"), "x", "asPoint", "y"],
  7835. referencedClasses: ["Point"]
  7836. }),
  7837. smalltalk.Point);
  7838. smalltalk.addMethod(
  7839. unescape('__slash'),
  7840. smalltalk.method({
  7841. selector: unescape('/'),
  7842. category: 'arithmetic',
  7843. fn: function (aPoint){
  7844. var self=this;
  7845. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver /smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__slash", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver /smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__slash", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  7846. return self;},
  7847. args: ["aPoint"],
  7848. source: unescape('/%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20/%20aPoint%20asPoint%20x%20y%3A%20self%20y%20/%20aPoint%20asPoint%20y'),
  7849. messageSends: ["x:y:", unescape("/"), "x", "asPoint", "y"],
  7850. referencedClasses: ["Point"]
  7851. }),
  7852. smalltalk.Point);
  7853. smalltalk.addMethod(
  7854. unescape('_asPoint'),
  7855. smalltalk.method({
  7856. selector: unescape('asPoint'),
  7857. category: 'converting',
  7858. fn: function (){
  7859. var self=this;
  7860. return self;
  7861. return self;},
  7862. args: [],
  7863. source: unescape('asPoint%0A%09%5Eself'),
  7864. messageSends: [],
  7865. referencedClasses: []
  7866. }),
  7867. smalltalk.Point);
  7868. smalltalk.addMethod(
  7869. unescape('__eq'),
  7870. smalltalk.method({
  7871. selector: unescape('%3D'),
  7872. category: 'arithmetic',
  7873. fn: function (aPoint){
  7874. var self=this;
  7875. return smalltalk.send(smalltalk.send(smalltalk.send(aPoint, "_class", []), "__eq", [smalltalk.send(self, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aPoint, "_x", []), "__eq", [smalltalk.send(self, "_x", [])]), "_&", [smalltalk.send(smalltalk.send(aPoint, "_y", []), "__eq", [smalltalk.send(self, "_y", [])])]);})]);
  7876. return self;},
  7877. args: ["aPoint"],
  7878. source: unescape('%3D%20aPoint%0A%09%5EaPoint%20class%20%3D%20self%20class%20and%3A%20%5B%0A%09%09%28aPoint%20x%20%3D%20self%20x%29%20%26%20%28aPoint%20y%20%3D%20self%20y%29%5D'),
  7879. messageSends: ["and:", unescape("%3D"), "class", unescape("%26"), "x", "y"],
  7880. referencedClasses: []
  7881. }),
  7882. smalltalk.Point);
  7883. smalltalk.addMethod(
  7884. unescape('_x_y_'),
  7885. smalltalk.method({
  7886. selector: unescape('x%3Ay%3A'),
  7887. category: 'instance creation',
  7888. fn: function (aNumber, anotherNumber){
  7889. var self=this;
  7890. return (function($rec){smalltalk.send($rec, "_x_", [aNumber]);smalltalk.send($rec, "_y_", [anotherNumber]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  7891. return self;},
  7892. args: ["aNumber", "anotherNumber"],
  7893. source: unescape('x%3A%20aNumber%20y%3A%20anotherNumber%0A%09%5Eself%20new%0A%09%09x%3A%20aNumber%3B%0A%09%09y%3A%20anotherNumber%3B%0A%09%09yourself'),
  7894. messageSends: ["x:", "y:", "yourself", "new"],
  7895. referencedClasses: []
  7896. }),
  7897. smalltalk.Point.klass);
  7898. smalltalk.addClass('Message', smalltalk.Object, ['selector', 'arguments'], 'Kernel');
  7899. smalltalk.addMethod(
  7900. unescape('_selector'),
  7901. smalltalk.method({
  7902. selector: unescape('selector'),
  7903. category: 'accessing',
  7904. fn: function (){
  7905. var self=this;
  7906. return self['@selector'];
  7907. return self;},
  7908. args: [],
  7909. source: unescape('selector%0A%09%5Eselector'),
  7910. messageSends: [],
  7911. referencedClasses: []
  7912. }),
  7913. smalltalk.Message);
  7914. smalltalk.addMethod(
  7915. unescape('_selector_'),
  7916. smalltalk.method({
  7917. selector: unescape('selector%3A'),
  7918. category: 'accessing',
  7919. fn: function (aString){
  7920. var self=this;
  7921. self['@selector']=aString;
  7922. return self;},
  7923. args: ["aString"],
  7924. source: unescape('selector%3A%20aString%0A%09selector%20%3A%3D%20aString'),
  7925. messageSends: [],
  7926. referencedClasses: []
  7927. }),
  7928. smalltalk.Message);
  7929. smalltalk.addMethod(
  7930. unescape('_arguments_'),
  7931. smalltalk.method({
  7932. selector: unescape('arguments%3A'),
  7933. category: 'accessing',
  7934. fn: function (anArray){
  7935. var self=this;
  7936. self['@arguments']=anArray;
  7937. return self;},
  7938. args: ["anArray"],
  7939. source: unescape('arguments%3A%20anArray%0A%09arguments%20%3A%3D%20anArray'),
  7940. messageSends: [],
  7941. referencedClasses: []
  7942. }),
  7943. smalltalk.Message);
  7944. smalltalk.addMethod(
  7945. unescape('_arguments'),
  7946. smalltalk.method({
  7947. selector: unescape('arguments'),
  7948. category: 'accessing',
  7949. fn: function (){
  7950. var self=this;
  7951. return self['@arguments'];
  7952. return self;},
  7953. args: [],
  7954. source: unescape('arguments%0A%09%5Earguments'),
  7955. messageSends: [],
  7956. referencedClasses: []
  7957. }),
  7958. smalltalk.Message);
  7959. smalltalk.addMethod(
  7960. unescape('_printString'),
  7961. smalltalk.method({
  7962. selector: unescape('printString'),
  7963. category: 'printing',
  7964. fn: function (){
  7965. var self=this;
  7966. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(aStream){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_printString", [], smalltalk.Object)]);smalltalk.send($rec, "_nextPutAll_", [unescape("%28")]);smalltalk.send($rec, "_nextPutAll_", [self['@selector']]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%29")]);})(aStream);})]);
  7967. return self;},
  7968. args: [],
  7969. source: unescape('printString%0A%09%5E%20String%20streamContents%3A%20%5B%3AaStream%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20super%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20%27%28%27%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20selector%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20%27%29%27%20%09%09%09%09%5D'),
  7970. messageSends: ["streamContents:", "nextPutAll:", "printString"],
  7971. referencedClasses: ["String"]
  7972. }),
  7973. smalltalk.Message);
  7974. smalltalk.addMethod(
  7975. unescape('_selector_arguments_'),
  7976. smalltalk.method({
  7977. selector: unescape('selector%3Aarguments%3A'),
  7978. category: 'instance creation',
  7979. fn: function (aString, anArray){
  7980. var self=this;
  7981. return (function($rec){smalltalk.send($rec, "_selector_", [aString]);smalltalk.send($rec, "_arguments_", [anArray]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  7982. return self;},
  7983. args: ["aString", "anArray"],
  7984. source: unescape('selector%3A%20aString%20arguments%3A%20anArray%0A%09%5Eself%20new%0A%09%09selector%3A%20aString%3B%0A%09%09arguments%3A%20anArray%3B%0A%09%09yourself'),
  7985. messageSends: ["selector:", "arguments:", "yourself", "new"],
  7986. referencedClasses: []
  7987. }),
  7988. smalltalk.Message.klass);
  7989. smalltalk.addClass('MessageNotUnderstood', smalltalk.Error, ['message', 'receiver'], 'Kernel');
  7990. smalltalk.addMethod(
  7991. unescape('_message'),
  7992. smalltalk.method({
  7993. selector: unescape('message'),
  7994. category: 'accessing',
  7995. fn: function (){
  7996. var self=this;
  7997. return self['@message'];
  7998. return self;},
  7999. args: [],
  8000. source: unescape('message%0A%09%5Emessage'),
  8001. messageSends: [],
  8002. referencedClasses: []
  8003. }),
  8004. smalltalk.MessageNotUnderstood);
  8005. smalltalk.addMethod(
  8006. unescape('_message_'),
  8007. smalltalk.method({
  8008. selector: unescape('message%3A'),
  8009. category: 'accessing',
  8010. fn: function (aMessage){
  8011. var self=this;
  8012. self['@message']=aMessage;
  8013. return self;},
  8014. args: ["aMessage"],
  8015. source: unescape('message%3A%20aMessage%0A%09message%20%3A%3D%20aMessage'),
  8016. messageSends: [],
  8017. referencedClasses: []
  8018. }),
  8019. smalltalk.MessageNotUnderstood);
  8020. smalltalk.addMethod(
  8021. unescape('_receiver'),
  8022. smalltalk.method({
  8023. selector: unescape('receiver'),
  8024. category: 'accessing',
  8025. fn: function (){
  8026. var self=this;
  8027. return self['@receiver'];
  8028. return self;},
  8029. args: [],
  8030. source: unescape('receiver%0A%09%5Ereceiver'),
  8031. messageSends: [],
  8032. referencedClasses: []
  8033. }),
  8034. smalltalk.MessageNotUnderstood);
  8035. smalltalk.addMethod(
  8036. unescape('_receiver_'),
  8037. smalltalk.method({
  8038. selector: unescape('receiver%3A'),
  8039. category: 'accessing',
  8040. fn: function (anObject){
  8041. var self=this;
  8042. self['@receiver']=anObject;
  8043. return self;},
  8044. args: ["anObject"],
  8045. source: unescape('receiver%3A%20anObject%0A%09receiver%20%3A%3D%20anObject'),
  8046. messageSends: [],
  8047. referencedClasses: []
  8048. }),
  8049. smalltalk.MessageNotUnderstood);
  8050. smalltalk.addMethod(
  8051. unescape('_messageText'),
  8052. smalltalk.method({
  8053. selector: unescape('messageText'),
  8054. category: 'accessing',
  8055. fn: function (){
  8056. var self=this;
  8057. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_receiver", []), "_asString", []), "__comma", [unescape("%20does%20not%20understand%20%23")]), "__comma", [smalltalk.send(smalltalk.send(self, "_message", []), "_selector", [])]);
  8058. return self;},
  8059. args: [],
  8060. source: unescape('messageText%0A%09%5Eself%20receiver%20asString%2C%20%27%20does%20not%20understand%20%23%27%2C%20self%20message%20selector'),
  8061. messageSends: [unescape("%2C"), "asString", "receiver", "selector", "message"],
  8062. referencedClasses: []
  8063. }),
  8064. smalltalk.MessageNotUnderstood);
  8065. smalltalk.addClass('ErrorHandler', smalltalk.Object, [], 'Kernel');
  8066. smalltalk.addMethod(
  8067. unescape('_handleError_'),
  8068. smalltalk.method({
  8069. selector: unescape('handleError%3A'),
  8070. category: 'error handling',
  8071. fn: function (anError){
  8072. var self=this;
  8073. (($receiver = smalltalk.send(anError, "_context", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logErrorContext_", [smalltalk.send(anError, "_context", [])]);})() : nil;
  8074. smalltalk.send(self, "_logError_", [anError]);
  8075. return self;},
  8076. args: ["anError"],
  8077. source: unescape('handleError%3A%20anError%0A%09anError%20context%20ifNotNil%3A%20%5Bself%20logErrorContext%3A%20anError%20context%5D.%0A%09self%20logError%3A%20anError'),
  8078. messageSends: ["ifNotNil:", "context", "logErrorContext:", "logError:"],
  8079. referencedClasses: []
  8080. }),
  8081. smalltalk.ErrorHandler);
  8082. smalltalk.addMethod(
  8083. unescape('_logContext_'),
  8084. smalltalk.method({
  8085. selector: unescape('logContext%3A'),
  8086. category: 'private',
  8087. fn: function (aContext){
  8088. var self=this;
  8089. (($receiver = smalltalk.send(aContext, "_home", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logContext_", [smalltalk.send(aContext, "_home", [])]);})() : nil;
  8090. smalltalk.send(self, "_log_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aContext, "_receiver", []), "_asString", []), "__comma", [unescape("%3E%3E")]), "__comma", [smalltalk.send(aContext, "_selector", [])])]);
  8091. return self;},
  8092. args: ["aContext"],
  8093. source: unescape('logContext%3A%20aContext%0A%09aContext%20home%20ifNotNil%3A%20%5B%0A%09%09self%20logContext%3A%20aContext%20home%5D.%0A%09self%20log%3A%20aContext%20receiver%20asString%2C%20%27%3E%3E%27%2C%20aContext%20selector'),
  8094. messageSends: ["ifNotNil:", "home", "logContext:", "log:", unescape("%2C"), "asString", "receiver", "selector"],
  8095. referencedClasses: []
  8096. }),
  8097. smalltalk.ErrorHandler);
  8098. smalltalk.addMethod(
  8099. unescape('_logErrorContext_'),
  8100. smalltalk.method({
  8101. selector: unescape('logErrorContext%3A'),
  8102. category: 'private',
  8103. fn: function (aContext){
  8104. var self=this;
  8105. (($receiver = aContext) != nil && $receiver != undefined) ? (function(){return (($receiver = smalltalk.send(aContext, "_home", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logContext_", [smalltalk.send(aContext, "_home", [])]);})() : nil;})() : nil;
  8106. return self;},
  8107. args: ["aContext"],
  8108. source: unescape('logErrorContext%3A%20aContext%0A%09aContext%20ifNotNil%3A%20%5B%0A%09%09aContext%20home%20ifNotNil%3A%20%5B%0A%09%09%09self%20logContext%3A%20aContext%20home%5D%5D'),
  8109. messageSends: ["ifNotNil:", "home", "logContext:"],
  8110. referencedClasses: []
  8111. }),
  8112. smalltalk.ErrorHandler);
  8113. smalltalk.addMethod(
  8114. unescape('_logError_'),
  8115. smalltalk.method({
  8116. selector: unescape('logError%3A'),
  8117. category: 'private',
  8118. fn: function (anError){
  8119. var self=this;
  8120. smalltalk.send(self, "_log_", [smalltalk.send(anError, "_messageText", [])]);
  8121. return self;},
  8122. args: ["anError"],
  8123. source: unescape('logError%3A%20anError%0A%09self%20log%3A%20anError%20messageText'),
  8124. messageSends: ["log:", "messageText"],
  8125. referencedClasses: []
  8126. }),
  8127. smalltalk.ErrorHandler);
  8128. smalltalk.addMethod(
  8129. unescape('_log_'),
  8130. smalltalk.method({
  8131. selector: unescape('log%3A'),
  8132. category: 'private',
  8133. fn: function (aString){
  8134. var self=this;
  8135. smalltalk.send((typeof console == 'undefined' ? nil : console), "_log_", [aString]);
  8136. return self;},
  8137. args: ["aString"],
  8138. source: unescape('log%3A%20aString%0A%09console%20log%3A%20aString'),
  8139. messageSends: ["log:"],
  8140. referencedClasses: []
  8141. }),
  8142. smalltalk.ErrorHandler);
  8143. smalltalk.ErrorHandler.klass.iVarNames = ['current'];
  8144. smalltalk.addMethod(
  8145. unescape('_current'),
  8146. smalltalk.method({
  8147. selector: unescape('current'),
  8148. category: 'accessing',
  8149. fn: function (){
  8150. var self=this;
  8151. return (($receiver = self['@current']) == nil || $receiver == undefined) ? (function(){return self['@current']=smalltalk.send(self, "_new", []);})() : $receiver;
  8152. return self;},
  8153. args: [],
  8154. source: unescape('current%0A%09%5Ecurrent%20ifNil%3A%20%5Bcurrent%20%3A%3D%20self%20new%5D'),
  8155. messageSends: ["ifNil:", "new"],
  8156. referencedClasses: []
  8157. }),
  8158. smalltalk.ErrorHandler.klass);
  8159. smalltalk.addMethod(
  8160. unescape('_initialize'),
  8161. smalltalk.method({
  8162. selector: unescape('initialize'),
  8163. category: 'initialization',
  8164. fn: function (){
  8165. var self=this;
  8166. smalltalk.send(self, "_register", []);
  8167. return self;},
  8168. args: [],
  8169. source: unescape('initialize%0A%09self%20register'),
  8170. messageSends: ["register"],
  8171. referencedClasses: []
  8172. }),
  8173. smalltalk.ErrorHandler.klass);
  8174. smalltalk.addMethod(
  8175. unescape('_register'),
  8176. smalltalk.method({
  8177. selector: unescape('register'),
  8178. category: 'initialization',
  8179. fn: function (){
  8180. var self=this;
  8181. smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_setCurrent_", [smalltalk.send(self, "_new", [])]);
  8182. return self;},
  8183. args: [],
  8184. source: unescape('register%0A%09ErrorHandler%20setCurrent%3A%20self%20new'),
  8185. messageSends: ["setCurrent:", "new"],
  8186. referencedClasses: ["ErrorHandler"]
  8187. }),
  8188. smalltalk.ErrorHandler.klass);
  8189. smalltalk.addMethod(
  8190. unescape('_setCurrent_'),
  8191. smalltalk.method({
  8192. selector: unescape('setCurrent%3A'),
  8193. category: 'accessing',
  8194. fn: function (anHandler){
  8195. var self=this;
  8196. self['@current']=anHandler;
  8197. return self;},
  8198. args: ["anHandler"],
  8199. source: unescape('setCurrent%3A%20anHandler%0A%09current%20%3A%3D%20anHandler'),
  8200. messageSends: [],
  8201. referencedClasses: []
  8202. }),
  8203. smalltalk.ErrorHandler.klass);
  8204. smalltalk.addClass('JSObjectProxy', smalltalk.Object, ['jsObject'], 'Kernel');
  8205. smalltalk.addMethod(
  8206. unescape('_jsObject_'),
  8207. smalltalk.method({
  8208. selector: unescape('jsObject%3A'),
  8209. category: 'accessing',
  8210. fn: function (aJSObject){
  8211. var self=this;
  8212. self['@jsObject']=aJSObject;
  8213. return self;},
  8214. args: ["aJSObject"],
  8215. source: unescape('jsObject%3A%20aJSObject%0A%09jsObject%20%3A%3D%20aJSObject'),
  8216. messageSends: [],
  8217. referencedClasses: []
  8218. }),
  8219. smalltalk.JSObjectProxy);
  8220. smalltalk.addMethod(
  8221. unescape('_jsObject'),
  8222. smalltalk.method({
  8223. selector: unescape('jsObject'),
  8224. category: 'accessing',
  8225. fn: function (){
  8226. var self=this;
  8227. return self['@jsObject'];
  8228. return self;},
  8229. args: [],
  8230. source: unescape('jsObject%0A%09%5EjsObject'),
  8231. messageSends: [],
  8232. referencedClasses: []
  8233. }),
  8234. smalltalk.JSObjectProxy);
  8235. smalltalk.addMethod(
  8236. unescape('_printString'),
  8237. smalltalk.method({
  8238. selector: unescape('printString'),
  8239. category: 'proxy',
  8240. fn: function (){
  8241. var self=this;
  8242. return smalltalk.send(smalltalk.send(self, "_jsObject", []), "_toString", []);
  8243. return self;},
  8244. args: [],
  8245. source: unescape('printString%0A%09%5Eself%20jsObject%20toString'),
  8246. messageSends: ["toString", "jsObject"],
  8247. referencedClasses: []
  8248. }),
  8249. smalltalk.JSObjectProxy);
  8250. smalltalk.addMethod(
  8251. unescape('_inspectOn_'),
  8252. smalltalk.method({
  8253. selector: unescape('inspectOn%3A'),
  8254. category: 'proxy',
  8255. fn: function (anInspector){
  8256. var self=this;
  8257. var variables=nil;
  8258. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  8259. smalltalk.send(variables, "_at_put_", [unescape("%23self"), smalltalk.send(self, "_jsObject", [])]);
  8260. smalltalk.send(anInspector, "_setLabel_", [smalltalk.send(self, "_printString", [])]);
  8261. for(var i in self['@jsObject']) {
  8262. variables._at_put_(i, self['@jsObject'][i]);
  8263. };
  8264. smalltalk.send(anInspector, "_setVariables_", [variables]);
  8265. return self;},
  8266. args: ["anInspector"],
  8267. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self%20jsObject.%0A%09anInspector%20setLabel%3A%20self%20printString.%0A%09%3Cfor%28var%20i%20in%20self%5B%27@jsObject%27%5D%29%20%7B%0A%09%09variables._at_put_%28i%2C%20self%5B%27@jsObject%27%5D%5Bi%5D%29%3B%0A%09%7D%3E.%0A%09anInspector%20setVariables%3A%20variables'),
  8268. messageSends: ["new", "at:put:", "jsObject", "setLabel:", "printString", "setVariables:"],
  8269. referencedClasses: ["Dictionary"]
  8270. }),
  8271. smalltalk.JSObjectProxy);
  8272. smalltalk.addMethod(
  8273. unescape('_doesNotUnderstand_'),
  8274. smalltalk.method({
  8275. selector: unescape('doesNotUnderstand%3A'),
  8276. category: 'proxy',
  8277. fn: function (aMessage){
  8278. var self=this;
  8279. var obj=nil;
  8280. var selector=nil;
  8281. var jsSelector=nil;
  8282. var arguments=nil;
  8283. obj=smalltalk.send(self, "_jsObject", []);
  8284. selector=smalltalk.send(aMessage, "_selector", []);
  8285. jsSelector=smalltalk.send(selector, "_asJavaScriptSelector", []);
  8286. arguments=smalltalk.send(aMessage, "_arguments", []);
  8287. if(obj[jsSelector] != undefined) {return smalltalk.send(obj, jsSelector, arguments)};
  8288. smalltalk.send(self, "_doesNotUnderstand_", [aMessage], smalltalk.Object);
  8289. return self;},
  8290. args: ["aMessage"],
  8291. source: unescape('doesNotUnderstand%3A%20aMessage%0A%09%7C%20obj%20selector%20jsSelector%20arguments%20%7C%0A%09obj%20%3A%3D%20self%20jsObject.%0A%09selector%20%3A%3D%20aMessage%20selector.%0A%09jsSelector%20%3A%3D%20selector%20asJavaScriptSelector.%0A%09arguments%20%3A%3D%20aMessage%20arguments.%0A%09%3Cif%28obj%5BjsSelector%5D%20%21%3D%20undefined%29%20%7Breturn%20smalltalk.send%28obj%2C%20jsSelector%2C%20arguments%29%7D%3E.%0A%09super%20doesNotUnderstand%3A%20aMessage'),
  8292. messageSends: ["jsObject", "selector", "asJavaScriptSelector", "arguments", "doesNotUnderstand:"],
  8293. referencedClasses: []
  8294. }),
  8295. smalltalk.JSObjectProxy);
  8296. smalltalk.addMethod(
  8297. unescape('_at_'),
  8298. smalltalk.method({
  8299. selector: unescape('at%3A'),
  8300. category: 'accessing',
  8301. fn: function (aString){
  8302. var self=this;
  8303. return self['@jsObject'][aString];
  8304. return self;},
  8305. args: ["aString"],
  8306. source: unescape('at%3A%20aString%0A%09%3Creturn%20self%5B%27@jsObject%27%5D%5BaString%5D%3E'),
  8307. messageSends: [],
  8308. referencedClasses: []
  8309. }),
  8310. smalltalk.JSObjectProxy);
  8311. smalltalk.addMethod(
  8312. unescape('_at_put_'),
  8313. smalltalk.method({
  8314. selector: unescape('at%3Aput%3A'),
  8315. category: 'accessing',
  8316. fn: function (aString, anObject){
  8317. var self=this;
  8318. self['@jsObject'][aString] = anObject;
  8319. return self;},
  8320. args: ["aString", "anObject"],
  8321. source: unescape('at%3A%20aString%20put%3A%20anObject%0A%09%3Cself%5B%27@jsObject%27%5D%5BaString%5D%20%3D%20anObject%3E'),
  8322. messageSends: [],
  8323. referencedClasses: []
  8324. }),
  8325. smalltalk.JSObjectProxy);
  8326. smalltalk.addMethod(
  8327. unescape('_on_'),
  8328. smalltalk.method({
  8329. selector: unescape('on%3A'),
  8330. category: 'instance creation',
  8331. fn: function (aJSObject){
  8332. var self=this;
  8333. return (function($rec){smalltalk.send($rec, "_jsObject_", [aJSObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  8334. return self;},
  8335. args: ["aJSObject"],
  8336. source: unescape('on%3A%20aJSObject%0A%09%5Eself%20new%0A%09%09jsObject%3A%20aJSObject%3B%0A%09%09yourself'),
  8337. messageSends: ["jsObject:", "yourself", "new"],
  8338. referencedClasses: []
  8339. }),
  8340. smalltalk.JSObjectProxy.klass);
  8341. smalltalk.addClass('Set', smalltalk.Collection, ['elements'], 'Kernel');
  8342. smalltalk.addMethod(
  8343. unescape('_add_'),
  8344. smalltalk.method({
  8345. selector: unescape('add%3A'),
  8346. category: 'adding/removing',
  8347. fn: function (anObject){
  8348. var self=this;
  8349. var found;
  8350. for(var i in self['@elements']) {
  8351. if(anObject == self['@elements'][i]) {
  8352. found = true;
  8353. break;
  8354. }
  8355. }
  8356. if(!found) {self['@elements'].push(anObject)}
  8357. ;
  8358. return self;},
  8359. args: ["anObject"],
  8360. source: unescape('add%3A%20anObject%0A%09%3C%0A%09%09var%20found%3B%0A%09%09for%28var%20i%20in%20self%5B%27@elements%27%5D%29%20%7B%0A%09%09%09if%28anObject%20%3D%3D%20self%5B%27@elements%27%5D%5Bi%5D%29%20%7B%0A%09%09%09%09found%20%3D%20true%3B%0A%09%09%09%09break%3B%0A%09%09%09%7D%0A%09%09%7D%0A%09%09if%28%21found%29%20%7Bself%5B%27@elements%27%5D.push%28anObject%29%7D%0A%09%3E'),
  8361. messageSends: [],
  8362. referencedClasses: []
  8363. }),
  8364. smalltalk.Set);
  8365. smalltalk.addMethod(
  8366. unescape('_remove_'),
  8367. smalltalk.method({
  8368. selector: unescape('remove%3A'),
  8369. category: 'adding/removing',
  8370. fn: function (anObject){
  8371. var self=this;
  8372. smalltalk.send(self['@elements'], "_remove_", [anObject]);
  8373. return self;},
  8374. args: ["anObject"],
  8375. source: unescape('remove%3A%20anObject%0A%09elements%20remove%3A%20anObject'),
  8376. messageSends: ["remove:"],
  8377. referencedClasses: []
  8378. }),
  8379. smalltalk.Set);
  8380. smalltalk.addMethod(
  8381. unescape('_initialize'),
  8382. smalltalk.method({
  8383. selector: unescape('initialize'),
  8384. category: 'initialization',
  8385. fn: function (){
  8386. var self=this;
  8387. smalltalk.send(self, "_initialize", [], smalltalk.Collection);
  8388. self['@elements']=[];
  8389. return self;},
  8390. args: [],
  8391. source: unescape('initialize%0A%09super%20initialize.%0A%09elements%20%3A%3D%20%23%28%29'),
  8392. messageSends: ["initialize"],
  8393. referencedClasses: []
  8394. }),
  8395. smalltalk.Set);
  8396. smalltalk.addMethod(
  8397. unescape('_size'),
  8398. smalltalk.method({
  8399. selector: unescape('size'),
  8400. category: 'accessing',
  8401. fn: function (){
  8402. var self=this;
  8403. return smalltalk.send(self['@elements'], "_size", []);
  8404. return self;},
  8405. args: [],
  8406. source: unescape('size%0A%09%5Eelements%20size'),
  8407. messageSends: ["size"],
  8408. referencedClasses: []
  8409. }),
  8410. smalltalk.Set);
  8411. smalltalk.addMethod(
  8412. unescape('_asArray'),
  8413. smalltalk.method({
  8414. selector: unescape('asArray'),
  8415. category: 'converting',
  8416. fn: function (){
  8417. var self=this;
  8418. return smalltalk.send(self['@elements'], "_copy", []);
  8419. return self;},
  8420. args: [],
  8421. source: unescape('asArray%0A%09%5Eelements%20copy'),
  8422. messageSends: ["copy"],
  8423. referencedClasses: []
  8424. }),
  8425. smalltalk.Set);
  8426. smalltalk.addMethod(
  8427. unescape('_detect_ifNone_'),
  8428. smalltalk.method({
  8429. selector: unescape('detect%3AifNone%3A'),
  8430. category: 'enumerating',
  8431. fn: function (aBlock, anotherBlock){
  8432. var self=this;
  8433. return smalltalk.send(self['@elements'], "_detect_ifNone_", [aBlock, anotherBlock]);
  8434. return self;},
  8435. args: ["aBlock", "anotherBlock"],
  8436. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%5Eelements%20detect%3A%20aBlock%20ifNone%3A%20anotherBlock'),
  8437. messageSends: ["detect:ifNone:"],
  8438. referencedClasses: []
  8439. }),
  8440. smalltalk.Set);
  8441. smalltalk.addMethod(
  8442. unescape('_do_'),
  8443. smalltalk.method({
  8444. selector: unescape('do%3A'),
  8445. category: 'enumerating',
  8446. fn: function (aBlock){
  8447. var self=this;
  8448. smalltalk.send(self['@elements'], "_do_", [aBlock]);
  8449. return self;},
  8450. args: ["aBlock"],
  8451. source: unescape('do%3A%20aBlock%0A%09elements%20do%3A%20aBlock'),
  8452. messageSends: ["do:"],
  8453. referencedClasses: []
  8454. }),
  8455. smalltalk.Set);
  8456. smalltalk.addMethod(
  8457. unescape('_includes_'),
  8458. smalltalk.method({
  8459. selector: unescape('includes%3A'),
  8460. category: 'testing',
  8461. fn: function (anObject){
  8462. var self=this;
  8463. return smalltalk.send(self['@elements'], "_includes_", [anObject]);
  8464. return self;},
  8465. args: ["anObject"],
  8466. source: unescape('includes%3A%20anObject%0A%09%5Eelements%20includes%3A%20anObject'),
  8467. messageSends: ["includes:"],
  8468. referencedClasses: []
  8469. }),
  8470. smalltalk.Set);
  8471. smalltalk.addMethod(
  8472. unescape('__eq'),
  8473. smalltalk.method({
  8474. selector: unescape('%3D'),
  8475. category: 'comparing',
  8476. fn: function (aCollection){
  8477. var self=this;
  8478. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aCollection, "_class", [])]), "_and_", [(function(){return smalltalk.send(self['@elements'], "__eq", [smalltalk.send(aCollection, "_asArray", [])]);})]);
  8479. return self;},
  8480. args: ["aCollection"],
  8481. source: unescape('%3D%20aCollection%0A%09%5Eself%20class%20%3D%20aCollection%20class%20and%3A%20%5B%0A%20%20%20%20%20%20%20%20%09elements%20%3D%20aCollection%20asArray%5D'),
  8482. messageSends: ["and:", unescape("%3D"), "class", "asArray"],
  8483. referencedClasses: []
  8484. }),
  8485. smalltalk.Set);
  8486. smalltalk.addClass('Transcript', smalltalk.Object, ['textarea'], 'Kernel');
  8487. smalltalk.Transcript.klass.iVarNames = ['current'];
  8488. smalltalk.addMethod(
  8489. unescape('_open'),
  8490. smalltalk.method({
  8491. selector: unescape('open'),
  8492. category: 'instance creation',
  8493. fn: function (){
  8494. var self=this;
  8495. smalltalk.send(smalltalk.send(self, "_current", []), "_open", []);
  8496. return self;},
  8497. args: [],
  8498. source: unescape('open%0A%20%20%20%20self%20current%20open'),
  8499. messageSends: ["open", "current"],
  8500. referencedClasses: []
  8501. }),
  8502. smalltalk.Transcript.klass);
  8503. smalltalk.addMethod(
  8504. unescape('_new'),
  8505. smalltalk.method({
  8506. selector: unescape('new'),
  8507. category: 'instance creation',
  8508. fn: function (){
  8509. var self=this;
  8510. smalltalk.send(self, "_shouldNotImplement", []);
  8511. return self;},
  8512. args: [],
  8513. source: unescape('new%0A%20%20%20%20self%20shouldNotImplement'),
  8514. messageSends: ["shouldNotImplement"],
  8515. referencedClasses: []
  8516. }),
  8517. smalltalk.Transcript.klass);
  8518. smalltalk.addMethod(
  8519. unescape('_current'),
  8520. smalltalk.method({
  8521. selector: unescape('current'),
  8522. category: 'instance creation',
  8523. fn: function (){
  8524. var self=this;
  8525. return self['@current'];
  8526. return self;},
  8527. args: [],
  8528. source: unescape('current%0A%20%20%20%20%5Ecurrent'),
  8529. messageSends: [],
  8530. referencedClasses: []
  8531. }),
  8532. smalltalk.Transcript.klass);
  8533. smalltalk.addMethod(
  8534. unescape('_show_'),
  8535. smalltalk.method({
  8536. selector: unescape('show%3A'),
  8537. category: 'printing',
  8538. fn: function (anObject){
  8539. var self=this;
  8540. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [anObject]);
  8541. return self;},
  8542. args: ["anObject"],
  8543. source: unescape('show%3A%20anObject%0A%20%20%20%20self%20current%20show%3A%20anObject'),
  8544. messageSends: ["show:", "current"],
  8545. referencedClasses: []
  8546. }),
  8547. smalltalk.Transcript.klass);
  8548. smalltalk.addMethod(
  8549. unescape('_cr'),
  8550. smalltalk.method({
  8551. selector: unescape('cr'),
  8552. category: 'printing',
  8553. fn: function (){
  8554. var self=this;
  8555. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [smalltalk.send((smalltalk.String || String), "_cr", [])]);
  8556. return self;},
  8557. args: [],
  8558. source: unescape('cr%0A%20%20%20%20self%20current%20show%3A%20String%20cr'),
  8559. messageSends: ["show:", "current", "cr"],
  8560. referencedClasses: ["String"]
  8561. }),
  8562. smalltalk.Transcript.klass);
  8563. smalltalk.addMethod(
  8564. unescape('_clear'),
  8565. smalltalk.method({
  8566. selector: unescape('clear'),
  8567. category: 'printing',
  8568. fn: function (){
  8569. var self=this;
  8570. smalltalk.send(smalltalk.send(self, "_current", []), "_clear", []);
  8571. return self;},
  8572. args: [],
  8573. source: unescape('clear%0A%20%20%20%20self%20current%20clear'),
  8574. messageSends: ["clear", "current"],
  8575. referencedClasses: []
  8576. }),
  8577. smalltalk.Transcript.klass);
  8578. smalltalk.addMethod(
  8579. unescape('_register_'),
  8580. smalltalk.method({
  8581. selector: unescape('register%3A'),
  8582. category: 'instance creation',
  8583. fn: function (aTranscript){
  8584. var self=this;
  8585. self['@current']=aTranscript;
  8586. return self;},
  8587. args: ["aTranscript"],
  8588. source: unescape('register%3A%20aTranscript%0A%09current%20%3A%3D%20aTranscript'),
  8589. messageSends: [],
  8590. referencedClasses: []
  8591. }),
  8592. smalltalk.Transcript.klass);
  8593. smalltalk.addClass('ConsoleTranscript', smalltalk.Object, ['textarea'], 'Kernel');
  8594. smalltalk.addMethod(
  8595. unescape('_clear'),
  8596. smalltalk.method({
  8597. selector: unescape('clear'),
  8598. category: 'printing',
  8599. fn: function (){
  8600. var self=this;
  8601. return self;},
  8602. args: [],
  8603. source: unescape('clear%0A%09%22no%20op%22'),
  8604. messageSends: [],
  8605. referencedClasses: []
  8606. }),
  8607. smalltalk.ConsoleTranscript);
  8608. smalltalk.addMethod(
  8609. unescape('_cr'),
  8610. smalltalk.method({
  8611. selector: unescape('cr'),
  8612. category: 'printing',
  8613. fn: function (){
  8614. var self=this;
  8615. return self;},
  8616. args: [],
  8617. source: unescape('cr%0A%09%22no%20op%22'),
  8618. messageSends: [],
  8619. referencedClasses: []
  8620. }),
  8621. smalltalk.ConsoleTranscript);
  8622. smalltalk.addMethod(
  8623. unescape('_show_'),
  8624. smalltalk.method({
  8625. selector: unescape('show%3A'),
  8626. category: 'printing',
  8627. fn: function (anObject){
  8628. var self=this;
  8629. var string=nil;
  8630. string=smalltalk.send(anObject, "_asString", []);
  8631. console.log(String(string));
  8632. return self;},
  8633. args: ["anObject"],
  8634. source: unescape('show%3A%20anObject%0A%09%7C%20string%20%7C%0A%09string%20%3A%3D%20anObject%20asString.%0A%09%3Cconsole.log%28String%28string%29%29%3E'),
  8635. messageSends: ["asString"],
  8636. referencedClasses: []
  8637. }),
  8638. smalltalk.ConsoleTranscript);
  8639. smalltalk.addMethod(
  8640. unescape('_open'),
  8641. smalltalk.method({
  8642. selector: unescape('open'),
  8643. category: 'actions',
  8644. fn: function (){
  8645. var self=this;
  8646. return self;},
  8647. args: [],
  8648. source: unescape('open'),
  8649. messageSends: [],
  8650. referencedClasses: []
  8651. }),
  8652. smalltalk.ConsoleTranscript);
  8653. smalltalk.addMethod(
  8654. unescape('_initialize'),
  8655. smalltalk.method({
  8656. selector: unescape('initialize'),
  8657. category: 'initialization',
  8658. fn: function (){
  8659. var self=this;
  8660. smalltalk.send((smalltalk.Transcript || Transcript), "_register_", [smalltalk.send(self, "_new", [])]);
  8661. return self;},
  8662. args: [],
  8663. source: unescape('initialize%0A%09Transcript%20register%3A%20self%20new'),
  8664. messageSends: ["register:", "new"],
  8665. referencedClasses: ["Transcript"]
  8666. }),
  8667. smalltalk.ConsoleTranscript.klass);