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

com.recurly.v3.ClientOptions Maven / Gradle / Ivy

There is a newer version: 4.58.0
Show newest version
package com.recurly.v3;
import java.util.HashMap;

public class ClientOptions {

  public enum Regions {
    US,
    EU
  };

  private static final HashMap regionsMap = new HashMap<>();
  static {
      regionsMap.put(Regions.US, "https://v3.recurly.com");
      regionsMap.put(Regions.EU, "https://v3.eu.recurly.com");
  }

  private Regions region;

  public ClientOptions() {
    this.region = Regions.US;
  }

  public void setRegion(Regions r) {
    this.region = r;
  }

  /** BaseUrl is determined by the region */
  public String getBaseUrl() {
    return regionsMap.get(this.region);
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy