class EnvironmentDriver implements Driver {

    @Override
    public Connection connect(String url, Properties info) throws SQLException {
        String name = url.substring("jdbc:environment:".length());
        String delegateUrl = null;
        Properties delegateProperties = new Properties();
        for(String key : System.getenv().keySet()) {
            if (key.startsWith("PIRANHA_ENVIRONMENT." + name + ".URL")) {
                delegateUrl = System.getenv("PIRANHA_ENVIRONMENT." + name + ".URL");
            }
        }
        Driver driver = DriverManager.getDriver(delegateUrl);
        return driver.connect(delegateUrl, delegateProperties);
    }

    public  EnvironmentDriver();

}