PsiFile (@NotNull Language target) { PsiFileImpl file = myRoots.get(target); if (file == null) { if (!shouldCreatePsi()) return null; if (target != getBaseLanguage() && !getLanguages().contains(target)) { return null; } file = createPsiFileImpl(target); if (file == null) return null; if (myOriginal != null) { PsiFile originalFile = myOriginal.getPsi(target); if (originalFile != null) { file.setOriginalFile(originalFile); } } file = ConcurrencyUtil.cacheOrGet(myRoots, target, file); } return file; }