This repository has been archived by the owner on Jun 15, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
removed dep and created util for same solution
can quote from other DMs now bumped version number
- Loading branch information
Showing
5 changed files
with
48 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/* | ||
* To change this license header, choose License Headers in Project Properties. | ||
* To change this template file, choose Tools | Templates | ||
* and open the template in the editor. | ||
*/ | ||
package jselfbot.utils; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* | ||
* @author John Grosh ([email protected]) | ||
*/ | ||
public class FormatUtil | ||
{ | ||
|
||
public static String join(List<String> strings, String joiner) | ||
{ | ||
if(strings.isEmpty()) | ||
return ""; | ||
StringBuilder sb = new StringBuilder(strings.get(0)); | ||
for(int i=1; i<strings.size(); i++) | ||
sb.append(joiner).append(strings.get(i)); | ||
return sb.toString(); | ||
} | ||
} |