Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Unsupported Content Type for package-info.java
Unsupported Content Type for package-info.java [message #536987] Mon, 31 May 2010 19:31 Go to next message
Reinhardt Christiansen is currently offline Reinhardt ChristiansenFriend
Messages: 73
Registered: March 2010
Member
I've recently made the decision to start using package-info.java files in
place of the older package.html files to document my packages in Javadoc.
Unfortunately, Eclipse is giving me a rather cryptic message when I try to
edit one of these package-info files and I'm not sure how to handle it.

If I click on a package-info.java file, the file contents display correctly
in the edit window but there is a message: "Unsupported Content Type -
Unsupported content type in editor. To associate file extension with a
supported content type, please see Content Types Preference Page." (There is
also a "Do not show this message again" checkbox, which I've left
unchecked.).
When I click on the Content Types Preference Page link, a preferences page
comes up where I am presumably supposed to do something to keep the message
from appearing.

I have no earthly idea what I should be doing on the Preferences page. I'm
guessing the message is happening because package-info is not a valid name
for a Java source file. Since this is the recommended name in the Javadoc
documentation, I would have thought the Eclipse developers would have made
whatever internal changes were necessary so that this message does not come
up and not made this the responsibility of the Eclipse user community. Then
again, maybe I'm misunderstanding the situation!

Nevertheless, I would appreciate some information on exactly what I need to
do to make this message go away. I'd prefer NOT to check the "don't show
this again" checkbox: I would rather do whatever it takes to satisfy
Eclipse's internal logic that everything is set up the way it should be.

Hmm, I just did a bug search and found 86168 (which is fully 5 years old and
STILL not resolved!). I found that if I try to create a _TEXT_ file named
package-info.java, it lets me do so. It also lets me edit the file and
reopen it WITHOUT the "unsupported content type" message.

It looks like I've found my workaround. Now, if only the developers can fix
the underlying issue from bug 86168....

By the way, if there is a way to make the unsupported content type message
go away for package-info.java files created with the New Class wizard, I
would love to know what it is.
--
Rhino
Re: Unsupported Content Type for package-info.java [message #539899 is a reply to message #536987] Mon, 14 June 2010 08:56 Go to previous message
Dani Megert is currently offline Dani MegertFriend
Messages: 3802
Registered: July 2009
Senior Member
Rhino wrote:
> I've recently made the decision to start using package-info.java files in
> place of the older package.html files to document my packages in Javadoc.
> Unfortunately, Eclipse is giving me a rather cryptic message when I try to
> edit one of these package-info files and I'm not sure how to handle it.
>
Something must be wrong with your install. Using latest 3.6 RC
( http://download.eclipse.org/eclipse/downloads/drops/I2010060 8-0911/index.php).I
can create package-info.java files via File > New > File without
problems and the editor opens up as expected. Maybe you installed a
plug-in that defines an invalid content type for that file?

Dani
> If I click on a package-info.java file, the file contents display correctly
> in the edit window but there is a message: "Unsupported Content Type -
> Unsupported content type in editor. To associate file extension with a
> supported content type, please see Content Types Preference Page." (There is
> also a "Do not show this message again" checkbox, which I've left
> unchecked.).
> When I click on the Content Types Preference Page link, a preferences page
> comes up where I am presumably supposed to do something to keep the message
> from appearing.
>
> I have no earthly idea what I should be doing on the Preferences page. I'm
> guessing the message is happening because package-info is not a valid name
> for a Java source file. Since this is the recommended name in the Javadoc
> documentation, I would have thought the Eclipse developers would have made
> whatever internal changes were necessary so that this message does not come
> up and not made this the responsibility of the Eclipse user community. Then
> again, maybe I'm misunderstanding the situation!
>
> Nevertheless, I would appreciate some information on exactly what I need to
> do to make this message go away. I'd prefer NOT to check the "don't show
> this again" checkbox: I would rather do whatever it takes to satisfy
> Eclipse's internal logic that everything is set up the way it should be.
>
> Hmm, I just did a bug search and found 86168 (which is fully 5 years old and
> STILL not resolved!). I found that if I try to create a _TEXT_ file named
> package-info.java, it lets me do so. It also lets me edit the file and
> reopen it WITHOUT the "unsupported content type" message.
>
> It looks like I've found my workaround. Now, if only the developers can fix
> the underlying issue from bug 86168....
>
> By the way, if there is a way to make the unsupported content type message
> go away for package-info.java files created with the New Class wizard, I
> would love to know what it is.
> --
> Rhino
>
>
>
Previous Topic:how do i set an orientation specifically to views and editors?
Next Topic:SourceViewer.setEditable() or disabled EditorParts
Goto Forum:
  


Current Time: Fri Apr 26 13:22:57 GMT 2024

Powered by FUDForum. Page generated in 0.02753 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top