Package-level declarations

Types

Link copied to clipboard

Stands for kotlin.jvm.Synchronized on the JVM platform and a dummy annotation on the other platforms.

Without any effects on the JS Platform.

actual typealias JvmSynchronized = Synchronized

Typealias for kotlin.jvm.Synchronized.

Link copied to clipboard
interface PeekingIterator<out T : Any> : Iterator<T>

An Iterator which provides the peek function in addition.

Link copied to clipboard

Represents the option to which traversal algorithm shall be applied.

Link copied to clipboard
interface Tuple2Like<A1, A2>

Represents a tuple like data structure which has 2 components.

Link copied to clipboard
interface Tuple3Like<A1, A2, A3>

Represents a tuple like data structure which has 3 components.

Link copied to clipboard
data class Tuple4<A1, A2, A3, A4>(val a1: A1, val a2: A2, val a3: A3, val a4: A4)

Represents a simple data structure to hold 4 values.

Link copied to clipboard
interface Tuple4Like<A1, A2, A3, A4>

Represents a tuple like data structure which has 4 components.

Link copied to clipboard
data class Tuple5<A1, A2, A3, A4, A5>(val a1: A1, val a2: A2, val a3: A3, val a4: A4, val a5: A5)

Represents a simple data structure to hold 5 values.

Link copied to clipboard
interface Tuple5Like<A1, A2, A3, A4, A5>

Represents a tuple like data structure which has 5 components.

Link copied to clipboard
data class Tuple6<A1, A2, A3, A4, A5, A6>(val a1: A1, val a2: A2, val a3: A3, val a4: A4, val a5: A5, val a6: A6)

Represents a simple data structure to hold 6 values.

Link copied to clipboard
interface Tuple6Like<A1, A2, A3, A4, A5, A6>

Represents a tuple like data structure which has 6 components.

Link copied to clipboard
data class Tuple7<A1, A2, A3, A4, A5, A6, A7>(val a1: A1, val a2: A2, val a3: A3, val a4: A4, val a5: A5, val a6: A6, val a7: A7)

Represents a simple data structure to hold 7 values.

Link copied to clipboard
interface Tuple7Like<A1, A2, A3, A4, A5, A6, A7>

Represents a tuple like data structure which has 7 components.

Link copied to clipboard
data class Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>(val a1: A1, val a2: A2, val a3: A3, val a4: A4, val a5: A5, val a6: A6, val a7: A7, val a8: A8)

Represents a simple data structure to hold 8 values.

Link copied to clipboard
interface Tuple8Like<A1, A2, A3, A4, A5, A6, A7, A8>

Represents a tuple like data structure which has 8 components.

Link copied to clipboard
data class Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>(val a1: A1, val a2: A2, val a3: A3, val a4: A4, val a5: A5, val a6: A6, val a7: A7, val a8: A8, val a9: A9)

Represents a simple data structure to hold 9 values.

Link copied to clipboard
interface Tuple9Like<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Represents a tuple like data structure which has 9 components.

Functions

Link copied to clipboard
fun <A1, A2, A3, A4, A5> Tuple4<A1, A2, A3, A4>.append(a5: A5): Tuple5<A1, A2, A3, A4, A5>

Transforms this Tuple4 into a Tuple5 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6> Tuple5<A1, A2, A3, A4, A5>.append(a6: A6): Tuple6<A1, A2, A3, A4, A5, A6>

Transforms this Tuple5 into a Tuple6 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple6<A1, A2, A3, A4, A5, A6>.append(a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Transforms this Tuple6 into a Tuple7 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple7<A1, A2, A3, A4, A5, A6, A7>.append(a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Tuple7 into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.append(a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Tuple8 into a Tuple9 by appending the given arguments.

fun <A1, A2, A3> Pair<A1, A2>.append(a3: A3): Triple<A1, A2, A3>

Transforms this Pair into a Triple by appending the given arguments.

fun <A1, A2, A3, A4> Triple<A1, A2, A3>.append(a4: A4): Tuple4<A1, A2, A3, A4>

Transforms this Triple into a Tuple4 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6> Tuple4<A1, A2, A3, A4>.append(a5: A5, a6: A6): Tuple6<A1, A2, A3, A4, A5, A6>

Transforms this Tuple4 into a Tuple6 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple5<A1, A2, A3, A4, A5>.append(a6: A6, a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Transforms this Tuple5 into a Tuple7 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple6<A1, A2, A3, A4, A5, A6>.append(a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Tuple6 into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple7<A1, A2, A3, A4, A5, A6, A7>.append(a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Tuple7 into a Tuple9 by appending the given arguments.

fun <A1, A2, A3, A4> Pair<A1, A2>.append(a3: A3, a4: A4): Tuple4<A1, A2, A3, A4>

Transforms this Pair into a Tuple4 by appending the given arguments.

fun <A1, A2, A3, A4, A5> Triple<A1, A2, A3>.append(a4: A4, a5: A5): Tuple5<A1, A2, A3, A4, A5>

Transforms this Triple into a Tuple5 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple4<A1, A2, A3, A4>.append(a5: A5, a6: A6, a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Transforms this Tuple4 into a Tuple7 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple5<A1, A2, A3, A4, A5>.append(a6: A6, a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Tuple5 into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple6<A1, A2, A3, A4, A5, A6>.append(a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Tuple6 into a Tuple9 by appending the given arguments.

fun <A1, A2, A3, A4, A5> Pair<A1, A2>.append(a3: A3, a4: A4, a5: A5): Tuple5<A1, A2, A3, A4, A5>

Transforms this Pair into a Tuple5 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6> Triple<A1, A2, A3>.append(a4: A4, a5: A5, a6: A6): Tuple6<A1, A2, A3, A4, A5, A6>

Transforms this Triple into a Tuple6 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple4<A1, A2, A3, A4>.append(a5: A5, a6: A6, a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Tuple4 into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple5<A1, A2, A3, A4, A5>.append(a6: A6, a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Tuple5 into a Tuple9 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6> Pair<A1, A2>.append(a3: A3, a4: A4, a5: A5, a6: A6): Tuple6<A1, A2, A3, A4, A5, A6>

Transforms this Pair into a Tuple6 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7> Triple<A1, A2, A3>.append(a4: A4, a5: A5, a6: A6, a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Transforms this Triple into a Tuple7 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple4<A1, A2, A3, A4>.append(a5: A5, a6: A6, a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Tuple4 into a Tuple9 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7> Pair<A1, A2>.append(a3: A3, a4: A4, a5: A5, a6: A6, a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Transforms this Pair into a Tuple7 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Triple<A1, A2, A3>.append(a4: A4, a5: A5, a6: A6, a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Triple into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Pair<A1, A2>.append(a3: A3, a4: A4, a5: A5, a6: A6, a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Transforms this Pair into a Tuple8 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Triple<A1, A2, A3>.append(a4: A4, a5: A5, a6: A6, a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Triple into a Tuple9 by appending the given arguments.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Pair<A1, A2>.append(a3: A3, a4: A4, a5: A5, a6: A6, a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Transforms this Pair into a Tuple9 by appending the given arguments.

Link copied to clipboard
inline fun <T> Array<T>.appendToStringBuilder(sb: StringBuilder, separator: String, append: (it: T) -> Unit)

Appends all elements of this list to the given sb by calling append and separates the elements with the given separator.

inline fun <T> Iterable<T>.appendToStringBuilder(sb: StringBuilder, separator: String, append: (it: T) -> Unit)

Appends all elements of this Iterable to the given sb by calling append and separates the elements with the given separator.

inline fun <T> List<T>.appendToStringBuilder(sb: StringBuilder, separator: String, append: (it: T) -> Unit)

Appends all elements of this List to the given sb by calling append and separates the elements with the given separator.

inline fun <T> Sequence<T>.appendToStringBuilder(sb: StringBuilder, separator: String, append: (it: T) -> Unit)

Appends all elements of this Sequence to the given sb by calling append and separates the elements with the given separator.

inline fun <T> Array<T>.appendToStringBuilder(sb: StringBuilder, separator: String, lastSeparator: String, append: (it: T) -> Unit)

Appends all elements of this list to the given sb by calling append and separates the elements with the given separator whereas lastSeparator is used to separate the last and the second last element.

inline fun <T> List<T>.appendToStringBuilder(sb: StringBuilder, separator: String, lastSeparator: String, append: (it: T) -> Unit)

Appends all elements of this List to the given sb by calling append and separates the elements with the given separator whereas lastSeparator is used to separate the last and the second last element.

Link copied to clipboard
inline fun <T : CharSequence> T.blankToNull(): T?

Returns this CharSequence if it is not blank, null otherwise.

Link copied to clipboard
@JvmName(name = "dynamicTraversalIterable")
fun <T> Sequence<T>.dynamicTraversal(revisit: Boolean = false, dropRoots: Boolean = true, traversalAlgorithm: TraversalAlgorithmOption = TraversalAlgorithmOption.BreadthFirst, loadElements: (element: T) -> Iterable<T>): Sequence<T>

Returns a single sequence containing all elements loadElements recursively provides for the elements of the original sequence as well as the elements as such if dropRoots = false is specified. The operation is intermediate and stateless.

fun <T> Sequence<T>.dynamicTraversal(revisit: Boolean = false, dropRoots: Boolean = true, traversalAlgorithm: TraversalAlgorithmOption = TraversalAlgorithmOption.BreadthFirst, loadElements: (element: T) -> Sequence<T>): Sequence<T>

Returns a single sequence containing all elements loadElements recursively provides for the elements of the original sequence as well as the elements itself if dropRoots = false is specified. The operation is intermediate and stateless.

Link copied to clipboard
inline fun failIf(predicate: Boolean, errorMessage: () -> String)

Delegates to check but inverting the predicate, i.e. throws an IllegalStateException if predicate is true.

Link copied to clipboard
inline fun <T> forEachIn(arr1: Array<out T>, arr2: Array<out T>, action: (T) -> Unit)

Applies action to each entry in arr1 and in arr2.

inline fun <T> forEachIn(iterable1: Iterable<T>, iterable2: Iterable<T>, action: (T) -> Unit)

Applies action to each entry in iterable1 and in iterable2.

inline fun <T> forEachIn(sequence1: Sequence<T>, sequence2: Sequence<T>, action: (T) -> Unit)

Applies action to each entry in sequence1 and to each entry in sequence2.

inline fun <T> forEachIn(arr1: Array<out T>, arr2: Array<out T>, arr3: Array<out T>, action: (T) -> Unit)

Applies action to each entry in arr1, arr2 and in arr3.

inline fun <T> forEachIn(iterable1: Iterable<T>, iterable2: Iterable<T>, iterable3: Iterable<T>, action: (T) -> Unit)

Applies action to each entry in iterable1, iterable2 and in iterable3.

inline fun <T> forEachIn(sequence1: Sequence<T>, sequence2: Sequence<T>, sequence3: Sequence<T>, action: (T) -> Unit)

Applies action to each entry in sequence1, sequence2 and in sequence3.

inline fun <T> forEachIn(arr1: Array<out T>, arr2: Array<out T>, arr3: Array<out T>, vararg arrays: Array<out T>, action: (T) -> Unit)

Applies action to each entry in arr1, arr2, arr3 and to each entry of Array in arrays.

inline fun <T> forEachIn(iterable1: Iterable<T>, iterable2: Iterable<T>, iterable3: Iterable<T>, vararg iterables: Iterable<T>, action: (T) -> Unit)

Applies action to each entry in iterable1, iterable2, iterable3 and to each entry of Iterable in iterables.

inline fun <T> forEachIn(sequence1: Sequence<T>, sequence2: Sequence<T>, sequence3: Sequence<T>, vararg sequences: Sequence<T>, action: (T) -> Unit)

Applies action to each entry in sequence1, sequence2, sequence3 and to each entry of Sequence in sequences.

Link copied to clipboard
inline fun <T> Iterator<T>.forEachRemaining(operation: (T) -> Unit)

Performs the given operation on each remaining element.

Link copied to clipboard
inline fun <E> forElementAndForEachIn(element: E, arr: Array<out E>, action: (E) -> Unit)

Applies action to this and to each entry in arr.

inline fun <E> forElementAndForEachIn(element: E, iterable: Iterable<E>, action: (E) -> Unit)

Applies action to this and to each entry in iterable.

inline fun <E> forElementAndForEachIn(element: E, sequence: Sequence<E>, action: (E) -> Unit)

Applies action to this and to each entry in sequence.

inline fun <E> forElementAndForEachIn(element: E, arr1: Array<out E>, arr2: Array<out E>, action: (E) -> Unit)

Applies action to this and to each entry in arr1 and in arr2.

inline fun <E> forElementAndForEachIn(element: E, iterable1: Iterable<E>, iterable2: Iterable<E>, action: (E) -> Unit)

Applies action to this and to each entry in iterable1 and in iterable2.

inline fun <E> forElementAndForEachIn(element: E, sequence1: Sequence<E>, sequence2: Sequence<E>, action: (E) -> Unit)

Applies action to this and to each entry in sequence1 and in sequence2.

inline fun <E> forElementAndForEachIn(element: E, arr1: Array<out E>, arr2: Array<out E>, vararg arrays: Array<out E>, action: (E) -> Unit)

Applies action to this and to each entry in arr1, arr2 and each entry of Iterable in arrays.

inline fun <E> forElementAndForEachIn(element: E, iterable1: Iterable<E>, iterable2: Iterable<E>, vararg iterables: Iterable<E>, action: (E) -> Unit)

Applies action to this and to each entry in iterable1, iterable2 and each entry of Iterable in iterables.

inline fun <E> forElementAndForEachIn(element: E, sequence1: Sequence<E>, sequence2: Sequence<E>, vararg sequences: Sequence<E>, action: (E) -> Unit)

Applies action to this and to each entry in sequence1, sequence2 and each entry of Sequence in sequences.

Link copied to clipboard
infix inline fun <T> T.glue(otherArgs: Array<out T>): List<T>

Delegates to varargToList -- adds this and the otherArgs into a new List and returns it.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple4<A1, A2, A3, A4>.glue(tuple4: Tuple4<A5, A6, A7, A8>): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Glues the given tuple4 to this Tuple4 and thus results in a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple4<A1, A2, A3, A4>.glue(tuple5: Tuple5<A5, A6, A7, A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given tuple5 to this Tuple4 and thus results in a Tuple9.

fun <A1, A2, A3, A4, A5, A6> Tuple4<A1, A2, A3, A4>.glue(pair: Pair<A5, A6>): Tuple6<A1, A2, A3, A4, A5, A6>

Glues the given pair to this Tuple4 and thus results in a Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple4<A1, A2, A3, A4>.glue(triple: Triple<A5, A6, A7>): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Glues the given triple to this Tuple4 and thus results in a Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple5<A1, A2, A3, A4, A5>.glue(tuple4: Tuple4<A6, A7, A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given tuple4 to this Tuple5 and thus results in a Tuple9.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple5<A1, A2, A3, A4, A5>.glue(pair: Pair<A6, A7>): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Glues the given pair to this Tuple5 and thus results in a Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple5<A1, A2, A3, A4, A5>.glue(triple: Triple<A6, A7, A8>): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Glues the given triple to this Tuple5 and thus results in a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple6<A1, A2, A3, A4, A5, A6>.glue(pair: Pair<A7, A8>): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Glues the given pair to this Tuple6 and thus results in a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple6<A1, A2, A3, A4, A5, A6>.glue(triple: Triple<A7, A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given triple to this Tuple6 and thus results in a Tuple9.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple7<A1, A2, A3, A4, A5, A6, A7>.glue(pair: Pair<A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given pair to this Tuple7 and thus results in a Tuple9.

fun <A1, A2, A3, A4, A5, A6> Pair<A1, A2>.glue(tuple4: Tuple4<A3, A4, A5, A6>): Tuple6<A1, A2, A3, A4, A5, A6>

Glues the given tuple4 to this Pair and thus results in a Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7> Pair<A1, A2>.glue(tuple5: Tuple5<A3, A4, A5, A6, A7>): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Glues the given tuple5 to this Pair and thus results in a Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Pair<A1, A2>.glue(tuple6: Tuple6<A3, A4, A5, A6, A7, A8>): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Glues the given tuple6 to this Pair and thus results in a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Pair<A1, A2>.glue(tuple7: Tuple7<A3, A4, A5, A6, A7, A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given tuple7 to this Pair and thus results in a Tuple9.

fun <A1, A2, A3, A4> Pair<A1, A2>.glue(pair: Pair<A3, A4>): Tuple4<A1, A2, A3, A4>

Glues the given pair to this Pair and thus results in a Tuple4.

fun <A1, A2, A3, A4, A5> Pair<A1, A2>.glue(triple: Triple<A3, A4, A5>): Tuple5<A1, A2, A3, A4, A5>

Glues the given triple to this Pair and thus results in a Tuple5.

fun <A1, A2, A3, A4, A5, A6, A7> Triple<A1, A2, A3>.glue(tuple4: Tuple4<A4, A5, A6, A7>): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Glues the given tuple4 to this Triple and thus results in a Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Triple<A1, A2, A3>.glue(tuple5: Tuple5<A4, A5, A6, A7, A8>): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Glues the given tuple5 to this Triple and thus results in a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Triple<A1, A2, A3>.glue(tuple6: Tuple6<A4, A5, A6, A7, A8, A9>): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Glues the given tuple6 to this Triple and thus results in a Tuple9.

fun <A1, A2, A3, A4, A5> Triple<A1, A2, A3>.glue(pair: Pair<A4, A5>): Tuple5<A1, A2, A3, A4, A5>

Glues the given pair to this Triple and thus results in a Tuple5.

fun <A1, A2, A3, A4, A5, A6> Triple<A1, A2, A3>.glue(triple: Triple<A4, A5, A6>): Tuple6<A1, A2, A3, A4, A5, A6>

Glues the given triple to this Triple and thus results in a Tuple6.

Link copied to clipboard
inline fun <T> identity(t: T): T

An identity function which inlines if possible.

Link copied to clipboard
inline fun <T : Collection<*>, SuperTypeOfT, SuperTypeOfT : Iterable<*>> T.ifNotEmpty(transformation: (T) -> SuperTypeOfT): SuperTypeOfT

Checks if this collection is empty and if not applies the given transformation.

Link copied to clipboard
inline fun <E, R> Array<E>.ifWithinBound(index: Int, thenBlock: () -> R, elseBlock: () -> R): R
inline fun <E, R> List<E>.ifWithinBound(index: Int, thenBlock: () -> R, elseBlock: () -> R): R

Checks if the given index is within the bound of this List (index<List.size) and correspondingly executes the thenBlock or the elseBlock.

Link copied to clipboard

Returns true if this CharSequence is neither null nor blank.

Link copied to clipboard

Returns true if this CharSequence is neither null nor empty.

Link copied to clipboard
inline fun <T> Array<T>.joinToString(separator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this list by calling append and separates the elements with the given separator.

inline fun <T> Iterable<T>.joinToString(separator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this Iterable by calling append and separates the elements with the given separator.

inline fun <T> List<T>.joinToString(separator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this List by calling append and separates the elements with the given separator.

inline fun <T> Sequence<T>.joinToString(separator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this Sequence by calling append and separates the elements with the given separator.

inline fun <T> Array<T>.joinToString(separator: String, lastSeparator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this list by calling append and separates the elements with the given separator whereas lastSeparator is used to separate the last and the second last element.

inline fun <T> List<T>.joinToString(separator: String, lastSeparator: String, append: (it: T, sb: StringBuilder) -> Unit): String

Joins all elements of this List by calling append and separates the elements with the given separator whereas lastSeparator is used to separate the last and the second last element.

Link copied to clipboard
fun <A1, A2, A3, A4, A1New> Tuple4<A1, A2, A3, A4>.mapA1(transform: (A1) -> A1New): Tuple4<A1New, A2, A3, A4>

Maps Tuple4.a1 with the given transform function and returns a new Tuple4.

fun <A1, A2, A3, A4, A5, A1New> Tuple5<A1, A2, A3, A4, A5>.mapA1(transform: (A1) -> A1New): Tuple5<A1New, A2, A3, A4, A5>

Maps Tuple5.a1 with the given transform function and returns a new Tuple5.

fun <A1, A2, A3, A4, A5, A6, A1New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA1(transform: (A1) -> A1New): Tuple6<A1New, A2, A3, A4, A5, A6>

Maps Tuple6.a1 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A1New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA1(transform: (A1) -> A1New): Tuple7<A1New, A2, A3, A4, A5, A6, A7>

Maps Tuple7.a1 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A1New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA1(transform: (A1) -> A1New): Tuple8<A1New, A2, A3, A4, A5, A6, A7, A8>

Maps Tuple8.a1 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A1New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA1(transform: (A1) -> A1New): Tuple9<A1New, A2, A3, A4, A5, A6, A7, A8, A9>

Maps Tuple9.a1 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A2New> Tuple4<A1, A2, A3, A4>.mapA2(transform: (A2) -> A2New): Tuple4<A1, A2New, A3, A4>

Maps Tuple4.a2 with the given transform function and returns a new Tuple4.

fun <A1, A2, A3, A4, A5, A2New> Tuple5<A1, A2, A3, A4, A5>.mapA2(transform: (A2) -> A2New): Tuple5<A1, A2New, A3, A4, A5>

Maps Tuple5.a2 with the given transform function and returns a new Tuple5.

fun <A1, A2, A3, A4, A5, A6, A2New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA2(transform: (A2) -> A2New): Tuple6<A1, A2New, A3, A4, A5, A6>

Maps Tuple6.a2 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A2New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA2(transform: (A2) -> A2New): Tuple7<A1, A2New, A3, A4, A5, A6, A7>

Maps Tuple7.a2 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A2New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA2(transform: (A2) -> A2New): Tuple8<A1, A2New, A3, A4, A5, A6, A7, A8>

Maps Tuple8.a2 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A2New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA2(transform: (A2) -> A2New): Tuple9<A1, A2New, A3, A4, A5, A6, A7, A8, A9>

Maps Tuple9.a2 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A3New> Tuple4<A1, A2, A3, A4>.mapA3(transform: (A3) -> A3New): Tuple4<A1, A2, A3New, A4>

Maps Tuple4.a3 with the given transform function and returns a new Tuple4.

fun <A1, A2, A3, A4, A5, A3New> Tuple5<A1, A2, A3, A4, A5>.mapA3(transform: (A3) -> A3New): Tuple5<A1, A2, A3New, A4, A5>

Maps Tuple5.a3 with the given transform function and returns a new Tuple5.

fun <A1, A2, A3, A4, A5, A6, A3New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA3(transform: (A3) -> A3New): Tuple6<A1, A2, A3New, A4, A5, A6>

Maps Tuple6.a3 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A3New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA3(transform: (A3) -> A3New): Tuple7<A1, A2, A3New, A4, A5, A6, A7>

Maps Tuple7.a3 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A3New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA3(transform: (A3) -> A3New): Tuple8<A1, A2, A3New, A4, A5, A6, A7, A8>

Maps Tuple8.a3 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A3New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA3(transform: (A3) -> A3New): Tuple9<A1, A2, A3New, A4, A5, A6, A7, A8, A9>

Maps Tuple9.a3 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A4New> Tuple4<A1, A2, A3, A4>.mapA4(transform: (A4) -> A4New): Tuple4<A1, A2, A3, A4New>

Maps Tuple4.a4 with the given transform function and returns a new Tuple4.

fun <A1, A2, A3, A4, A5, A4New> Tuple5<A1, A2, A3, A4, A5>.mapA4(transform: (A4) -> A4New): Tuple5<A1, A2, A3, A4New, A5>

Maps Tuple5.a4 with the given transform function and returns a new Tuple5.

fun <A1, A2, A3, A4, A5, A6, A4New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA4(transform: (A4) -> A4New): Tuple6<A1, A2, A3, A4New, A5, A6>

Maps Tuple6.a4 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A4New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA4(transform: (A4) -> A4New): Tuple7<A1, A2, A3, A4New, A5, A6, A7>

Maps Tuple7.a4 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A4New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA4(transform: (A4) -> A4New): Tuple8<A1, A2, A3, A4New, A5, A6, A7, A8>

Maps Tuple8.a4 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A4New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA4(transform: (A4) -> A4New): Tuple9<A1, A2, A3, A4New, A5, A6, A7, A8, A9>

Maps Tuple9.a4 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A5, A5New> Tuple5<A1, A2, A3, A4, A5>.mapA5(transform: (A5) -> A5New): Tuple5<A1, A2, A3, A4, A5New>

Maps Tuple5.a5 with the given transform function and returns a new Tuple5.

fun <A1, A2, A3, A4, A5, A6, A5New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA5(transform: (A5) -> A5New): Tuple6<A1, A2, A3, A4, A5New, A6>

Maps Tuple6.a5 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A5New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA5(transform: (A5) -> A5New): Tuple7<A1, A2, A3, A4, A5New, A6, A7>

Maps Tuple7.a5 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A5New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA5(transform: (A5) -> A5New): Tuple8<A1, A2, A3, A4, A5New, A6, A7, A8>

Maps Tuple8.a5 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A5New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA5(transform: (A5) -> A5New): Tuple9<A1, A2, A3, A4, A5New, A6, A7, A8, A9>

Maps Tuple9.a5 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A5, A6, A6New> Tuple6<A1, A2, A3, A4, A5, A6>.mapA6(transform: (A6) -> A6New): Tuple6<A1, A2, A3, A4, A5, A6New>

Maps Tuple6.a6 with the given transform function and returns a new Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7, A6New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA6(transform: (A6) -> A6New): Tuple7<A1, A2, A3, A4, A5, A6New, A7>

Maps Tuple7.a6 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A6New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA6(transform: (A6) -> A6New): Tuple8<A1, A2, A3, A4, A5, A6New, A7, A8>

Maps Tuple8.a6 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A6New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA6(transform: (A6) -> A6New): Tuple9<A1, A2, A3, A4, A5, A6New, A7, A8, A9>

Maps Tuple9.a6 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A5, A6, A7, A7New> Tuple7<A1, A2, A3, A4, A5, A6, A7>.mapA7(transform: (A7) -> A7New): Tuple7<A1, A2, A3, A4, A5, A6, A7New>

Maps Tuple7.a7 with the given transform function and returns a new Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A7New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA7(transform: (A7) -> A7New): Tuple8<A1, A2, A3, A4, A5, A6, A7New, A8>

Maps Tuple8.a7 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A7New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA7(transform: (A7) -> A7New): Tuple9<A1, A2, A3, A4, A5, A6, A7New, A8, A9>

Maps Tuple9.a7 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A5, A6, A7, A8, A8New> Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>.mapA8(transform: (A8) -> A8New): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8New>

Maps Tuple8.a8 with the given transform function and returns a new Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A8New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA8(transform: (A8) -> A8New): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8New, A9>

Maps Tuple9.a8 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A3, A4, A5, A6, A7, A8, A9, A9New> Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>.mapA9(transform: (A9) -> A9New): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9New>

Maps Tuple9.a9 with the given transform function and returns a new Tuple9.

Link copied to clipboard
fun <A1, A2, A1New> Pair<A1, A2>.mapFirst(transform: (A1) -> A1New): Pair<A1New, A2>

Maps Pair.first with the given transform function and returns a new Pair.

fun <A1, A2, A3, A1New> Triple<A1, A2, A3>.mapFirst(transform: (A1) -> A1New): Triple<A1New, A2, A3>

Maps Triple.first with the given transform function and returns a new Triple.

Link copied to clipboard
fun <T> Map<T, T>.mapParents(child: T, failIfCyclic: Boolean = false): LinkedHashSet<T>

It is assumed that the Map represents a child parent relation where this function returns a LinkedHashSet with all collected parents.

Link copied to clipboard
fun <T, R> Iterator<T>.mapRemaining(transform: (T) -> R): List<R>

Maps remaining values of this Iterator with the help of the given transform functions, returns an empty list if Iterator.hasNext returns false for the first call.

Link copied to clipboard
fun <T, R> Iterator<T>.mapRemainingWithCounter(transform: (index: Int, T) -> R): List<R>

Maps remaining values of this Iterator with the help of the given transform functions where a counter variable is passed ot the transform function starting by 0; returns an empty list if Iterator.hasNext returns false for the first call.

Link copied to clipboard
fun <A1, A2, A2New> Pair<A1, A2>.mapSecond(transform: (A2) -> A2New): Pair<A1, A2New>

Maps Pair.second with the given transform function and returns a new Pair.

fun <A1, A2, A3, A2New> Triple<A1, A2, A3>.mapSecond(transform: (A2) -> A2New): Triple<A1, A2New, A3>

Maps Triple.second with the given transform function and returns a new Triple.

Link copied to clipboard
fun <A1, A2, A3, A3New> Triple<A1, A2, A3>.mapThird(transform: (A3) -> A3New): Triple<A1, A2, A3New>

Maps Triple.third with the given transform function and returns a new Triple.

Link copied to clipboard
inline fun <R> takeIf(predicate: Boolean, provider: () -> R): R?

Calls the provider only if the predicate holds, returns null otherwise.

Link copied to clipboard

Wraps this Iterator into a PeekingIterator and returns it.

Link copied to clipboard
fun <A1, A2> Tuple(a1: A1, a2: A2): Pair<A1, A2>

Factory method to create a Pair.

fun <A1, A2, A3> Tuple(a1: A1, a2: A2, a3: A3): Triple<A1, A2, A3>

Factory method to create a Triple.

fun <A1, A2, A3, A4> Tuple(a1: A1, a2: A2, a3: A3, a4: A4): Tuple4<A1, A2, A3, A4>

Factory method to create a Tuple4.

fun <A1, A2, A3, A4, A5> Tuple(a1: A1, a2: A2, a3: A3, a4: A4, a5: A5): Tuple5<A1, A2, A3, A4, A5>

Factory method to create a Tuple5.

fun <A1, A2, A3, A4, A5, A6> Tuple(a1: A1, a2: A2, a3: A3, a4: A4, a5: A5, a6: A6): Tuple6<A1, A2, A3, A4, A5, A6>

Factory method to create a Tuple6.

fun <A1, A2, A3, A4, A5, A6, A7> Tuple(a1: A1, a2: A2, a3: A3, a4: A4, a5: A5, a6: A6, a7: A7): Tuple7<A1, A2, A3, A4, A5, A6, A7>

Factory method to create a Tuple7.

fun <A1, A2, A3, A4, A5, A6, A7, A8> Tuple(a1: A1, a2: A2, a3: A3, a4: A4, a5: A5, a6: A6, a7: A7, a8: A8): Tuple8<A1, A2, A3, A4, A5, A6, A7, A8>

Factory method to create a Tuple8.

fun <A1, A2, A3, A4, A5, A6, A7, A8, A9> Tuple(a1: A1, a2: A2, a3: A3, a4: A4, a5: A5, a6: A6, a7: A7, a8: A8, a9: A9): Tuple9<A1, A2, A3, A4, A5, A6, A7, A8, A9>

Factory method to create a Tuple9.

Link copied to clipboard
fun <T> varargToList(arg: T, otherArgs: Array<out T>): List<T>

Adds the given arg and the otherArgs into a new List and returns it.