public final class Utils extends Object
| Modifier and Type | Method and Description |
|---|---|
static List<String> |
tokenize(char separator,
String quoteChars,
boolean includeEmptyTokens,
String text)
Tokenize provide
text by separator char respecting quoted sub-sequences. |
static void |
write(ByteBuffer byteBuffer,
OutputStream out)
Appends the content of the given byte buffer into the given output stream.
|
public static List<String> tokenize(char separator, String quoteChars, boolean includeEmptyTokens, String text)
text by separator char respecting quoted sub-sequences. Quoted sub-sequences are
parts of text which starts and ends by the same quoteChar.separator - a token separator.quoteChars - characters which can be used for quoting. Quoted part must start and ends with the same
character.includeEmptyTokens - return also tokens with length == 0.text - a text to be tokenized.public static void write(ByteBuffer byteBuffer, OutputStream out) throws IOException
out - the stream where to append the byte bufferbyteBuffer - the byte buffer to append to the streamIOException - in case of an IO problemCopyright © 2018, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.