001package squidpony.squidmath;
002
003/**
004 * A simple interface for RandomnessSources that have the additional property of a state that can be re-set.
005 * Created by Tommy Ettinger on 9/15/2015.
006 */
007public interface StatefulRandomness extends RandomnessSource {
008    /**
009     * Get the current internal state of the StatefulRandomness as a long.
010     * @return the current internal state of this object.
011     */
012    long getState();
013
014    /**
015     * Set the current internal state of this StatefulRandomness with a long.
016     *
017     * @param state a 64-bit long. You should avoid passing 0, even though some implementations can handle that.
018     */
019    void setState(long state);
020}