public final class LanguageUtil
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.util.Comparator<Language> |
LANGUAGE_COMPARATOR |
Modifier and Type | Method and Description |
---|---|
static ParserDefinition.SpaceRequirements |
canStickTokensTogetherByLexer(ASTNode left,
ASTNode right,
Lexer lexer) |
static java.util.Set<Language> |
getAllDerivedLanguages(Language base) |
static Language |
getFileLanguage(VirtualFile file) |
static java.util.List<Language> |
getFileLanguages() |
static Language |
getFileTypeLanguage(FileType fileType) |
static FileType |
getLanguageFileType(Language language) |
static Language |
getLanguageForPsi(Project project,
VirtualFile file) |
static Language |
getRootLanguage(PsiElement element) |
static boolean |
isFileLanguage(Language language) |
static boolean |
isInjectableLanguage(Language language) |
static boolean |
isInTemplateLanguageFile(PsiElement element) |
public static final java.util.Comparator<Language> LANGUAGE_COMPARATOR
public static Language getLanguageForPsi(Project project, VirtualFile file)
public static Language getFileLanguage(VirtualFile file)
public static ParserDefinition.SpaceRequirements canStickTokensTogetherByLexer(ASTNode left, ASTNode right, Lexer lexer)
public static boolean isInTemplateLanguageFile(PsiElement element)
public static boolean isInjectableLanguage(Language language)
public static boolean isFileLanguage(Language language)
public static java.util.List<Language> getFileLanguages()
public static Language getRootLanguage(PsiElement element)