src/org/kocakosm/pitaya/util/Strings.java
public static String padLeft(String str, int len, char padChar)
	{
		Parameters.checkCondition(len >= 0);
		StringBuilder sb = new StringBuilder(len);
		while (sb.length() < len - str.length()) {
			sb.append(padChar);
		}
		sb.append(str);
		return sb.toString();
	}
public static String padLeft(String str, int len, char padChar)
	{
		Parameters.checkCondition(len >= 0);
		StringBuilder sb = new StringBuilder(len);
		while (sb.length() < len - str.length()) {
			sb.append(padChar);
		}
		sb.append(str);
		return sb.toString();
	}
public static String padLeft ( String str , int len , char padChar ) { Parameters . checkCondition ( len >= 0 ) ; StringBuilder sb = new StringBuilder ( len ) ; while ( sb . length ( ) < len - str . length ( ) ) { sb . append ( padChar ) ; } sb . append ( str ) ; return sb . toString ( ) ; }
Returns a {@code String} of length at least {@code len} created by
prepending as many copies of {@code padChar} as necessary to reach
that length.

@param str the {@code String} to pad.
@param len the result's minimum length.
@param padChar the padding character.

@return the padded {@code String}.

@throws IllegalArgumentException if {@code len} is negative.
@throws NullPointerException if {@code str} is {@code null}.
Returns a { @code String } of length at least { @code len } created by prepending as many copies of { @code padChar } as necessary to reach that length .