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 155310 - Make spring code completion as smart as Java cc
Summary: Make spring code completion as smart as Java cc
Status: NEW
Alias: None
Product: javaee
Classification: Unclassified
Component: Spring (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker with 1 vote (vote)
Assignee: Martin Fousek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-12-12 09:53 UTC by masvacaquecarnero
Modified: 2012-12-27 12:52 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description masvacaquecarnero 2008-12-12 09:53:37 UTC
Take the following code as an example of the ill-code completion on spring support. see the | for the place where the cursor ends up
 In java, type:
        Date d = new Date();
        Color c = new Color(1234);
        GregorianCalendar x = new GregorianCalendar();
        x.setTime(|);
then you type x.setTime( and press c-space. The autocompletion pops up and "d" (the right type for the parameter) gets bubbled up to the top of the 
autocompletion list.
 
 <bean id="d" class="java.util.Date"/>
 <bean id="c" class="java.awt.Color"><constructor-arg value="2913"/></bean>
 <bean class="java.util.GregorianCalendar" p:time-ref="|"/>
Now I press c-space to popup autocompletion. There is no bubbling and no magic line showing me what beans have the right type. And the Color object, 
named "c", appears first on the list.
 
Let's look at another testcase:
 <bean class="java.lang.Long" factory-method="toOctalString" id="x">
    <constructor-arg value="1234"/>
 </bean>
 <bean class="java.util.Scanner">
    <constructor-arg ref="|"/>
 </bean>
 
 Autocomplete on "|" with c-space. See how the "x"-named bean. It shows its type is "java.lang.Long" type, even though its really java.lang.String.
 
Obviously, these testcases use standard java classes. But in a reallife spring configuration you often find business classes and objects with complex and 
varied dependencies.
Comment 1 Petr Cyhelsky 2009-11-04 16:25:42 UTC
Seeems to be RFE more than defect