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

net.lightbody.bmp.proxy.guice.LegacyProxyServerProvider Maven / Gradle / Ivy

There is a newer version: 2.1.5
Show newest version
package net.lightbody.bmp.proxy.guice;

import com.google.inject.Provider;
import net.lightbody.bmp.BrowserMobProxyServerLegacyAdapter;
import net.lightbody.bmp.proxy.LegacyProxyServer;
import net.lightbody.bmp.proxy.ProxyServer;

public class LegacyProxyServerProvider implements Provider {
    // temporary, until REST API is replaced
    public static volatile boolean useLittleProxy = false;

    @Override
    public LegacyProxyServer get() {
        if (useLittleProxy || Boolean.getBoolean("bmp.use.littleproxy")) {
            return new BrowserMobProxyServerLegacyAdapter();
        } else {
            return new ProxyServer();
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy