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.
I propose to add public static Lookup getLookup(String mimePath) { getLookup(MimePath.parse(mimePath)); } for easier operation with the mime lookup. For example LanguagePath only has mime-path as a string (to not have a direct dependency on mime lookup) so this method would help to have simpler code. Also as the mimePath can in fact be a single mime-type (described in javadoc of the attached patch) this would make the dealing with the mime lookup easier in such case.
Created attachment 36037 [details] Patch (test and apichanges not included)
Fine by me. It's needed in 99% of situations when using ML.
Obsolete milestone, please reevaluate
Oops. It was reviewed a long ago but I forgot to commit it. Fixed. Checking in manifest.mf; /cvs/editor/mimelookup/manifest.mf,v <-- manifest.mf new revision: 1.11; previous revision: 1.10 done Checking in src/org/netbeans/api/editor/mimelookup/MimeLookup.java; /cvs/editor/mimelookup/src/org/netbeans/api/editor/mimelookup/MimeLookup.java,v <-- MimeLookup.java new revision: 1.10; previous revision: 1.9 done Checking in arch/apichanges.xml; /cvs/editor/mimelookup/arch/apichanges.xml,v <-- apichanges.xml new revision: 1.2; previous revision: 1.1