Java Collection Concatenate concatNumber(Collection keys)

Here you can find the source of concatNumber(Collection keys)

Description

concat Number

License

Apache License

Declaration

public static String concatNumber(Collection<? extends Number> keys) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.util.Collection;

public class Main {
    public static String concatNumber(Collection<? extends Number> keys) {
        StringBuffer res = new StringBuffer();
        for (Number key : keys) {
            res.append(key);// w w w  .  j a v a2s  . c  o  m
            res.append(',');
        }
        res.deleteCharAt(res.length() - 1);

        return res.toString();
    }
}

Related

  1. concatenateIds(final Collection ids)
  2. concatenateWithComma(Collection collection)
  3. concatEntries(Collection coll, String sep, String lastSep)
  4. concatInt(Collection collection)
  5. concatNames(Collection cNames, String split)
  6. concatStrings(Collection strings)
  7. concatStrings(Collection values, String separator)
  8. concatStringsWSep(Collection strings, String separator)
  9. concatTokens(Collection tokens)