This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Need implementation of Step Into action in j2seproject | ||
---|---|---|---|
Product: | java | Reporter: | Jan Jancura <jjancura> |
Component: | Unsupported | Assignee: | David Konecny <dkonecny> |
Status: | RESOLVED FIXED | ||
Severity: | blocker | CC: | dkonecny, jglick, mgrebac, phrebejk |
Priority: | P1 | Keywords: | API, REGRESSION |
Version: | 4.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | |
Bug Depends on: | |||
Bug Blocks: | 41448, 42851 |
Description
Jan Jancura
2004-05-10 17:30:35 UTC
Provisionally reassigning back to debugger. To answer your main question, no there is no particular way to detect the "type" of any project, and in fact if you are asking the question you are doing something wrong. If you want this kind of functionality, probably you need to define some interface in the debugger which represents what kind of pluggable functionality the project should have, and make sure some impl is in the project lookup for relevant project types. I assume you are talking about invoking Step Into when the debugger is not yet running, right? I.e. that once the debugger is running the debuggerjpda module can take over? Keeping Petr on CC since I have not followed the details of debugger's usage of main-project-sensitive actions so I may be missing something. I do not want to add a new unnecessary compile dependency. Is it possible to add a new Project Type action? Like ActionProvider ("debug-stop", lookup) And a new parameter to JPDAStart ant task? It will be better for me because I need this information inside the ant task implementation. In this case the Project Type can easily specify if it supports Step Into starting debugging. So its issue for Ja2SE project type now... David and/or Petr could you take a look at this? AFAIK Hanz can add this action himself but I am not sure what it would look like in the build script. So, we have agreement (with David) how to do it. I will start. The <nbjpdastart> Ant task will be enhanced with new property (name is illustrative) "stopAtMainMethodOfClass=fully.qualified.class.name". The J2SE project type will set this property when Step.Into action is executed. As for the Web project, Step Into should stop after loading some class. Hanz needs to talk to Web team and make sure that this solution works for them too. They might need something like "stopAfterLoadingClass=..." attribute. OK, sounds reasonable. Maybe <... stopat="fully.qualified.clazz.Name.main" ...> which might be usable for web apps too (if you change the method to be the service method of a servlet or whatever). *** Issue 42851 has been marked as a duplicate of this issue. *** Should be fixed on my side now. My StepInto action calls ActionProvider ("debug-stepInto", lookup). And I have added new parameter "stopClassName" to JPDAStart ANT task. You should implement "debug-stepInto" action and call JPDAStart with "stopClassName" = main class name. I will do that. But first I would like to hear from somebody from Web team that this works also for them and that their project type will just set a special class where to stop and that's it. Hanz could you put somebody from Web team on CC and ask him to confirm that. Thanx. Back to Hanz to get the answer. MGrebas is responsible for JSPDebugger. mgrebac told me offline that it is OK with him. Fixed in: debuggerjpda/ant/antsrc/org/netbeans/modules/debugger/jpda/ant/JPDAStart.java; new revision: 1.20; previous revision: 1.19 debuggerjpda/ant/src/org/netbeans/modules/debugger/projects/StepIntoActionProvider.java; new revision: 1.7; previous revision: 1.6 java/j2seproject/src/org/netbeans/modules/java/j2seproject/J2SEActionProvider.java; new revision: 1.12; previous revision: 1.11 java/j2seproject/src/org/netbeans/modules/java/j2seproject/resources/build-impl.xsl; new revision: 1.10; previous revision: 1.9 projects/projectapi/src/org/netbeans/spi/project/ActionProvider.java; new revision: 1.5; previous revision: 1.4 |