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 129112 - Missing optional attributes for code completion in XSD editor
Summary: Missing optional attributes for code completion in XSD editor
Status: RESOLVED WONTFIX
Alias: None
Product: xml
Classification: Unclassified
Component: Schema Tools (show other bugs)
Version: 8.0
Hardware: All All
: P3 blocker with 3 votes (vote)
Assignee: Svata Dedic
URL:
Keywords:
: 138863 (view as bug list)
Depends on:
Blocks: 138486
  Show dependency tree
 
Reported: 2008-03-04 11:40 UTC by lpolycarpou
Modified: 2016-07-07 09:56 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
XSD missing code completion suggestions in places (85.72 KB, image/jpeg)
2008-03-04 11:54 UTC, lpolycarpou
Details
example of topLevelElement attributes (274.04 KB, image/png)
2011-11-23 09:34 UTC, kosmos-mgtu
Details
example of localElement attributes (287.63 KB, image/png)
2011-11-23 09:35 UTC, kosmos-mgtu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description lpolycarpou 2008-03-04 11:40:44 UTC
When using the autocomplete feature (ALT+SPACE) within the source view of the XML Schema Editor, some optional
attributes do not appear for the Sequence field.  Autocomplete under Sequence should include minOccurs and maxOccurs. 
See screenshot for further clarification.

Please check that all optional attributes are available for autocompletion in the XML Schema Editor.
Comment 1 lpolycarpou 2008-03-04 11:54:38 UTC
Created attachment 57717 [details]
XSD missing code completion suggestions in places
Comment 2 Samaresh Panda 2008-06-26 15:18:08 UTC
I'll try to fix this for 6.5.
Comment 3 Samaresh Panda 2008-06-26 15:35:19 UTC
Briefly looking into the meta schema reveals that element inside a sequence is of type "localElement" and has only four
attributes which are currently being offered. OTOH, attributes such as name, min/maxOccurs should also appear, but not
based on the model from meta-schema. So I guess, there is something more to the spec that our model is not aware of.

Will look into it.
Comment 4 Samaresh Panda 2008-07-02 21:43:39 UTC
*** Issue 138863 has been marked as a duplicate of this issue. ***
Comment 5 Samaresh Panda 2008-11-18 17:47:30 UTC
Will look into it again...
Comment 6 kosmos-mgtu 2011-11-23 09:32:53 UTC
It seems like the problem with complex types inheritance via restriction mechanism and prohibited attributes. For example, there are complex types 
1. element - abstract with attributes 
   a) type 
   b) abstract
   c) minOccurs
   etc.
2. topLevelElement - restriction of element, which prohibits usage of attribute "minOccurs" and some other
3. localElement - restriction of element, which prohibits usage of attribute "abstract" and some other

But in attached screenshoots you can see that code assistant suggests only prohibited attributes instead of inherited attributes excluding prohibited.

So on we can make conclusion that there are problems with inheritance and "use" option of attributes

---------------------

Working environment:
Ubuntu 10.04
NetBeans 7.0.1
java version "1.6.0_20"
OpenJDK Runtime Environment (IcedTea6 1.9.10) (6b20-1.9.10-0ubuntu1~10.04.2)
OpenJDK Server VM (build 19.0-b09, mixed mode)
Comment 7 kosmos-mgtu 2011-11-23 09:34:35 UTC
Created attachment 113450 [details]
example of topLevelElement attributes
Comment 8 kosmos-mgtu 2011-11-23 09:35:16 UTC
Created attachment 113451 [details]
example of localElement attributes
Comment 9 Martin Balin 2016-07-07 09:56:15 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss