Read a string as an arbitrary sequence of characters, stopping at the delimiter Used to read part of a response code inside []. @param delim the delimiter character @return the string
(char delim)
| 285 | * @return the string |
| 286 | */ |
| 287 | public String readString(char delim) { |
| 288 | skipSpaces(); |
| 289 | |
| 290 | if (index >= size) // already at end of response |
| 291 | return null; |
| 292 | |
| 293 | int start = index; |
| 294 | while (index < size && buffer[index] != delim) |
| 295 | index++; |
| 296 | |
| 297 | return toString(buffer, start, index); |
| 298 | } |
| 299 | |
| 300 | public String[] readStringList() { |
| 301 | return readStringList(false); |
no test coverage detected