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

com.github.mike10004.seleniumhelp.WebdrivingConfigs Maven / Gradle / Ivy

There is a newer version: 0.58
Show newest version
package com.github.mike10004.seleniumhelp;

import com.browserup.bup.mitm.CertificateAndKeySource;

import javax.annotation.Nullable;

class WebdrivingConfigs {

    private WebdrivingConfigs() {}

    private static final WebdrivingConfig EMPTY = new WebdrivingConfig() {

        @Override
        public WebdrivingProxyDefinition getProxySpecification() {
            return NoProxySpecification.getInstance().asWebdrivingProxyDefinition();
        }

        @Nullable
        @Override
        public CertificateAndKeySource getCertificateAndKeySource() {
            return null;
        }

        @Override
        public String toString() {
            return "WebdrivingConfig{INACTIVE}";
        }
    };

    /**
     * Returns an immutable empty config instance.
     * @return an empty config instance.
     */
    public static WebdrivingConfig empty() {
        return EMPTY;
    }

    /**
     * @deprecated use {@link WebdrivingConfig#builder()}
     */
    @Deprecated
    public static WebdrivingConfig.Builder builder() {
        return WebdrivingConfig.builder();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy