/** * Returns the {@link FileObject} represented by this {@link CompilationInfo}. * @return FileObject */ public @NullUnknown FileObject getFileObject() { checkConfinement(); return impl.getFileObject(); }
/**Return {@link PositionConverter} binding virtual Java source and the real source. * Please note that this method is needed only for clients that need to work * in non-Java files (e.g. JSP files) or in dialogs, like code completion. * Most clients do not need to use {@link PositionConverter}. * * @return PositionConverter binding the virtual Java source and the real source. * @since 0.21 * @deprecated as of 0.42, this is superseded by Parsing API. */ @Deprecated public PositionConverter getPositionConverter() { checkConfinement(); if (this.impl.getFileObject() == null) { throw new IllegalStateException (); } return new PositionConverter(impl.getSnapshot()); }
FileObject file = info.getFileObject(); String fileName = FileUtil.getFileDisplayName(file); String origName = file.getName();
if (this.impl.getFileObject() == null) { throw new IllegalStateException (); assert elements != null; assert this.impl.getRoot() != null; String name = FileObjects.convertFolder2Package(FileObjects.stripExtension(FileUtil.getRelativePath(this.impl.getRoot(), this.impl.getFileObject()))); TypeElement e = ((JavacElements)elements).getTypeElementByBinaryName(name); if (e != null) {
FileObject currentFile = currentInfo.getFileObject(); TIME_LOGGER.log(Level.FINE, "Compilation Unit", new Object[] {currentFile, unit}); currentPhase = Phase.ELEMENTS_RESOLVED; long end = System.currentTimeMillis(); logTime(currentInfo.getFileObject(),currentPhase,(end-start)); currentPhase = Phase.RESOLVED; long end = System.currentTimeMillis (); logTime(currentInfo.getFileObject(),currentPhase,(end-start));
final String newBody) throws IOException { assert ci != null; final FileObject fo = ci.getFileObject(); if (LOGGER.isLoggable(Level.FINER)) { LOGGER.log(Level.FINER, "Reparse method in: {0}", fo); //NOI18N