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

com.metamx.emitter.core.ParametrizedUriEmitterConfig Maven / Gradle / Ivy

There is a newer version: 1.3.8
Show newest version
package com.metamx.emitter.core;

import com.fasterxml.jackson.annotation.JsonProperty;

import javax.validation.constraints.NotNull;

public class ParametrizedUriEmitterConfig
{
  private static final BaseHttpEmittingConfig DEFAULT_HTTP_EMITTING_CONFIG = new BaseHttpEmittingConfig();

  @NotNull
  @JsonProperty
  private String recipientBaseUrlPattern;

  @JsonProperty("httpEmitting")
  private BaseHttpEmittingConfig httpEmittingConfig = DEFAULT_HTTP_EMITTING_CONFIG;

  public String getRecipientBaseUrlPattern()
  {
    return recipientBaseUrlPattern;
  }

  public HttpEmitterConfig buildHttpEmitterConfig(String baseUri)
  {
    return new HttpEmitterConfig(httpEmittingConfig, baseUri);
  }

  @Override
  public String toString()
  {
    return "ParametrizedUriEmitterConfig{" +
           "recipientBaseUrlPattern='" + recipientBaseUrlPattern + '\'' +
           ", httpEmittingConfig=" + httpEmittingConfig +
           '}';
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy