package de.thedevstack.conversationsplus.services.filetransfer; /** * */ public enum FileTransferFailureType { RECOVERABLE(Integer.MAX_VALUE), LIMITEDRECOVERABLE(5), NONRECOVERABLE(1); int maxAttempts; FileTransferFailureType(int maxAttempts) { this.maxAttempts = maxAttempts; } public boolean isRetryPossible(int attempt) { return attempt < this.maxAttempts; } public int getMaxAttempts() { return this.maxAttempts; } }