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

io.github.kosmx.bendylib.impl.IterableRePos Maven / Gradle / Ivy

The newest version!
package io.github.kosmx.bendylib.impl;

import java.util.function.Consumer;

/**
 * Anything what can iterate on its positions
 * for {@link IBendable}
 * transform method doesn't create a new matrix for every position
 */
@FunctionalInterface
public interface IterableRePos {

    /**
     * Call consumer to every position
     * @param consumer do consumer.accept(pos)
     */
    void iteratePositions(Consumer consumer);
    /* do something like
    {
        for(IPosWithOrigin pos:this.positions) {
            consumer.accept(pos);
        }
    }
     */
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy