Simplify String concatenation
This commit is contained in:
committed by
Juergen Hoeller
parent
cc4593fda8
commit
49873a30c5
@@ -544,9 +544,7 @@ public class AspectJExpressionPointcut extends AbstractExpressionPointcut
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
StringBuilder sb = new StringBuilder();
|
StringBuilder sb = new StringBuilder("AspectJExpressionPointcut: (");
|
||||||
sb.append("AspectJExpressionPointcut: ");
|
|
||||||
sb.append("(");
|
|
||||||
for (int i = 0; i < this.pointcutParameterTypes.length; i++) {
|
for (int i = 0; i < this.pointcutParameterTypes.length; i++) {
|
||||||
sb.append(this.pointcutParameterTypes[i].getName());
|
sb.append(this.pointcutParameterTypes[i].getName());
|
||||||
sb.append(" ");
|
sb.append(" ");
|
||||||
@@ -555,8 +553,7 @@ public class AspectJExpressionPointcut extends AbstractExpressionPointcut
|
|||||||
sb.append(", ");
|
sb.append(", ");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
sb.append(")");
|
sb.append(") ");
|
||||||
sb.append(" ");
|
|
||||||
if (getExpression() != null) {
|
if (getExpression() != null) {
|
||||||
sb.append(getExpression());
|
sb.append(getExpression());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -987,14 +987,11 @@ public abstract class AbstractNestablePropertyAccessor extends AbstractPropertyA
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
StringBuilder sb = new StringBuilder(getClass().getName());
|
String className = getClass().getName();
|
||||||
if (this.wrappedObject != null) {
|
if (this.wrappedObject == null) {
|
||||||
sb.append(": wrapping object [").append(ObjectUtils.identityToString(this.wrappedObject)).append("]");
|
return className + ": no wrapped object set";
|
||||||
}
|
}
|
||||||
else {
|
return className + ": wrapping object [" + ObjectUtils.identityToString(this.wrappedObject) + ']';
|
||||||
sb.append(": no wrapped object set");
|
|
||||||
}
|
|
||||||
return sb.toString();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -380,11 +380,10 @@ public class MutablePropertyValues implements PropertyValues, Serializable {
|
|||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
PropertyValue[] pvs = getPropertyValues();
|
PropertyValue[] pvs = getPropertyValues();
|
||||||
StringBuilder sb = new StringBuilder("PropertyValues: length=").append(pvs.length);
|
|
||||||
if (pvs.length > 0) {
|
if (pvs.length > 0) {
|
||||||
sb.append("; ").append(StringUtils.arrayToDelimitedString(pvs, "; "));
|
return "PropertyValues: length=" + pvs.length + "; " + StringUtils.arrayToDelimitedString(pvs, "; ");
|
||||||
}
|
}
|
||||||
return sb.toString();
|
return "PropertyValues: length=0";
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -135,12 +135,10 @@ public class BeanDefinitionHolder implements BeanMetadataElement {
|
|||||||
* @see #getAliases()
|
* @see #getAliases()
|
||||||
*/
|
*/
|
||||||
public String getShortDescription() {
|
public String getShortDescription() {
|
||||||
StringBuilder sb = new StringBuilder();
|
if (this.aliases == null) {
|
||||||
sb.append("Bean definition with name '").append(this.beanName).append("'");
|
return "Bean definition with name '" + this.beanName + "'";
|
||||||
if (this.aliases != null) {
|
|
||||||
sb.append(" and aliases [").append(StringUtils.arrayToCommaDelimitedString(this.aliases)).append("]");
|
|
||||||
}
|
}
|
||||||
return sb.toString();
|
return "Bean definition with name '" + this.beanName + "' and aliases [" + StringUtils.arrayToCommaDelimitedString(this.aliases) + ']';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user