String (@NotNull GroovyFile groovyFile) { VirtualFile virtualFile = groovyFile.getVirtualFile(); if (virtualFile == null) return ""; final Module module = ModuleUtilCore.findModuleForPsiElement(groovyFile); if (module == null) { return ""; } final File scriptFile = VfsUtilCore.virtualToIoFile(virtualFile); final String className = CachedValuesManager.getManager(module.getProject()) .getCachedValue(module, GRADLE_CLASS_NAME, new ScriptSourceMapCalculator(module), false) .get(scriptFile); return className == null ? "" : className; }