package cz.moneta.test.dsl.openapi;

import cz.moneta.test.dsl.Harness;
import cz.moneta.test.harness.endpoints.openapi.OpenApiEndpoint;
import cz.moneta.test.harness.support.rest.Builders;
import cz.moneta.test.harness.support.rest.RestRequest;

public abstract class OpenApiBaseBuilder {

    protected final Harness harness;

    public OpenApiBaseBuilder(Harness harness) {
        this.harness = harness;
    }

    protected <RESP, B extends RestRequest<B, ?, RESP>> B getBuilder(Class<B> builderClass) {
        return Builders.newRestBuilder(builderClass, OpenApiEndpoint.class, harness);
    }
}
