swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

problem with ProbeMap and java and subclass?


From: Steve Brophy
Subject: problem with ProbeMap and java and subclass?
Date: Thu, 13 Apr 2000 16:19:13 -0400

I'm getting an error trying to use "getCompleteVarMapFor" with a java class
extended from a java class which is extended from SwarmObjectImpl.  I can
get it working for the direct subclass of SwarmObjectImpl, or can use the
extended hierarchy successfully with Objective C.  Does it look like a
problem here, or have I missed something in testing?  Example code below,
this is on an NT 4.0 system with Swarm 2.1.1.

Example code:
----------------------

import swarm.Globals;
import swarm.objectbase.ProbeMap;
import swarm.objectbase.SwarmObjectImpl

class T4Base extends SwarmObjectImpl {
    public int myibase;
}

class T4Sub extends T4Base {
    public int myisub;
}

public class Tst4 {
    public static void main(String[] args) {
        Globals.env.initSwarm("tst4", "00", "address@hidden", args);
        ProbeMap pmap =
            Globals.env.probeLibrary.getCompleteVarMapFor(T4Sub.class);
        System.out.println("Got it.");
    };
}


I get the same runtime error whether using the javaswarm or the jdkswarm
commands:
----------------------
*** event raised for error: SourceMessage
*** function: _i_VarProbe__createEnd(), file:
/src/Swarm/swarm/src/objectbase/VarProbe.m, line: 76
Cannot find field to be probed in the Java class.
*** execution terminating due to error
/src/Swarm/swarm/src/defobj/Symbol.m:173 -[Error(c) _raiseEvent:]
     0 [sig] Kaffe 1789 stackdump: Dumping stack trace to
Kaffe.exe.stackdump

thanks,
Steve

Steve Brophy,  address@hidden
ERIM, Ann Arbor MI


                  ==================================
   Swarm-Support is for discussion of the technical details of the day
   to day usage of Swarm.  For list administration needs (esp.
   [un]subscribing), please send a message to <address@hidden>
   with "help" in the body of the message.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]