diff options
author | Robert Antoni Buj i Gelonch <robert.buj@gmail.com> | 2014-10-08 16:55:54 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2014-10-19 10:12:55 +0000 |
commit | 2a0569b53d87cf5f0971d87a537e275ea5271d8c (patch) | |
tree | c1eb2831451ba3a9295cb2646e0377f7fe8be660 /scripting/java | |
parent | a8e723ed3eed44a85714abf1cb04b74178d2424f (diff) |
scripting: redundant cast to String
Change-Id: I5e048964cc7885a32c59ff8a9eb1fc5b9523e843
Reviewed-on: https://gerrit.libreoffice.org/11859
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'scripting/java')
-rw-r--r-- | scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java | 6 | ||||
-rw-r--r-- | scripting/java/com/sun/star/script/framework/provider/java/ScriptDescriptor.java | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java b/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java index 59004f02a6bb..424c25969c37 100644 --- a/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java +++ b/scripting/java/com/sun/star/script/framework/provider/beanshell/ScriptProviderForBeanShell.java @@ -331,8 +331,8 @@ class ScriptImpl implements XScript { new StringTokenizer(full.substring(index), ":"); if (tokenizer.countTokens() > 2) { - LogUtils.DEBUG("First token = " + (String)tokenizer.nextElement()); - wrappedException = (String)tokenizer.nextElement(); + LogUtils.DEBUG("First token = " + tokenizer.nextToken()); + wrappedException = tokenizer.nextToken(); LogUtils.DEBUG("wrapped exception = = " + wrappedException); } } @@ -364,4 +364,4 @@ class ScriptImpl implements XScript { } } -}
\ No newline at end of file +} diff --git a/scripting/java/com/sun/star/script/framework/provider/java/ScriptDescriptor.java b/scripting/java/com/sun/star/script/framework/provider/java/ScriptDescriptor.java index 9d45332f7ca2..1ca7cb540d00 100644 --- a/scripting/java/com/sun/star/script/framework/provider/java/ScriptDescriptor.java +++ b/scripting/java/com/sun/star/script/framework/provider/java/ScriptDescriptor.java @@ -86,8 +86,8 @@ public class ScriptDescriptor { public void setClasspath(String classpath) { StringTokenizer stk = new StringTokenizer(classpath, ":"); - while (stk.hasMoreElements()) { - this.m_classpath.add((String) stk.nextElement()); + while (stk.hasMoreTokens()) { + this.m_classpath.add(stk.nextToken()); } } |