src/JavaLookup.st
branchjk_new_structure
changeset 761 43e017ec7958
parent 752 ff7bc6428c9c
child 772 0f92c23b80ee
equal deleted inserted replaced
760:5f55da80009b 761:43e017ec7958
    66 !
    66 !
    67 
    67 
    68 lookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    68 lookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    69     "as a courtesy to the smalltalker, try to map methods"
    69     "as a courtesy to the smalltalker, try to map methods"
    70     | m |
    70     | m |
    71     m := self javaLookupMethodForSelector: selector for: aReceiver withArguments: argArrayOrNil.
    71     self halt.
    72     m ifNotNil: [ ^ m ] .
    72 "/    m := self javaLookupMethodForSelector: selector for: aReceiver withArguments: argArrayOrNil.
       
    73 "/    m ifNotNil: [ ^ m ] .
    73     "
    74     "
    74             I am not sure, if we should invoke builtin lookup. It will search for the Smalltalk-like methods.
    75             I am not sure, if we should invoke builtin lookup. It will search for the Smalltalk-like methods.
    75             For example, if you invoke #isNumber on java.lang.String 
    76             For example, if you invoke #isNumber on java.lang.String 
    76                 a) you should get 'doesNotUnderstand'
    77                 a) you should get 'doesNotUnderstand'
    77                 b) the isNumber from Object is invoked (currently implemented)
    78                 b) the isNumber from Object is invoked (currently implemented)
    78     "
    79     "
    79     self breakPoint: #libjava.
    80     self breakPoint: #libjava.
    80     ^ self smalltalkLookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    81     ^ self smalltalkLookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    81 
    82 
    82     "Created: / 21-02-2011 / 13:38:55 / kursjan <kursjan@fit.cvut.cz>"
    83     "Created: / 21-02-2011 / 13:38:55 / kursjan <kursjan@fit.cvut.cz>"
    83     "Modified: / 25-02-2011 / 20:03:30 / kursjan <kursjan@fit.cvut.cz>"
    84     "Modified: / 11-04-2011 / 20:19:50 / kursjan <kursjan@fit.cvut.cz>"
    84 !
    85 !
    85 
    86 
    86 smalltalkLookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    87 smalltalkLookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext
    87     ^ Lookup builtin lookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext.
    88     ^ Lookup builtin lookupMethodForSelector:selector directedTo:initialSearchClass for:aReceiver withArguments:argArrayOrNil from:sendingContext.
    88 
    89 
    92 !JavaLookup class methodsFor:'documentation'!
    93 !JavaLookup class methodsFor:'documentation'!
    93 
    94 
    94 version_SVN
    95 version_SVN
    95     ^ '$Id$'
    96     ^ '$Id$'
    96 ! !
    97 ! !
       
    98