Example usage for org.eclipse.jdt.internal.compiler.lookup FieldBinding sourceField

List of usage examples for org.eclipse.jdt.internal.compiler.lookup FieldBinding sourceField

Introduction

In this page you can find the example usage for org.eclipse.jdt.internal.compiler.lookup FieldBinding sourceField.

Prototype

public FieldDeclaration sourceField() 

Source Link

Usage

From source file:org.eclipse.objectteams.otdt.internal.core.compiler.lookup.SyntheticRoleFieldAccess.java

License:Open Source License

public SyntheticRoleFieldAccess(FieldBinding targetField, boolean isReadAccess,
        SourceTypeBinding declaringClass) {
    super(targetField, isReadAccess, false, declaringClass);
    FieldDeclaration sourceField = targetField.sourceField();
    if (sourceField != null) {
        this.sourceStart = sourceField.sourceStart;
        retrieveLineNumber(declaringClass);
    }//from   www.  ja  v  a 2 s .c om
    this.modifiers &= ~ClassFileConstants.AccStatic;
    this.selector = CharOperation.concatWith(isReadAccess ? FIELD_GET_PREFIX : FIELD_SET_PREFIX,
            new char[][] { targetField.declaringClass.sourceName(), targetField.name }, '$');
}