public final class Strings extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
Strings.ToBooleanFunction<T> |
| Modifier and Type | Method and Description |
|---|---|
static String[] |
split(String str,
char delimiter)
|
static <A,R> R |
split(String str,
char delimiter,
java.util.stream.Collector<String,A,R> collector)
Split the given
str using the delimiter and uses the given collector to create a value of type R |
static void |
split(String str,
char delimiter,
java.util.function.Consumer<String> consumer)
Split the given
str using the delimiter and passes all parts to the given consumer |
static <A,R> R |
split(String str,
char delimiter,
java.util.function.Predicate<String> continueCondition,
java.util.stream.Collector<String,A,R> collector)
Split the given
str using the delimiter and uses the given collector to create a value of type R |
static void |
split(String str,
char delimiter,
Strings.ToBooleanFunction<String> consumer)
Split the given
str using the delimiter and passes all parts to the given consumer,
as long as the consumer returns true |
static String[] |
split(String str,
String delimiter)
|
static <A,R> R |
split(String str,
String delimiter,
java.util.stream.Collector<String,A,R> collector)
Split the given
str using the delimiter and uses the given collector to create a value of type R |
static void |
split(String str,
String delimiter,
java.util.function.Consumer<String> consumer)
Split the given
str using the delimiter and passes all parts to the given consumer |
static <A,R> R |
split(String str,
String delimiter,
java.util.function.Predicate<String> continueCondition,
java.util.stream.Collector<String,A,R> collector)
Split the given
str using the delimiter and uses the given collector to create a value of type R |
static void |
split(String str,
String delimiter,
Strings.ToBooleanFunction<String> consumer)
Split the given
str using the delimiter and passes all parts to the given consumer,
as long as the consumer returns true |
public static String[] split(String str, char delimiter)
str - The string to splitdelimiter - The delimiter to split atString containing all partssplit(String, char, Collector)public static String[] split(String str, String delimiter)
str - The string to splitdelimiter - The delimiter to split atString containing all partssplit(String, String, Collector)public static <A,R> R split(String str, char delimiter, java.util.stream.Collector<String,A,R> collector)
str using the delimiter and uses the given collector to create a value of type RA - The Accumulator-TypeR - The Resulting-Typestr - The string to splitdelimiter - The delimiter to split atcollector - The collector to create the return valuecollectorsplit(String, char, Predicate, Collector)public static <A,R> R split(String str, char delimiter, java.util.function.Predicate<String> continueCondition, java.util.stream.Collector<String,A,R> collector)
str using the delimiter and uses the given collector to create a value of type RA - The Accumulator-TypeR - The Resulting-Typestr - The string to splitdelimiter - The delimiter to split atcontinueCondition - A Predicate to test whether the splitting should continue or notcollector - The collector to create the return valuecollectorsplit(String, char, ToBooleanFunction)public static <A,R> R split(String str, String delimiter, java.util.stream.Collector<String,A,R> collector)
str using the delimiter and uses the given collector to create a value of type RA - The Accumulator-TypeR - The Resulting-Typestr - The string to splitdelimiter - The delimiter to split atcollector - The collector to create the return valuecollectorsplit(String, String, Predicate, Collector)public static <A,R> R split(String str, String delimiter, java.util.function.Predicate<String> continueCondition, java.util.stream.Collector<String,A,R> collector)
str using the delimiter and uses the given collector to create a value of type RA - The Accumulator-TypeR - The Resulting-Typestr - The string to splitdelimiter - The delimiter to split atcontinueCondition - A Predicate to test whether the splitting should continue or notcollector - The collector to create the return valuecollectorsplit(String, String, ToBooleanFunction)public static void split(String str, char delimiter, java.util.function.Consumer<String> consumer)
str using the delimiter and passes all parts to the given consumerstr - The string to splitdelimiter - The delimiter to split atconsumer - The consumer receiving all partssplit(String, char, ToBooleanFunction)public static void split(String str, char delimiter, Strings.ToBooleanFunction<String> consumer)
str using the delimiter and passes all parts to the given consumer,
as long as the consumer returns truestr - The string to splitdelimiter - The delimiter to split atconsumer - The consumer receiving all parts (until in returns false)split(String, String, ToBooleanFunction)public static void split(String str, String delimiter, java.util.function.Consumer<String> consumer)
str using the delimiter and passes all parts to the given consumerstr - The string to splitdelimiter - The delimiter to split atconsumer - The consumer receiving all partssplit(String, String, ToBooleanFunction)public static void split(String str, String delimiter, Strings.ToBooleanFunction<String> consumer)
str using the delimiter and passes all parts to the given consumer,
as long as the consumer returns truestr - The string to splitdelimiter - The delimiter to split atconsumer - The consumer receiving all parts (until in returns false)split(String, char, ToBooleanFunction)Copyright © 2019. All rights reserved.