Skip to content

λ A pipeline for data transformations using Java 8 functional interfaces

License

Notifications You must be signed in to change notification settings

damonkelley/pipeline

Repository files navigation

Pipeline Build Status

The Pipeline is an attempt to bring the pipe operation from bash and many functional programming languages to Java. The Pipeline leverages functional interfaces and generics to allow one to pipe the output of a method as input to another method in a readable way.

Example
class MyClass {
    public MyClass withoutPipeline() {
        return baz(bar(foo(this)));
    }

    MyClass foo(MyClass myClass) {...}

    MyClass foo(MyClass myClass) {...}

    MyClass foo(MyClass myClass) {...}
}
With Pipeline
class MyClass {
    public MyClass withPipeline() {
        return Pipeline.with(1)
            .into(this::foo)
            .into(this::bar)
            .into(this::baz)
            .get();
    }
    // ...
}

About

λ A pipeline for data transformations using Java 8 functional interfaces

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages