summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrbuj <robert.buj@gmail.com>2014-09-10 00:02:15 +0200
committerNoel Grandin <noelgrandin@gmail.com>2014-09-11 06:10:39 +0000
commitf1b8d8832d38621ae9fbe08bf9bde414230fc5c3 (patch)
treea2b5fc4744e3421b13db3d2e6f61aa062561ca78
parent037d03b9facb414ba6be01fa6ee92fc7ca89f70c (diff)
qadevOOo: use String.length()==0 instead of String.equals(empty string)
Change-Id: I5cdd1fb4fe77c7fc9614f2a6de8995d98d60b551 Reviewed-on: https://gerrit.libreoffice.org/11368 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
-rw-r--r--qadevOOo/runner/convwatch/GraphicalDifferenceCheck.java2
-rw-r--r--qadevOOo/runner/helper/CfgParser.java2
-rw-r--r--qadevOOo/runner/helper/OfficeProvider.java2
-rw-r--r--qadevOOo/runner/util/XMLTools.java4
4 files changed, 5 insertions, 5 deletions
diff --git a/qadevOOo/runner/convwatch/GraphicalDifferenceCheck.java b/qadevOOo/runner/convwatch/GraphicalDifferenceCheck.java
index 1e6971868f32..2d59022c527d 100644
--- a/qadevOOo/runner/convwatch/GraphicalDifferenceCheck.java
+++ b/qadevOOo/runner/convwatch/GraphicalDifferenceCheck.java
@@ -320,7 +320,7 @@ public class GraphicalDifferenceCheck
private static String ensureEndingFileSep(String s)
{
- if(s != null && !s.equals("") && !s.endsWith(File.separator))
+ if(s != null && s.length() != 0 && !s.endsWith(File.separator))
{
s = s.trim() + File.separator;
}
diff --git a/qadevOOo/runner/helper/CfgParser.java b/qadevOOo/runner/helper/CfgParser.java
index 263655f3aafd..6c77461c3880 100644
--- a/qadevOOo/runner/helper/CfgParser.java
+++ b/qadevOOo/runner/helper/CfgParser.java
@@ -48,7 +48,7 @@ public class CfgParser
{
debug = param.getBool(PropertyName.DEBUG_IS_ACTIVE);
Properties cfg = null;
- if (iniFile.equals(""))
+ if (iniFile.length() == 0)
{
//no iniFile given, search one in the users home directory
cfg = getProperties(getDefaultFileName(true));
diff --git a/qadevOOo/runner/helper/OfficeProvider.java b/qadevOOo/runner/helper/OfficeProvider.java
index 6b21841b1802..d5ac4bacbaf1 100644
--- a/qadevOOo/runner/helper/OfficeProvider.java
+++ b/qadevOOo/runner/helper/OfficeProvider.java
@@ -183,7 +183,7 @@ public class OfficeProvider implements AppProvider
Exception exConnectFailed = null;
boolean isExecutable = false;
boolean isAppKnown = ((cncstr.indexOf("host=localhost") > 0) || (cncstr.indexOf("pipe,name=") > 0));
- isAppKnown &= !((String) param.get("AppExecutionCommand")).equals("");
+ isAppKnown &= ((String) param.get("AppExecutionCommand")).length() != 0;
if (isAppKnown)
{
diff --git a/qadevOOo/runner/util/XMLTools.java b/qadevOOo/runner/util/XMLTools.java
index a59f523758ca..5f43f06d7c0c 100644
--- a/qadevOOo/runner/util/XMLTools.java
+++ b/qadevOOo/runner/util/XMLTools.java
@@ -377,7 +377,7 @@ public class XMLTools {
super.startElement(name, attrs) ;
if (tags.containsKey(name)) {
String outerTag = tags.get(name);
- if (!outerTag.equals("")) {
+ if (outerTag.length() != 0) {
boolean isInTag = false ;
for (int i = 0; i < tagStack.size(); i++) {
if (outerTag.equals(tagStack.get(i))) {
@@ -401,7 +401,7 @@ public class XMLTools {
if (chars.containsKey(ch)) {
String outerTag = chars.get(ch);
- if (!outerTag.equals("")) {
+ if (outerTag.length() != 0) {
boolean isInTag = false ;
for (int i = 0; i < tagStack.size(); i++) {
if (outerTag.equals(tagStack.get(i))) {