equal
deleted
inserted
replaced
250 just a class name and selector as a name for native method impl. |
250 just a class name and selector as a name for native method impl. |
251 The new one uses fully qualified class name. |
251 The new one uses fully qualified class name. |
252 " |
252 " |
253 |
253 |
254 | nm newStyleSel oldStyleSel | |
254 | nm newStyleSel oldStyleSel | |
255 nm := selector copyWithoutLast:signature size. |
255 nm := selector upTo: $(. |
256 newStyleSel := ('_' , ((javaClass name copyReplaceAll:$/ with:$_) replaceAll:$$ with:$_), '_' , nm , ':') asSymbol. |
256 newStyleSel := ('_' , ((javaClass name copyReplaceAll:$/ with:$_) replaceAll:$$ with:$_), '_' , nm , ':') asSymbol. |
257 (JavaVM class canUnderstand: newStyleSel) ifTrue: |
257 (JavaVM class canUnderstand: newStyleSel) ifTrue: |
258 ["Good, a JavaVM understands new style native selectors" |
258 ["Good, a JavaVM understands new style native selectors" |
259 ^newStyleSel]. |
259 ^newStyleSel]. |
260 |
260 |
273 ]]. |
273 ]]. |
274 self compileNativeImplementationStub: newStyleSel. |
274 self compileNativeImplementationStub: newStyleSel. |
275 ^newStyleSel |
275 ^newStyleSel |
276 |
276 |
277 "Created: / 30-04-2011 / 23:50:29 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
277 "Created: / 30-04-2011 / 23:50:29 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
278 "Modified: / 01-05-2011 / 13:13:07 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
278 "Modified: / 13-08-2011 / 01:08:04 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
279 ! ! |
279 ! ! |
280 |
280 |
281 !JavaNativeMethod methodsFor:'vm support'! |
281 !JavaNativeMethod methodsFor:'vm support'! |
282 |
282 |
283 nativeMethodInvokation |
283 nativeMethodInvokation |