@Override public boolean equals(Object other) { if (other instanceof ResolvedType) { return this == other; } else { return super.equals(other); } }
private boolean equal2(UnresolvedType[] typeParameters, UnresolvedType[] resolvedParameters) { if (typeParameters.length != resolvedParameters.length) { return false; } int len = typeParameters.length; for (int p = 0; p < len; p++) { if (!typeParameters[p].equals(resolvedParameters[p])) { return false; } } return true; }
private boolean equal(UnresolvedType[] typeParameters, ResolvedType[] resolvedParameters) { if (typeParameters.length != resolvedParameters.length) { return false; } int len = typeParameters.length; for (int p = 0; p < len; p++) { if (!typeParameters[p].equals(resolvedParameters[p])) { return false; } } return true; }
public boolean equals(Object other) { if (!(other instanceof BindingTypePattern)) { return false; } BindingTypePattern o = (BindingTypePattern) other; if (includeSubtypes != o.includeSubtypes) { return false; } if (isVarArgs != o.isVarArgs) { return false; } return o.type.equals(this.type) && o.formalIndex == this.formalIndex; }
private static boolean equalTypes(UnresolvedType[] a, UnresolvedType[] b) { int len = a.length; if (len != b.length) { return false; } for (int i = 0; i < len; i++) { if (!a[i].equals(b[i])) { return false; } } return true; }
public boolean equals(Object other) { if (other instanceof Instanceof) { Instanceof o = (Instanceof) other; return o.var.equals(var) && o.type.equals(type); } else { return false; } }
public boolean equals(Object other) { if (!(other instanceof FieldHostTypeMunger)) { return false; } FieldHostTypeMunger o = (FieldHostTypeMunger) other; return ((o.aspect == null) ? (aspect == null) : aspect.equals(o.aspect)) && ((o.typePattern == null) ? (typePattern == null) : typePattern.equals(o.typePattern)); }
public boolean equals(Object other) { if (!(other instanceof MethodDelegateTypeMunger)) { return false; } MethodDelegateTypeMunger o = (MethodDelegateTypeMunger) other; return ((o.aspect == null) ? (aspect == null) : aspect.equals(o.aspect)) && ((o.typePattern == null) ? (typePattern == null) : typePattern.equals(o.typePattern)) && ((o.implClassName == null) ? (implClassName == null) : implClassName.equals(o.implClassName)) && ((o.fieldType == null ? (fieldType == null) : fieldType.equals(o.fieldType))) && ((o.factoryMethodName == null) ? (factoryMethodName == null) : factoryMethodName.equals(o.factoryMethodName)) && ((o.factoryMethodSignature == null) ? (factoryMethodSignature == null) : factoryMethodSignature .equals(o.factoryMethodSignature)) && o.bitflags == bitflags; }
public boolean equals(Object other) { if (!(other instanceof NewMemberClassTypeMunger)) { return false; } NewMemberClassTypeMunger o = (NewMemberClassTypeMunger) other; return ((kind == null) ? (o.kind == null) : kind.equals(o.kind)) && memberTypeName.equals(o.memberTypeName) && targetType.equals(o.targetType) && ((typeVariableAliases == null) ? (o.typeVariableAliases == null) : typeVariableAliases .equals(o.typeVariableAliases)); } }
/** * @return true, iff this shadow returns a value */ private boolean hasANonVoidReturnType() { return !this.getReturnType().equals(UnresolvedType.VOID); }
@Override public boolean equals(Object other) { if (!(other instanceof PerTypeWithinTargetTypeMunger)) { return false; } PerTypeWithinTargetTypeMunger o = (PerTypeWithinTargetTypeMunger) other; return ((o.testPointcut == null) ? (testPointcut == null) : testPointcut.equals(o.testPointcut)) && ((o.aspectType == null) ? (aspectType == null) : aspectType.equals(o.aspectType)); }
public boolean equals(Object other) { if (!(other instanceof ReferencePointcut)) { return false; } if (this == other) { return true; } ReferencePointcut o = (ReferencePointcut) other; return o.name.equals(name) && o.arguments.equals(arguments) && ((o.onType == null) ? (onType == null) : o.onType.equals(onType)); }
@Override public boolean equals(Object obj) { if (!(obj instanceof ExactAnnotationTypePattern)) { return false; } ExactAnnotationTypePattern other = (ExactAnnotationTypePattern) obj; return (other.annotationType.equals(annotationType)) && isForParameterAnnotationMatch() == other.isForParameterAnnotationMatch() && (annotationValues == null ? other.annotationValues == null : annotationValues.equals(other.annotationValues)); }
private boolean matchesTypeVariable(TypeVariableReferenceType matchType) { // was this method previously coded to return false *on purpose* ?? pr124808 return this.type.equals(((TypeVariableReference) matchType).getTypeVariable().getFirstBound()); // return false; }
public static boolean hasSerialVersionUIDField(ResolvedType type) { ResolvedMember[] fields = type.getDeclaredFields(); for (int i = 0; i < fields.length; i++) { ResolvedMember field = fields[i]; if (field.getName().equals("serialVersionUID") && Modifier.isStatic(field.getModifiers()) && field.getType().equals(UnresolvedType.LONG)) { return true; } } return false; }
public static boolean isVisible(int modifiers, ResolvedType targetType, ResolvedType fromType) { // System.err.println("mod: " + modifiers + ", " + targetType + " and " // + fromType); if (Modifier.isPublic(modifiers)) { return true; } else if (Modifier.isPrivate(modifiers)) { return targetType.getOutermostType().equals(fromType.getOutermostType()); } else if (Modifier.isProtected(modifiers)) { return samePackage(targetType, fromType) || targetType.isAssignableFrom(fromType); } else { // package-visible return samePackage(targetType, fromType); } }
public boolean equals(Object other) { if (!(other instanceof ExceptionRange)) return false; ExceptionRange o = (ExceptionRange) other; return o.getStart() == getStart() && o.getEnd() == getEnd() && o.handler == handler && ((o.exceptionType == null) ? (exceptionType == null) : o.exceptionType.equals(exceptionType)) && o.priority == priority; }
private ResolvedMember findField(ResolvedMember[] members, Member lookingFor) { for (int i = 0; i < members.length; i++) { ResolvedMember member = members[i]; if (member.getName().equals(getSignature().getName()) && member.getType().equals(getSignature().getType())) { return member; } } return null; }
@Override public final boolean equals(Object other) { if (!(other instanceof Member)) { return false; } Member o = (Member) other; return (getKind() == o.getKind() && getName().equals(o.getName()) && getSignature().equals(o.getSignature()) && getDeclaringType() .equals(o.getDeclaringType())); }
public boolean isCompatibleWith(Member am) { if (kind != METHOD || am.getKind() != METHOD) { return true; } if (!name.equals(am.getName())) { return true; } if (!equalTypes(getParameterTypes(), am.getParameterTypes())) { return true; } return getReturnType().equals(am.getReturnType()); }