]> git.mxchange.org Git - jcore.git/commitdiff
Closed internal TODO, got rid of 'size' as countTokens() can be used instead
authorRoland Haeder <roland@mxchange.org>
Mon, 31 Aug 2015 07:46:21 +0000 (09:46 +0200)
committerRoland Haeder <roland@mxchange.org>
Mon, 31 Aug 2015 07:46:21 +0000 (09:46 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

src/org/mxchange/jcore/BaseFrameworkSystem.java

index f8becfbf6a1ed6c599c4cf46170ca07748d3643d..51bd2106ce9e4463d5d4ebd4e2260e82e8526c16 100644 (file)
@@ -586,19 +586,18 @@ public class BaseFrameworkSystem implements FrameworkInterface {
         *
         * @param str String to tokenize and get array from
         * @param delimiter Delimiter
-        * @param size Size of array
         * @return Array from tokenized string
         * TODO Get rid of size parameter
         */
-       protected String[] getArrayFromString (final String str, final String delimiter, final int size) {
+       protected String[] getArrayFromString (final String str, final String delimiter) {
                // Trace message
-               this.getLogger().trace(MessageFormat.format("str={0},delimiter={1},size={2} - CALLED!", str, delimiter, size)); //NOI18N
+               this.getLogger().trace(MessageFormat.format("str={0},delimiter={1} - CALLED!", str, delimiter)); //NOI18N
 
                // Get tokenizer
                StringTokenizer tokenizer = new StringTokenizer(str, delimiter);
 
                // Init array and index
-               String[] tokens = new String[size];
+               String[] tokens = new String[tokenizer.countTokens()];
                int index = 0;
 
                // Run through all tokens