import "copyrightAndOthers.stg"
import "primitiveLiteral.stg"

targetPath() ::= "org/eclipse/collections/api"

fileName(primitive) ::= "Lazy<primitive.name>Iterable"

class(primitive) ::= <<
<body(primitive.type, primitive.name)>
>>

collectPrimitive(fromName, fromType, toName, toType) ::= <<

/**
 * @since 7.0
 */
Lazy<toName>Iterable collect<toName>(<fromName>To<toName>Function function);
>>

body(type, name) ::= <<
<copyrightAndOthers()>

package org.eclipse.collections.api;

import org.eclipse.collections.api.block.function.primitive.<name>ToBooleanFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToByteFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToCharFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToDoubleFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToFloatFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToIntFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToLongFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToObjectFunction;
import org.eclipse.collections.api.block.function.primitive.<name>ToShortFunction;
import org.eclipse.collections.api.block.predicate.primitive.<name>Predicate;
import org.eclipse.collections.api.block.procedure.primitive.<name>Procedure;

/**
 * This file was automatically generated from template file lazyPrimitiveIterable.stg.
 */
public interface Lazy<name>Iterable extends <name>Iterable
{
    /**
     * @since 9.0.
     */
    @Override
    Lazy<name>Iterable tap(<name>Procedure procedure);

    @Override
    Lazy<name>Iterable select(<name>Predicate predicate);

    @Override
    Lazy<name>Iterable reject(<name>Predicate predicate);

    @Override
    \<V> LazyIterable\<V> collect(<name>ToObjectFunction\<? extends V> function);

    /**
     * @since 9.0
     */
    \<V> LazyIterable\<V> flatCollect(<name>ToObjectFunction\<? extends Iterable\<V>\> function);

    <collectPrimitive(name, type, "Boolean", "boolean")>

    <collectPrimitive(name, type, "Byte", "byte")>

    <collectPrimitive(name, type, "Char", "char")>

    <collectPrimitive(name, type, "Short", "short")>

    <collectPrimitive(name, type, "Int", "int")>

    <collectPrimitive(name, type, "Float", "float")>

    <collectPrimitive(name, type, "Long", "long")>

    <collectPrimitive(name, type, "Double", "double")>
}

>>
