(Object input, Object length2, Object padStr)
| 1172 | } |
| 1173 | |
| 1174 | public static String padStart(Object input, Object length2, Object padStr) { |
| 1175 | int length = toInt(length2); |
| 1176 | String str = toString(input); |
| 1177 | String pad = toString(padStr); |
| 1178 | |
| 1179 | if (pad.isEmpty()) { |
| 1180 | throw new IllegalArgumentException("padStr must not be empty"); |
| 1181 | } |
| 1182 | |
| 1183 | while (str.length() < length) { |
| 1184 | str = pad + str; |
| 1185 | } |
| 1186 | |
| 1187 | return str.substring(str.length() - length); |
| 1188 | } |
| 1189 | |
| 1190 | public static String json(Object obj) { |
| 1191 | try { |
no test coverage detected