Ver Fonte

Adds Environment >> allSelectors

Nicolas Petton há 11 anos atrás
pai
commit
2c5bab899b
3 ficheiros alterados com 37 adições e 0 exclusões
  1. 14 0
      js/Kernel-Objects.deploy.js
  2. 19 0
      js/Kernel-Objects.js
  3. 4 0
      st/Kernel-Objects.st

+ 14 - 0
js/Kernel-Objects.deploy.js

@@ -1511,6 +1511,20 @@ return self}, function($ctx1) {$ctx1.fill(self,"addInstVarNamed:to:",{aString:aS
 messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "superclass", "name", "add:", "copy", "instanceVariableNames", "yourself", "package", "classBuilder"]}),
 smalltalk.Environment);
 
+smalltalk.addMethod(
+smalltalk.method({
+selector: "allSelectors",
+fn: function (){
+var self=this;
+function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(_st(_st($Smalltalk())._current())._at_("allSelectors"))._value();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"allSelectors",{},smalltalk.Environment)})},
+messageSends: ["value", "at:", "current"]}),
+smalltalk.Environment);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "availableClassNames",

+ 19 - 0
js/Kernel-Objects.js

@@ -2115,6 +2115,25 @@ referencedClasses: []
 }),
 smalltalk.Environment);
 
+smalltalk.addMethod(
+smalltalk.method({
+selector: "allSelectors",
+category: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+return smalltalk.withContext(function($ctx1) { 
+var $1;
+$1=_st(_st(_st($Smalltalk())._current())._at_("allSelectors"))._value();
+return $1;
+}, function($ctx1) {$ctx1.fill(self,"allSelectors",{},smalltalk.Environment)})},
+args: [],
+source: "allSelectors\x0a\x09^ (Smalltalk current at: 'allSelectors') value",
+messageSends: ["value", "at:", "current"],
+referencedClasses: ["Smalltalk"]
+}),
+smalltalk.Environment);
+
 smalltalk.addMethod(
 smalltalk.method({
 selector: "availableClassNames",

+ 4 - 0
st/Kernel-Objects.st

@@ -667,6 +667,10 @@ Abstract class defining common behavior for local and remote environments!
 
 !Environment methodsFor: 'accessing'!
 
+allSelectors
+	^ (Smalltalk current at: 'allSelectors') value
+!
+
 availableClassNames
 	^ Smalltalk current classes 
 		collect: [ :each | each name ]