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 201809 - no autocompletition for c:forEach
Summary: no autocompletition for c:forEach
Status: RESOLVED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: Expression Language (show other bugs)
Version: 7.1
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: Marek Fukala
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-08 11:40 UTC by muellermi
Modified: 2012-06-09 04:36 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description muellermi 2011-09-08 11:40:08 UTC
Product Version = NetBeans IDE Dev (Build 201109060600)
Operating System = Windows XP version 5.1 running on x86
Java; VM; Vendor = 1.7.0
Runtime = Java HotSpot(TM) Client VM 21.0-b17

Let's assume your writing a loop within a facelets page. You keyed in the first line and after the ">" Netbeans inserts the closing tag automatically. Next you type "#{}"
<ui:repeat value="#{editUserMaintenance.topics}" var="topic">
       #{}  <----- this is your last input
</ui:repeat>

At this point autocomplete opens and offers you "topic". And if you've choosen topic you'll see the methods etc. Everythings is quite fine.

No delete the lines above and use forEach to build up the loop.

<c:forEach items="#{editUserMaintenance.topics}" var="topic">
       #{}  <----- this is your last input
</c:forEach>

NB offers no automatic autocompletion. Nor at this point, neither after inserting "topic." manually. After pressing {Ctrl}{Space} it offers the wrong content for autocompletion.
And due to a JSF design problem, forEach is the more important loop statement. (see http://blog.mueller-bruehl.de/en/programming/jsf-insert-a-variable-count-od-files/. Switch to German version for an explanating comment)
Comment 1 PetrPodzimek 2012-06-08 12:30:50 UTC
web-main: 7ea83b8b5214

Changed Code Completion "iterable" tags in IceFaces, JSF, PrimeFaces and RichFaces support modules.
Comment 2 Quality Engineering 2012-06-09 04:36:10 UTC
Integrated into 'main-golden', will be available in build *201206090001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/76e9b88afd71
User: Petr Podzimek<petrpodzimek@netbeans.org>
Log: #201809 - no autocompletition for c:forEach