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

io.github.mike10004.vhs.ReplaySessionState Maven / Gradle / Ivy

There is a newer version: 0.32
Show newest version
package io.github.mike10004.vhs;

import io.github.mike10004.vhs.harbridge.ParsedRequest;

public interface ReplaySessionState {
    static ReplaySessionState stateless() {
        return new ReplaySessionState() {
            @Override
            public void register(ParsedRequest r) {
            }

            @Override
            public int query(ParsedRequest request) {
                return 0;
            }

            @Override
            public String toString() {
                return String.format("ReplaySessionState{STATELESS}@%08x", System.identityHashCode(this));
            }
        };
    }

    void register(ParsedRequest request);

    int query(ParsedRequest request);

    static ReplaySessionState countingUrlMethodPairs() {
        return new BasicRequestTrackingState();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy