aboutsummaryrefslogtreecommitdiffstats
path: root/compatibility-server
diff options
context:
space:
mode:
authorAhmed Ashour <asashour@yahoo.com>2017-09-28 07:45:09 +0200
committerHenri Sara <henri.sara@gmail.com>2017-09-28 08:45:09 +0300
commit7fd440d2448587f7e9958e84c84ec2bfd30ba8a0 (patch)
treec0186a8d940f07c060fcaf4b03e82271bfa9e5c2 /compatibility-server
parentcb91ab76eecbf85ad598fc5054fa2ec5ab3308f6 (diff)
downloadvaadin-framework-7fd440d2448587f7e9958e84c84ec2bfd30ba8a0.tar.gz
vaadin-framework-7fd440d2448587f7e9958e84c84ec2bfd30ba8a0.zip
Use single character for StringBuilder.append (#10102)
Diffstat (limited to 'compatibility-server')
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/RowItem.java4
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/FreeformQuery.java2
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/TableQuery.java4
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/DefaultSQLGenerator.java4
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/OracleGenerator.java2
-rw-r--r--compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/filter/QueryBuilder.java2
6 files changed, 9 insertions, 9 deletions
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/RowItem.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/RowItem.java
index 9030202638..b7e6a4f38e 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/RowItem.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/RowItem.java
@@ -129,9 +129,9 @@ public final class RowItem implements Item {
s.append("ID:");
s.append(getId().toString());
for (Object propId : getItemPropertyIds()) {
- s.append("|");
+ s.append('|');
s.append(propId.toString());
- s.append(":");
+ s.append(':');
Object value = getItemProperty(propId).getValue();
s.append((null != value) ? value.toString() : null);
}
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/FreeformQuery.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/FreeformQuery.java
index 8c1282673e..bc5cfc56a3 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/FreeformQuery.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/FreeformQuery.java
@@ -471,7 +471,7 @@ public class FreeformQuery extends AbstractTransactionalQuery
if (keys[ix] == null) {
where.append(" IS NULL");
} else {
- where.append(" = '").append(keys[ix]).append("'");
+ where.append(" = '").append(keys[ix]).append('\'');
}
if (ix < primaryKeyColumns.size() - 1) {
where.append(" AND ");
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/TableQuery.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/TableQuery.java
index 065f16c029..b415c5ac51 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/TableQuery.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/TableQuery.java
@@ -439,10 +439,10 @@ public class TableQuery extends AbstractTransactionalQuery
if (fullTableName == null) {
StringBuilder sb = new StringBuilder();
if (catalogName != null) {
- sb.append(catalogName).append(".");
+ sb.append(catalogName).append('.');
}
if (schemaName != null) {
- sb.append(schemaName).append(".");
+ sb.append(schemaName).append('.');
}
sb.append(tableName);
fullTableName = sb.toString();
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/DefaultSQLGenerator.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/DefaultSQLGenerator.java
index 2c8ff8b126..88fc18084c 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/DefaultSQLGenerator.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/DefaultSQLGenerator.java
@@ -213,12 +213,12 @@ public class DefaultSQLGenerator implements SQLGenerator {
if (!first) {
query.append(", ");
}
- query.append("?");
+ query.append('?');
sh.addParameterValue(columnToValueMap.get(column),
item.getItemProperty(column).getType());
first = false;
}
- query.append(")");
+ query.append(')');
sh.setQueryString(query.toString());
return sh;
}
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/OracleGenerator.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/OracleGenerator.java
index bc7c659f07..34f93ec038 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/OracleGenerator.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/OracleGenerator.java
@@ -88,7 +88,7 @@ public class OracleGenerator extends DefaultSQLGenerator {
query.append(
QueryBuilder.getWhereStringForFilters(filters, sh));
}
- query.append(")");
+ query.append(')');
sh.setQueryString(query.toString());
return sh;
}
diff --git a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/filter/QueryBuilder.java b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/filter/QueryBuilder.java
index b435757e8e..6bd65de0dc 100644
--- a/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/filter/QueryBuilder.java
+++ b/compatibility-server/src/main/java/com/vaadin/v7/data/util/sqlcontainer/query/generator/filter/QueryBuilder.java
@@ -94,7 +94,7 @@ public class QueryBuilder implements Serializable {
StringBuilder result = new StringBuilder();
for (Filter f : filters) {
result.append(getWhereStringForFilter(f, sh));
- result.append(" ").append(joinString).append(" ");
+ result.append(' ').append(joinString).append(' ');
}
// Remove the last instance of joinString
result.delete(result.length() - joinString.length() - 2,