
com.github.rutledgepaulv.rqe.utils.StreamUtil Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of rest-query-engine Show documentation
Show all versions of rest-query-engine Show documentation
A library for parsing rsql queries into database queries for a REST API.
The newest version!
/*
* com.github.rutledgepaulv.rqe.utils.StreamUtil
* *
* * Copyright (C) 2016 Paul Rutledge
* *
* * This software may be modified and distributed under the terms
* * of the MIT license. See the LICENSE file for details.
*
*/
package com.github.rutledgepaulv.rqe.utils;
import java.util.Iterator;
import java.util.stream.Stream;
import java.util.stream.StreamSupport;
public class StreamUtil {
public static Stream fromIterator(Iterator iter) {
Iterable iterable = () -> iter;
return StreamSupport.stream(iterable.spliterator(), false);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy