Is there a Java or Javascript library that can be used to identify a given text (even partially) if what code syntax the text is. Example, to identify if the text is a Java code, Javascript code, etc.
Doesn't have to be too accurate, as it will be used for user suggestion.