Uses of Interface
com.gengoai.function.SerializableFunction
-
Packages that use SerializableFunction Package Description com.gengoai A set of utilities, frameworks, and tools to speed up and ease programming in Java.com.gengoai.cache Methods for creating and manage caches as well as auto-caching method calls.com.gengoai.collection Contains collections useful for Data Science and continence methods for creating, wrapping, writing, and reading of existing collection classes.com.gengoai.function Checked and Serializable versions of Java 8's functional elements.com.gengoai.io Classes for reading and writing to various different sources, e.g.com.gengoai.parsing com.gengoai.stream A unified stream interface that can work across Java and Spark streams.com.gengoai.stream.spark com.gengoai.string Functions, predicates, and utilities to create, format, parse, and manipulate strings. -
-
Uses of SerializableFunction in com.gengoai
Fields in com.gengoai declared as SerializableFunction Modifier and Type Field Description protected SerializableFunction<String,T>
Registry. newInstance
Constructors in com.gengoai with parameters of type SerializableFunction Constructor Description HierarchicalRegistry(SerializableFunction<String,T> newInstance, Class<T> owner)
Instantiates a new Hierarchical registry.HierarchicalRegistry(SerializableFunction<String,T> newInstance, Class<T> owner, String rootName)
Instantiates a new Registry.Registry(SerializableFunction<String,T> newInstance, Class<T> owner)
Instantiates a new Registry. -
Uses of SerializableFunction in com.gengoai.cache
Methods in com.gengoai.cache with parameters of type SerializableFunction Modifier and Type Method Description static <K,V>
Cache<K,V>Cache. create(int maxSize, @NonNull SerializableFunction<K,V> valueCalculator)
Creates an Auto Calculating LRU cache.Constructors in com.gengoai.cache with parameters of type SerializableFunction Constructor Description AutoCalculatingLRUCache(int maxSize, SerializableFunction<K,V> valueCalculator)
Instantiates a new Auto calculating lru cache. -
Uses of SerializableFunction in com.gengoai.collection
Methods in com.gengoai.collection with parameters of type SerializableFunction Modifier and Type Method Description static <I,O>
Iterable<O>Iterables. transform(@NonNull Iterable<? extends I> iterable, @NonNull SerializableFunction<? super I,? extends O> function)
Transforms the elements in the iterablestatic <I,O>
Iterator<O>Iterators. transform(Iterator<? extends I> iterator, SerializableFunction<? super I,? extends O> function)
Creates an iterator that transforms the elements of the iteratorstatic <I,O>
List<O>Lists. transform(@NonNull List<? extends I> list, @NonNull SerializableFunction<? super I,? extends O> converter)
Transforms the given list with the given functionstatic <E,R>
Set<R>Sets. transform(Set<? extends E> collection, SerializableFunction<? super E,R> transform)
Transforms a given collection using a supplied transform function returning the results as a set. -
Uses of SerializableFunction in com.gengoai.function
Classes in com.gengoai.function that implement SerializableFunction Modifier and Type Class Description static class
Funcs.When<I,O>
The type When.class
Switch<T>
The type Switch.Methods in com.gengoai.function that return SerializableFunction Modifier and Type Method Description default <F> SerializableFunction<T,F>
SerializableFunction. andThen(SerializableFunction<? super R,? extends F> function)
And then serializable function.default <R> SerializableFunction<T,R>
SerializableConsumer. asFunction()
As consumer serializable consumer.static <T,R>
SerializableFunction<T,R>SerializableConsumer. asFunction(SerializableConsumer<T> consumer)
static <T,R>
SerializableFunction<T,R>SerializableConsumer. asFunction(SerializableConsumer<T> consumer, R returnValue)
default <R> SerializableFunction<T,R>
SerializableConsumer. asFunction(R returnValue)
As consumer serializable consumer.default <V> SerializableFunction<V,R>
SerializableFunction. compose(SerializableFunction<? super V,? extends T> function)
Compose serializable function.static <T,R>
SerializableFunction<T,R>Unchecked. function(CheckedFunction<T,R> checked)
Generates a version of Function that will capture exceptions and rethrow them as runtime exceptionsstatic <T> SerializableFunction<T,T>
SerializableFunction. identity()
Identity serializable function.static <T,R>
SerializableFunction<T,R>SerializableFunction. literal(R returnValue)
SerializableFunction<I,O>
Funcs.When. otherwise(SerializableFunction<? super I,? extends O> falseAction)
Otherwise function.SerializableFunction<I,O>
Funcs.When. otherwise(O falseValue)
Otherwise function.Methods in com.gengoai.function with parameters of type SerializableFunction Modifier and Type Method Description default <F> SerializableFunction<T,F>
SerializableFunction. andThen(SerializableFunction<? super R,? extends F> function)
And then serializable function.static <T> SerializableConsumer<T>
SerializableFunction. asConsumer(SerializableFunction<T,?> function)
As consumer serializable consumer.default <V> SerializableFunction<V,R>
SerializableFunction. compose(SerializableFunction<? super V,? extends T> function)
Compose serializable function.static <T> SerializableConsumer<T>
Unchecked. consumer(CheckedConsumer<T> consumer, SerializableFunction<Throwable,Throwable> throwableHandler)
void
Switch.SwitchBuilder. defaultAction(@NonNull SerializableFunction<?,V> function)
Default action.<T> void
Switch.SwitchBuilder. equals(T value, @NonNull SerializableFunction<T,V> function)
Equals.static <T,R>
Function<T,R>Serialized. function(SerializableFunction<T,R> serialized)
Generates a serialized version of Function<T> void
Switch.SwitchBuilder. instanceOf(@NonNull Class<? super T> clazz, @NonNull SerializableFunction<T,V> function)
Instance of.<T> void
Switch.SwitchBuilder. isNull(@NonNull SerializableFunction<T,V> function)
Is null.SerializableFunction<I,O>
Funcs.When. otherwise(SerializableFunction<? super I,? extends O> falseAction)
Otherwise function.static <I,O>
Funcs.When<I,O>Funcs. when(SerializablePredicate<? super I> predicate, SerializableFunction<? super I,? extends O> trueAction)
When when.<T,R>
voidSwitch.SwitchBuilder. when(SerializablePredicate<? super T> predicate, @NonNull SerializableFunction<T,R> mapper, @NonNull SerializableFunction<R,V> function)
When.<T> void
Switch.SwitchBuilder. when(SerializablePredicate<? super T> predicate, @NonNull SerializableFunction<T,V> function)
When. -
Uses of SerializableFunction in com.gengoai.io
Methods in com.gengoai.io with parameters of type SerializableFunction Modifier and Type Method Description <R> List<R>
CSVReader. processRows(SerializableFunction<List<String>,Optional<R>> converter)
-
Uses of SerializableFunction in com.gengoai.parsing
Methods in com.gengoai.parsing with parameters of type SerializableFunction Modifier and Type Method Description static PrefixHandler
ValueExpression. handler(SerializableFunction<ParserToken,Object> converter)
Creates a generic handler which uses the givenSerializableFunction
to convert theParserToken
to a value. -
Uses of SerializableFunction in com.gengoai.stream
Methods in com.gengoai.stream with parameters of type SerializableFunction Modifier and Type Method Description <R> MStream<R>
MStream. flatMap(SerializableFunction<? super T,Stream<? extends R>> mapper)
Maps the objects in this stream to one or more new objects using the given function.<R,U>
MPairStream<R,U>MStream. flatMapToPair(SerializableFunction<? super T,Stream<? extends Map.Entry<? extends R,? extends U>>> function)
Maps the objects in this stream to one or more new key-value pairs using the given function.<U> MPairStream<U,Iterable<T>>
MStream. groupBy(SerializableFunction<? super T,? extends U> function)
Groups the items in the stream using the given function that maps objects to key values<R> MStream<R>
MStream. map(SerializableFunction<? super T,? extends R> function)
Maps the objects in the stream using the given function<R,U>
MPairStream<R,U>MStream. mapToPair(SerializableFunction<? super T,? extends Map.Entry<? extends R,? extends U>> function)
Maps the objects in this stream to a key-value pair using the given function.<R extends Comparable<R>>
MStream<T>MStream. sortBy(boolean ascending, SerializableFunction<? super T,? extends R> keyFunction)
Sorts the items in the stream in ascending or descending order using the given keyFunction to determine how to compare. -
Uses of SerializableFunction in com.gengoai.stream.spark
Methods in com.gengoai.stream.spark with parameters of type SerializableFunction Modifier and Type Method Description <R> SparkStream<R>
SparkStream. flatMap(SerializableFunction<? super T,Stream<? extends R>> mapper)
<R,U>
SparkPairStream<R,U>SparkStream. flatMapToPair(SerializableFunction<? super T,Stream<? extends Map.Entry<? extends R,? extends U>>> function)
<U> SparkPairStream<U,Iterable<T>>
SparkStream. groupBy(SerializableFunction<? super T,? extends U> function)
<R> SparkStream<R>
SparkStream. map(SerializableFunction<? super T,? extends R> function)
<R> SparkStream<R>
SparkStream. mapPartitions(SerializableFunction<Iterator<? super T>,Stream<R>> function)
Maps the objects in the stream by block using the given function<R,U>
SparkPairStream<R,U>SparkStream. mapToPair(SerializableFunction<? super T,? extends Map.Entry<? extends R,? extends U>> function)
<R extends Comparable<R>>
MStream<T>SparkStream. sortBy(boolean ascending, SerializableFunction<? super T,? extends R> keyFunction)
-
Uses of SerializableFunction in com.gengoai.string
Classes in com.gengoai.string that implement SerializableFunction Modifier and Type Class Description class
StringFunctions
Commonly used string transforms asSerializableFunction
Methods in com.gengoai.string that return SerializableFunction Modifier and Type Method Description static SerializableFunction<String,String>
StringFunctions. REGEX_REPLACE(String pattern, String replacement)
Creates a function that performs a regular expression replacement on a stringstatic SerializableFunction<String,String>
StringFunctions. REGEX_REPLACE(Pattern pattern, String replacement)
Creates a function that performs a regular expression replacement on a string
-