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.

Bug 122258

Summary: Load annotation type by file name
Product: editor Reporter: Miloslav Metelka <mmetelka>
Component: Hints & AnnotationsAssignee: Milutin Kristofic <mkristofic>
Status: NEW ---    
Severity: blocker Keywords: PERFORMANCE
Priority: P2    
Version: 6.x   
Hardware: PC   
OS: All   
Issue Type: TASK Exception Reporter:

Description Miloslav Metelka 2007-11-19 10:03:38 UTC
Although javadoc of Annotation.getAnnotationType() defines file name of .xml file describing the annotation's data in
reality the result of that method is used to match against content of <name> attribute. This way _all_ the registered
annotations' xml files first get loaded and then the one with the <name> attribute corresponding to the given A.gAT() is
used (see AnnotationTypes and AnnotationTypesFolder). With the present >80 annotaions this affects performance
negatively (it's currently done as a warmup task but still it consumes extra memory etc.)
As the javadoc already says it right it's just necessary to obey the contract and check if all the annotations have
their file name equal to their <name> attribute (they mostly should).
Comment 1 Jiri Prox 2008-04-11 00:43:09 UTC
moving opened issues from TM <= 6.1 to TM=Dev