Search in sources :

Example 16 with Annotation

use of org.eclipse.n4js.n4JS.Annotation in project n4js by eclipse.

the class ScriptImpl method getAllAnnotations.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public EList<Annotation> getAllAnnotations() {
    final BasicEList<Annotation> result = XcoreCollectionLiterals.<Annotation>newBasicEList();
    final EObject parent = this.eContainer();
    if ((parent instanceof ExportDeclaration)) {
        EList<Annotation> _annotations = ((ExportDeclaration) parent).getAnnotations();
        Iterables.<Annotation>addAll(result, _annotations);
    }
    EList<Annotation> _annotations_1 = this.getAnnotations();
    Iterables.<Annotation>addAll(result, _annotations_1);
    return result;
}
Also used : EObject(org.eclipse.emf.ecore.EObject) InternalEObject(org.eclipse.emf.ecore.InternalEObject) ExportDeclaration(org.eclipse.n4js.n4JS.ExportDeclaration) Annotation(org.eclipse.n4js.n4JS.Annotation)

Example 17 with Annotation

use of org.eclipse.n4js.n4JS.Annotation in project n4js by eclipse.

the class PropertyGetterDeclarationImpl method getAnnotations.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public EList<Annotation> getAnnotations() {
    EList<Annotation> _elvis = null;
    PropertyAssignmentAnnotationList _annotationList = this.getAnnotationList();
    EList<Annotation> _annotations = null;
    if (_annotationList != null) {
        _annotations = _annotationList.getAnnotations();
    }
    if (_annotations != null) {
        _elvis = _annotations;
    } else {
        EList<Annotation> _emptyEList = XcoreCollectionLiterals.<Annotation>emptyEList();
        _elvis = _emptyEList;
    }
    return _elvis;
}
Also used : PropertyAssignmentAnnotationList(org.eclipse.n4js.n4JS.PropertyAssignmentAnnotationList) Annotation(org.eclipse.n4js.n4JS.Annotation)

Example 18 with Annotation

use of org.eclipse.n4js.n4JS.Annotation in project n4js by eclipse.

the class AnnotableElementImpl method getAllAnnotations.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public EList<Annotation> getAllAnnotations() {
    final BasicEList<Annotation> result = XcoreCollectionLiterals.<Annotation>newBasicEList();
    final EObject parent = this.eContainer();
    if ((parent instanceof ExportDeclaration)) {
        EList<Annotation> _annotations = ((ExportDeclaration) parent).getAnnotations();
        Iterables.<Annotation>addAll(result, _annotations);
    }
    EList<Annotation> _annotations_1 = this.getAnnotations();
    Iterables.<Annotation>addAll(result, _annotations_1);
    return result;
}
Also used : EObject(org.eclipse.emf.ecore.EObject) ExportDeclaration(org.eclipse.n4js.n4JS.ExportDeclaration) Annotation(org.eclipse.n4js.n4JS.Annotation)

Example 19 with Annotation

use of org.eclipse.n4js.n4JS.Annotation in project n4js by eclipse.

the class AnnotableN4MemberDeclarationImpl method getAnnotations.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public EList<Annotation> getAnnotations() {
    EList<Annotation> _elvis = null;
    N4MemberAnnotationList _annotationList = this.getAnnotationList();
    EList<Annotation> _annotations = null;
    if (_annotationList != null) {
        _annotations = _annotationList.getAnnotations();
    }
    if (_annotations != null) {
        _elvis = _annotations;
    } else {
        EList<Annotation> _emptyEList = XcoreCollectionLiterals.<Annotation>emptyEList();
        _elvis = _emptyEList;
    }
    return _elvis;
}
Also used : N4MemberAnnotationList(org.eclipse.n4js.n4JS.N4MemberAnnotationList) Annotation(org.eclipse.n4js.n4JS.Annotation)

Example 20 with Annotation

use of org.eclipse.n4js.n4JS.Annotation in project n4js by eclipse.

the class AnnotablePropertyAssignmentImpl method getAnnotations.

/**
 * <!-- begin-user-doc -->
 * <!-- end-user-doc -->
 * @generated
 */
public EList<Annotation> getAnnotations() {
    EList<Annotation> _elvis = null;
    PropertyAssignmentAnnotationList _annotationList = this.getAnnotationList();
    EList<Annotation> _annotations = null;
    if (_annotationList != null) {
        _annotations = _annotationList.getAnnotations();
    }
    if (_annotations != null) {
        _elvis = _annotations;
    } else {
        EList<Annotation> _emptyEList = XcoreCollectionLiterals.<Annotation>emptyEList();
        _elvis = _emptyEList;
    }
    return _elvis;
}
Also used : PropertyAssignmentAnnotationList(org.eclipse.n4js.n4JS.PropertyAssignmentAnnotationList) Annotation(org.eclipse.n4js.n4JS.Annotation)

Aggregations

Annotation (org.eclipse.n4js.n4JS.Annotation)21 EObject (org.eclipse.emf.ecore.EObject)7 ExportDeclaration (org.eclipse.n4js.n4JS.ExportDeclaration)7 InternalEObject (org.eclipse.emf.ecore.InternalEObject)5 AnnotationList (org.eclipse.n4js.n4JS.AnnotationList)5 N4MemberAnnotationList (org.eclipse.n4js.n4JS.N4MemberAnnotationList)4 PropertyAssignmentAnnotationList (org.eclipse.n4js.n4JS.PropertyAssignmentAnnotationList)4 ExpressionAnnotationList (org.eclipse.n4js.n4JS.ExpressionAnnotationList)3 N4FieldDeclaration (org.eclipse.n4js.n4JS.N4FieldDeclaration)2 VariableDeclaration (org.eclipse.n4js.n4JS.VariableDeclaration)2 EPackage (org.eclipse.emf.ecore.EPackage)1 AdditiveExpression (org.eclipse.n4js.n4JS.AdditiveExpression)1 Argument (org.eclipse.n4js.n4JS.Argument)1 ArrayBindingPattern (org.eclipse.n4js.n4JS.ArrayBindingPattern)1 ArrayElement (org.eclipse.n4js.n4JS.ArrayElement)1 ArrayLiteral (org.eclipse.n4js.n4JS.ArrayLiteral)1 ArrayPadding (org.eclipse.n4js.n4JS.ArrayPadding)1 ArrowFunction (org.eclipse.n4js.n4JS.ArrowFunction)1 AssignmentExpression (org.eclipse.n4js.n4JS.AssignmentExpression)1 AwaitExpression (org.eclipse.n4js.n4JS.AwaitExpression)1