Bug 224290 - New FileType template contains invalid createEditor method signature.
New FileType template contains invalid createEditor method signature.
Status: RESOLVED FIXED
Product: apisupport
Classification: Unclassified
Component: Templates
7.3
Macintosh (x86) Mac OS X
: P3 (vote)
: 7.3
Assigned To: issues@apisupport
issues@apisupport
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-12-28 20:32 UTC by esmithbss
Modified: 2013-01-04 02:29 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description esmithbss 2012-12-28 20:32:19 UTC
When creating a new FileType object in a module, the generated method signature for "public static MultiViewEditorElement createEditor(Lookup lkp)" contains 2 errors.

First, it references TopComponent.PERSISTENCE_ONLY_OPENED which is not available via the imports.

Second, it uses Lookup which is not available via the imports.

Solution:

Simple import of the TopComponent class will generate a third error regarding the type of values allowed in the annotation so the proper correction is to provide a static import for the TopComponent.PERSISTENCE_ONLY_OPENED value.

A simple import of the Lookup class is sufficient to correct the second problem.
Comment 1 Ondrej Vrabec 2013-01-02 14:54:29 UTC
fix: http://hg.netbeans.org/core-main/rev/fbc6a22c00c6
Comment 2 Quality Engineering 2013-01-04 02:29:14 UTC
Integrated into 'main-golden', will be available in build *201301040001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/fbc6a22c00c6
User: Ondrej Vrabec <ovrabec@netbeans.org>
Log: #224290 - New FileType template contains invalid createEditor method signature.
fixing missing imports in template


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo