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

ca.gc.aafc.dina.repository.GoneException Maven / Gradle / Ivy

There is a newer version: 0.132
Show newest version
package ca.gc.aafc.dina.repository;

import io.crnk.core.engine.document.ErrorData;
import io.crnk.core.exception.CrnkMappableException;

/**
 * Crnk Exception for HTTP 410 : GONE
 *
 */
public class GoneException extends CrnkMappableException {

  private static final long serialVersionUID = 2658981047986565140L;

  public GoneException(String title, String message) {
    this(title, message, null);
  }

  public GoneException(String title, String message, String link) {
    super(410, ErrorData.builder()
      .setTitle(title)
      .setDetail(message)
      .setStatus("410")
      .setAboutLink(link)
      .build());
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy