private List<Fix> createQualifierFix( CompilationInfo compilationInfo, Element annotation, Element classElement ) { PackageElement packageElement = compilationInfo.getElements() .getPackageOf(classElement); FileObject targetFile = SourceUtils.getFile( ElementHandle.create(classElement), compilationInfo.getClasspathInfo()); return Collections.<Fix> singletonList(new CreateQualifierFix( compilationInfo, annotation.getSimpleName().toString(), packageElement.getQualifiedName().toString(), targetFile)); }
private List<Fix> createInterceptorFix( CompilationInfo compilationInfo, Element annotation, Element classElement ) { PackageElement packageElement = compilationInfo.getElements() .getPackageOf(classElement); FileObject targetFile = SourceUtils.getFile( ElementHandle.create(classElement), compilationInfo.getClasspathInfo()); return Collections.<Fix> singletonList(new CreateInterceptorBinding( compilationInfo, annotation.getSimpleName().toString(), packageElement.getQualifiedName().toString(), targetFile)); }
LinkedList<DeclaredType> bases = new LinkedList<DeclaredType>(); bases.add(baseType); ClassIndex index = info.getClasspathInfo().getClassIndex(); Trees trees = info.getTrees(); Types types = info.getTypes();
InjectableTreeNode(FileObject fileObject, T element, DeclaredType parentType, boolean disabled , CompilationInfo compilationInfo) { myFileObject = fileObject; myElementHandle = ElementHandle.create(element); myElementKind = element.getKind(); myModifiers = element.getModifiers(); myCpInfo = compilationInfo.getClasspathInfo(); isDisabled = disabled; setName(element.getSimpleName().toString()); setIcon(ElementIcons.getElementIcon(element.getKind(), element.getModifiers())); setLabel(Utils.format(element, parentType, compilationInfo)); setFQNLabel(Utils.format(element, parentType, compilationInfo , false, true)); setToolTip(Utils.format(element, parentType, compilationInfo, true, WebBeansNavigationOptions.isShowFQN())); }
public void run(final Result result, final SchedulerEvent event) { final CompilationInfo info = CompilationInfo.get(result); final ClasspathInfo cpInfo = info.getClasspathInfo(); if (cpInfo != null) { final ClassPath src = cpInfo.getClassPath(PathKind.SOURCE);
ClassPath cp = info.getClasspathInfo().getClassPath(ClasspathInfo.PathKind.SOURCE); FileObject fileObject = info.getFileObject(); if(!fileObject.isValid()) { //File is probably deleted
ClassPath cp = info.getClasspathInfo().getClassPath(ClasspathInfo.PathKind.SOURCE); FileObject fileObject = info.getFileObject(); if(!fileObject.isValid()) { //File is probably deleted
return new TreePathHandle(new ElementDelegate(ElementHandle.create(element), u, qualName, info.getClasspathInfo()));
FileObject target; FileObject root = myInfo.getClasspathInfo() .getClassPath(PathKind.SOURCE) .findOwnerRoot(myInfo.getFileObject());