Uses of Interface
org.eclipse.xtext.xbase.lib.Functions.Function1
Packages that use Functions.Function1
-
Uses of Functions.Function1 in org.eclipse.xtext.xbase.lib
Methods in org.eclipse.xtext.xbase.lib that return Functions.Function1Modifier and TypeMethodDescriptionstatic <V,T, R> Functions.Function1<V, R> FunctionExtensions.andThen(Functions.Function1<? super V, ? extends T> before, Functions.Function1<? super T, ? extends R> after) Returns a composed function that first applies thebeforefunction to its input, and then applies theafterfunction to the result.static <V,T, R> Functions.Function1<V, R> FunctionExtensions.compose(Functions.Function1<? super T, ? extends R> after, Functions.Function1<? super V, ? extends T> before) Returns a composed function that first applies thebeforefunction to its input, and then applies theafterfunction to the result.static <P1,P2, RESULT>
Functions.Function1<P2,RESULT> FunctionExtensions.curry(Functions.Function2<? super P1, ? super P2, ? extends RESULT> function, P1 argument) Curries a function that takes two arguments.Methods in org.eclipse.xtext.xbase.lib with parameters of type Functions.Function1Modifier and TypeMethodDescriptionstatic <V,T, R> Functions.Function1<V, R> FunctionExtensions.andThen(Functions.Function1<? super V, ? extends T> before, Functions.Function1<? super T, ? extends R> after) Returns a composed function that first applies thebeforefunction to its input, and then applies theafterfunction to the result.static <V1,V2, T, R>
Functions.Function2<V1,V2, R> FunctionExtensions.andThen(Functions.Function2<? super V1, ? super V2, ? extends T> before, Functions.Function1<? super T, ? extends R> after) Returns a composed function that first applies thebeforefunction to its input, and then applies theafterfunction to the result.static <V,T, R> Functions.Function1<V, R> FunctionExtensions.compose(Functions.Function1<? super T, ? extends R> after, Functions.Function1<? super V, ? extends T> before) Returns a composed function that first applies thebeforefunction to its input, and then applies theafterfunction to the result.static <P1,RESULT>
Functions.Function0<RESULT>FunctionExtensions.curry(Functions.Function1<? super P1, ? extends RESULT> function, P1 argument) Curries a function that takes one argument.static <T> Iterable<T>IterableExtensions.dropWhile(Iterable<? extends T> iterable, Functions.Function1<? super T, Boolean> predicate) Returns an Iterable containing all elements starting from the first element for which the drop-predicate returned false.static <T> Iterator<T>IteratorExtensions.dropWhile(Iterator<? extends T> iterator, Functions.Function1<? super T, Boolean> predicate) Returns an Iterator containing all elements starting from the first element for which the drop-predicate returned false.static <T> booleanIterableExtensions.exists(Iterable<T> iterable, Functions.Function1<? super T, Boolean> predicate) Returnstrueif one or more elements initerablesatisfy the predicate.static <T> booleanIteratorExtensions.exists(Iterator<T> iterator, Functions.Function1<? super T, Boolean> predicate) Returnstrueif one or more elements initeratorsatisfy the predicate.static <T> Iterable<T>IterableExtensions.filter(Iterable<T> unfiltered, Functions.Function1<? super T, Boolean> predicate) Returns the elements ofunfilteredthat satisfy a predicate.static <T> Iterator<T>IteratorExtensions.filter(Iterator<T> unfiltered, Functions.Function1<? super T, Boolean> predicate) Returns the elements ofunfilteredthat satisfy a predicate.static <T> TIterableExtensions.findFirst(Iterable<T> iterable, Functions.Function1<? super T, Boolean> predicate) Finds the first element in the given iterable that fulfills the predicate.static <T> TIteratorExtensions.findFirst(Iterator<T> iterator, Functions.Function1<? super T, Boolean> predicate) Finds the first element in the given iterator that fulfills the predicate.static <T> TIterableExtensions.findLast(Iterable<T> iterable, Functions.Function1<? super T, Boolean> predicate) Finds the last element in the given iterable that fulfills the predicate.static <T> TIteratorExtensions.findLast(Iterator<T> iterator, Functions.Function1<? super T, Boolean> predicate) Finds the last element in the given iterator that fulfills the predicate.static <T,R> Iterable<R> IterableExtensions.flatMap(Iterable<T> original, Functions.Function1<? super T, ? extends Iterable<R>> transformation) Returns an iterable that performs the giventransformationfor each element oforiginalwhen requested.static <T,R> Iterator<R> IteratorExtensions.flatMap(Iterator<T> original, Functions.Function1<? super T, ? extends Iterator<R>> transformation) Returns an iterable that performs the giventransformationfor each element oforiginalwhen requested.static <T> booleanIterableExtensions.forall(Iterable<T> iterable, Functions.Function1<? super T, Boolean> predicate) Returnstrueif every element initerablesatisfies the predicate.static <T> booleanIteratorExtensions.forall(Iterator<T> iterator, Functions.Function1<? super T, Boolean> predicate) Returnstrueif every element initeratorsatisfies the predicate.IterableExtensions.groupBy(Iterable<? extends V> values, Functions.Function1<? super V, ? extends K> computeKeys) Returns a map for which theMap.values()is a collection of lists, where the elements in the list will appear in the order as they appeared in the iterable.IteratorExtensions.groupBy(Iterator<? extends V> values, Functions.Function1<? super V, ? extends K> computeKeys) Returns a map for which theMap.values()is a collection of lists, where the elements in the list will appear in the order as they appeared in the iterator.static <T> StringIterableExtensions.join(Iterable<T> iterable, CharSequence before, CharSequence separator, CharSequence after, Functions.Function1<? super T, ? extends CharSequence> function) Returns the concatenated string representation of the elements in the given iterable.static <T> StringIterableExtensions.join(Iterable<T> iterable, CharSequence separator, Functions.Function1<? super T, ? extends CharSequence> function) Returns the concatenated string representation of the elements in the given iterable.static <T> StringIteratorExtensions.join(Iterator<T> iterator, CharSequence before, CharSequence separator, CharSequence after, Functions.Function1<? super T, ? extends CharSequence> function) Returns the concatenated string representation of the elements in the given iterator.static <T> StringIteratorExtensions.join(Iterator<T> iterator, CharSequence separator, Functions.Function1<? super T, ? extends CharSequence> function) Returns the concatenated string representation of the elements in the given iterator.static <T,R> Iterable<R> IterableExtensions.map(Iterable<T> original, Functions.Function1<? super T, ? extends R> transformation) Returns an iterable that performs the giventransformationfor each element oforiginalwhen requested.static <T,R> Iterator<R> IteratorExtensions.map(Iterator<T> original, Functions.Function1<? super T, ? extends R> transformation) Returns an iterator that performs the giventransformationfor each element oforiginalwhen requested.static <T,R> List<R> ListExtensions.map(List<T> original, Functions.Function1<? super T, ? extends R> transformation) Returns a list that performs the giventransformationfor each element oforiginalwhen requested.static <K,V1, V2> Map<K, V2> MapExtensions.mapValues(Map<K, V1> original, Functions.Function1<? super V1, ? extends V2> transformation) Returns a map that performs the giventransformationfor each value oforiginalwhen requested.static <T,C extends Comparable<? super C>>
TIterableExtensions.maxBy(Iterable<T> iterable, Functions.Function1<? super T, C> compareBy) Finds the element that yields the maximum value when passed tocompareByIf there are several maxima, the first one will be returned.static <T,C extends Comparable<? super C>>
TIteratorExtensions.maxBy(Iterator<T> iterator, Functions.Function1<? super T, C> compareBy) Finds the element that yields the maximum value when passed tocompareByIf there are several maxima, the first one will be returned.static <T,C extends Comparable<? super C>>
TIterableExtensions.minBy(Iterable<T> iterable, Functions.Function1<? super T, C> compareBy) Finds the element that yields the minimum value when passed tocompareBy.static <T,C extends Comparable<? super C>>
TIteratorExtensions.minBy(Iterator<T> iterator, Functions.Function1<? super T, C> compareBy) Finds the element that yields the minimum value when passed tocompareBy.static <T> Iterable<T>IterableExtensions.reject(Iterable<T> unfiltered, Functions.Function1<? super T, Boolean> predicate) Returns the elements ofunfilteredthat do not satisfy a predicate.static <T> Iterator<T>IteratorExtensions.reject(Iterator<T> unfiltered, Functions.Function1<? super T, Boolean> predicate) Returns the elements ofunfilteredthat do not satisfy a predicate.static <T,C extends Comparable<? super C>>
List<T>IterableExtensions.sortBy(Iterable<T> iterable, Functions.Function1<? super T, C> key) Creates a sorted list that contains the items of the given iterable.static <T,C extends Comparable<? super C>>
List<T>ListExtensions.sortInplaceBy(List<T> list, Functions.Function1<? super T, C> key) Sorts the specified list itself according to the order induced by applying a key function to each element which yields a comparable criteria.static <T> Iterable<T>IterableExtensions.takeWhile(Iterable<? extends T> iterable, Functions.Function1<? super T, Boolean> predicate) Returns an Iterable containing all elements starting from the head of the source up to and excluding the first element that violates the predicate The resulting Iterable is a lazily computed view, so any modifications to the underlying Iterables will be reflected on subsequent iterations.static <T> Iterator<T>IteratorExtensions.takeWhile(Iterator<? extends T> iterator, Functions.Function1<? super T, Boolean> predicate) Returns an Iterator containing all elements starting from the head of the source up to and excluding the first element that violates the predicate.static <K,V> Map<K, V> IterableExtensions.toInvertedMap(Iterable<? extends K> keys, Functions.Function1<? super K, V> computeValues) Returns a map for which theMap.values()are computed by the given function, and each key is an element in the givenkeys.static <K,V> Map<K, V> IteratorExtensions.toInvertedMap(Iterator<? extends K> keys, Functions.Function1<? super K, V> computeValues) Returns a map for which theMap.values()are computed by the given function, and each key is an element in the givenkeys.static <T,K, V> Map<K, V> IterableExtensions.toMap(Iterable<? extends T> inputs, Functions.Function1<? super T, K> computeKeys, Functions.Function1<? super T, V> computeValues) Returns a map for which theMap.values()are the product of invoking supplied functioncomputeValueson input iterable elements, and each key is the product of invoking a supplied functioncomputeKeyson same elements.static <K,V> Map<K, V> IterableExtensions.toMap(Iterable<? extends V> values, Functions.Function1<? super V, K> computeKeys) Returns a map for which theMap.values()are the given elements in the given order, and each key is the product of invoking a supplied functioncomputeKeyson its corresponding value.static <T,K, V> Map<K, V> IteratorExtensions.toMap(Iterator<? extends T> inputs, Functions.Function1<? super T, K> computeKeys, Functions.Function1<? super T, V> computeValues) Returns a map for which theMap.values()are the product of invoking supplied functioncomputeValueson input iterable elements, and each key is the product of invoking a supplied functioncomputeKeyson same elements.static <K,V> Map<K, V> IteratorExtensions.toMap(Iterator<? extends V> values, Functions.Function1<? super V, K> computeKeys) Returns a map for which theMap.values()are the given elements in the given order, and each key is the product of invoking a supplied functioncomputeKeyson its corresponding value. -
Uses of Functions.Function1 in org.eclipse.xtext.xbase.lib.internal
Constructors in org.eclipse.xtext.xbase.lib.internal with parameters of type Functions.Function1ModifierConstructorDescriptionBooleanFunctionDelegate(Functions.Function1<? super T, Boolean> delegate) Creates a newBooleanFunctionDelegatethat wraps the given delegate function.FunctionDelegate(Functions.Function1<? super P, ? extends R> delegate) Creates a newFunctionDelegatethat wraps the given delegate function.KeyComparator(Functions.Function1<? super T, C> keyFunction)