Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-debug-dev] A j2me debug problem

I don't think this is an issue with Java ME, but with the JDWP bridging that most of the toolkits provide. Those bridges do not provide full specification support. I have not seen any type of evaluation in the remote VM work. I guess the question is whether the Netbeans tools are able to coax more information out of the ME VM's.

Darin Wright wrote:
The Java debugger's evaluation support is performed by interpretting an expression and sending JDI commands over the socket to the target VM. We basically parse the expression in to an AST, and then visit the AST to interpret the expression. At various times we need to resolve class objects - for example when referencing a static field, sending a static message, etc. To do this, we look up the class by name. We use the method:

public static Class forName(String name, boolean initialize, ClassLoader loader)

If this method is not in the J2ME libraries, the evaluation will fail (currently). Is there an equivalent method we could use for J2ME?

Darin Wright




"Zhuohui Qiu" <zqiu@xxxxxxx> Sent by: platform-debug-dev-bounces@xxxxxxxxxxx
10/16/2007 05:33 PM
Please respond to
"Eclipse Platform Debug component developers list." <platform-debug-dev@xxxxxxxxxxx>


To
<platform-debug-dev@xxxxxxxxxxx>
cc

Subject
[platform-debug-dev] A j2me debug problem






Hey, Our plug-in is supposed to work with our simulator which is running in j2me. For some reason, Eclipse can not execute expression evaluation properly on the project running on our simulator (we have a debugger running on the simulator and it talks to the eclipse debugger). It seems the reason is eclipse is running in J2SDK environment and our simulator is running in J2ME environment, there is some problem in the communication. I did some debug to find out the reason and have found that eclipse debugger has some problem when it tries to get the IJAvaType of an object, e.g. java.lang.Class. In the Eclipse's implementation of com.sun.jdi.ReferenceType class, eclipse tries to use the methodsByName() method to find the object type; the passed in selector is “forName”, and the signature is “(Ljava/lang/String;ZLjava/lang/ClassLoader;)Ljava/lang/Class;”. The problem is that the signature of “forName” item in the visible methods list of ReferenceTypeImpl of eclipse is “()Ljava/lang/Class;”, thus, eclipse throws an exception that it can not find the class type. It seems that J2ME does not support reflection but exlipse expression evaluator is asking for that information. So, the question could be how does eclipse do expression
evaluation with J2ME?

I tried to install the DSF-SDK and mtj-sdk, but the problem is still
there. Can anyone tell me what I should do? Thanks.

Raymond
--------------------------------------------------------------------- This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful. _______________________________________________
platform-debug-dev mailing list
platform-debug-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/platform-debug-dev


------------------------------------------------------------------------

_______________________________________________
platform-debug-dev mailing list
platform-debug-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/platform-debug-dev


Back to the top