summaryrefslogtreecommitdiff
path: root/qadevOOo
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-08-21 08:27:25 +0200
committerNoel Grandin <noel@peralex.com>2014-10-07 13:20:03 +0200
commit68fa1410975ccecc35db8a97669f0fbe5ef9b451 (patch)
tree5fd946ab04ea37e17813ec3c0345badc59ae5400 /qadevOOo
parent81968336ea6433293c603110a75bd13d5898c0eb (diff)
java: use isEmpty() instead of "size() == 0"
Change-Id: I23e1038246999b0744d8e9ae83b66fa1f7dafa99
Diffstat (limited to 'qadevOOo')
-rw-r--r--qadevOOo/runner/graphical/IniFile.java2
-rw-r--r--qadevOOo/runner/share/DescGetter.java2
-rw-r--r--qadevOOo/runner/util/XMLTools.java4
3 files changed, 4 insertions, 4 deletions
diff --git a/qadevOOo/runner/graphical/IniFile.java b/qadevOOo/runner/graphical/IniFile.java
index 8c3e6f31168e..16bf0ad79743 100644
--- a/qadevOOo/runner/graphical/IniFile.java
+++ b/qadevOOo/runner/graphical/IniFile.java
@@ -52,7 +52,7 @@ public class IniFile implements Enumeration<String>
public void insertFirstComment(String[] _aList)
{
- if (m_aList.size() == 0)
+ if (m_aList.isEmpty())
{
// can only insert if there is nothing else already in the ini file
for (int i = 0; i < _aList.length; i++)
diff --git a/qadevOOo/runner/share/DescGetter.java b/qadevOOo/runner/share/DescGetter.java
index e9bd0d5efa32..ad0ce136786e 100644
--- a/qadevOOo/runner/share/DescGetter.java
+++ b/qadevOOo/runner/share/DescGetter.java
@@ -153,7 +153,7 @@ public abstract class DescGetter
}
}
- if (entryList.size() == 0)
+ if (entryList.isEmpty())
{
return null;
}
diff --git a/qadevOOo/runner/util/XMLTools.java b/qadevOOo/runner/util/XMLTools.java
index 5f43f06d7c0c..ce15982727f9 100644
--- a/qadevOOo/runner/util/XMLTools.java
+++ b/qadevOOo/runner/util/XMLTools.java
@@ -289,7 +289,7 @@ public class XMLTools {
public void endElement(String name) {
super.endElement(name);
if (wellFormed) {
- if (tagStack.size() == 0) {
+ if (tagStack.isEmpty()) {
wellFormed = false ;
printError("No tags to close (bad closing tag </" + name + ">)") ;
} else {
@@ -718,7 +718,7 @@ public class XMLTools {
if (!isWellFormed())
log.println("!!! Some errors were found in XML structure") ;
- boolean result = tags.size() == 0 && chars.size() == 0 && isWellFormed();
+ boolean result = tags.isEmpty() && chars.size() == 0 && isWellFormed();
reset();
return result;
}