Consistent equals implementations in AOP support classes
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2021 the original author or authors.
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -191,14 +191,9 @@ public class AnnotationTransactionAttributeSource extends AbstractFallbackTransa
|
||||
|
||||
@Override
|
||||
public boolean equals(@Nullable Object other) {
|
||||
if (this == other) {
|
||||
return true;
|
||||
}
|
||||
if (!(other instanceof AnnotationTransactionAttributeSource otherTas)) {
|
||||
return false;
|
||||
}
|
||||
return (this.annotationParsers.equals(otherTas.annotationParsers) &&
|
||||
this.publicMethodsOnly == otherTas.publicMethodsOnly);
|
||||
return (this == other || (other instanceof AnnotationTransactionAttributeSource otherTas &&
|
||||
this.annotationParsers.equals(otherTas.annotationParsers) &&
|
||||
this.publicMethodsOnly == otherTas.publicMethodsOnly));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2021 the original author or authors.
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -239,13 +239,8 @@ public class MethodMapTransactionAttributeSource
|
||||
|
||||
@Override
|
||||
public boolean equals(@Nullable Object other) {
|
||||
if (this == other) {
|
||||
return true;
|
||||
}
|
||||
if (!(other instanceof MethodMapTransactionAttributeSource otherTas)) {
|
||||
return false;
|
||||
}
|
||||
return ObjectUtils.nullSafeEquals(this.methodMap, otherTas.methodMap);
|
||||
return (this == other || (other instanceof MethodMapTransactionAttributeSource otherTas &&
|
||||
ObjectUtils.nullSafeEquals(this.methodMap, otherTas.methodMap)));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2021 the original author or authors.
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -164,13 +164,8 @@ public class NameMatchTransactionAttributeSource
|
||||
|
||||
@Override
|
||||
public boolean equals(@Nullable Object other) {
|
||||
if (this == other) {
|
||||
return true;
|
||||
}
|
||||
if (!(other instanceof NameMatchTransactionAttributeSource otherTas)) {
|
||||
return false;
|
||||
}
|
||||
return ObjectUtils.nullSafeEquals(this.nameMap, otherTas.nameMap);
|
||||
return (this == other || (other instanceof NameMatchTransactionAttributeSource otherTas &&
|
||||
ObjectUtils.nullSafeEquals(this.nameMap, otherTas.nameMap)));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user