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 56288 - Register java extension resolver to MIME resolver list
Summary: Register java extension resolver to MIME resolver list
Status: CLOSED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 4.x
Hardware: All All
: P2 blocker (vote)
Assignee: Martin Matula
URL:
Keywords: PERFORMANCE
Depends on:
Blocks: 55701
  Show dependency tree
 
Reported: 2005-03-11 16:05 UTC by Antonin Nebuzelsky
Modified: 2007-09-26 09:14 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 Antonin Nebuzelsky 2005-03-11 16:05:59 UTC
Currently java extension is not registered to directly map to text/x-java MIME
type and therefore MIMEResolverImpl$Type.accept() does not immediately map
MyClass.java against java in the list of extensions and instead goes through
checking various magic strings against the file (opening the java file and
reading its head).

Simple registering of MIME resolver xml with the following contents prevents this:

<MIME-resolver>
    <file>
        <ext name="java"/>
        <resolver mime="text/x-java"/>
    </file>
</MIME-resolver>
Comment 1 Martin Matula 2005-03-14 12:31:33 UTC
Fixed.
Checking in src/org/netbeans/modules/java/Bundle.properties;
/cvs/java/src/org/netbeans/modules/java/Bundle.properties,v  <--  Bundle.properties
new revision: 1.81; previous revision: 1.80
done
Checking in src/org/netbeans/modules/java/resources/mf-layer.xml;
/cvs/java/src/org/netbeans/modules/java/resources/mf-layer.xml,v  <--  mf-layer.xml
new revision: 1.54; previous revision: 1.53
done
RCS file: /cvs/java/src/org/netbeans/modules/java/resources/mime-resolver.xml,v
done
Checking in src/org/netbeans/modules/java/resources/mime-resolver.xml;
/cvs/java/src/org/netbeans/modules/java/resources/mime-resolver.xml,v  <-- 
mime-resolver.xml
initial revision: 1.1
done
Comment 2 Antonin Nebuzelsky 2005-03-23 13:56:42 UTC
OK