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 15980 - Backward compatibility problem - Kit has not define method getContetntType().
Summary: Backward compatibility problem - Kit has not define method getContetntType().
Status: CLOSED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 3.x
Hardware: PC Linux
: P1 blocker (vote)
Assignee: Martin Roskanin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-09-27 12:52 UTC by Martin Schovanek
Modified: 2007-11-05 13:44 UTC (History)
2 users (show)

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 Martin Schovanek 2001-09-27 12:52:04 UTC
[Linux, NB Build 200109270100, JDK1.3.1]

Steps to reproduce:
-------------------
1) install pilsen_fcs XML, XML-Syntax, (CORBA) modules into NB 3.3
2) expand Tools > Options > Editing > Editor Settings

IDE throws thre Warning dialogs:

"KitClass class org.netbeans.modules.xml.text.syntax.XML(DTD,CSS)Kit has not
define method getContetntType(). It should not be displayed as node in Editor
Settings."

I saw it too in Corba IDL Kit.
Comment 1 Martin Roskanin 2001-09-27 13:17:54 UTC
All subclasses of NbEditorKit have to override and define the method
public String getContentType() 

I have already announced this via nbdev mailing list.
http://www.netbeans.org/servlets/ReadMsg?msgId=144469&listName=nbdev

As I see it is neccessary to fire a bug against appropriate modules.

Thanks,

Mato

Comment 2 Martin Roskanin 2001-09-27 13:46:12 UTC
bug #15982 and bug #15983 have been fired against xml and corba module.
Comment 3 Martin Schovanek 2001-09-27 14:28:02 UTC
Yes, I understand it. But modules written for NetBeans 3.2 (Pilsen)
has to run in NetBeans 3.3. That is reason why I fire this bug.
Comment 4 Martin Roskanin 2001-09-27 15:09:00 UTC
Yes. I apologize. I was too quick.;-)

Comment 5 Martin Schovanek 2001-10-01 16:47:25 UTC
By definition, all such bugs are Beta stoppers.
Comment 6 Jan Lahoda 2001-10-01 19:09:14 UTC
I found in JavaDoc from EditorKit.getContentType():
"Gets the MIME type of the data that this kit represents support for."

I understand this that each EditorKit is *required* to return proper
MIME type string. If it is not, it is a bug.
If I understand right the JavaDoc, I recommend to close this bug.
Comment 7 Jan Lahoda 2001-10-02 08:49:33 UTC
Fix this bug please. The JavaDoc is not so clear and old modules
should work.
Comment 8 Martin Roskanin 2001-10-02 09:17:56 UTC
fixed in [maintrunk]

getContentType has been implementented for
"org.netbeans.modules.properties.syntax.PropertiesKit", "text/x-properties"
"org.netbeans.modules.web.core.syntax.JSPKit", "text/x-jsp"
"org.netbeans.modules.css.text.syntax.CSSEditorKit", "text/css"
"org.netbeans.modules.xml.css.editor.CSSEditorKit", "text/css"
"org.netbeans.modules.xml.text.syntax.DTDKit", "text/x-dtd"
"org.netbeans.modules.xml.text.syntax.XMLKit", "text/xml"
"org.netbeans.modules.corba.idl.editor.coloring.IDLKit", "text/x-idl"

/cvs/editor/src/org/netbeans/modules/editor/NbEditorKit.java,v  <--  NbEditorKit.java
new revision: 1.25; previous revision: 1.24

Comment 9 Martin Roskanin 2001-10-02 09:58:55 UTC
getContentType() implements unknown kitclasses too ...
Comment 10 ehucka 2002-10-15 13:18:26 UTC
Verified in 200210150100
Comment 11 Quality Engineering 2003-06-30 18:09:10 UTC
Resolved for 3.3.x or earlier, no new info since then -> closing.