Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-dev] Public interface to access AspectJ AST?

Hi Mik,

thank you very much for this hint, I think this is exactly what we have been looking for. We'll definitely look into that.

Thanks again, best regards,
	Max

Mik Kersten wrote:
For the cases where using the org.aspectj.asm API is not sufficient I have
added an extension point to the AST visitor used by the ASM.  So you get the
whole AST, on a per-file basis (it's discarded after each compilation unit
has been processed).  You don't need to modify any source code, just extend
the AsmHierarchyBuilder using the ExtendedAsmHiearchyBuilder as an example
template.  To run it check out the following directory as a project:

http://dev.eclipse.org/viewcvs/index.cgi/org.aspectj/modules/docs/sandbox/ap
i-clients/?cvsroot=Technology_Project
Note that AsmHierarchyBuilderExtensionTest runs as a JUnit test using an
example system only available if you've checked out org.aspectj.ajde and its
dependencies.  If you're interested in extending the relationships that the
ASM builds you can use the AsmRelationshipMapExtensionTest as an example
template.  In general that ASM's map can be a convenient place to stick
extra relationships that you want to persist across compiles.  But if you're
planning on supporting incremental compilation, which I don't recommend
doing for a research tool, you have to be weary of leaving bogus elements
and relationships in the model.

Mik


-----Original Message-----
From: aspectj-dev-admin@xxxxxxxxxxx [mailto:aspectj-dev-admin@xxxxxxxxxxx]
On Behalf Of Maximilian Stoerzer
Sent: Monday, October 04, 2004 9:51 AM
To: aspectj-dev@xxxxxxxxxxx
Subject: [aspectj-dev] Public interface to access AspectJ AST?

Hi everybody,

for an AspectJ tool project (extending the ajdt Eclipse plugin) we need to
access
the AST for AspectJ. The hierarchy model/ASM unfortunately has not enough
information for our purposes.

What we would like to have is dependencies from advice/pointcuts to
referenced
pointcuts. Is it possible to get this information from the ASM or is there
an
interface where we can get the AST (without modifying the original
aspectj/ajdt code)?

Thanks for any hints!

Best regards,
	Max
--
Maximilian Stoerzer
Lehrstuhl Software Systeme - FMI - University of Passau
Tel: +49 851 509 3096, eMail: stoerzer@xxxxxxxxxxxxxxxxx
_______________________________________________
aspectj-dev mailing list
aspectj-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-dev


_______________________________________________
aspectj-dev mailing list
aspectj-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-dev

--
Maximilian Stoerzer
Lehrstuhl Software Systeme - FMI - University of Passau
Tel: +49 851 509 3096, eMail: stoerzer@xxxxxxxxxxxxxxxxx


Back to the top