Next: , Previous: , Up: Behavior   [Index]


1.9.15 Behavior: method dictionary

addSelector: selector withMethod: compiledMethod

Add the given compiledMethod to the method dictionary, giving it the passed selector. Answer compiledMethod

compile: code

Compile method source. If there are parsing errors, answer nil. Else, return a CompiledMethod result of compilation

compile: code ifError: block

Compile method source. If there are parsing errors, invoke exception block, ’block’ passing file name, line number and error. Return a CompiledMethod result of compilation

compile: code notifying: requestor

Compile method source. If there are parsing errors, send #error: to the requestor object, else return a CompiledMethod result of compilation

compileAll

Recompile all selectors in the receiver. Ignore errors.

compileAll: aNotifier

Recompile all selectors in the receiver. Notify aNotifier by sending #error: messages if something goes wrong.

compileAllSubclasses

Recompile all selector of all subclasses. Notify aNotifier by sending #error: messages if something goes wrong.

compileAllSubclasses: aNotifier

Recompile all selector of all subclasses. Notify aNotifier by sending #error: messages if something goes wrong.

createGetMethod: what

Create a method accessing the variable ‘what’.

createGetMethod: what default: value

Create a method accessing the variable ‘what’, with a default value of ‘value’, using lazy initialization

createSetMethod: what

Create a method which sets the variable ‘what’.

decompile: selector

Decompile the bytecodes for the given selector.

defineAsyncCFunc: cFuncNameString withSelectorArgs: selectorAndArgs args: argsArray

Please lookup the part on the C interface in the manual. This method is deprecated, you should use the asyncCCall:args: attribute.

defineCFunc: cFuncNameString withSelectorArgs: selectorAndArgs returning: returnTypeSymbol args: argsArray

Please lookup the part on the C interface in the manual. This method is deprecated, you should use the cCall:returning:args: attribute.

edit: selector

Open Emacs to edit the method with the passed selector, then compile it

methodDictionary

Answer the receiver’s method dictionary. Don’t modify the method dictionary unless you exactly know what you’re doing

methodDictionary: aDictionary

Set the receiver’s method dictionary to aDictionary

recompile: selector

Recompile the given selector, answer nil if something goes wrong or the new CompiledMethod if everything’s ok.

recompile: selector notifying: aNotifier

Recompile the given selector. If there are parsing errors, send #error: to the aNotifier object, else return a CompiledMethod result of compilation

removeSelector: selector

Remove the given selector from the method dictionary, answer the CompiledMethod attached to that selector

removeSelector: selector ifAbsent: aBlock

Remove the given selector from the method dictionary, answer the CompiledMethod attached to that selector. If the selector cannot be found, answer the result of evaluating aBlock.

selectorsAndMethodsDo: aBlock

Evaluate aBlock, passing for each evaluation a selector that’s defined in the receiver and the corresponding method.


Next: , Previous: , Up: Behavior   [Index]