Skip to content

Instantly share code, notes, and snippets.

Created September 10, 2018 19:31
What would you like to do?
public class ApiError {
private LocalDateTime timestamp;
private String error;
private int errorCode;
private List<ErrorCause> causes;
private ApiError(LocalDateTime timestamp, String error, int errorCode, List<ErrorCause> causes) {
this.timestamp = timestamp == null? timestamp ;
this.error = error == null? "": error;
this.errorCode = errorCode;
this.causes = causes == null? Collections.emptyList(): causes;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment