Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] astview for AJDT?

Hi Raffi:

As far as I see, It may be pretty difficult to find a satisfactory AST View Eclipse plugin-in for AJDT. 
But you may write one in a simple way.

Define a new class as wrapper for ASTNode:

public class MyASTNode extends javax.swing.tree.DefaultMutableTreeNode{
    public ASTNode actualNode;
    remember to override the clone() method

Then, add the MyASTNode one by one according to the hierarchy defined in the AST node,
show the AST tree like:

        DefaultMutableTreeNode root = new DefaultMutableTreeNode();
        .....//Add the node
        JTree jt = new JTree(root);
        JFrame frame = new JFrame();
        JScrollPane jsp = new JScrollPane(jt);

That would be OK.

Hope it would be helpful.


>Sai Zhang (saizhang@xxxxxxxxxxx)

On Fri, Mar 21, 2008 at 5:07 AM, Raffi Khatchadourian <khatchad@xxxxxxxxxxxxxxxxxx> wrote:
Apologies for multiple posts ...

Does anyone have any idea if there is an ASTView Eclipse plug-in
( for the AJDT? I find
it an indispensable resource when I'm developing plug-ins for Eclipse on
normal Java.  Anything comparable would also be appreciated. Thanks!
aspectj-users mailing list

Back to the top