public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
@Override public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
public void consumeAnnotation() { if (!(this.element instanceof IAnnotatable)) return; int size = this.types.size(); if (size == 0) return; IJavaElement annotationType = ((JavaElementFinder) this.types.get(size-1)).element; this.element = ((IAnnotatable) this.element).getAnnotation(annotationType.getElementName()); }
protected IAnnotation transplantHandle(IAnnotatable parent, IAnnotation element) { return parent.getAnnotation(element.getElementName()); }
protected IAnnotation transplantHandle(IAnnotatable parent, IAnnotation element) { return parent.getAnnotation(element.getElementName()); }
protected IAnnotation transplantHandle(IAnnotatable parent, IAnnotation element) { return parent.getAnnotation(element.getElementName()); }
private static IAnnotation getAnnotation(IAnnotatable element, String name, String startSimple, String startFq) { String annotSource = null; IAnnotation annotation = element.getAnnotation(name); if (!exists(annotation)) { return null; } try { annotSource = annotation.getSource(); if (annotSource != null) { annotSource = annotSource.trim(); } } catch (Exception e) { SdkLog.warning("Could not get source of annotation '{}' in element '{}'.", name, element, e); } if (annotSource == null || annotSource.startsWith(startSimple) || annotSource.startsWith(startFq)) { return annotation; } else if (element instanceof IMember) { annotSource = getAnnotationSourceFixed((IMember) element, annotation, startSimple); if (annotSource != null && (annotSource.startsWith(startSimple) || annotSource.startsWith(startFq))) { return annotation; } } return null; }
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());
return ((IAnnotatable) parentElement).getAnnotation(getAnnotationType().getQualifiedName()); return ((IAnnotatable) parentElement).getAnnotation(getName());