JavaClass.st
changeset 625 b0d1764545b5
parent 624 35975d55bbb5
child 626 ee0094f07603
--- a/JavaClass.st	Tue Nov 09 15:43:45 1999 +0000
+++ b/JavaClass.st	Tue Nov 09 17:00:14 1999 +0000
@@ -881,53 +881,20 @@
 
 !JavaClass methodsFor:'documentation support'!
 
-htmlDocumentation
-    ^ nil "/ replace by access to javadoc-generated documentation later
+ethodsAccessingGlobal:aGlobalKey
+    "/ dummy for now
 
-    "Modified: 22.3.1997 / 14:18:50 / cg"
+    "Created: / 9.11.1999 / 16:42:09 / cg"
 ! !
 
 !JavaClass methodsFor:'executing programs'!
 
-startApplet
-    |f me stub|
-
-    "/ TODO: setup embeddedAppletFrame correctly
-    "/ (for getParameter to work ...)
-
-    "/ create a frame and wrap me;
-    "/ as in:
+eplace by access to javadoc-generated documentation later
 
-"/    public static void main(String args[]) {
-"/        Frame f = new Frame("myName");
-"/        mySelf me = new mySelf();
-"/
-"/        me.init();
-"/        me.start();
-"/
-"/        f.add("Center", me);
-"/        f.setSize(300, 300);
-"/        f.show();
-"/    }
-    f := (Java at:'java.awt.Frame') basicNew.
-    f perform:#'<init>(Ljava/lang/String;)V' with:(Java as_String:self name).
-self halt.
-    me := self basicNew.
-    me perform:#'<init>()V'.
-self halt.
+    "Modified: 22.3.1997 / 14:18:50 / cg"
+!
 
-    stub := (Java at:'netscape.applet.EmbeddedAppletFrame') new.
-    me instVarNamed:'stub' put:stub.
-self halt.
-
-    me perform:#'init()V'.
-    me perform:#'start()V'.
-self halt.
-
-    f perform:#'add(Ljava/lang/String;Ljava/awt/Component;)Ljava/awt/Component;' 
-         with:(Java as_String:'Center')
-         with:me.
-self halt.
+halt.
     f perform:#'setSize(II)V' with:300 with:300.
 self halt.
     f perform:#'show()V'.
@@ -936,143 +903,52 @@
     "Modified: / 3.11.1998 / 23:04:41 / cg"
 !
 
-startMain
-    "start a thread for my main() method"
-
-    ^ self startMainWithArgumentString:nil
-
-    "Modified: / 30.12.1998 / 20:24:58 / cg"
-!
+g"
+! !
 
-startMainWithArgumentString:aCommandLineString
-    "start a thread for my main() method, passing a string with arguments"
-
-    |p|
+!JavaClass methodsFor:'fileOut'!
 
-    p := Java javaProcessForMainOf:self argumentString:aCommandLineString.
-    p notNil ifTrue:[
-        p resume.
-        Object abortSignal handle:[:ex |
-p == JavaVM javaScreenUpdaterThread ifTrue:[self halt].
-            p terminate.
-            ex reject.
+.
         ] do:[
             p waitUntilTerminated
         ].
     ]
 
     "Modified: / 8.1.1999 / 17:17:40 / cg"
-! !
+!
 
-!JavaClass methodsFor:'fileOut'!
-
-basicFileOutDefinitionOn:aStream withNameSpace:nameSpaceBoolean
+leOutDefinitionOn:aStream withNameSpace:nameSpaceBoolean
     JavaDecompiler definitionOf:self on:aStream
 
     "Modified: 22.3.1997 / 14:30:28 / cg"
-!
-
-fileOut
-    self warn:'fileOut not yet supported'
-
-    "Modified: 22.3.1997 / 14:30:28 / cg"
-    "Created: 22.3.1997 / 14:35:43 / cg"
 ! !
 
 !JavaClass methodsFor:'java initialization'!
 
-classInit
-    "call the classes JAVA clinit function"
-
-    |m|
-
-    (accessFlags bitAnd:A_INITIALIZED) ~~ 0 ifTrue:[^ self].
-
-    accessFlags := accessFlags bitOr:A_INITIALIZED.
-
-    superclass ~~ JavaObject ifTrue:[
-        superclass classInit
-    ].
-"/    "/ also, all referenced classes must be ...
-"/    constantPool classReferencesDo:[:aClass |
-"/        aClass classInit
-"/    ].
+yet supported'
 
-    m := self compiledMethodAt:#'<clinit>()V'.
-    m notNil ifTrue:[
-"/        'calling clinit() of ' print. self fullName printNL.
-        [
-            OrderOfClassInits notNil ifTrue:[
-                OrderOfClassInits add:self.
-            ].
+    "Modified: 22.3.1997 / 14:30:28 / cg"
+    "Created: 22.3.1997 / 14:35:43 / cg"
+!
 
-            m 
-                valueWithReceiver:self 
-                arguments:#() 
-                selector:#'<clinit>()V' 
-                search:self class
-                sender:nil
-        ] valueOnUnwindDo:[
-            accessFlags := accessFlags bitXor:A_INITIALIZED.
-        ]
-    ] ifFalse:[
-"/        self fullName print. ' has no clinit()' printNL.
-    ].
-
-    "
-     JavaVM instructionTrace:true.
-     JavaVM callTrace:true.
-
-     (Java classNamed:'java.lang.String') classInit
-     (Java classNamed:'java.lang.System') classInit
-
-     (Java classNamed:'java/io/FileDescriptor') classInit
+ed:'java/io/FileDescriptor') classInit
      (Java classNamed:'java.util.Properties') classInit 
     "
 
     "Modified: / 12.11.1998 / 15:41:11 / cg"
-!
-
-initializeStaticFields
-    staticFields isNil ifTrue:[^ self].
-
-    staticFields do:[:f |
-	|val type|
+! !
 
-	(val := f constantValue) isNil ifTrue:[
-	    "/ careful: int/long etc. constants must be initialized
-	    "/ with correct type.
-	    type := f type.
-	    type == #long ifTrue:[
-		val := 0.
-	    ] ifFalse:[type == #int ifTrue:[
-		val := 0.
-	    ] ifFalse:[type == #float ifTrue:[
-		val := 0.0 asShortFloat
-	    ] ifFalse:[type == #double ifTrue:[
-		val := 0.0 
-	    ] ifFalse:[type == #byte ifTrue:[
-		val := 0.
-	    ] ifFalse:[type == #char ifTrue:[
-		val := 0.
-	    ] ifFalse:[type == #'unsigned short' ifTrue:[
-		val := 0.
-	    ] ifFalse:[type == #boolean ifTrue:[
+!JavaClass methodsFor:'java instance creation'!
+
+== #boolean ifTrue:[
 		val := 0.
 	    ]]]]]]]].
 	].
 	self instVarNamed:(f name) put:val.
     ].
-! !
-
-!JavaClass methodsFor:'java instance creation'!
+!
 
-initValueFor:instVarName
-    |idx field|
-
-    idx := fields findFirst:[:field | field name = instVarName].
-    idx == 0 ifTrue:[
-	superclass ~~ JavaObject ifTrue:[
+JavaObject ifTrue:[
 	    ^ superclass initValueFor:instVarName
 	].
 	self halt
@@ -1082,88 +958,21 @@
     ].
 !
 
-new
-    "create a new instance, preset its fields,
-     and call its JAVA init function"
-
-    |newJavaObject|
-
-    newJavaObject := self newCleared.
-    newJavaObject perform:#'<init>()V'.
-    ^ newJavaObject
-
-    "
-     (Java classNamed:'java.lang.String') basicNew inspect
-     (Java classNamed:'java.lang.String') newCleared inspect
+med:'java.lang.String') newCleared inspect
      (Java classNamed:'java.lang.String') new inspect
     "
 
     "Modified: / 4.11.1998 / 18:04:34 / cg"
 !
 
-newCleared
-    "create a new cleared JAVA instance.
-     Its instVars are cleared to the corresponding typed values;
-     however, <init> is not invoked for it."
-
-    |newJavaObject sz "{ Class: SmallInteger }" |
-
-    (accessFlags bitAnd:A_ABSTRACT_OR_INTERFACE) ~~ 0 ifTrue:[
-        JavaVM throwInstantiationExceptionFor:self.
-        ^ nil
-    ].
-
-    newJavaObject := super basicNew.
-    initValues notNil ifTrue:[
-        sz := self instSize.
-        1 to:sz do:[:i |
-            newJavaObject instVarAt:i put:(initValues at:i)
-        ].
-    ].
-
-    ^ newJavaObject
-
-    "
-     (Java classNamed:'java.lang.String') basicNew inspect
-     (Java classNamed:'java.lang.String') newCleared inspect
+ed:'java.lang.String') newCleared inspect
      (Java classNamed:'java.lang.String') new inspect
     "
 
     "Modified: / 13.11.1998 / 14:10:45 / cg"
 !
 
-newWith_String:argString
-    "create a new instance, preset its fields,
-     and call its JAVA init function passing a String arg"
-
-    |newJavaObject|
-
-    newJavaObject := self newCleared.
-    newJavaObject 
-        perform:#'<init>(Ljava/lang/String;)V' 
-        with:(Java as_String:argString).
-    ^ newJavaObject
-
-    "
-     ((Java classNamed:'java.lang.ArrayStoreException') newWith_String:'foo') inspect
-    "
-
-    "Modified: / 4.11.1998 / 18:04:34 / cg"
-    "Created: / 13.11.1998 / 14:17:01 / cg"
-!
-
-newWith_int:arg
-    "create a new instance, preset its fields,
-     and call its JAVA init function passing an int arg"
-
-    |newJavaObject|
-
-    newJavaObject := self newCleared.
-    newJavaObject perform:#'<init>(I)V' with:arg.
-    ^ newJavaObject
-
-    "
-     ((Java classNamed:'java.lang.Integer') newWith_int:123) inspect
+.ArrayStoreException') newWith_String:'foo') inspect
     "
 
     "Modified: / 4.11.1998 / 18:04:34 / cg"
@@ -1172,113 +981,21 @@
 
 !JavaClass methodsFor:'message sending'!
 
-doesNotUnderstand:aMessage
-    "as a courtesy to the smalltalker, try to map static methods as
-     Smalltalk-class methods"
-
-    |r args numArgs methods javaMethod sel anyMethodsFound argType
-     argSignature newArgs oArgIdx nArgIdx canConvert
-     retVal|
-
-    args := aMessage arguments.
-    numArgs := args size.
-    sel := aMessage selector.
-
-    methods := JavaClass lookupMethods:sel numArgs:numArgs in:self static:true.
-    methods size == 1 ifTrue:[
-        javaMethod := methods first.
-        "/ there is only one - try that one.
-    ] ifFalse:[
-        methods size > 1 ifTrue:[
-            "/ more than one - select the ones that could be used.
-            methods := methods select:[:aMethod |
-                |argSignature|
-
-                argSignature := aMethod argSignature.
-                (JavaClass canConvertArgsToJava:args asSpecifiedIn:argSignature) 
-            ].
-            methods size == 1 ifTrue:[
-                javaMethod := methods first.
-            ]
-        ]
-    ].
+inspect
+    "
 
-    javaMethod notNil ifTrue:[
-        (ArgumentConversionErrorSignal catch:[
-            args notNil ifTrue:[
-                args := JavaClass 
-                            convertArgsToJava:args 
-                            asSpecifiedIn:(javaMethod argSignature)
-                            numArgs:numArgs.
-            ].
-        ]) ifFalse:[
-            retVal := javaMethod 
-                        valueWithReceiver:self "/ (javaMethod javaClass) 
-                        arguments:args
-                        selector:(javaMethod selector)
-                        search:self "/ (javaMethod javaClass class)
-                        sender:nil.
-            ^ JavaClass convertToSmalltalk:retVal type:(javaMethod returnType).
-        ].
-        ^ MessageNotUnderstoodSignal
-                    raiseRequestWith:aMessage
-                         errorString:'no method for given argument(s)'
-                                  in:thisContext "sender"
-    ].
-
-    anyMethodsFound := false.
-
-    "/ try all with that name (the number of args could be different ...
+    "Modified: / 4.11.1998 / 18:04:34 / cg"
+    "Created: / 13.11.1998 / 14:17:01 / cg"
+!
 
-    methods := JavaClass lookupMethods:sel numArgs:nil in:self static:true.
-    methods size > 0 ifTrue:[
-        anyMethodsFound := true.
-        numArgs > 0 ifTrue:[
-            methods do:[:methodToTry |
-                (ArgumentConversionErrorSignal catch:[
-                    newArgs := JavaClass 
-                                convertArgsToJava:args 
-                                asSpecifiedIn:(methodToTry argSignature)
-                                numArgs:methodToTry numArgs.
-                ]) ifFalse:[
-                    retVal :=  methodToTry 
-                                    valueWithReceiver:self "/ (methodToTry javaClass) 
-                                    arguments:newArgs
-                                    selector:(methodToTry selector)
-                                    search:self "/ (methodToTry javaClass class)
-                                    sender:nil.
-                    ^ JavaClass convertToSmalltalk:retVal type:(methodToTry returnType).
-                ].
-            ].
-        ]
-    ].
-
-    anyMethodsFound ifTrue:[
-        methods size == 1 ifTrue:[
-            javaMethod := methods first.
-
-            ^ MessageNotUnderstoodSignal
-                        raiseRequestWith:aMessage
-                             errorString:(sel , ' expects ' , javaMethod argSignature size printString , ' argument(s)')
-                                      in:thisContext "sender"
-        ].
-        ^ MessageNotUnderstoodSignal
-                    raiseRequestWith:aMessage
-                         errorString:'no method for given argument count or type'
-                                  in:thisContext "sender"
+in:thisContext "sender"
     ].
     ^ super doesNotUnderstand:aMessage
 
     "Modified: / 6.11.1998 / 00:57:22 / cg"
 !
 
-lookupMethodFor:selector
-    |method cls sel|
-
-    sel := selector asSymbolIfInterned.
-    sel notNil ifTrue:[
-	cls := self.
-	[cls notNil] whileTrue:[
+Nil] whileTrue:[
 	    method := cls compiledMethodAt:sel.
 	    method notNil ifTrue:[ ^ method ].
 	    cls := cls superclass.
@@ -1288,101 +1005,42 @@
     ^ nil
 !
 
-performStatic:selector
-    "send a static message, without args."
-
-    |javaMethod sel|
-
-    sel := selector asSymbolIfInterned.
-    sel notNil ifTrue:[
-        javaMethod := methodDictionary at:sel.
-        javaMethod notNil ifTrue:[
-            javaMethod isStatic ifTrue:[
-                ^ javaMethod 
-                    valueWithReceiver:self 
-                    arguments:#()
-            ]
-        ].
-    ].
-
-    ^ self doesNotUnderstand:(Message selector:selector)
+^ self doesNotUnderstand:(Message selector:selector)
 
     "Modified: / 15.1.1998 / 00:31:27 / cg"
     "Created: / 12.11.1998 / 16:29:20 / cg"
-!
-
-performStatic:selector with:arg
-    "send a static message, with one args."
-
-    |javaMethod sel|
-
-    sel := selector asSymbolIfInterned.
-    sel notNil ifTrue:[
-        javaMethod := methodDictionary at:sel.
-        javaMethod notNil ifTrue:[
-            javaMethod isStatic ifTrue:[
-                ^ javaMethod 
-                    valueWithReceiver:self 
-                    arguments:(Array with:arg)
-            ]
-        ].
-    ].
-
-    ^ self doesNotUnderstand:(Message selector:selector argument:arg)
-
-    "Modified: / 15.1.1998 / 00:31:27 / cg"
-    "Created: / 10.12.1998 / 21:50:29 / cg"
 ! !
 
 !JavaClass methodsFor:'printOut'!
 
-printNameInHierarchy
-    "return my name as printed in the hierarchy"
+elector argument:arg)
 
-    ^ self displayString
-
-    "Modified: 22.3.1997 / 14:16:55 / cg"
+    "Modified: / 15.1.1998 / 00:31:27 / cg"
+    "Created: / 10.12.1998 / 21:50:29 / cg"
 !
 
-printOutOn:aStream
-    self warn:'printOut not yet supported'
+ntOut'!
 
-    "Created: 22.3.1997 / 14:36:12 / cg"
-!
+"Modified: 22.3.1997 / 14:16:55 / cg"
+! !
 
-printOutProtocolOn:aStream
+!JavaClass methodsFor:'printing & storing'!
+
+tocolOn:aStream
     self warn:'printOut not yet supported'
 
     "Created: 22.3.1997 / 14:36:28 / cg"
 ! !
 
-!JavaClass methodsFor:'printing & storing'!
+!JavaClass methodsFor:'private accessing'!
 
-displayString
-    ^ fullName copyReplaceAll:$/ with:$.
-
-"/    ^ 'JAVA-' , name .
-"/    ^ name , '(Java)'  "/ 'JavaClass(' , name , ')'
+, name , ')'
 
     "Created: / 15.4.1996 / 16:02:48 / cg"
     "Modified: / 18.7.1998 / 22:56:30 / cg"
-! !
-
-!JavaClass methodsFor:'private accessing'!
-
-addMethod:m name:name signature:signature
-    |sel|
+!
 
-    sel := (name , signature) asSymbol.
-    self addSelector:sel withMethod:m.
-    ^ self.
-
-"/    selectorArray isNil ifTrue:[
-"/        selectorArray := #().
-"/        methodArray := #()
-"/    ].
-"/    selectorArray := selectorArray copyWith:(name , signature) asSymbol. "/ name.
-"/"/    selectorArray := selectorArray copyWith:name asSymbol. "/ name.
+ctorArray := selectorArray copyWith:name asSymbol. "/ name.
 "/    methodArray := methodArray copyWith:m
 
     "Created: 15.4.1996 / 16:42:52 / cg"
@@ -1390,13 +1048,7 @@
 
 !
 
-addSelector:newSelector withMethod:newMethod
-    "redefined to not flush smalltalk caches and send NO smalltalk-class
-     change notification. Will eventually flush Java caches."
-
-    |nargs oldMethod|
-
-    oldMethod := self compiledMethodAt:newSelector.
+t:newSelector.
     (self primAddSelector:newSelector withMethod:newMethod) ifFalse:[^ false].
 
     ^ true
@@ -1404,52 +1056,27 @@
     "Created: 20.1.1997 / 13:00:48 / cg"
 !
 
-makeObsolete
-    accessFlags := accessFlags bitOr:A_OBSOLETE
-
-    "Created: 7.8.1997 / 19:04:48 / cg"
+"Created: 20.1.1997 / 13:00:48 / cg"
 !
 
-markUninitialized
-    (accessFlags bitAnd:A_INITIALIZED) ~~ 0 ifTrue:[
-	accessFlags := accessFlags bitXor:A_INITIALIZED
+/ 19:04:48 / cg"
+!
+
+accessFlags := accessFlags bitXor:A_INITIALIZED
     ].
 !
 
-setAccessFlags:flags
+ccessFlags:flags
     accessFlags := flags.
 
     "Created: 15.4.1996 / 16:42:52 / cg"
 !
 
-setBinaryFilePath:aPathName
+ilePath:aPathName
     binaryFilePath := aPathName
 !
 
-setConstantPool:anArray
-    constantPool := anArray.
-
-    "Created: 15.4.1996 / 16:42:52 / cg"
-!
-
-setFields:f
-    |vals|
-
-    JavaClass setInstanceVariableStringFromFields:f in:self.
-
-    instSize := superclass instSize + f size.
-
-    fields := f.
-    vals := self allInstVarNames 
-                collect:[:nm |
-                            self initValueFor:nm
-                        ].
-    vals isEmpty ifTrue:[
-        initValues := nil
-    ] ifFalse:[
-        (vals detect:[:el | el notNil] ifNone:nil) isNil ifTrue:[
-            initValues := nil
-        ] ifFalse:[
+se:[
             initValues := vals asArray
         ]
     ]
@@ -1458,71 +1085,36 @@
     "Modified: / 6.11.1998 / 01:53:01 / cg"
 !
 
-setFullName:aString
-    |nameComponents|
-
-    fullName := aString asSymbol.
-    nameComponents := aString asCollectionOfSubstringsSeparatedBy:$/.
-    name := nameComponents last asSymbol.
+name := nameComponents last asSymbol.
 name := fullName.
 
     "Created: / 15.4.1996 / 16:42:52 / cg"
     "Modified: / 5.11.1998 / 19:14:39 / cg"
 !
 
-setInterfaces:i
-    i size > 0 ifTrue:[
-	interfaces := i
-    ] ifFalse:[
-	interfaces := nil
+cg"
+!
+
+l
     ]
 
     "Modified: 7.4.1997 / 15:44:53 / cg"
 !
 
-setSourceFile:aFilename
-    sourceFile := aFilename.
-
-    "Created: 15.4.1996 / 16:42:52 / cg"
-!
-
-setStaticFields:f
-    JavaClass setInstanceVariableStringFromFields:f in:self class.
-
-    staticFields := f.
-
-
-!
+eated: 15.4.1996 / 16:42:52 / cg"
+! !
 
-setSuperclass:aClass
-    |iVars numIvars|
+!JavaClass methodsFor:'queries'!
 
-    aClass isNil ifTrue:[
-	super setSuperclass:JavaObject
-    ] ifFalse:[
-	(aClass isMemberOf:JavaUnresolvedClassConstant) ifTrue:[
-	    self halt.
-	].
-	super setSuperclass:aClass.
-    ].
-
-    iVars := self instVarNames.
-    ((numIvars := iVars size) > 0) ifTrue:[
-	(superclass notNil and:[(superclass isMemberOf:JavaUnresolvedClassConstant) not]) ifTrue:[
-	    instSize := superclass instSize + numIvars
-	] ifFalse:[
-	    instSize := numIvars
+tSize := numIvars
 	]
     ].
 
     "Created: 15.4.1996 / 16:42:52 / cg"
     "Modified: 22.8.1997 / 15:06:45 / cg"
-! !
+!
 
-!JavaClass methodsFor:'queries'!
-
-canBeSubclassed
-    "return true, if its allowed to create subclasses of the receiver."
+of the receiver."
 
     self isFinal ifTrue:[^ false].
     self isInterface ifTrue:[^ false].
@@ -1531,23 +1123,7 @@
     "Created: / 5.11.1998 / 23:04:50 / cg"
 !
 
-hasInterface:aJavaInterface
-    "return true, if I respond to all methods as
-     required by the argument, an aJavaInterface"
-
-    interfaces size > 0 ifTrue:[
-        self interfaces do:[:if |
-            aJavaInterface == if ifTrue:[
-                ^ true
-            ].
-        ]
-    ].
-    superclass isJavaClass ifTrue:[
-        ^ superclass hasInterface:aJavaInterface
-    ].
-    ^ false.
-
-"/    aJavaInterface methodDictionary keysAndValuesDo:[:sel :mthd |
+|
 "/        (self canUnderstand:sel) ifFalse:[
 "/            ^ false.
 "/        ]
@@ -1558,8 +1134,7 @@
 
 !
 
-isAbstract
-    "return true, if the receiver is abstract
+he receiver is abstract
      (i.e. may not have instances)"
 
     ^ (accessFlags bitAnd:A_ABSTRACT) ~~ 0
@@ -1567,8 +1142,7 @@
     "Modified: / 7.5.1998 / 12:24:42 / cg"
 !
 
-isFinal
-    "return true, if the receiver is final
+e, if the receiver is final
      (i.e. may not be subclassed)"
 
     ^ (accessFlags bitAnd:A_FINAL) ~~ 0
@@ -1576,7 +1150,7 @@
     "Modified: / 7.5.1998 / 12:24:21 / cg"
 !
 
-isInitialized
+alized
     "return true, if the receiver is initialized"
 
     ^ (accessFlags bitAnd:A_INITIALIZED) ~~ 0
@@ -1584,7 +1158,7 @@
     "Modified: / 7.5.1998 / 12:23:54 / cg"
 !
 
-isInterface
+terface
     "return true, if the receiver is an interface"
 
     ^ (accessFlags bitAnd:A_INTERFACE) ~~ 0
@@ -1592,20 +1166,24 @@
     "Modified: / 7.5.1998 / 12:23:39 / cg"
 !
 
-isJavaClass
+isJavaClassRef
+    ^ false
+
+    "Created: / 9.11.1999 / 17:06:54 / cg"
+!
+
+tAnd:A_INTERFACE) ~~ 0
+
+    "Modified: / 7.5.1998 / 12:23:39 / cg"
+!
+
+aClass
     ^ self ~~ JavaClass
 
     "Created: 18.3.1997 / 17:48:01 / cg"
 !
 
-isJavaMethodRef
-    ^ false
-
-    "Created: / 9.11.1999 / 15:42:10 / cg"
-!
-
-isObsolete 
-    "return true, if the receiver is obsolete 
+, if the receiver is obsolete 
      Java classes are never."
 
     ^ (accessFlags bitAnd:A_OBSOLETE) ~~ 0.
@@ -1613,16 +1191,10 @@
     "Modified: 7.8.1997 / 19:04:28 / cg"
 !
 
-isPublic
-    "return true, if the receiver is public" 
-
-    ^ (accessFlags bitAnd:A_PUBLIC) ~~ 0
-
-    "Modified: / 7.5.1998 / 12:22:44 / cg"
+cg"
 !
 
-isUnresolved
-    "return true, if the receiver is unresolved;
+the receiver is unresolved;
      javaClasses are never; JavaUnresolvedClasses are always" 
 
     ^ false
@@ -1630,95 +1202,39 @@
     "Modified: / 7.5.1998 / 12:23:14 / cg"
 !
 
-nameSpacePath
-    |parts s|
-
-    parts := self fullName asCollectionOfSubstringsSeparatedBy:$/.
-    s := '' writeStream.
-    s nextPutAll:'JAVA'.
-    parts from:1 to:(parts size - 1) do:[:aPart |
-        s nextPutAll:'::'.
-        s nextPutAll:aPart
-    ].
-    ^ s contents
-
-    "
-     JAVA::java::lang::Object fullName        
-     JAVA::java::lang::Object nameSpacePath   
+JAVA::java::lang::Object nameSpacePath   
      JAVA::java::lang::Object name            
     "
 
     "Modified: / 19.10.1998 / 20:07:24 / cg"
 !
 
-supportsMethodCategories
-    ^ self isJavaClass not
+/ cg"
+! !
 
-    "Created: / 30.7.1997 / 14:58:58 / cg"
-    "Modified: / 7.5.1998 / 12:25:54 / cg"
-!
+!JavaClass methodsFor:'special'!
 
-typeName
-    ^ 'L' , self fullName
+f fullName
 
     "
      (Java at:'java.util.Stack') typeName 
     "
 
     "Modified: / 10.2.1998 / 17:13:26 / cg"
-! !
-
-!JavaClass methodsFor:'special'!
-
-arrayClass
-"/ self halt.
-        ^ Array
-
-    "Created: / 10.11.1998 / 02:07:32 / cg"
-    "Modified: / 8.1.1999 / 14:11:34 / cg"
-!
-
-asClassPointerRef
-"/ self halt.
-     ^ self
-
-    "Created: / 10.11.1998 / 02:07:01 / cg"
-    "Modified: / 8.1.1999 / 14:11:26 / cg"
 !
 
-deref
-        ^ self
+odsFor:'special'!
 
-    "Created: / 10.11.1998 / 02:08:06 / cg"
+:11:34 / cg"
 !
 
-updateClassRefsFrom:oldClass to:newClass
-    self == oldClass ifTrue:[
-        self makeObsolete.
-        ^ self
-    ].
-
-    constantPool updateClassRefsFrom:oldClass to:newClass.
-    interfaces notNil ifTrue:[
-        interfaces := interfaces collect:[:anInterface |
-                                            anInterface == oldClass ifTrue:[
-                                                newClass isNil ifTrue:[
-                                                    nil "/ replace by an unresolvedInterface
-                                                ] ifFalse:[
-                                                    newClass
-                                                ]
-                                            ] ifFalse:[
-                                                anInterface
-                                            ]
-                                         ]
-    ]
-
-    "Modified: / 4.2.1998 / 22:08:19 / cg"
+ated: / 10.11.1998 / 02:07:01 / cg"
+    "Modified: / 8.1.1999 / 14:11:26 / cg"
 ! !
 
 !JavaClass class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /home/jv/Projects/SmalltalkX/repositories/cvs/stx/libjava/JavaClass.st,v 1.107 1999/11/09 15:43:45 cg Exp $'
+    ^ '$Header: /home/jv/Projects/SmalltalkX/repositories/cvs/stx/libjava/JavaClass.st,v 1.108 1999/11/09 17:00:14 cg Exp $'
 ! !
 JavaClass initialize!