Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 31686 Details for
Bug 120739
LTW Optimization: Disable World if it has No Aspects
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Disable weaving if no aspects are defined.
dontEnableWhenNoAspects.txt (text/plain), 2.04 KB, created by
Ron Bodkin
on 2005-12-13 16:11:42 EST
(
hide
)
Description:
Disable weaving if no aspects are defined.
Filename:
MIME Type:
Creator:
Ron Bodkin
Created:
2005-12-13 16:11:42 EST
Size:
2.04 KB
patch
obsolete
>Index: ClassLoaderWeavingAdaptor.java >=================================================================== >RCS file: /home/technology/org.aspectj/modules/loadtime/src/org/aspectj/weaver/loadtime/ClassLoaderWeavingAdaptor.java,v >retrieving revision 1.35 >diff -u -r1.35 ClassLoaderWeavingAdaptor.java >--- ClassLoaderWeavingAdaptor.java 12 Dec 2005 15:42:19 -0000 1.35 >+++ ClassLoaderWeavingAdaptor.java 13 Dec 2005 21:08:39 -0000 >@@ -121,12 +121,18 @@ > > // register the definitions > registerDefinitions(weaver, loader, definitions); >- messageHandler = bcelWorld.getMessageHandler(); >+ if (enabled) { >+ messageHandler = bcelWorld.getMessageHandler(); > >- //bcelWorld.setResolutionLoader(loader.getParent());//(ClassLoader)null);// >+ //bcelWorld.setResolutionLoader(loader.getParent());//(ClassLoader)null);// > >- // after adding aspects >- weaver.prepareForWeave(); >+ // after adding aspects >+ weaver.prepareForWeave(); >+ } else { >+ // free up unused world & weaver.. >+ bcelWorld = null; >+ weaver = null; >+ } > } > > /** >@@ -315,6 +321,8 @@ > //TODO: the exclude aspect allow to exclude aspect defined upper in the CL hierarchy - is it what we want ?? > // if not, review the getResource so that we track which resource is defined by which CL > >+ enabled = false; // if no aspects are accepted, it is disabled >+ > //iterate aspectClassNames > //exclude if in any of the exclude list > for (Iterator iterator = definitions.iterator(); iterator.hasNext();) { >@@ -323,6 +331,7 @@ > String aspectClassName = (String) aspects.next(); > if (acceptAspect(aspectClassName)) { > info("register aspect " + aspectClassName); >+ enabled = true; // if any aspects are accepted, it is enabled > /*ResolvedType aspect = */weaver.addLibraryAspect(aspectClassName); > > //generate key for SC
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
aclement
:
iplog+
Actions:
View
|
Diff
Attachments on
bug 120739
: 31686