Examples of canBeSeenBy()


Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

}
public void generatePostIncrement(BlockScope currentScope, CodeStream codeStream, CompoundAssignment postIncrement, boolean valueRequired) {
  switch (this.bits & RestrictiveFlagMASK) {
    case Binding.FIELD : // assigning to a field
      FieldBinding fieldBinding = (FieldBinding) this.codegenBinding;
      if (fieldBinding.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
        if (fieldBinding.isStatic()) {
          codeStream.getstatic(fieldBinding);
        } else {
          if ((this.bits & DepthMASK) != 0) {
            ReferenceBinding targetType = currentScope.enclosingSourceType().enclosingTypeAt((this.bits & DepthMASK) >> DepthSHIFT);
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding.canBeSeenBy()

      return ArrayBinding.ArrayLength;
    return null;
  }

  ReferenceBinding currentType = (ReferenceBinding) receiverType;
  if (!currentType.canBeSeenBy(this))
    return new ProblemFieldBinding(currentType, fieldName, ProblemReasons.ReceiverTypeNotVisible);

  FieldBinding field = currentType.getField(fieldName, true /*resolve*/);
  if (field != null) {
    if (canBeSeenByForCodeSnippet(field, currentType, invocationSite, this))
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding.canBeSeenBy()

          // from 1.5 compliant mode on, array#clone() resolves to array type, but codegen to #clone()Object - thus require extra inserted cast
      this.valueCast = runtimeTimeType;     
    }
        if (this.valueCast instanceof ReferenceBinding) {
      ReferenceBinding referenceCast = (ReferenceBinding) this.valueCast;
      if (!referenceCast.canBeSeenBy(scope)) {
            scope.problemReporter().invalidType(this,
                new ProblemReferenceBinding(
              CharOperation.splitOn('.', referenceCast.shortReadableName()),
              referenceCast,
              ProblemReasons.NotVisible));
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.compiler.lookup.ReferenceBinding.canBeSeenBy()

          : runtimeTimeType;
        TypeBinding typeCast = originalType.genericCast(targetType);
        setGenericCast(length, typeCast);
          if (typeCast instanceof ReferenceBinding) {
        ReferenceBinding referenceCast = (ReferenceBinding) typeCast;
        if (!referenceCast.canBeSeenBy(scope)) {
              scope.problemReporter().invalidType(this,
                  new ProblemReferenceBinding(
                CharOperation.splitOn('.', referenceCast.shortReadableName()),
                referenceCast,
                ProblemReasons.NotVisible));
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

      if (field.isSynthetic()) continue next;

      if (onlyStaticFields && !field.isStatic()) continue next;

      if (!field.canBeSeenBy(receiverType, invocationSite, scope)) continue next;

      for (int i = fieldsFound.size; --i >= 0;) {
        FieldBinding otherField = (FieldBinding) fieldsFound.elementAt(i);
        if (CharOperation.equals(field.name, otherField.name, true)) {
          continue next;
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

    }
  }
  switch (this.bits & RestrictiveFlagMASK) {
    case Binding.FIELD : // assigning to a field
      FieldBinding codegenField = ((FieldBinding) this.binding).original();
      if (codegenField.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
        if (!codegenField.isStatic()) { // need a receiver?
          if ((this.bits & DepthMASK) != 0) {
            ReferenceBinding targetType = currentScope.enclosingSourceType().enclosingTypeAt((this.bits & DepthMASK) >> DepthSHIFT);
            Object[] emulationPath = currentScope.getEmulationPath(targetType, true /*only exact match*/, false/*consider enclosing arg*/);
            codeStream.generateOuterAccess(emulationPath, this, targetType, currentScope);
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

        if (!valueRequired)
          break;
        FieldBinding codegenField = ((FieldBinding) this.binding).original();
        Constant fieldConstant = codegenField.constant();
        if (fieldConstant == Constant.NotAConstant) { // directly use inlined value for constant fields
          if (codegenField.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
            TypeBinding someReceiverType = this.delegateThis != null ? this.delegateThis.type : this.actualReceiverType;
            TypeBinding constantPoolDeclaringClass = CodeStream.getConstantPoolDeclaringClass(currentScope, codegenField, someReceiverType, true /* implicit this */);
            if (codegenField.isStatic()) {
              codeStream.fieldAccess(Opcodes.OPC_getstatic, codegenField, constantPoolDeclaringClass);
            } else {
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

public void generateCompoundAssignment(BlockScope currentScope, CodeStream codeStream, MethodBinding writeAccessor, Expression expression, int operator, int assignmentImplicitConversion, boolean valueRequired) {
  switch (this.bits & RestrictiveFlagMASK) {
    case Binding.FIELD : // assigning to a field
      FieldBinding codegenField = ((FieldBinding) this.binding).original();
      if (codegenField.isStatic()) {
        if (codegenField.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
          TypeBinding someReceiverType = this.delegateThis != null ? this.delegateThis.type : this.actualReceiverType;
          TypeBinding constantPoolDeclaringClass = CodeStream.getConstantPoolDeclaringClass(currentScope, codegenField, someReceiverType, true /* implicit this */);
          codeStream.fieldAccess(Opcodes.OPC_getstatic, codegenField, constantPoolDeclaringClass);
        } else {
          // used to store the value
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

          // used to retrieve the actual value
          codeStream.aconst_null();
          codeStream.generateEmulatedReadAccessForField(codegenField);
        }
      } else {
        if (codegenField.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
          if ((this.bits & DepthMASK) != 0) {
            ReferenceBinding targetType = currentScope.enclosingSourceType().enclosingTypeAt((this.bits & DepthMASK) >> DepthSHIFT);
            Object[] emulationPath = currentScope.getEmulationPath(targetType, true /*only exact match*/, false/*consider enclosing arg*/);
            codeStream.generateOuterAccess(emulationPath, this, targetType, currentScope);
          } else {
View Full Code Here

Examples of org.eclipse.jdt.internal.compiler.lookup.FieldBinding.canBeSeenBy()

  }
  // store the result back into the variable
  switch (this.bits & RestrictiveFlagMASK) {
    case Binding.FIELD : // assigning to a field
      FieldBinding codegenField = ((FieldBinding) this.binding).original();
      if (codegenField.canBeSeenBy(getReceiverType(currentScope), this, currentScope)) {
        fieldStore(currentScope, codeStream, codegenField, writeAccessor, this.actualReceiverType, this.delegateThis == null /* implicit this */, valueRequired);
      } else {
        // current stack is:
        // field receiver value
        if (valueRequired) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.