Java List Merge merge(List stringList)

Here you can find the source of merge(List stringList)

Description

Merges a string list into a single string without inserting any extra characters between strings.

License

Open Source License

Parameter

Parameter Description
stringList a parameter

Return

merged string

Declaration

public static String merge(List<String> stringList) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.util.List;

public class Main {
    /**/*from w  ww. j av  a  2s . co  m*/
     * Merges a string list into a single string without inserting any extra
     * characters between strings.
     * 
     * @param stringList
     * @return merged string
     */
    public static String merge(List<String> stringList) {
        StringBuilder stringBuilder = new StringBuilder();
        for (String string : stringList) {
            stringBuilder.append(string);
        }
        return stringBuilder.toString();
    }
}

Related

  1. merge(List> list)
  2. merge(List l1, List l2)
  3. merge(List l1, List l2)
  4. merge(List list)
  5. merge(List lst1, List lst2)
  6. merge(List text)
  7. merge(List a, List b)
  8. merge(List a, List b, Comparator comp)
  9. merge(List list)