jlahoda commented on pull request #3594:
URL: https://github.com/apache/netbeans/pull/3594#issuecomment-1047464076


   Without working MimeLookup, filesystems, etc., the LanguageManager needs a 
different implementation of LanguageProvider. What I had in mind is something 
along the lines of (untested):
   ```
   @ServiceProvider(service=LanguageProvider.class)
   public class LanguageProviderImpl extends LanguageProvider {
   
       @Override
       public Language<?> findLanguage(String mimeType) {
           switch (mimeType) {
               case "text/x-java": return JavaTokenId.language();
           }
           return null;
       }
   
       @Override
       public LanguageEmbedding<?> findLanguageEmbedding(Token<?> token, 
LanguagePath languagePath, InputAttributes inputAttributes) {
           return null;
       }
   
   }
   ```
   
   In case of PartialReparseTest, it is probably "just" a matter of formatting 
changing the code so that existing positions (in the test) no longer work. You 
may be able to use Positions, to keep track of the changes.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to