All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.vanillabp.springboot.utils.MutableStream Maven / Gradle / Ivy

package io.vanillabp.springboot.utils;

import java.util.function.Function;
import java.util.stream.Stream;

public class MutableStream {
    
    private Stream stream;

    private MutableStream(
            final Stream stream) {
        
        this.stream = stream;
        
    }
    
    public static final  MutableStream from(
            final Stream stream) {
        
        return new MutableStream(stream);
        
    }

    public Stream getStream() {
        return stream;
    }
    
    public void apply(
            Function, Stream> action) {
        
        this.stream = action.apply(stream);
        
    }
    
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy