Polish: redundant pairs of parentheses should be removed
This commit is contained in:
parent
eeecbaef2c
commit
67a91cf6f9
|
@ -414,7 +414,7 @@ public class DefaultListableBeanFactory extends AbstractAutowireCapableBeanFacto
|
||||||
RootBeanDefinition mbd = getMergedLocalBeanDefinition(beanName);
|
RootBeanDefinition mbd = getMergedLocalBeanDefinition(beanName);
|
||||||
// Only check bean definition if it is complete.
|
// Only check bean definition if it is complete.
|
||||||
if (!mbd.isAbstract() && (allowEagerInit ||
|
if (!mbd.isAbstract() && (allowEagerInit ||
|
||||||
((mbd.hasBeanClass() || !mbd.isLazyInit() || isAllowEagerClassLoading())) &&
|
(mbd.hasBeanClass() || !mbd.isLazyInit() || isAllowEagerClassLoading()) &&
|
||||||
!requiresEagerInitForType(mbd.getFactoryBeanName()))) {
|
!requiresEagerInitForType(mbd.getFactoryBeanName()))) {
|
||||||
// In case of FactoryBean, match object created by FactoryBean.
|
// In case of FactoryBean, match object created by FactoryBean.
|
||||||
boolean isFactoryBean = isFactoryBean(beanName, mbd);
|
boolean isFactoryBean = isFactoryBean(beanName, mbd);
|
||||||
|
|
|
@ -1202,7 +1202,7 @@ public class BeanDefinitionParserDelegate {
|
||||||
boolean hasKeyAttribute = entryEle.hasAttribute(KEY_ATTRIBUTE);
|
boolean hasKeyAttribute = entryEle.hasAttribute(KEY_ATTRIBUTE);
|
||||||
boolean hasKeyRefAttribute = entryEle.hasAttribute(KEY_REF_ATTRIBUTE);
|
boolean hasKeyRefAttribute = entryEle.hasAttribute(KEY_REF_ATTRIBUTE);
|
||||||
if ((hasKeyAttribute && hasKeyRefAttribute) ||
|
if ((hasKeyAttribute && hasKeyRefAttribute) ||
|
||||||
((hasKeyAttribute || hasKeyRefAttribute)) && keyEle != null) {
|
(hasKeyAttribute || hasKeyRefAttribute) && keyEle != null) {
|
||||||
error("<entry> element is only allowed to contain either " +
|
error("<entry> element is only allowed to contain either " +
|
||||||
"a 'key' attribute OR a 'key-ref' attribute OR a <key> sub-element", entryEle);
|
"a 'key' attribute OR a 'key-ref' attribute OR a <key> sub-element", entryEle);
|
||||||
}
|
}
|
||||||
|
@ -1231,7 +1231,7 @@ public class BeanDefinitionParserDelegate {
|
||||||
boolean hasValueRefAttribute = entryEle.hasAttribute(VALUE_REF_ATTRIBUTE);
|
boolean hasValueRefAttribute = entryEle.hasAttribute(VALUE_REF_ATTRIBUTE);
|
||||||
boolean hasValueTypeAttribute = entryEle.hasAttribute(VALUE_TYPE_ATTRIBUTE);
|
boolean hasValueTypeAttribute = entryEle.hasAttribute(VALUE_TYPE_ATTRIBUTE);
|
||||||
if ((hasValueAttribute && hasValueRefAttribute) ||
|
if ((hasValueAttribute && hasValueRefAttribute) ||
|
||||||
((hasValueAttribute || hasValueRefAttribute)) && valueEle != null) {
|
(hasValueAttribute || hasValueRefAttribute) && valueEle != null) {
|
||||||
error("<entry> element is only allowed to contain either " +
|
error("<entry> element is only allowed to contain either " +
|
||||||
"'value' attribute OR 'value-ref' attribute OR <value> sub-element", entryEle);
|
"'value' attribute OR 'value-ref' attribute OR <value> sub-element", entryEle);
|
||||||
}
|
}
|
||||||
|
|
|
@ -365,7 +365,7 @@ public class ResolvableType implements Serializable {
|
||||||
if (this == NONE) {
|
if (this == NONE) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return (((this.type instanceof Class && ((Class<?>) this.type).isArray())) ||
|
return ((this.type instanceof Class && ((Class<?>) this.type).isArray()) ||
|
||||||
this.type instanceof GenericArrayType || resolveType().isArray());
|
this.type instanceof GenericArrayType || resolveType().isArray());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -607,7 +607,7 @@ public class Jaxb2Marshaller implements MimeMarshaller, MimeUnmarshaller, Generi
|
||||||
Type typeArgument = parameterizedType.getActualTypeArguments()[0];
|
Type typeArgument = parameterizedType.getActualTypeArguments()[0];
|
||||||
if (typeArgument instanceof Class) {
|
if (typeArgument instanceof Class) {
|
||||||
Class<?> classArgument = (Class<?>) typeArgument;
|
Class<?> classArgument = (Class<?>) typeArgument;
|
||||||
return (((classArgument.isArray() && Byte.TYPE == classArgument.getComponentType())) ||
|
return ((classArgument.isArray() && Byte.TYPE == classArgument.getComponentType()) ||
|
||||||
isPrimitiveWrapper(classArgument) || isStandardClass(classArgument) ||
|
isPrimitiveWrapper(classArgument) || isStandardClass(classArgument) ||
|
||||||
supportsInternal(classArgument, false));
|
supportsInternal(classArgument, false));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue