![JAR search and dependency download from the Maven repository](/logo.png)
functionalj.stream.LongStreamProcessor Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of functionalj-core Show documentation
Show all versions of functionalj-core Show documentation
Brining functional goodies to Java: functionalj-core
package functionalj.stream;
import static functionalj.lens.Access.theLong;
import java.util.function.ToLongFunction;
import lombok.val;
public interface LongStreamProcessor {
public TARGET process(LongStreamPlus stream);
default StreamProcessor ofLong() {
return of(theLong);
}
default StreamProcessor of(ToLongFunction mapper) {
return new StreamProcessor() {
@Override
public TARGET process(StreamPlus stream) {
val dataStream = stream.mapToLong(mapper);
val target = LongStreamProcessor.this.process(dataStream);
return target;
}
};
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy